From 95909d1b02a29bbe12e4abe5e12178d273425ebc Mon Sep 17 00:00:00 2001 From: Neenu1995 Date: Thu, 26 Aug 2021 17:43:46 -0400 Subject: [PATCH 1/3] feat: generate java files for error_reason.proto, bigquery_audit_metadata.proto and localized_text.proto --- .github/release-trigger.yml | 1 + .github/workflows/ci.yaml | 15 +- .kokoro/build.sh | 2 +- .kokoro/nightly/integration.cfg | 2 +- .kokoro/nightly/samples.cfg | 2 +- .../main/java/com/google/api/ErrorReason.java | 1071 + .../java/com/google/api/ErrorReasonProto.java | 64 + .../cloud/audit/BigQueryAuditMetadata.java | 67540 ++++++++++++++++ .../audit/BigQueryAuditMetadataOrBuilder.java | 667 + .../audit/BigQueryAuditMetadataProto.java | 1033 + .../java/com/google/type/LocalizedText.java | 821 + .../google/type/LocalizedTextOrBuilder.java | 79 + .../com/google/type/LocalizedTextProto.java | 63 + .../cloud/audit/bigquery_audit_metadata.proto | 1184 + synth.metadata | 380 +- 15 files changed, 72531 insertions(+), 393 deletions(-) create mode 100644 .github/release-trigger.yml create mode 100644 proto-google-common-protos/src/main/java/com/google/api/ErrorReason.java create mode 100644 proto-google-common-protos/src/main/java/com/google/api/ErrorReasonProto.java create mode 100644 proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadata.java create mode 100644 proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataOrBuilder.java create mode 100644 proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataProto.java create mode 100644 proto-google-common-protos/src/main/java/com/google/type/LocalizedText.java create mode 100644 proto-google-common-protos/src/main/java/com/google/type/LocalizedTextOrBuilder.java create mode 100644 proto-google-common-protos/src/main/java/com/google/type/LocalizedTextProto.java create mode 100644 proto-google-common-protos/src/main/proto/google/cloud/audit/bigquery_audit_metadata.proto diff --git a/.github/release-trigger.yml b/.github/release-trigger.yml new file mode 100644 index 00000000..d4ca9418 --- /dev/null +++ b/.github/release-trigger.yml @@ -0,0 +1 @@ +enabled: true diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 0195b32f..d510359d 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - java: [7, 8, 11] + java: [8, 11] steps: - uses: actions/checkout@v2 - uses: actions/setup-java@v1 @@ -42,19 +42,6 @@ jobs: java-version: ${{matrix.java}} - 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 - - name: Install artifacts to local Maven repository - run: .kokoro/build.sh - shell: bash - - name: Validate any conflicts with regard to com.google.cloud:libraries-bom (latest release) - uses: GoogleCloudPlatform/cloud-opensource-java/linkage-monitor@v1-linkagemonitor lint: runs-on: ubuntu-latest steps: diff --git a/.kokoro/build.sh b/.kokoro/build.sh index c1c9a337..75da3504 100755 --- a/.kokoro/build.sh +++ b/.kokoro/build.sh @@ -115,7 +115,7 @@ fi # fix output location of logs bash .kokoro/coerce_logs.sh -if [[ "${ENABLE_BUILD_COP}" == "true" ]] +if [[ "${ENABLE_FLAKYBOT}" == "true" ]] then chmod +x ${KOKORO_GFILE_DIR}/linux_amd64/flakybot ${KOKORO_GFILE_DIR}/linux_amd64/flakybot -repo=googleapis/java-common-protos diff --git a/.kokoro/nightly/integration.cfg b/.kokoro/nightly/integration.cfg index 0048c8ec..e51c7b4c 100644 --- a/.kokoro/nightly/integration.cfg +++ b/.kokoro/nightly/integration.cfg @@ -22,7 +22,7 @@ env_vars: { } env_vars: { - key: "ENABLE_BUILD_COP" + key: "ENABLE_FLAKYBOT" value: "true" } diff --git a/.kokoro/nightly/samples.cfg b/.kokoro/nightly/samples.cfg index f2542931..9761fd86 100644 --- a/.kokoro/nightly/samples.cfg +++ b/.kokoro/nightly/samples.cfg @@ -33,6 +33,6 @@ env_vars: { } env_vars: { - key: "ENABLE_BUILD_COP" + key: "ENABLE_FLAKYBOT" value: "true" } diff --git a/proto-google-common-protos/src/main/java/com/google/api/ErrorReason.java b/proto-google-common-protos/src/main/java/com/google/api/ErrorReason.java new file mode 100644 index 00000000..64f38c1c --- /dev/null +++ b/proto-google-common-protos/src/main/java/com/google/api/ErrorReason.java @@ -0,0 +1,1071 @@ +/* + * 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/api/error_reason.proto + +package com.google.api; + +/** + * + * + *
+ * Defines the supported values for `google.rpc.ErrorInfo.reason` for the
+ * `googleapis.com` error domain. This error domain is reserved for [Service
+ * Infrastructure](https://cloud.google.com/service-infrastructure/docs/overview).
+ * For each error info of this domain, the metadata key "service" refers to the
+ * logical identifier of an API service, such as "pubsub.googleapis.com". The
+ * "consumer" refers to the entity that consumes an API Service. It typically is
+ * a Google project that owns the client application or the server resource,
+ * such as "projects/123". Other metadata keys are specific to each error
+ * reason. For more information, see the definition of the specific error
+ * reason.
+ * 
+ * + * Protobuf enum {@code google.api.ErrorReason} + */ +public enum ErrorReason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Do not use this default value.
+   * 
+ * + * ERROR_REASON_UNSPECIFIED = 0; + */ + ERROR_REASON_UNSPECIFIED(0), + /** + * + * + *
+   * The request is calling a disabled service for a consumer.
+   * Example of an ErrorInfo when the consumer "projects/123" contacting
+   * "pubsub.googleapis.com" service which is disabled:
+   *     { "reason": "SERVICE_DISABLED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "pubsub.googleapis.com"
+   *       }
+   *     }
+   * This response indicates the "pubsub.googleapis.com" has been disabled in
+   * "projects/123".
+   * 
+ * + * SERVICE_DISABLED = 1; + */ + SERVICE_DISABLED(1), + /** + * + * + *
+   * The request whose associated billing account is disabled.
+   * Example of an ErrorInfo when the consumer "projects/123" fails to contact
+   * "pubsub.googleapis.com" service because the associated billing account is
+   * disabled:
+   *     { "reason": "BILLING_DISABLED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "pubsub.googleapis.com"
+   *       }
+   *     }
+   * This response indicates the billing account associated has been disabled.
+   * 
+ * + * BILLING_DISABLED = 2; + */ + BILLING_DISABLED(2), + /** + * + * + *
+   * The request is denied because the provided [API
+   * key](https://cloud.google.com/docs/authentication/api-keys) is invalid. It
+   * may be in a bad format, cannot be found, or has been expired).
+   * Example of an ErrorInfo when the request is contacting
+   * "storage.googleapis.com" service with an invalid API key:
+   *     { "reason": "API_KEY_INVALID",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "service": "storage.googleapis.com",
+   *       }
+   *     }
+   * 
+ * + * API_KEY_INVALID = 3; + */ + API_KEY_INVALID(3), + /** + * + * + *
+   * The request is denied because it violates [API key API
+   * restrictions](https://cloud.google.com/docs/authentication/api-keys#adding_api_restrictions).
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call the
+   * "storage.googleapis.com" service because this service is restricted in the
+   * API key:
+   *     { "reason": "API_KEY_SERVICE_BLOCKED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * API_KEY_SERVICE_BLOCKED = 4; + */ + API_KEY_SERVICE_BLOCKED(4), + /** + * + * + *
+   * The request is denied because it violates [API key HTTP
+   * restrictions](https://cloud.google.com/docs/authentication/api-keys#adding_http_restrictions).
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call
+   * "storage.googleapis.com" service because the http referrer of the request
+   * violates API key HTTP restrictions:
+   *     { "reason": "API_KEY_HTTP_REFERRER_BLOCKED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com",
+   *       }
+   *     }
+   * 
+ * + * API_KEY_HTTP_REFERRER_BLOCKED = 7; + */ + API_KEY_HTTP_REFERRER_BLOCKED(7), + /** + * + * + *
+   * The request is denied because it violates [API key IP address
+   * restrictions](https://cloud.google.com/docs/authentication/api-keys#adding_application_restrictions).
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call
+   * "storage.googleapis.com" service because the caller IP of the request
+   * violates API key IP address restrictions:
+   *     { "reason": "API_KEY_IP_ADDRESS_BLOCKED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com",
+   *       }
+   *     }
+   * 
+ * + * API_KEY_IP_ADDRESS_BLOCKED = 8; + */ + API_KEY_IP_ADDRESS_BLOCKED(8), + /** + * + * + *
+   * The request is denied because it violates [API key Android application
+   * restrictions](https://cloud.google.com/docs/authentication/api-keys#adding_application_restrictions).
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call
+   * "storage.googleapis.com" service because the request from the Android apps
+   * violates the API key Android application restrictions:
+   *     { "reason": "API_KEY_ANDROID_APP_BLOCKED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * API_KEY_ANDROID_APP_BLOCKED = 9; + */ + API_KEY_ANDROID_APP_BLOCKED(9), + /** + * + * + *
+   * The request is denied because it violates [API key iOS application
+   * restrictions](https://cloud.google.com/docs/authentication/api-keys#adding_application_restrictions).
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call
+   * "storage.googleapis.com" service because the request from the iOS apps
+   * violates the API key iOS application restrictions:
+   *     { "reason": "API_KEY_IOS_APP_BLOCKED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * API_KEY_IOS_APP_BLOCKED = 13; + */ + API_KEY_IOS_APP_BLOCKED(13), + /** + * + * + *
+   * The request is denied because there is not enough rate quota for the
+   * consumer.
+   * Example of an ErrorInfo when the consumer "projects/123" fails to contact
+   * "pubsub.googleapis.com" service because consumer's rate quota usage has
+   * reached the maximum value set for the quota limit
+   * "ReadsPerMinutePerProject" on the quota metric
+   * "pubsub.googleapis.com/read_requests":
+   *     { "reason": "RATE_LIMIT_EXCEEDED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "pubsub.googleapis.com",
+   *         "quota_metric": "pubsub.googleapis.com/read_requests",
+   *         "quota_limit": "ReadsPerMinutePerProject"
+   *       }
+   *     }
+   * Example of an ErrorInfo when the consumer "projects/123" checks quota on
+   * the service "dataflow.googleapis.com" and hits the organization quota
+   * limit "DefaultRequestsPerMinutePerOrganization" on the metric
+   * "dataflow.googleapis.com/default_requests".
+   *     { "reason": "RATE_LIMIT_EXCEEDED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "dataflow.googleapis.com",
+   *         "quota_metric": "dataflow.googleapis.com/default_requests",
+   *         "quota_limit": "DefaultRequestsPerMinutePerOrganization"
+   *       }
+   *     }
+   * 
+ * + * RATE_LIMIT_EXCEEDED = 5; + */ + RATE_LIMIT_EXCEEDED(5), + /** + * + * + *
+   * The request is denied because there is not enough resource quota for the
+   * consumer.
+   * Example of an ErrorInfo when the consumer "projects/123" fails to contact
+   * "compute.googleapis.com" service because consumer's resource quota usage
+   * has reached the maximum value set for the quota limit "VMsPerProject"
+   * on the quota metric "compute.googleapis.com/vms":
+   *     { "reason": "RESOURCE_QUOTA_EXCEEDED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "compute.googleapis.com",
+   *         "quota_metric": "compute.googleapis.com/vms",
+   *         "quota_limit": "VMsPerProject"
+   *       }
+   *     }
+   * Example of an ErrorInfo when the consumer "projects/123" checks resource
+   * quota on the service "dataflow.googleapis.com" and hits the organization
+   * quota limit "jobs-per-organization" on the metric
+   * "dataflow.googleapis.com/job_count".
+   *     { "reason": "RESOURCE_QUOTA_EXCEEDED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "dataflow.googleapis.com",
+   *         "quota_metric": "dataflow.googleapis.com/job_count",
+   *         "quota_limit": "jobs-per-organization"
+   *       }
+   *     }
+   * 
+ * + * RESOURCE_QUOTA_EXCEEDED = 6; + */ + RESOURCE_QUOTA_EXCEEDED(6), + /** + * + * + *
+   * The request whose associated billing account address is in a tax restricted
+   * location, violates the local tax restrictions when creating resources in
+   * the restricted region.
+   * Example of an ErrorInfo when creating the Cloud Storage Bucket in the
+   * container "projects/123" under a tax restricted region
+   * "locations/asia-northeast3":
+   *     { "reason": "LOCATION_TAX_POLICY_VIOLATED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com",
+   *         "location": "locations/asia-northeast3"
+   *       }
+   *     }
+   * This response indicates creating the Cloud Storage Bucket in
+   * "locations/asia-northeast3" violates the location tax restriction.
+   * 
+ * + * LOCATION_TAX_POLICY_VIOLATED = 10; + */ + LOCATION_TAX_POLICY_VIOLATED(10), + /** + * + * + *
+   * The request is denied because the caller does not have required permission
+   * on the user project "projects/123" or the user project is invalid. For more
+   * information, check the [userProject System
+   * Parameters](https://cloud.google.com/apis/docs/system-parameters).
+   * Example of an ErrorInfo when the caller is calling Cloud Storage service
+   * with insufficient permissions on the user project:
+   *     { "reason": "USER_PROJECT_DENIED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * USER_PROJECT_DENIED = 11; + */ + USER_PROJECT_DENIED(11), + /** + * + * + *
+   * The request is denied because the consumer "projects/123" is suspended due
+   * to Terms of Service(Tos) violations. Check [Project suspension
+   * guidelines](https://cloud.google.com/resource-manager/docs/project-suspension-guidelines)
+   * for more information.
+   * Example of an ErrorInfo when calling Cloud Storage service with the
+   * suspended consumer "projects/123":
+   *     { "reason": "CONSUMER_SUSPENDED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * CONSUMER_SUSPENDED = 12; + */ + CONSUMER_SUSPENDED(12), + /** + * + * + *
+   * The request is denied because the associated consumer is invalid. It may be
+   * in a bad format, cannot be found, or have been deleted.
+   * Example of an ErrorInfo when calling Cloud Storage service with the
+   * invalid consumer "projects/123":
+   *     { "reason": "CONSUMER_INVALID",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * CONSUMER_INVALID = 14; + */ + CONSUMER_INVALID(14), + /** + * + * + *
+   * The request is denied because it violates [VPC Service
+   * Controls](https://cloud.google.com/vpc-service-controls/docs/overview).
+   * The 'uid' field is a random generated identifier that customer can use it
+   * to search the audit log for a request rejected by VPC Service Controls. For
+   * more information, please refer [VPC Service Controls
+   * Troubleshooting](https://cloud.google.com/vpc-service-controls/docs/troubleshooting#unique-id)
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call
+   * Cloud Storage service because the request is prohibited by the VPC Service
+   * Controls.
+   *     { "reason": "SECURITY_POLICY_VIOLATED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "uid": "123456789abcde",
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * SECURITY_POLICY_VIOLATED = 15; + */ + SECURITY_POLICY_VIOLATED(15), + /** + * + * + *
+   * The request is denied because the provided access token has expired.
+   * Example of an ErrorInfo when the request is calling Cloud Storage service
+   * with an expired access token:
+   *     { "reason": "ACCESS_TOKEN_EXPIRED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "service": "storage.googleapis.com",
+   *         "method": "google.storage.v1.Storage.GetObject"
+   *       }
+   *     }
+   * 
+ * + * ACCESS_TOKEN_EXPIRED = 16; + */ + ACCESS_TOKEN_EXPIRED(16), + /** + * + * + *
+   * The request is denied because the provided access token doesn't have at
+   * least one of the acceptable scopes required for the API. Please check
+   * [OAuth 2.0 Scopes for Google
+   * APIs](https://developers.google.com/identity/protocols/oauth2/scopes) for
+   * the list of the OAuth 2.0 scopes that you might need to request to access
+   * the API.
+   * Example of an ErrorInfo when the request is calling Cloud Storage service
+   * with an access token that is missing required scopes:
+   *     { "reason": "ACCESS_TOKEN_SCOPE_INSUFFICIENT",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "service": "storage.googleapis.com",
+   *         "method": "google.storage.v1.Storage.GetObject"
+   *       }
+   *     }
+   * 
+ * + * ACCESS_TOKEN_SCOPE_INSUFFICIENT = 17; + */ + ACCESS_TOKEN_SCOPE_INSUFFICIENT(17), + /** + * + * + *
+   * The request is denied because the account associated with the provided
+   * access token is in an invalid state, such as disabled or deleted.
+   * For more information, see https://cloud.google.com/docs/authentication.
+   * Warning: For privacy reasons, the server may not be able to disclose the
+   * email address for some accounts. The client MUST NOT depend on the
+   * availability of the `email` attribute.
+   * Example of an ErrorInfo when the request is to the Cloud Storage API with
+   * an access token that is associated with a disabled or deleted [service
+   * account](http://cloud/iam/docs/service-accounts):
+   *     { "reason": "ACCOUNT_STATE_INVALID",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "service": "storage.googleapis.com",
+   *         "method": "google.storage.v1.Storage.GetObject",
+   *         "email": "user@123.iam.gserviceaccount.com"
+   *       }
+   *     }
+   * 
+ * + * ACCOUNT_STATE_INVALID = 18; + */ + ACCOUNT_STATE_INVALID(18), + /** + * + * + *
+   * The request is denied because the type of the provided access token is not
+   * supported by the API being called.
+   * Example of an ErrorInfo when the request is to the Cloud Storage API with
+   * an unsupported token type.
+   *     { "reason": "ACCESS_TOKEN_TYPE_UNSUPPORTED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "service": "storage.googleapis.com",
+   *         "method": "google.storage.v1.Storage.GetObject"
+   *       }
+   *     }
+   * 
+ * + * ACCESS_TOKEN_TYPE_UNSUPPORTED = 19; + */ + ACCESS_TOKEN_TYPE_UNSUPPORTED(19), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+   * Do not use this default value.
+   * 
+ * + * ERROR_REASON_UNSPECIFIED = 0; + */ + public static final int ERROR_REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+   * The request is calling a disabled service for a consumer.
+   * Example of an ErrorInfo when the consumer "projects/123" contacting
+   * "pubsub.googleapis.com" service which is disabled:
+   *     { "reason": "SERVICE_DISABLED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "pubsub.googleapis.com"
+   *       }
+   *     }
+   * This response indicates the "pubsub.googleapis.com" has been disabled in
+   * "projects/123".
+   * 
+ * + * SERVICE_DISABLED = 1; + */ + public static final int SERVICE_DISABLED_VALUE = 1; + /** + * + * + *
+   * The request whose associated billing account is disabled.
+   * Example of an ErrorInfo when the consumer "projects/123" fails to contact
+   * "pubsub.googleapis.com" service because the associated billing account is
+   * disabled:
+   *     { "reason": "BILLING_DISABLED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "pubsub.googleapis.com"
+   *       }
+   *     }
+   * This response indicates the billing account associated has been disabled.
+   * 
+ * + * BILLING_DISABLED = 2; + */ + public static final int BILLING_DISABLED_VALUE = 2; + /** + * + * + *
+   * The request is denied because the provided [API
+   * key](https://cloud.google.com/docs/authentication/api-keys) is invalid. It
+   * may be in a bad format, cannot be found, or has been expired).
+   * Example of an ErrorInfo when the request is contacting
+   * "storage.googleapis.com" service with an invalid API key:
+   *     { "reason": "API_KEY_INVALID",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "service": "storage.googleapis.com",
+   *       }
+   *     }
+   * 
+ * + * API_KEY_INVALID = 3; + */ + public static final int API_KEY_INVALID_VALUE = 3; + /** + * + * + *
+   * The request is denied because it violates [API key API
+   * restrictions](https://cloud.google.com/docs/authentication/api-keys#adding_api_restrictions).
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call the
+   * "storage.googleapis.com" service because this service is restricted in the
+   * API key:
+   *     { "reason": "API_KEY_SERVICE_BLOCKED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * API_KEY_SERVICE_BLOCKED = 4; + */ + public static final int API_KEY_SERVICE_BLOCKED_VALUE = 4; + /** + * + * + *
+   * The request is denied because it violates [API key HTTP
+   * restrictions](https://cloud.google.com/docs/authentication/api-keys#adding_http_restrictions).
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call
+   * "storage.googleapis.com" service because the http referrer of the request
+   * violates API key HTTP restrictions:
+   *     { "reason": "API_KEY_HTTP_REFERRER_BLOCKED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com",
+   *       }
+   *     }
+   * 
+ * + * API_KEY_HTTP_REFERRER_BLOCKED = 7; + */ + public static final int API_KEY_HTTP_REFERRER_BLOCKED_VALUE = 7; + /** + * + * + *
+   * The request is denied because it violates [API key IP address
+   * restrictions](https://cloud.google.com/docs/authentication/api-keys#adding_application_restrictions).
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call
+   * "storage.googleapis.com" service because the caller IP of the request
+   * violates API key IP address restrictions:
+   *     { "reason": "API_KEY_IP_ADDRESS_BLOCKED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com",
+   *       }
+   *     }
+   * 
+ * + * API_KEY_IP_ADDRESS_BLOCKED = 8; + */ + public static final int API_KEY_IP_ADDRESS_BLOCKED_VALUE = 8; + /** + * + * + *
+   * The request is denied because it violates [API key Android application
+   * restrictions](https://cloud.google.com/docs/authentication/api-keys#adding_application_restrictions).
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call
+   * "storage.googleapis.com" service because the request from the Android apps
+   * violates the API key Android application restrictions:
+   *     { "reason": "API_KEY_ANDROID_APP_BLOCKED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * API_KEY_ANDROID_APP_BLOCKED = 9; + */ + public static final int API_KEY_ANDROID_APP_BLOCKED_VALUE = 9; + /** + * + * + *
+   * The request is denied because it violates [API key iOS application
+   * restrictions](https://cloud.google.com/docs/authentication/api-keys#adding_application_restrictions).
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call
+   * "storage.googleapis.com" service because the request from the iOS apps
+   * violates the API key iOS application restrictions:
+   *     { "reason": "API_KEY_IOS_APP_BLOCKED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * API_KEY_IOS_APP_BLOCKED = 13; + */ + public static final int API_KEY_IOS_APP_BLOCKED_VALUE = 13; + /** + * + * + *
+   * The request is denied because there is not enough rate quota for the
+   * consumer.
+   * Example of an ErrorInfo when the consumer "projects/123" fails to contact
+   * "pubsub.googleapis.com" service because consumer's rate quota usage has
+   * reached the maximum value set for the quota limit
+   * "ReadsPerMinutePerProject" on the quota metric
+   * "pubsub.googleapis.com/read_requests":
+   *     { "reason": "RATE_LIMIT_EXCEEDED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "pubsub.googleapis.com",
+   *         "quota_metric": "pubsub.googleapis.com/read_requests",
+   *         "quota_limit": "ReadsPerMinutePerProject"
+   *       }
+   *     }
+   * Example of an ErrorInfo when the consumer "projects/123" checks quota on
+   * the service "dataflow.googleapis.com" and hits the organization quota
+   * limit "DefaultRequestsPerMinutePerOrganization" on the metric
+   * "dataflow.googleapis.com/default_requests".
+   *     { "reason": "RATE_LIMIT_EXCEEDED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "dataflow.googleapis.com",
+   *         "quota_metric": "dataflow.googleapis.com/default_requests",
+   *         "quota_limit": "DefaultRequestsPerMinutePerOrganization"
+   *       }
+   *     }
+   * 
+ * + * RATE_LIMIT_EXCEEDED = 5; + */ + public static final int RATE_LIMIT_EXCEEDED_VALUE = 5; + /** + * + * + *
+   * The request is denied because there is not enough resource quota for the
+   * consumer.
+   * Example of an ErrorInfo when the consumer "projects/123" fails to contact
+   * "compute.googleapis.com" service because consumer's resource quota usage
+   * has reached the maximum value set for the quota limit "VMsPerProject"
+   * on the quota metric "compute.googleapis.com/vms":
+   *     { "reason": "RESOURCE_QUOTA_EXCEEDED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "compute.googleapis.com",
+   *         "quota_metric": "compute.googleapis.com/vms",
+   *         "quota_limit": "VMsPerProject"
+   *       }
+   *     }
+   * Example of an ErrorInfo when the consumer "projects/123" checks resource
+   * quota on the service "dataflow.googleapis.com" and hits the organization
+   * quota limit "jobs-per-organization" on the metric
+   * "dataflow.googleapis.com/job_count".
+   *     { "reason": "RESOURCE_QUOTA_EXCEEDED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "dataflow.googleapis.com",
+   *         "quota_metric": "dataflow.googleapis.com/job_count",
+   *         "quota_limit": "jobs-per-organization"
+   *       }
+   *     }
+   * 
+ * + * RESOURCE_QUOTA_EXCEEDED = 6; + */ + public static final int RESOURCE_QUOTA_EXCEEDED_VALUE = 6; + /** + * + * + *
+   * The request whose associated billing account address is in a tax restricted
+   * location, violates the local tax restrictions when creating resources in
+   * the restricted region.
+   * Example of an ErrorInfo when creating the Cloud Storage Bucket in the
+   * container "projects/123" under a tax restricted region
+   * "locations/asia-northeast3":
+   *     { "reason": "LOCATION_TAX_POLICY_VIOLATED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com",
+   *         "location": "locations/asia-northeast3"
+   *       }
+   *     }
+   * This response indicates creating the Cloud Storage Bucket in
+   * "locations/asia-northeast3" violates the location tax restriction.
+   * 
+ * + * LOCATION_TAX_POLICY_VIOLATED = 10; + */ + public static final int LOCATION_TAX_POLICY_VIOLATED_VALUE = 10; + /** + * + * + *
+   * The request is denied because the caller does not have required permission
+   * on the user project "projects/123" or the user project is invalid. For more
+   * information, check the [userProject System
+   * Parameters](https://cloud.google.com/apis/docs/system-parameters).
+   * Example of an ErrorInfo when the caller is calling Cloud Storage service
+   * with insufficient permissions on the user project:
+   *     { "reason": "USER_PROJECT_DENIED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * USER_PROJECT_DENIED = 11; + */ + public static final int USER_PROJECT_DENIED_VALUE = 11; + /** + * + * + *
+   * The request is denied because the consumer "projects/123" is suspended due
+   * to Terms of Service(Tos) violations. Check [Project suspension
+   * guidelines](https://cloud.google.com/resource-manager/docs/project-suspension-guidelines)
+   * for more information.
+   * Example of an ErrorInfo when calling Cloud Storage service with the
+   * suspended consumer "projects/123":
+   *     { "reason": "CONSUMER_SUSPENDED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * CONSUMER_SUSPENDED = 12; + */ + public static final int CONSUMER_SUSPENDED_VALUE = 12; + /** + * + * + *
+   * The request is denied because the associated consumer is invalid. It may be
+   * in a bad format, cannot be found, or have been deleted.
+   * Example of an ErrorInfo when calling Cloud Storage service with the
+   * invalid consumer "projects/123":
+   *     { "reason": "CONSUMER_INVALID",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * CONSUMER_INVALID = 14; + */ + public static final int CONSUMER_INVALID_VALUE = 14; + /** + * + * + *
+   * The request is denied because it violates [VPC Service
+   * Controls](https://cloud.google.com/vpc-service-controls/docs/overview).
+   * The 'uid' field is a random generated identifier that customer can use it
+   * to search the audit log for a request rejected by VPC Service Controls. For
+   * more information, please refer [VPC Service Controls
+   * Troubleshooting](https://cloud.google.com/vpc-service-controls/docs/troubleshooting#unique-id)
+   * Example of an ErrorInfo when the consumer "projects/123" fails to call
+   * Cloud Storage service because the request is prohibited by the VPC Service
+   * Controls.
+   *     { "reason": "SECURITY_POLICY_VIOLATED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "uid": "123456789abcde",
+   *         "consumer": "projects/123",
+   *         "service": "storage.googleapis.com"
+   *       }
+   *     }
+   * 
+ * + * SECURITY_POLICY_VIOLATED = 15; + */ + public static final int SECURITY_POLICY_VIOLATED_VALUE = 15; + /** + * + * + *
+   * The request is denied because the provided access token has expired.
+   * Example of an ErrorInfo when the request is calling Cloud Storage service
+   * with an expired access token:
+   *     { "reason": "ACCESS_TOKEN_EXPIRED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "service": "storage.googleapis.com",
+   *         "method": "google.storage.v1.Storage.GetObject"
+   *       }
+   *     }
+   * 
+ * + * ACCESS_TOKEN_EXPIRED = 16; + */ + public static final int ACCESS_TOKEN_EXPIRED_VALUE = 16; + /** + * + * + *
+   * The request is denied because the provided access token doesn't have at
+   * least one of the acceptable scopes required for the API. Please check
+   * [OAuth 2.0 Scopes for Google
+   * APIs](https://developers.google.com/identity/protocols/oauth2/scopes) for
+   * the list of the OAuth 2.0 scopes that you might need to request to access
+   * the API.
+   * Example of an ErrorInfo when the request is calling Cloud Storage service
+   * with an access token that is missing required scopes:
+   *     { "reason": "ACCESS_TOKEN_SCOPE_INSUFFICIENT",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "service": "storage.googleapis.com",
+   *         "method": "google.storage.v1.Storage.GetObject"
+   *       }
+   *     }
+   * 
+ * + * ACCESS_TOKEN_SCOPE_INSUFFICIENT = 17; + */ + public static final int ACCESS_TOKEN_SCOPE_INSUFFICIENT_VALUE = 17; + /** + * + * + *
+   * The request is denied because the account associated with the provided
+   * access token is in an invalid state, such as disabled or deleted.
+   * For more information, see https://cloud.google.com/docs/authentication.
+   * Warning: For privacy reasons, the server may not be able to disclose the
+   * email address for some accounts. The client MUST NOT depend on the
+   * availability of the `email` attribute.
+   * Example of an ErrorInfo when the request is to the Cloud Storage API with
+   * an access token that is associated with a disabled or deleted [service
+   * account](http://cloud/iam/docs/service-accounts):
+   *     { "reason": "ACCOUNT_STATE_INVALID",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "service": "storage.googleapis.com",
+   *         "method": "google.storage.v1.Storage.GetObject",
+   *         "email": "user@123.iam.gserviceaccount.com"
+   *       }
+   *     }
+   * 
+ * + * ACCOUNT_STATE_INVALID = 18; + */ + public static final int ACCOUNT_STATE_INVALID_VALUE = 18; + /** + * + * + *
+   * The request is denied because the type of the provided access token is not
+   * supported by the API being called.
+   * Example of an ErrorInfo when the request is to the Cloud Storage API with
+   * an unsupported token type.
+   *     { "reason": "ACCESS_TOKEN_TYPE_UNSUPPORTED",
+   *       "domain": "googleapis.com",
+   *       "metadata": {
+   *         "service": "storage.googleapis.com",
+   *         "method": "google.storage.v1.Storage.GetObject"
+   *       }
+   *     }
+   * 
+ * + * ACCESS_TOKEN_TYPE_UNSUPPORTED = 19; + */ + public static final int ACCESS_TOKEN_TYPE_UNSUPPORTED_VALUE = 19; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ErrorReason 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 ErrorReason forNumber(int value) { + switch (value) { + case 0: + return ERROR_REASON_UNSPECIFIED; + case 1: + return SERVICE_DISABLED; + case 2: + return BILLING_DISABLED; + case 3: + return API_KEY_INVALID; + case 4: + return API_KEY_SERVICE_BLOCKED; + case 7: + return API_KEY_HTTP_REFERRER_BLOCKED; + case 8: + return API_KEY_IP_ADDRESS_BLOCKED; + case 9: + return API_KEY_ANDROID_APP_BLOCKED; + case 13: + return API_KEY_IOS_APP_BLOCKED; + case 5: + return RATE_LIMIT_EXCEEDED; + case 6: + return RESOURCE_QUOTA_EXCEEDED; + case 10: + return LOCATION_TAX_POLICY_VIOLATED; + case 11: + return USER_PROJECT_DENIED; + case 12: + return CONSUMER_SUSPENDED; + case 14: + return CONSUMER_INVALID; + case 15: + return SECURITY_POLICY_VIOLATED; + case 16: + return ACCESS_TOKEN_EXPIRED; + case 17: + return ACCESS_TOKEN_SCOPE_INSUFFICIENT; + case 18: + return ACCOUNT_STATE_INVALID; + case 19: + return ACCESS_TOKEN_TYPE_UNSUPPORTED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public ErrorReason findValueByNumber(int number) { + return ErrorReason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.api.ErrorReasonProto.getDescriptor().getEnumTypes().get(0); + } + + private static final ErrorReason[] VALUES = values(); + + public static ErrorReason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private ErrorReason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.api.ErrorReason) +} diff --git a/proto-google-common-protos/src/main/java/com/google/api/ErrorReasonProto.java b/proto-google-common-protos/src/main/java/com/google/api/ErrorReasonProto.java new file mode 100644 index 00000000..9bdb05a4 --- /dev/null +++ b/proto-google-common-protos/src/main/java/com/google/api/ErrorReasonProto.java @@ -0,0 +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/api/error_reason.proto + +package com.google.api; + +public final class ErrorReasonProto { + private ErrorReasonProto() {} + + 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 com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n\035google/api/error_reason.proto\022\ngoogle." + + "api*\304\004\n\013ErrorReason\022\034\n\030ERROR_REASON_UNSP" + + "ECIFIED\020\000\022\024\n\020SERVICE_DISABLED\020\001\022\024\n\020BILLI" + + "NG_DISABLED\020\002\022\023\n\017API_KEY_INVALID\020\003\022\033\n\027AP" + + "I_KEY_SERVICE_BLOCKED\020\004\022!\n\035API_KEY_HTTP_" + + "REFERRER_BLOCKED\020\007\022\036\n\032API_KEY_IP_ADDRESS" + + "_BLOCKED\020\010\022\037\n\033API_KEY_ANDROID_APP_BLOCKE" + + "D\020\t\022\033\n\027API_KEY_IOS_APP_BLOCKED\020\r\022\027\n\023RATE" + + "_LIMIT_EXCEEDED\020\005\022\033\n\027RESOURCE_QUOTA_EXCE" + + "EDED\020\006\022 \n\034LOCATION_TAX_POLICY_VIOLATED\020\n" + + "\022\027\n\023USER_PROJECT_DENIED\020\013\022\026\n\022CONSUMER_SU" + + "SPENDED\020\014\022\024\n\020CONSUMER_INVALID\020\016\022\034\n\030SECUR" + + "ITY_POLICY_VIOLATED\020\017\022\030\n\024ACCESS_TOKEN_EX" + + "PIRED\020\020\022#\n\037ACCESS_TOKEN_SCOPE_INSUFFICIE" + + "NT\020\021\022\031\n\025ACCOUNT_STATE_INVALID\020\022\022!\n\035ACCES" + + "S_TOKEN_TYPE_UNSUPPORTED\020\023Bp\n\016com.google" + + ".apiB\020ErrorReasonProtoP\001ZCgoogle.golang." + + "org/genproto/googleapis/api/error_reason" + + ";error_reason\242\002\004GAPIb\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, new com.google.protobuf.Descriptors.FileDescriptor[] {}); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadata.java b/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadata.java new file mode 100644 index 00000000..2a70955f --- /dev/null +++ b/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadata.java @@ -0,0 +1,67540 @@ +/* + * 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/cloud/audit/bigquery_audit_metadata.proto + +package com.google.cloud.audit; + +/** + * + * + *
+ * Audit log format for BigQuery cloud audit logs metadata.
+ * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata} + */ +public final class BigQueryAuditMetadata extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata) + BigQueryAuditMetadataOrBuilder { + private static final long serialVersionUID = 0L; + // Use BigQueryAuditMetadata.newBuilder() to construct. + private BigQueryAuditMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private BigQueryAuditMetadata() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new BigQueryAuditMetadata(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private BigQueryAuditMetadata( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder subBuilder = null; + if (eventCase_ == 1) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 1; + break; + } + case 18: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder subBuilder = null; + if (eventCase_ == 2) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_).toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 2; + break; + } + case 26: + { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder subBuilder = + null; + if (eventCase_ == 3) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 3; + break; + } + case 34: + { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder subBuilder = null; + if (eventCase_ == 4) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 4; + break; + } + case 42: + { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder subBuilder = + null; + if (eventCase_ == 5) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 5; + break; + } + case 50: + { + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder subBuilder = null; + if (eventCase_ == 6) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 6; + break; + } + case 66: + { + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder subBuilder = null; + if (eventCase_ == 8) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_).toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 8; + break; + } + case 74: + { + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder subBuilder = null; + if (eventCase_ == 9) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 9; + break; + } + case 82: + { + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder subBuilder = null; + if (eventCase_ == 10) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 10; + break; + } + case 90: + { + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder subBuilder = + null; + if (eventCase_ == 11) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 11; + break; + } + case 98: + { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder subBuilder = null; + if (eventCase_ == 12) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 12; + break; + } + case 106: + { + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder subBuilder = null; + if (eventCase_ == 13) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 13; + break; + } + case 114: + { + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder subBuilder = + null; + if (eventCase_ == 14) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 14; + break; + } + case 122: + { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder subBuilder = + null; + if (eventCase_ == 15) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 15; + break; + } + case 130: + { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder subBuilder = + null; + if (eventCase_ == 16) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 16; + break; + } + case 138: + { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder subBuilder = null; + if (eventCase_ == 17) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 17; + break; + } + case 146: + { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder subBuilder = + null; + if (eventCase_ == 18) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 18; + break; + } + case 154: + { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder subBuilder = null; + if (eventCase_ == 19) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_) + .toBuilder(); + } + event_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_); + event_ = subBuilder.buildPartial(); + } + eventCase_ = 19; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.class, + com.google.cloud.audit.BigQueryAuditMetadata.Builder.class); + } + + /** + * + * + *
+   * Describes whether a job should overwrite or append the existing destination
+   * table if it already exists.
+   * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.WriteDisposition} + */ + public enum WriteDisposition implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unknown.
+     * 
+ * + * WRITE_DISPOSITION_UNSPECIFIED = 0; + */ + WRITE_DISPOSITION_UNSPECIFIED(0), + /** + * + * + *
+     * This job should only be writing to empty tables.
+     * 
+ * + * WRITE_EMPTY = 1; + */ + WRITE_EMPTY(1), + /** + * + * + *
+     * This job will truncate the existing table data.
+     * 
+ * + * WRITE_TRUNCATE = 2; + */ + WRITE_TRUNCATE(2), + /** + * + * + *
+     * This job will append to the table.
+     * 
+ * + * WRITE_APPEND = 3; + */ + WRITE_APPEND(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Unknown.
+     * 
+ * + * WRITE_DISPOSITION_UNSPECIFIED = 0; + */ + public static final int WRITE_DISPOSITION_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * This job should only be writing to empty tables.
+     * 
+ * + * WRITE_EMPTY = 1; + */ + public static final int WRITE_EMPTY_VALUE = 1; + /** + * + * + *
+     * This job will truncate the existing table data.
+     * 
+ * + * WRITE_TRUNCATE = 2; + */ + public static final int WRITE_TRUNCATE_VALUE = 2; + /** + * + * + *
+     * This job will append to the table.
+     * 
+ * + * WRITE_APPEND = 3; + */ + public static final int WRITE_APPEND_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static WriteDisposition 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 WriteDisposition forNumber(int value) { + switch (value) { + case 0: + return WRITE_DISPOSITION_UNSPECIFIED; + case 1: + return WRITE_EMPTY; + case 2: + return WRITE_TRUNCATE; + case 3: + return WRITE_APPEND; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public WriteDisposition findValueByNumber(int number) { + return WriteDisposition.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.getDescriptor().getEnumTypes().get(0); + } + + private static final WriteDisposition[] VALUES = values(); + + public static WriteDisposition valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private WriteDisposition(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.WriteDisposition) + } + + /** + * + * + *
+   * Table copy job operation type.
+   * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.OperationType} + */ + public enum OperationType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unspecified operation type.
+     * 
+ * + * OPERATION_TYPE_UNSPECIFIED = 0; + */ + OPERATION_TYPE_UNSPECIFIED(0), + /** + * + * + *
+     * The source and the destination table have the same table type.
+     * 
+ * + * COPY = 1; + */ + COPY(1), + /** + * + * + *
+     * The source table type is TABLE and
+     * the destination table type is SNAPSHOT.
+     * 
+ * + * SNAPSHOT = 2; + */ + SNAPSHOT(2), + /** + * + * + *
+     * The source table type is SNAPSHOT and
+     * the destination table type is TABLE.
+     * 
+ * + * RESTORE = 3; + */ + RESTORE(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Unspecified operation type.
+     * 
+ * + * OPERATION_TYPE_UNSPECIFIED = 0; + */ + public static final int OPERATION_TYPE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * The source and the destination table have the same table type.
+     * 
+ * + * COPY = 1; + */ + public static final int COPY_VALUE = 1; + /** + * + * + *
+     * The source table type is TABLE and
+     * the destination table type is SNAPSHOT.
+     * 
+ * + * SNAPSHOT = 2; + */ + public static final int SNAPSHOT_VALUE = 2; + /** + * + * + *
+     * The source table type is SNAPSHOT and
+     * the destination table type is TABLE.
+     * 
+ * + * RESTORE = 3; + */ + public static final int RESTORE_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OperationType 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 OperationType forNumber(int value) { + switch (value) { + case 0: + return OPERATION_TYPE_UNSPECIFIED; + case 1: + return COPY; + case 2: + return SNAPSHOT; + case 3: + return RESTORE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public OperationType findValueByNumber(int number) { + return OperationType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.getDescriptor().getEnumTypes().get(1); + } + + private static final OperationType[] VALUES = values(); + + public static OperationType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private OperationType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.OperationType) + } + + /** + * + * + *
+   * Describes whether a job should create a destination table if it doesn't
+   * exist.
+   * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.CreateDisposition} + */ + public enum CreateDisposition implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unknown.
+     * 
+ * + * CREATE_DISPOSITION_UNSPECIFIED = 0; + */ + CREATE_DISPOSITION_UNSPECIFIED(0), + /** + * + * + *
+     * This job should never create tables.
+     * 
+ * + * CREATE_NEVER = 1; + */ + CREATE_NEVER(1), + /** + * + * + *
+     * This job should create a table if it doesn't already exist.
+     * 
+ * + * CREATE_IF_NEEDED = 2; + */ + CREATE_IF_NEEDED(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Unknown.
+     * 
+ * + * CREATE_DISPOSITION_UNSPECIFIED = 0; + */ + public static final int CREATE_DISPOSITION_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * This job should never create tables.
+     * 
+ * + * CREATE_NEVER = 1; + */ + public static final int CREATE_NEVER_VALUE = 1; + /** + * + * + *
+     * This job should create a table if it doesn't already exist.
+     * 
+ * + * CREATE_IF_NEEDED = 2; + */ + public static final int CREATE_IF_NEEDED_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static CreateDisposition 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 CreateDisposition forNumber(int value) { + switch (value) { + case 0: + return CREATE_DISPOSITION_UNSPECIFIED; + case 1: + return CREATE_NEVER; + case 2: + return CREATE_IF_NEEDED; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public CreateDisposition findValueByNumber(int number) { + return CreateDisposition.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.getDescriptor().getEnumTypes().get(2); + } + + private static final CreateDisposition[] VALUES = values(); + + public static CreateDisposition valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private CreateDisposition(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.CreateDisposition) + } + + /** + * + * + *
+   * State of a job.
+   * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.JobState} + */ + public enum JobState implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * State unknown.
+     * 
+ * + * JOB_STATE_UNSPECIFIED = 0; + */ + JOB_STATE_UNSPECIFIED(0), + /** + * + * + *
+     * Job is waiting for the resources.
+     * 
+ * + * PENDING = 1; + */ + PENDING(1), + /** + * + * + *
+     * Job is running.
+     * 
+ * + * RUNNING = 2; + */ + RUNNING(2), + /** + * + * + *
+     * Job is done.
+     * 
+ * + * DONE = 3; + */ + DONE(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * State unknown.
+     * 
+ * + * JOB_STATE_UNSPECIFIED = 0; + */ + public static final int JOB_STATE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * Job is waiting for the resources.
+     * 
+ * + * PENDING = 1; + */ + public static final int PENDING_VALUE = 1; + /** + * + * + *
+     * Job is running.
+     * 
+ * + * RUNNING = 2; + */ + public static final int RUNNING_VALUE = 2; + /** + * + * + *
+     * Job is done.
+     * 
+ * + * DONE = 3; + */ + public static final int DONE_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static JobState 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 JobState forNumber(int value) { + switch (value) { + case 0: + return JOB_STATE_UNSPECIFIED; + case 1: + return PENDING; + case 2: + return RUNNING; + case 3: + return DONE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public JobState findValueByNumber(int number) { + return JobState.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.getDescriptor().getEnumTypes().get(3); + } + + private static final JobState[] VALUES = values(); + + public static JobState valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private JobState(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.JobState) + } + + /** + * + * + *
+   * Type of the statement (e.g. SELECT, INSERT, CREATE_TABLE, CREATE_MODEL..)
+   * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.QueryStatementType} + */ + public enum QueryStatementType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unknown.
+     * 
+ * + * QUERY_STATEMENT_TYPE_UNSPECIFIED = 0; + */ + QUERY_STATEMENT_TYPE_UNSPECIFIED(0), + /** + * + * + *
+     * SELECT ... FROM <Table list> ...
+     * 
+ * + * SELECT = 1; + */ + SELECT(1), + /** + * + * + *
+     * ASSERT <condition> AS 'description'
+     * 
+ * + * ASSERT = 23; + */ + ASSERT(23), + /** + * + * + *
+     * INSERT INTO <Table> ....
+     * 
+ * + * INSERT = 2; + */ + INSERT(2), + /** + * + * + *
+     * UPDATE <Table> SET ...
+     * 
+ * + * UPDATE = 3; + */ + UPDATE(3), + /** + * + * + *
+     * DELETE <Table> ...
+     * 
+ * + * DELETE = 4; + */ + DELETE(4), + /** + * + * + *
+     * MERGE INTO <Table> ....
+     * 
+ * + * MERGE = 5; + */ + MERGE(5), + /** + * + * + *
+     * CREATE TABLE <Table> <column list>
+     * 
+ * + * CREATE_TABLE = 6; + */ + CREATE_TABLE(6), + /** + * + * + *
+     * CREATE TABLE <Table> AS SELECT
+     * 
+ * + * CREATE_TABLE_AS_SELECT = 7; + */ + CREATE_TABLE_AS_SELECT(7), + /** + * + * + *
+     * CREATE VIEW <View>
+     * 
+ * + * CREATE_VIEW = 8; + */ + CREATE_VIEW(8), + /** + * + * + *
+     * CREATE MODEL <Model> AS <Query>
+     * 
+ * + * CREATE_MODEL = 9; + */ + CREATE_MODEL(9), + /** + * + * + *
+     * CREATE MATERIALIZED VIEW <View> AS ...
+     * 
+ * + * CREATE_MATERIALIZED_VIEW = 13; + */ + CREATE_MATERIALIZED_VIEW(13), + /** + * + * + *
+     * CREATE FUNCTION <Function>(<Signature>) AS ...
+     * 
+ * + * CREATE_FUNCTION = 14; + */ + CREATE_FUNCTION(14), + /** + * + * + *
+     * CREATE PROCEDURE <Procedure>
+     * 
+ * + * CREATE_PROCEDURE = 20; + */ + CREATE_PROCEDURE(20), + /** + * + * + *
+     * CREATE SCHEMA <Schema>
+     * 
+ * + * CREATE_SCHEMA = 53; + */ + CREATE_SCHEMA(53), + /** + * + * + *
+     * DROP TABLE <Table>
+     * 
+ * + * DROP_TABLE = 10; + */ + DROP_TABLE(10), + /** + * + * + *
+     * DROP EXTERNAL TABLE <Table>
+     * 
+ * + * DROP_EXTERNAL_TABLE = 33; + */ + DROP_EXTERNAL_TABLE(33), + /** + * + * + *
+     * DROP VIEW <View>
+     * 
+ * + * DROP_VIEW = 11; + */ + DROP_VIEW(11), + /** + * + * + *
+     * DROP MODEL <Model>
+     * 
+ * + * DROP_MODEL = 12; + */ + DROP_MODEL(12), + /** + * + * + *
+     * DROP MATERIALIZED VIEW <View>
+     * 
+ * + * DROP_MATERIALIZED_VIEW = 15; + */ + DROP_MATERIALIZED_VIEW(15), + /** + * + * + *
+     * DROP FUNCTION <Function>
+     * 
+ * + * DROP_FUNCTION = 16; + */ + DROP_FUNCTION(16), + /** + * + * + *
+     * DROP PROCEDURE <Procedure>
+     * 
+ * + * DROP_PROCEDURE = 21; + */ + DROP_PROCEDURE(21), + /** + * + * + *
+     * DROP SCHEMA <Schema>
+     * 
+ * + * DROP_SCHEMA = 54; + */ + DROP_SCHEMA(54), + /** + * + * + *
+     * ALTER TABLE <Table>
+     * 
+ * + * ALTER_TABLE = 17; + */ + ALTER_TABLE(17), + /** + * + * + *
+     * ALTER VIEW <View>
+     * 
+ * + * ALTER_VIEW = 18; + */ + ALTER_VIEW(18), + /** + * + * + *
+     * ALTER MATERIALIZED_VIEW <view>
+     * 
+ * + * ALTER_MATERIALIZED_VIEW = 22; + */ + ALTER_MATERIALIZED_VIEW(22), + /** + * + * + *
+     * ALTER SCHEMA <Schema>
+     * 
+ * + * ALTER_SCHEMA = 55; + */ + ALTER_SCHEMA(55), + /** + * + * + *
+     * Script
+     * 
+ * + * SCRIPT = 19; + */ + SCRIPT(19), + /** + * + * + *
+     * TRUNCATE TABLE <Table&gt
+     * 
+ * + * TRUNCATE_TABLE = 26; + */ + TRUNCATE_TABLE(26), + /** + * + * + *
+     * CREATE EXTERNAL TABLE <TABLE>
+     * 
+ * + * CREATE_EXTERNAL_TABLE = 27; + */ + CREATE_EXTERNAL_TABLE(27), + /** + * + * + *
+     * EXPORT DATA;
+     * 
+ * + * EXPORT_DATA = 28; + */ + EXPORT_DATA(28), + /** + * + * + *
+     * CALL <stored procedure>
+     * 
+ * + * CALL = 29; + */ + CALL(29), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Unknown.
+     * 
+ * + * QUERY_STATEMENT_TYPE_UNSPECIFIED = 0; + */ + public static final int QUERY_STATEMENT_TYPE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * SELECT ... FROM <Table list> ...
+     * 
+ * + * SELECT = 1; + */ + public static final int SELECT_VALUE = 1; + /** + * + * + *
+     * ASSERT <condition> AS 'description'
+     * 
+ * + * ASSERT = 23; + */ + public static final int ASSERT_VALUE = 23; + /** + * + * + *
+     * INSERT INTO <Table> ....
+     * 
+ * + * INSERT = 2; + */ + public static final int INSERT_VALUE = 2; + /** + * + * + *
+     * UPDATE <Table> SET ...
+     * 
+ * + * UPDATE = 3; + */ + public static final int UPDATE_VALUE = 3; + /** + * + * + *
+     * DELETE <Table> ...
+     * 
+ * + * DELETE = 4; + */ + public static final int DELETE_VALUE = 4; + /** + * + * + *
+     * MERGE INTO <Table> ....
+     * 
+ * + * MERGE = 5; + */ + public static final int MERGE_VALUE = 5; + /** + * + * + *
+     * CREATE TABLE <Table> <column list>
+     * 
+ * + * CREATE_TABLE = 6; + */ + public static final int CREATE_TABLE_VALUE = 6; + /** + * + * + *
+     * CREATE TABLE <Table> AS SELECT
+     * 
+ * + * CREATE_TABLE_AS_SELECT = 7; + */ + public static final int CREATE_TABLE_AS_SELECT_VALUE = 7; + /** + * + * + *
+     * CREATE VIEW <View>
+     * 
+ * + * CREATE_VIEW = 8; + */ + public static final int CREATE_VIEW_VALUE = 8; + /** + * + * + *
+     * CREATE MODEL <Model> AS <Query>
+     * 
+ * + * CREATE_MODEL = 9; + */ + public static final int CREATE_MODEL_VALUE = 9; + /** + * + * + *
+     * CREATE MATERIALIZED VIEW <View> AS ...
+     * 
+ * + * CREATE_MATERIALIZED_VIEW = 13; + */ + public static final int CREATE_MATERIALIZED_VIEW_VALUE = 13; + /** + * + * + *
+     * CREATE FUNCTION <Function>(<Signature>) AS ...
+     * 
+ * + * CREATE_FUNCTION = 14; + */ + public static final int CREATE_FUNCTION_VALUE = 14; + /** + * + * + *
+     * CREATE PROCEDURE <Procedure>
+     * 
+ * + * CREATE_PROCEDURE = 20; + */ + public static final int CREATE_PROCEDURE_VALUE = 20; + /** + * + * + *
+     * CREATE SCHEMA <Schema>
+     * 
+ * + * CREATE_SCHEMA = 53; + */ + public static final int CREATE_SCHEMA_VALUE = 53; + /** + * + * + *
+     * DROP TABLE <Table>
+     * 
+ * + * DROP_TABLE = 10; + */ + public static final int DROP_TABLE_VALUE = 10; + /** + * + * + *
+     * DROP EXTERNAL TABLE <Table>
+     * 
+ * + * DROP_EXTERNAL_TABLE = 33; + */ + public static final int DROP_EXTERNAL_TABLE_VALUE = 33; + /** + * + * + *
+     * DROP VIEW <View>
+     * 
+ * + * DROP_VIEW = 11; + */ + public static final int DROP_VIEW_VALUE = 11; + /** + * + * + *
+     * DROP MODEL <Model>
+     * 
+ * + * DROP_MODEL = 12; + */ + public static final int DROP_MODEL_VALUE = 12; + /** + * + * + *
+     * DROP MATERIALIZED VIEW <View>
+     * 
+ * + * DROP_MATERIALIZED_VIEW = 15; + */ + public static final int DROP_MATERIALIZED_VIEW_VALUE = 15; + /** + * + * + *
+     * DROP FUNCTION <Function>
+     * 
+ * + * DROP_FUNCTION = 16; + */ + public static final int DROP_FUNCTION_VALUE = 16; + /** + * + * + *
+     * DROP PROCEDURE <Procedure>
+     * 
+ * + * DROP_PROCEDURE = 21; + */ + public static final int DROP_PROCEDURE_VALUE = 21; + /** + * + * + *
+     * DROP SCHEMA <Schema>
+     * 
+ * + * DROP_SCHEMA = 54; + */ + public static final int DROP_SCHEMA_VALUE = 54; + /** + * + * + *
+     * ALTER TABLE <Table>
+     * 
+ * + * ALTER_TABLE = 17; + */ + public static final int ALTER_TABLE_VALUE = 17; + /** + * + * + *
+     * ALTER VIEW <View>
+     * 
+ * + * ALTER_VIEW = 18; + */ + public static final int ALTER_VIEW_VALUE = 18; + /** + * + * + *
+     * ALTER MATERIALIZED_VIEW <view>
+     * 
+ * + * ALTER_MATERIALIZED_VIEW = 22; + */ + public static final int ALTER_MATERIALIZED_VIEW_VALUE = 22; + /** + * + * + *
+     * ALTER SCHEMA <Schema>
+     * 
+ * + * ALTER_SCHEMA = 55; + */ + public static final int ALTER_SCHEMA_VALUE = 55; + /** + * + * + *
+     * Script
+     * 
+ * + * SCRIPT = 19; + */ + public static final int SCRIPT_VALUE = 19; + /** + * + * + *
+     * TRUNCATE TABLE <Table&gt
+     * 
+ * + * TRUNCATE_TABLE = 26; + */ + public static final int TRUNCATE_TABLE_VALUE = 26; + /** + * + * + *
+     * CREATE EXTERNAL TABLE <TABLE>
+     * 
+ * + * CREATE_EXTERNAL_TABLE = 27; + */ + public static final int CREATE_EXTERNAL_TABLE_VALUE = 27; + /** + * + * + *
+     * EXPORT DATA;
+     * 
+ * + * EXPORT_DATA = 28; + */ + public static final int EXPORT_DATA_VALUE = 28; + /** + * + * + *
+     * CALL <stored procedure>
+     * 
+ * + * CALL = 29; + */ + public static final int CALL_VALUE = 29; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static QueryStatementType 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 QueryStatementType forNumber(int value) { + switch (value) { + case 0: + return QUERY_STATEMENT_TYPE_UNSPECIFIED; + case 1: + return SELECT; + case 23: + return ASSERT; + case 2: + return INSERT; + case 3: + return UPDATE; + case 4: + return DELETE; + case 5: + return MERGE; + case 6: + return CREATE_TABLE; + case 7: + return CREATE_TABLE_AS_SELECT; + case 8: + return CREATE_VIEW; + case 9: + return CREATE_MODEL; + case 13: + return CREATE_MATERIALIZED_VIEW; + case 14: + return CREATE_FUNCTION; + case 20: + return CREATE_PROCEDURE; + case 53: + return CREATE_SCHEMA; + case 10: + return DROP_TABLE; + case 33: + return DROP_EXTERNAL_TABLE; + case 11: + return DROP_VIEW; + case 12: + return DROP_MODEL; + case 15: + return DROP_MATERIALIZED_VIEW; + case 16: + return DROP_FUNCTION; + case 21: + return DROP_PROCEDURE; + case 54: + return DROP_SCHEMA; + case 17: + return ALTER_TABLE; + case 18: + return ALTER_VIEW; + case 22: + return ALTER_MATERIALIZED_VIEW; + case 55: + return ALTER_SCHEMA; + case 19: + return SCRIPT; + case 26: + return TRUNCATE_TABLE; + case 27: + return CREATE_EXTERNAL_TABLE; + case 28: + return EXPORT_DATA; + case 29: + return CALL; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public QueryStatementType findValueByNumber(int number) { + return QueryStatementType.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.getDescriptor().getEnumTypes().get(4); + } + + private static final QueryStatementType[] VALUES = values(); + + public static QueryStatementType valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private QueryStatementType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.QueryStatementType) + } + + public interface JobInsertionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobInsertion) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + * + * @return Whether the job field is set. + */ + boolean hasJob(); + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + * + * @return The job. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Job getJob(); + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder(); + + /** + * + * + *
+     * Describes how the job was inserted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the job was inserted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason getReason(); + } + /** + * + * + *
+   * Job insertion event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobInsertion} + */ + public static final class JobInsertion extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobInsertion) + JobInsertionOrBuilder { + private static final long serialVersionUID = 0L; + // Use JobInsertion.newBuilder() to construct. + private JobInsertion(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private JobInsertion() { + reason_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new JobInsertion(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private JobInsertion( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder subBuilder = null; + if (job_ != null) { + subBuilder = job_.toBuilder(); + } + job_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Job.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(job_); + job_ = subBuilder.buildPartial(); + } + + break; + } + case 16: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder.class); + } + + /** + * + * + *
+     * Describes how the job was inserted.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Job was inserted using the jobs.insert API.
+       * 
+ * + * JOB_INSERT_REQUEST = 1; + */ + JOB_INSERT_REQUEST(1), + /** + * + * + *
+       * Job was inserted using the jobs.query RPC.
+       * 
+ * + * QUERY_REQUEST = 2; + */ + QUERY_REQUEST(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Job was inserted using the jobs.insert API.
+       * 
+ * + * JOB_INSERT_REQUEST = 1; + */ + public static final int JOB_INSERT_REQUEST_VALUE = 1; + /** + * + * + *
+       * Job was inserted using the jobs.query RPC.
+       * 
+ * + * QUERY_REQUEST = 2; + */ + public static final int QUERY_REQUEST_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return JOB_INSERT_REQUEST; + case 2: + return QUERY_REQUEST; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason) + } + + public static final int JOB_FIELD_NUMBER = 1; + private com.google.cloud.audit.BigQueryAuditMetadata.Job job_; + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + * + * @return Whether the job field is set. + */ + @java.lang.Override + public boolean hasJob() { + return job_ != null; + } + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + * + * @return The job. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Job getJob() { + return job_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() + : job_; + } + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder() { + return getJob(); + } + + public static final int REASON_FIELD_NUMBER = 2; + private int reason_; + /** + * + * + *
+     * Describes how the job was inserted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the job was inserted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (job_ != null) { + output.writeMessage(1, getJob()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(2, reason_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (job_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getJob()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, reason_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) obj; + + if (hasJob() != other.hasJob()) return false; + if (hasJob()) { + if (!getJob().equals(other.getJob())) return false; + } + if (reason_ != other.reason_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasJob()) { + hash = (37 * hash) + JOB_FIELD_NUMBER; + hash = (53 * hash) + getJob().hashCode(); + } + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Job insertion event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobInsertion} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobInsertion) + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (jobBuilder_ == null) { + job_ = null; + } else { + job_ = null; + jobBuilder_ = null; + } + reason_ = 0; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion(this); + if (jobBuilder_ == null) { + result.job_ = job_; + } else { + result.job_ = jobBuilder_.build(); + } + result.reason_ = reason_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance()) + return this; + if (other.hasJob()) { + mergeJob(other.getJob()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Job job_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Job, + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder> + jobBuilder_; + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + * + * @return Whether the job field is set. + */ + public boolean hasJob() { + return jobBuilder_ != null || job_ != null; + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + * + * @return The job. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Job getJob() { + if (jobBuilder_ == null) { + return job_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() + : job_; + } else { + return jobBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + */ + public Builder setJob(com.google.cloud.audit.BigQueryAuditMetadata.Job value) { + if (jobBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + job_ = value; + onChanged(); + } else { + jobBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + */ + public Builder setJob( + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder builderForValue) { + if (jobBuilder_ == null) { + job_ = builderForValue.build(); + onChanged(); + } else { + jobBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + */ + public Builder mergeJob(com.google.cloud.audit.BigQueryAuditMetadata.Job value) { + if (jobBuilder_ == null) { + if (job_ != null) { + job_ = + com.google.cloud.audit.BigQueryAuditMetadata.Job.newBuilder(job_) + .mergeFrom(value) + .buildPartial(); + } else { + job_ = value; + } + onChanged(); + } else { + jobBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + */ + public Builder clearJob() { + if (jobBuilder_ == null) { + job_ = null; + onChanged(); + } else { + job_ = null; + jobBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder getJobBuilder() { + + onChanged(); + return getJobFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder() { + if (jobBuilder_ != null) { + return jobBuilder_.getMessageOrBuilder(); + } else { + return job_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() + : job_; + } + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Job, + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder> + getJobFieldBuilder() { + if (jobBuilder_ == null) { + jobBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Job, + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder>( + getJob(), getParentForChildren(), isClean()); + job_ = null; + } + return jobBuilder_; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the job was inserted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the job was inserted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the job was inserted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the job was inserted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the job was inserted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobInsertion) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobInsertion) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public JobInsertion parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new JobInsertion(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface JobChangeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobChange) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Job state before the job state change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; + * + * @return The enum numeric value on the wire for before. + */ + int getBeforeValue(); + /** + * + * + *
+     * Job state before the job state change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; + * + * @return The before. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobState getBefore(); + + /** + * + * + *
+     * Job state after the job state change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; + * + * @return The enum numeric value on the wire for after. + */ + int getAfterValue(); + /** + * + * + *
+     * Job state after the job state change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; + * + * @return The after. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobState getAfter(); + + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + * + * @return Whether the job field is set. + */ + boolean hasJob(); + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + * + * @return The job. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Job getJob(); + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder(); + } + /** + * + * + *
+   * Job state change event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobChange} + */ + public static final class JobChange extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobChange) + JobChangeOrBuilder { + private static final long serialVersionUID = 0L; + // Use JobChange.newBuilder() to construct. + private JobChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private JobChange() { + before_ = 0; + after_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new JobChange(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private JobChange( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + before_ = rawValue; + break; + } + case 16: + { + int rawValue = input.readEnum(); + + after_ = rawValue; + break; + } + case 26: + { + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder subBuilder = null; + if (job_ != null) { + subBuilder = job_.toBuilder(); + } + job_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Job.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(job_); + job_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder.class); + } + + public static final int BEFORE_FIELD_NUMBER = 1; + private int before_; + /** + * + * + *
+     * Job state before the job state change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; + * + * @return The enum numeric value on the wire for before. + */ + @java.lang.Override + public int getBeforeValue() { + return before_; + } + /** + * + * + *
+     * Job state before the job state change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; + * + * @return The before. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobState getBefore() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobState result = + com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(before_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED + : result; + } + + public static final int AFTER_FIELD_NUMBER = 2; + private int after_; + /** + * + * + *
+     * Job state after the job state change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; + * + * @return The enum numeric value on the wire for after. + */ + @java.lang.Override + public int getAfterValue() { + return after_; + } + /** + * + * + *
+     * Job state after the job state change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; + * + * @return The after. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobState getAfter() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobState result = + com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(after_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED + : result; + } + + public static final int JOB_FIELD_NUMBER = 3; + private com.google.cloud.audit.BigQueryAuditMetadata.Job job_; + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + * + * @return Whether the job field is set. + */ + @java.lang.Override + public boolean hasJob() { + return job_ != null; + } + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + * + * @return The job. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Job getJob() { + return job_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() + : job_; + } + /** + * + * + *
+     * Job metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder() { + return getJob(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (before_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, before_); + } + if (after_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(2, after_); + } + if (job_ != null) { + output.writeMessage(3, getJob()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (before_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, before_); + } + if (after_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, after_); + } + if (job_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getJob()); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobChange)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobChange other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) obj; + + if (before_ != other.before_) return false; + if (after_ != other.after_) return false; + if (hasJob() != other.hasJob()) return false; + if (hasJob()) { + if (!getJob().equals(other.getJob())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + BEFORE_FIELD_NUMBER; + hash = (53 * hash) + before_; + hash = (37 * hash) + AFTER_FIELD_NUMBER; + hash = (53 * hash) + after_; + if (hasJob()) { + hash = (37 * hash) + JOB_FIELD_NUMBER; + hash = (53 * hash) + getJob().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobChange prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Job state change event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobChange} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobChange) + com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobChange.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + before_ = 0; + + after_ = 0; + + if (jobBuilder_ == null) { + job_ = null; + } else { + job_ = null; + jobBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobChange getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobChange build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobChange result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobChange buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobChange result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobChange(this); + result.before_ = before_; + result.after_ = after_; + if (jobBuilder_ == null) { + result.job_ = job_; + } else { + result.job_ = jobBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobChange) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobChange) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobChange other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance()) + return this; + if (other.before_ != 0) { + setBeforeValue(other.getBeforeValue()); + } + if (other.after_ != 0) { + setAfterValue(other.getAfterValue()); + } + if (other.hasJob()) { + mergeJob(other.getJob()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobChange parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int before_ = 0; + /** + * + * + *
+       * Job state before the job state change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; + * + * @return The enum numeric value on the wire for before. + */ + @java.lang.Override + public int getBeforeValue() { + return before_; + } + /** + * + * + *
+       * Job state before the job state change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; + * + * @param value The enum numeric value on the wire for before to set. + * @return This builder for chaining. + */ + public Builder setBeforeValue(int value) { + + before_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Job state before the job state change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; + * + * @return The before. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobState getBefore() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobState result = + com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(before_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Job state before the job state change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; + * + * @param value The before to set. + * @return This builder for chaining. + */ + public Builder setBefore(com.google.cloud.audit.BigQueryAuditMetadata.JobState value) { + if (value == null) { + throw new NullPointerException(); + } + + before_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Job state before the job state change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; + * + * @return This builder for chaining. + */ + public Builder clearBefore() { + + before_ = 0; + onChanged(); + return this; + } + + private int after_ = 0; + /** + * + * + *
+       * Job state after the job state change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; + * + * @return The enum numeric value on the wire for after. + */ + @java.lang.Override + public int getAfterValue() { + return after_; + } + /** + * + * + *
+       * Job state after the job state change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; + * + * @param value The enum numeric value on the wire for after to set. + * @return This builder for chaining. + */ + public Builder setAfterValue(int value) { + + after_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Job state after the job state change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; + * + * @return The after. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobState getAfter() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobState result = + com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(after_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Job state after the job state change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; + * + * @param value The after to set. + * @return This builder for chaining. + */ + public Builder setAfter(com.google.cloud.audit.BigQueryAuditMetadata.JobState value) { + if (value == null) { + throw new NullPointerException(); + } + + after_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Job state after the job state change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; + * + * @return This builder for chaining. + */ + public Builder clearAfter() { + + after_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Job job_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Job, + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder> + jobBuilder_; + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + * + * @return Whether the job field is set. + */ + public boolean hasJob() { + return jobBuilder_ != null || job_ != null; + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + * + * @return The job. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Job getJob() { + if (jobBuilder_ == null) { + return job_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() + : job_; + } else { + return jobBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + */ + public Builder setJob(com.google.cloud.audit.BigQueryAuditMetadata.Job value) { + if (jobBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + job_ = value; + onChanged(); + } else { + jobBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + */ + public Builder setJob( + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder builderForValue) { + if (jobBuilder_ == null) { + job_ = builderForValue.build(); + onChanged(); + } else { + jobBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + */ + public Builder mergeJob(com.google.cloud.audit.BigQueryAuditMetadata.Job value) { + if (jobBuilder_ == null) { + if (job_ != null) { + job_ = + com.google.cloud.audit.BigQueryAuditMetadata.Job.newBuilder(job_) + .mergeFrom(value) + .buildPartial(); + } else { + job_ = value; + } + onChanged(); + } else { + jobBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + */ + public Builder clearJob() { + if (jobBuilder_ == null) { + job_ = null; + onChanged(); + } else { + job_ = null; + jobBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder getJobBuilder() { + + onChanged(); + return getJobFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder() { + if (jobBuilder_ != null) { + return jobBuilder_.getMessageOrBuilder(); + } else { + return job_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() + : job_; + } + } + /** + * + * + *
+       * Job metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Job, + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder> + getJobFieldBuilder() { + if (jobBuilder_ == null) { + jobBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Job, + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder>( + getJob(), getParentForChildren(), isClean()); + job_ = null; + } + return jobBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobChange) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobChange) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobChange DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobChange(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public JobChange parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new JobChange(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobChange getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface DatasetCreationOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Dataset metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return Whether the dataset field is set. + */ + boolean hasDataset(); + /** + * + * + *
+     * Dataset metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return The dataset. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset(); + /** + * + * + *
+     * Dataset metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder(); + + /** + * + * + *
+     * Describes how the dataset was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the dataset was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that created the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that created the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Dataset creation event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetCreation} + */ + public static final class DatasetCreation extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) + DatasetCreationOrBuilder { + private static final long serialVersionUID = 0L; + // Use DatasetCreation.newBuilder() to construct. + private DatasetCreation(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DatasetCreation() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DatasetCreation(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private DatasetCreation( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder subBuilder = null; + if (dataset_ != null) { + subBuilder = dataset_.toBuilder(); + } + dataset_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(dataset_); + dataset_ = subBuilder.buildPartial(); + } + + break; + } + case 16: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.class, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder.class); + } + + /** + * + * + *
+     * Describes how the dataset was created.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Dataset was created using the datasets.create API.
+       * 
+ * + * CREATE = 1; + */ + CREATE(1), + /** + * + * + *
+       * Dataset was created using a query job, e.g., CREATE SCHEMA statement.
+       * 
+ * + * QUERY = 2; + */ + QUERY(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Dataset was created using the datasets.create API.
+       * 
+ * + * CREATE = 1; + */ + public static final int CREATE_VALUE = 1; + /** + * + * + *
+       * Dataset was created using a query job, e.g., CREATE SCHEMA statement.
+       * 
+ * + * QUERY = 2; + */ + public static final int QUERY_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return CREATE; + case 2: + return QUERY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason) + } + + public static final int DATASET_FIELD_NUMBER = 1; + private com.google.cloud.audit.BigQueryAuditMetadata.Dataset dataset_; + /** + * + * + *
+     * Dataset metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return Whether the dataset field is set. + */ + @java.lang.Override + public boolean hasDataset() { + return dataset_ != null; + } + /** + * + * + *
+     * Dataset metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return The dataset. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset() { + return dataset_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() + : dataset_; + } + /** + * + * + *
+     * Dataset metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder() { + return getDataset(); + } + + public static final int REASON_FIELD_NUMBER = 2; + private int reason_; + /** + * + * + *
+     * Describes how the dataset was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the dataset was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 3; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that created the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that created the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (dataset_ != null) { + output.writeMessage(1, getDataset()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(2, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (dataset_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getDataset()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation other = + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) obj; + + if (hasDataset() != other.hasDataset()) return false; + if (hasDataset()) { + if (!getDataset().equals(other.getDataset())) return false; + } + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasDataset()) { + hash = (37 * hash) + DATASET_FIELD_NUMBER; + hash = (53 * hash) + getDataset().hashCode(); + } + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Dataset creation event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetCreation} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.class, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (datasetBuilder_ == null) { + dataset_ = null; + } else { + dataset_ = null; + datasetBuilder_ = null; + } + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation build() { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation result = + new com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation(this); + if (datasetBuilder_ == null) { + result.dataset_ = dataset_; + } else { + result.dataset_ = datasetBuilder_.build(); + } + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance()) + return this; + if (other.hasDataset()) { + mergeDataset(other.getDataset()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Dataset dataset_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Dataset, + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder> + datasetBuilder_; + /** + * + * + *
+       * Dataset metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return Whether the dataset field is set. + */ + public boolean hasDataset() { + return datasetBuilder_ != null || dataset_ != null; + } + /** + * + * + *
+       * Dataset metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return The dataset. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset() { + if (datasetBuilder_ == null) { + return dataset_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() + : dataset_; + } else { + return datasetBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Dataset metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public Builder setDataset(com.google.cloud.audit.BigQueryAuditMetadata.Dataset value) { + if (datasetBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + dataset_ = value; + onChanged(); + } else { + datasetBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Dataset metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public Builder setDataset( + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder builderForValue) { + if (datasetBuilder_ == null) { + dataset_ = builderForValue.build(); + onChanged(); + } else { + datasetBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Dataset metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public Builder mergeDataset(com.google.cloud.audit.BigQueryAuditMetadata.Dataset value) { + if (datasetBuilder_ == null) { + if (dataset_ != null) { + dataset_ = + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.newBuilder(dataset_) + .mergeFrom(value) + .buildPartial(); + } else { + dataset_ = value; + } + onChanged(); + } else { + datasetBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Dataset metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public Builder clearDataset() { + if (datasetBuilder_ == null) { + dataset_ = null; + onChanged(); + } else { + dataset_ = null; + datasetBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Dataset metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder getDatasetBuilder() { + + onChanged(); + return getDatasetFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Dataset metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder() { + if (datasetBuilder_ != null) { + return datasetBuilder_.getMessageOrBuilder(); + } else { + return dataset_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() + : dataset_; + } + } + /** + * + * + *
+       * Dataset metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Dataset, + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder> + getDatasetFieldBuilder() { + if (datasetBuilder_ == null) { + datasetBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Dataset, + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder>( + getDataset(), getParentForChildren(), isClean()); + dataset_ = null; + } + return datasetBuilder_; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the dataset was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the dataset was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the dataset was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the dataset was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the dataset was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that created the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that created the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that created the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that created the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that created the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) + private static final com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DatasetCreation parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DatasetCreation(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface DatasetChangeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.DatasetChange) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Dataset metadata after the change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return Whether the dataset field is set. + */ + boolean hasDataset(); + /** + * + * + *
+     * Dataset metadata after the change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return The dataset. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset(); + /** + * + * + *
+     * Dataset metadata after the change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder(); + + /** + * + * + *
+     * Describes how the dataset was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the dataset was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that updated the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that updated the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Dataset change event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetChange} + */ + public static final class DatasetChange extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetChange) + DatasetChangeOrBuilder { + private static final long serialVersionUID = 0L; + // Use DatasetChange.newBuilder() to construct. + private DatasetChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DatasetChange() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DatasetChange(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private DatasetChange( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder subBuilder = null; + if (dataset_ != null) { + subBuilder = dataset_.toBuilder(); + } + dataset_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(dataset_); + dataset_ = subBuilder.buildPartial(); + } + + break; + } + case 16: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder.class); + } + + /** + * + * + *
+     * Describes how the dataset was changed.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Dataset was changed using the datasets.update or datasets.patch API.
+       * 
+ * + * UPDATE = 1; + */ + UPDATE(1), + /** + * + * + *
+       * Dataset was changed using the SetIamPolicy API.
+       * 
+ * + * SET_IAM_POLICY = 2; + */ + SET_IAM_POLICY(2), + /** + * + * + *
+       * Dataset was changed using a query job, e.g., ALTER SCHEMA statement.
+       * 
+ * + * QUERY = 3; + */ + QUERY(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Dataset was changed using the datasets.update or datasets.patch API.
+       * 
+ * + * UPDATE = 1; + */ + public static final int UPDATE_VALUE = 1; + /** + * + * + *
+       * Dataset was changed using the SetIamPolicy API.
+       * 
+ * + * SET_IAM_POLICY = 2; + */ + public static final int SET_IAM_POLICY_VALUE = 2; + /** + * + * + *
+       * Dataset was changed using a query job, e.g., ALTER SCHEMA statement.
+       * 
+ * + * QUERY = 3; + */ + public static final int QUERY_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return UPDATE; + case 2: + return SET_IAM_POLICY; + case 3: + return QUERY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason) + } + + public static final int DATASET_FIELD_NUMBER = 1; + private com.google.cloud.audit.BigQueryAuditMetadata.Dataset dataset_; + /** + * + * + *
+     * Dataset metadata after the change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return Whether the dataset field is set. + */ + @java.lang.Override + public boolean hasDataset() { + return dataset_ != null; + } + /** + * + * + *
+     * Dataset metadata after the change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return The dataset. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset() { + return dataset_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() + : dataset_; + } + /** + * + * + *
+     * Dataset metadata after the change.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder() { + return getDataset(); + } + + public static final int REASON_FIELD_NUMBER = 2; + private int reason_; + /** + * + * + *
+     * Describes how the dataset was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the dataset was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 3; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that updated the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that updated the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (dataset_ != null) { + output.writeMessage(1, getDataset()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(2, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (dataset_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getDataset()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange other = + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) obj; + + if (hasDataset() != other.hasDataset()) return false; + if (hasDataset()) { + if (!getDataset().equals(other.getDataset())) return false; + } + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasDataset()) { + hash = (37 * hash) + DATASET_FIELD_NUMBER; + hash = (53 * hash) + getDataset().hashCode(); + } + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Dataset change event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetChange} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetChange) + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (datasetBuilder_ == null) { + dataset_ = null; + } else { + dataset_ = null; + datasetBuilder_ = null; + } + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange build() { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange result = + new com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange(this); + if (datasetBuilder_ == null) { + result.dataset_ = dataset_; + } else { + result.dataset_ = datasetBuilder_.build(); + } + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance()) + return this; + if (other.hasDataset()) { + mergeDataset(other.getDataset()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Dataset dataset_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Dataset, + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder> + datasetBuilder_; + /** + * + * + *
+       * Dataset metadata after the change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return Whether the dataset field is set. + */ + public boolean hasDataset() { + return datasetBuilder_ != null || dataset_ != null; + } + /** + * + * + *
+       * Dataset metadata after the change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + * + * @return The dataset. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset() { + if (datasetBuilder_ == null) { + return dataset_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() + : dataset_; + } else { + return datasetBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Dataset metadata after the change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public Builder setDataset(com.google.cloud.audit.BigQueryAuditMetadata.Dataset value) { + if (datasetBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + dataset_ = value; + onChanged(); + } else { + datasetBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Dataset metadata after the change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public Builder setDataset( + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder builderForValue) { + if (datasetBuilder_ == null) { + dataset_ = builderForValue.build(); + onChanged(); + } else { + datasetBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Dataset metadata after the change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public Builder mergeDataset(com.google.cloud.audit.BigQueryAuditMetadata.Dataset value) { + if (datasetBuilder_ == null) { + if (dataset_ != null) { + dataset_ = + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.newBuilder(dataset_) + .mergeFrom(value) + .buildPartial(); + } else { + dataset_ = value; + } + onChanged(); + } else { + datasetBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Dataset metadata after the change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public Builder clearDataset() { + if (datasetBuilder_ == null) { + dataset_ = null; + onChanged(); + } else { + dataset_ = null; + datasetBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Dataset metadata after the change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder getDatasetBuilder() { + + onChanged(); + return getDatasetFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Dataset metadata after the change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder() { + if (datasetBuilder_ != null) { + return datasetBuilder_.getMessageOrBuilder(); + } else { + return dataset_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() + : dataset_; + } + } + /** + * + * + *
+       * Dataset metadata after the change.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Dataset, + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder> + getDatasetFieldBuilder() { + if (datasetBuilder_ == null) { + datasetBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Dataset, + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder>( + getDataset(), getParentForChildren(), isClean()); + dataset_ = null; + } + return datasetBuilder_; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the dataset was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the dataset was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the dataset was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the dataset was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the dataset was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that updated the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that updated the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that updated the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that updated the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that updated the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetChange) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetChange) + private static final com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DatasetChange parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DatasetChange(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface DatasetDeletionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Describes how the dataset was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the dataset was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that deleted the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that deleted the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Dataset deletion event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion} + */ + public static final class DatasetDeletion extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) + DatasetDeletionOrBuilder { + private static final long serialVersionUID = 0L; + // Use DatasetDeletion.newBuilder() to construct. + private DatasetDeletion(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DatasetDeletion() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DatasetDeletion(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private DatasetDeletion( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.class, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder.class); + } + + /** + * + * + *
+     * Describes how the dataset was deleted.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Dataset was deleted using the datasets.delete API.
+       * 
+ * + * DELETE = 1; + */ + DELETE(1), + /** + * + * + *
+       * Dataset was deleted using a query job, e.g., DROP SCHEMA statement.
+       * 
+ * + * QUERY = 2; + */ + QUERY(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Dataset was deleted using the datasets.delete API.
+       * 
+ * + * DELETE = 1; + */ + public static final int DELETE_VALUE = 1; + /** + * + * + *
+       * Dataset was deleted using a query job, e.g., DROP SCHEMA statement.
+       * 
+ * + * QUERY = 2; + */ + public static final int QUERY_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return DELETE; + case 2: + return QUERY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason) + } + + public static final int REASON_FIELD_NUMBER = 1; + private int reason_; + /** + * + * + *
+     * Describes how the dataset was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the dataset was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 2; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that deleted the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that deleted the dataset.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion other = + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) obj; + + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Dataset deletion event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.class, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion build() { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion result = + new com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion(this); + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance()) + return this; + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the dataset was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the dataset was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the dataset was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the dataset was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the dataset was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that deleted the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that deleted the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that deleted the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that deleted the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that deleted the dataset.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) + private static final com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DatasetDeletion parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DatasetDeletion(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface TableCreationOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableCreation) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return Whether the table field is set. + */ + boolean hasTable(); + /** + * + * + *
+     * Table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return The table. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Table getTable(); + /** + * + * + *
+     * Table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder(); + + /** + * + * + *
+     * Describes how the table was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the table was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that created a table.
+     * Present if the reason is JOB or QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that created a table.
+     * Present if the reason is JOB or QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Table creation event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableCreation} + */ + public static final class TableCreation extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableCreation) + TableCreationOrBuilder { + private static final long serialVersionUID = 0L; + // Use TableCreation.newBuilder() to construct. + private TableCreation(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private TableCreation() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TableCreation(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private TableCreation( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder subBuilder = null; + if (table_ != null) { + subBuilder = table_.toBuilder(); + } + table_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Table.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(table_); + table_ = subBuilder.buildPartial(); + } + + break; + } + case 24: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder.class); + } + + /** + * + * + *
+     * Describes how the table was created.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Table was created as a destination table during a query, load or copy
+       * job.
+       * 
+ * + * JOB = 1; + */ + JOB(1), + /** + * + * + *
+       * Table was created using a DDL query.
+       * 
+ * + * QUERY = 2; + */ + QUERY(2), + /** + * + * + *
+       * Table was created using the tables.create API.
+       * 
+ * + * TABLE_INSERT_REQUEST = 3; + */ + TABLE_INSERT_REQUEST(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Table was created as a destination table during a query, load or copy
+       * job.
+       * 
+ * + * JOB = 1; + */ + public static final int JOB_VALUE = 1; + /** + * + * + *
+       * Table was created using a DDL query.
+       * 
+ * + * QUERY = 2; + */ + public static final int QUERY_VALUE = 2; + /** + * + * + *
+       * Table was created using the tables.create API.
+       * 
+ * + * TABLE_INSERT_REQUEST = 3; + */ + public static final int TABLE_INSERT_REQUEST_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return JOB; + case 2: + return QUERY; + case 3: + return TABLE_INSERT_REQUEST; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason) + } + + public static final int TABLE_FIELD_NUMBER = 1; + private com.google.cloud.audit.BigQueryAuditMetadata.Table table_; + /** + * + * + *
+     * Table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return Whether the table field is set. + */ + @java.lang.Override + public boolean hasTable() { + return table_ != null; + } + /** + * + * + *
+     * Table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return The table. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Table getTable() { + return table_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() + : table_; + } + /** + * + * + *
+     * Table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder() { + return getTable(); + } + + public static final int REASON_FIELD_NUMBER = 3; + private int reason_; + /** + * + * + *
+     * Describes how the table was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the table was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 4; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that created a table.
+     * Present if the reason is JOB or QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that created a table.
+     * Present if the reason is JOB or QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (table_ != null) { + output.writeMessage(1, getTable()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (table_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getTable()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableCreation)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation other = + (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) obj; + + if (hasTable() != other.hasTable()) return false; + if (hasTable()) { + if (!getTable().equals(other.getTable())) return false; + } + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasTable()) { + hash = (37 * hash) + TABLE_FIELD_NUMBER; + hash = (53 * hash) + getTable().hashCode(); + } + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Table creation event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableCreation} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableCreation) + com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (tableBuilder_ == null) { + table_ = null; + } else { + table_ = null; + tableBuilder_ = null; + } + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation build() { + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation result = + new com.google.cloud.audit.BigQueryAuditMetadata.TableCreation(this); + if (tableBuilder_ == null) { + result.table_ = table_; + } else { + result.table_ = tableBuilder_.build(); + } + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableCreation other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance()) + return this; + if (other.hasTable()) { + mergeTable(other.getTable()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Table table_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Table, + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder> + tableBuilder_; + /** + * + * + *
+       * Table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return Whether the table field is set. + */ + public boolean hasTable() { + return tableBuilder_ != null || table_ != null; + } + /** + * + * + *
+       * Table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return The table. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Table getTable() { + if (tableBuilder_ == null) { + return table_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() + : table_; + } else { + return tableBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public Builder setTable(com.google.cloud.audit.BigQueryAuditMetadata.Table value) { + if (tableBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + table_ = value; + onChanged(); + } else { + tableBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public Builder setTable( + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder builderForValue) { + if (tableBuilder_ == null) { + table_ = builderForValue.build(); + onChanged(); + } else { + tableBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public Builder mergeTable(com.google.cloud.audit.BigQueryAuditMetadata.Table value) { + if (tableBuilder_ == null) { + if (table_ != null) { + table_ = + com.google.cloud.audit.BigQueryAuditMetadata.Table.newBuilder(table_) + .mergeFrom(value) + .buildPartial(); + } else { + table_ = value; + } + onChanged(); + } else { + tableBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public Builder clearTable() { + if (tableBuilder_ == null) { + table_ = null; + onChanged(); + } else { + table_ = null; + tableBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder getTableBuilder() { + + onChanged(); + return getTableFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder() { + if (tableBuilder_ != null) { + return tableBuilder_.getMessageOrBuilder(); + } else { + return table_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() + : table_; + } + } + /** + * + * + *
+       * Table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Table, + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder> + getTableFieldBuilder() { + if (tableBuilder_ == null) { + tableBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Table, + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder>( + getTable(), getParentForChildren(), isClean()); + table_ = null; + } + return tableBuilder_; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the table was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the table was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the table was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the table was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the table was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that created a table.
+       * Present if the reason is JOB or QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that created a table.
+       * Present if the reason is JOB or QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that created a table.
+       * Present if the reason is JOB or QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that created a table.
+       * Present if the reason is JOB or QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that created a table.
+       * Present if the reason is JOB or QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableCreation) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableCreation) + private static final com.google.cloud.audit.BigQueryAuditMetadata.TableCreation + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableCreation(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public TableCreation parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new TableCreation(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ModelCreationOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.ModelCreation) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Model metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return Whether the model field is set. + */ + boolean hasModel(); + /** + * + * + *
+     * Model metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return The model. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Model getModel(); + /** + * + * + *
+     * Model metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder(); + + /** + * + * + *
+     * Describes how the model was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the model was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that created the model.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that created the model.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Model creation event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelCreation} + */ + public static final class ModelCreation extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.ModelCreation) + ModelCreationOrBuilder { + private static final long serialVersionUID = 0L; + // Use ModelCreation.newBuilder() to construct. + private ModelCreation(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ModelCreation() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ModelCreation(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ModelCreation( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder subBuilder = null; + if (model_ != null) { + subBuilder = model_.toBuilder(); + } + model_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Model.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(model_); + model_ = subBuilder.buildPartial(); + } + + break; + } + case 24: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.class, + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder.class); + } + + /** + * + * + *
+     * Describes how the model was created.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Model was created using a DDL query.
+       * 
+ * + * QUERY = 2; + */ + QUERY(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Model was created using a DDL query.
+       * 
+ * + * QUERY = 2; + */ + public static final int QUERY_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 2: + return QUERY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason) + } + + public static final int MODEL_FIELD_NUMBER = 1; + private com.google.cloud.audit.BigQueryAuditMetadata.Model model_; + /** + * + * + *
+     * Model metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return Whether the model field is set. + */ + @java.lang.Override + public boolean hasModel() { + return model_ != null; + } + /** + * + * + *
+     * Model metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return The model. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Model getModel() { + return model_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() + : model_; + } + /** + * + * + *
+     * Model metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder() { + return getModel(); + } + + public static final int REASON_FIELD_NUMBER = 3; + private int reason_; + /** + * + * + *
+     * Describes how the model was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the model was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 4; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that created the model.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that created the model.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (model_ != null) { + output.writeMessage(1, getModel()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (model_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getModel()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation other = + (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) obj; + + if (hasModel() != other.hasModel()) return false; + if (hasModel()) { + if (!getModel().equals(other.getModel())) return false; + } + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasModel()) { + hash = (37 * hash) + MODEL_FIELD_NUMBER; + hash = (53 * hash) + getModel().hashCode(); + } + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Model creation event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelCreation} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.ModelCreation) + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.class, + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (modelBuilder_ == null) { + model_ = null; + } else { + model_ = null; + modelBuilder_ = null; + } + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation build() { + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation result = + new com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation(this); + if (modelBuilder_ == null) { + result.model_ = model_; + } else { + result.model_ = modelBuilder_.build(); + } + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance()) + return this; + if (other.hasModel()) { + mergeModel(other.getModel()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Model model_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Model, + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder> + modelBuilder_; + /** + * + * + *
+       * Model metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return Whether the model field is set. + */ + public boolean hasModel() { + return modelBuilder_ != null || model_ != null; + } + /** + * + * + *
+       * Model metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return The model. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Model getModel() { + if (modelBuilder_ == null) { + return model_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() + : model_; + } else { + return modelBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Model metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public Builder setModel(com.google.cloud.audit.BigQueryAuditMetadata.Model value) { + if (modelBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + model_ = value; + onChanged(); + } else { + modelBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Model metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public Builder setModel( + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder builderForValue) { + if (modelBuilder_ == null) { + model_ = builderForValue.build(); + onChanged(); + } else { + modelBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Model metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public Builder mergeModel(com.google.cloud.audit.BigQueryAuditMetadata.Model value) { + if (modelBuilder_ == null) { + if (model_ != null) { + model_ = + com.google.cloud.audit.BigQueryAuditMetadata.Model.newBuilder(model_) + .mergeFrom(value) + .buildPartial(); + } else { + model_ = value; + } + onChanged(); + } else { + modelBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Model metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public Builder clearModel() { + if (modelBuilder_ == null) { + model_ = null; + onChanged(); + } else { + model_ = null; + modelBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Model metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder getModelBuilder() { + + onChanged(); + return getModelFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Model metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder() { + if (modelBuilder_ != null) { + return modelBuilder_.getMessageOrBuilder(); + } else { + return model_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() + : model_; + } + } + /** + * + * + *
+       * Model metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Model, + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder> + getModelFieldBuilder() { + if (modelBuilder_ == null) { + modelBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Model, + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder>( + getModel(), getParentForChildren(), isClean()); + model_ = null; + } + return modelBuilder_; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the model was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the model was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the model was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the model was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the model was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that created the model.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that created the model.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that created the model.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that created the model.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that created the model.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.ModelCreation) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.ModelCreation) + private static final com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ModelCreation parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ModelCreation(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface RoutineCreationOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Created routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return Whether the routine field is set. + */ + boolean hasRoutine(); + /** + * + * + *
+     * Created routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return The routine. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine(); + /** + * + * + *
+     * Created routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder(); + + /** + * + * + *
+     * Describes how the routine was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the routine was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that created the routine.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that created the routine.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Routine creation event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineCreation} + */ + public static final class RoutineCreation extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) + RoutineCreationOrBuilder { + private static final long serialVersionUID = 0L; + // Use RoutineCreation.newBuilder() to construct. + private RoutineCreation(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RoutineCreation() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RoutineCreation(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private RoutineCreation( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder subBuilder = null; + if (routine_ != null) { + subBuilder = routine_.toBuilder(); + } + routine_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Routine.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(routine_); + routine_ = subBuilder.buildPartial(); + } + + break; + } + case 24: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.class, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder.class); + } + + /** + * + * + *
+     * Describes how the routine was created.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Routine was created using a DDL query.
+       * 
+ * + * QUERY = 1; + */ + QUERY(1), + /** + * + * + *
+       * Routine was created using the routines.create API.
+       * 
+ * + * ROUTINE_INSERT_REQUEST = 2; + */ + ROUTINE_INSERT_REQUEST(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Routine was created using a DDL query.
+       * 
+ * + * QUERY = 1; + */ + public static final int QUERY_VALUE = 1; + /** + * + * + *
+       * Routine was created using the routines.create API.
+       * 
+ * + * ROUTINE_INSERT_REQUEST = 2; + */ + public static final int ROUTINE_INSERT_REQUEST_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return QUERY; + case 2: + return ROUTINE_INSERT_REQUEST; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason) + } + + public static final int ROUTINE_FIELD_NUMBER = 1; + private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; + /** + * + * + *
+     * Created routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return Whether the routine field is set. + */ + @java.lang.Override + public boolean hasRoutine() { + return routine_ != null; + } + /** + * + * + *
+     * Created routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return The routine. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { + return routine_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() + : routine_; + } + /** + * + * + *
+     * Created routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { + return getRoutine(); + } + + public static final int REASON_FIELD_NUMBER = 3; + private int reason_; + /** + * + * + *
+     * Describes how the routine was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the routine was created.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 4; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that created the routine.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that created the routine.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (routine_ != null) { + output.writeMessage(1, getRoutine()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (routine_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getRoutine()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation other = + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) obj; + + if (hasRoutine() != other.hasRoutine()) return false; + if (hasRoutine()) { + if (!getRoutine().equals(other.getRoutine())) return false; + } + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasRoutine()) { + hash = (37 * hash) + ROUTINE_FIELD_NUMBER; + hash = (53 * hash) + getRoutine().hashCode(); + } + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Routine creation event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineCreation} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.class, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (routineBuilder_ == null) { + routine_ = null; + } else { + routine_ = null; + routineBuilder_ = null; + } + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation build() { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation result = + new com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation(this); + if (routineBuilder_ == null) { + result.routine_ = routine_; + } else { + result.routine_ = routineBuilder_.build(); + } + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance()) + return this; + if (other.hasRoutine()) { + mergeRoutine(other.getRoutine()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Routine, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> + routineBuilder_; + /** + * + * + *
+       * Created routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return Whether the routine field is set. + */ + public boolean hasRoutine() { + return routineBuilder_ != null || routine_ != null; + } + /** + * + * + *
+       * Created routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return The routine. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { + if (routineBuilder_ == null) { + return routine_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() + : routine_; + } else { + return routineBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Created routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder setRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { + if (routineBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + routine_ = value; + onChanged(); + } else { + routineBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Created routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder setRoutine( + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder builderForValue) { + if (routineBuilder_ == null) { + routine_ = builderForValue.build(); + onChanged(); + } else { + routineBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Created routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder mergeRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { + if (routineBuilder_ == null) { + if (routine_ != null) { + routine_ = + com.google.cloud.audit.BigQueryAuditMetadata.Routine.newBuilder(routine_) + .mergeFrom(value) + .buildPartial(); + } else { + routine_ = value; + } + onChanged(); + } else { + routineBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Created routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder clearRoutine() { + if (routineBuilder_ == null) { + routine_ = null; + onChanged(); + } else { + routine_ = null; + routineBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Created routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder getRoutineBuilder() { + + onChanged(); + return getRoutineFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Created routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { + if (routineBuilder_ != null) { + return routineBuilder_.getMessageOrBuilder(); + } else { + return routine_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() + : routine_; + } + } + /** + * + * + *
+       * Created routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Routine, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> + getRoutineFieldBuilder() { + if (routineBuilder_ == null) { + routineBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Routine, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder>( + getRoutine(), getParentForChildren(), isClean()); + routine_ = null; + } + return routineBuilder_; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the routine was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the routine was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the routine was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the routine was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the routine was created.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that created the routine.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that created the routine.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that created the routine.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that created the routine.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that created the routine.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) + private static final com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RoutineCreation parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new RoutineCreation(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface TableDataReadOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableDataRead) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * List of the accessed fields. Entire list is truncated if the record size
+     * exceeds 100K.
+     * 
+ * + * repeated string fields = 2; + * + * @return A list containing the fields. + */ + java.util.List getFieldsList(); + /** + * + * + *
+     * List of the accessed fields. Entire list is truncated if the record size
+     * exceeds 100K.
+     * 
+ * + * repeated string fields = 2; + * + * @return The count of fields. + */ + int getFieldsCount(); + /** + * + * + *
+     * List of the accessed fields. Entire list is truncated if the record size
+     * exceeds 100K.
+     * 
+ * + * repeated string fields = 2; + * + * @param index The index of the element to return. + * @return The fields at the given index. + */ + java.lang.String getFields(int index); + /** + * + * + *
+     * List of the accessed fields. Entire list is truncated if the record size
+     * exceeds 100K.
+     * 
+ * + * repeated string fields = 2; + * + * @param index The index of the value to return. + * @return The bytes of the fields at the given index. + */ + com.google.protobuf.ByteString getFieldsBytes(int index); + + /** + * + * + *
+     * True if the fields list was truncated.
+     * 
+ * + * bool fields_truncated = 8; + * + * @return The fieldsTruncated. + */ + boolean getFieldsTruncated(); + + /** + * + * + *
+     * List of the referenced policy tags. That is, policy tags attached to the
+     * accessed fields or their ancestors.
+     * Policy tag resource name is a string of the format:
+     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+     * 
+ * + * repeated string policy_tags = 9; + * + * @return A list containing the policyTags. + */ + java.util.List getPolicyTagsList(); + /** + * + * + *
+     * List of the referenced policy tags. That is, policy tags attached to the
+     * accessed fields or their ancestors.
+     * Policy tag resource name is a string of the format:
+     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+     * 
+ * + * repeated string policy_tags = 9; + * + * @return The count of policyTags. + */ + int getPolicyTagsCount(); + /** + * + * + *
+     * List of the referenced policy tags. That is, policy tags attached to the
+     * accessed fields or their ancestors.
+     * Policy tag resource name is a string of the format:
+     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+     * 
+ * + * repeated string policy_tags = 9; + * + * @param index The index of the element to return. + * @return The policyTags at the given index. + */ + java.lang.String getPolicyTags(int index); + /** + * + * + *
+     * List of the referenced policy tags. That is, policy tags attached to the
+     * accessed fields or their ancestors.
+     * Policy tag resource name is a string of the format:
+     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+     * 
+ * + * repeated string policy_tags = 9; + * + * @param index The index of the value to return. + * @return The bytes of the policyTags at the given index. + */ + com.google.protobuf.ByteString getPolicyTagsBytes(int index); + + /** + * + * + *
+     * True if the policy tag list was truncated. At most 100 policy tags can be
+     * saved.
+     * 
+ * + * bool policy_tags_truncated = 10; + * + * @return The policyTagsTruncated. + */ + boolean getPolicyTagsTruncated(); + + /** + * + * + *
+     * Describes how the table data was read.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the table data was read.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that read a table.
+     * Present if the reason is JOB but can be redacted for privacy reasons.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that read a table.
+     * Present if the reason is JOB but can be redacted for privacy reasons.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + + /** + * + * + *
+     * The URI of the read session that read a table.
+     * Present if the reason is CREATE_READ_SESSION.
+     * Format:
+     * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
+     * 
+ * + * string session_name = 5; + * + * @return The sessionName. + */ + java.lang.String getSessionName(); + /** + * + * + *
+     * The URI of the read session that read a table.
+     * Present if the reason is CREATE_READ_SESSION.
+     * Format:
+     * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
+     * 
+ * + * string session_name = 5; + * + * @return The bytes for sessionName. + */ + com.google.protobuf.ByteString getSessionNameBytes(); + } + /** + * + * + *
+   * Table data read event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDataRead} + */ + public static final class TableDataRead extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableDataRead) + TableDataReadOrBuilder { + private static final long serialVersionUID = 0L; + // Use TableDataRead.newBuilder() to construct. + private TableDataRead(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private TableDataRead() { + fields_ = com.google.protobuf.LazyStringArrayList.EMPTY; + policyTags_ = com.google.protobuf.LazyStringArrayList.EMPTY; + reason_ = 0; + jobName_ = ""; + sessionName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TableDataRead(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private TableDataRead( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + fields_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + fields_.add(s); + break; + } + case 24: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + + sessionName_ = s; + break; + } + case 64: + { + fieldsTruncated_ = input.readBool(); + break; + } + case 74: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + policyTags_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000002; + } + policyTags_.add(s); + break; + } + case 80: + { + policyTagsTruncated_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + fields_ = fields_.getUnmodifiableView(); + } + if (((mutable_bitField0_ & 0x00000002) != 0)) { + policyTags_ = policyTags_.getUnmodifiableView(); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder.class); + } + + /** + * + * + *
+     * Describes how the table data was read.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Table was used as a source table during a BigQuery job.
+       * 
+ * + * JOB = 1; + */ + JOB(1), + /** + * + * + *
+       * Table data was accessed using the tabledata.list API.
+       * 
+ * + * TABLEDATA_LIST_REQUEST = 2; + */ + TABLEDATA_LIST_REQUEST(2), + /** + * + * + *
+       * Table data was accessed using the jobs.getQueryResults API.
+       * 
+ * + * GET_QUERY_RESULTS_REQUEST = 3; + */ + GET_QUERY_RESULTS_REQUEST(3), + /** + * + * + *
+       * Table data was accessed using the jobs.query RPC.
+       * 
+ * + * QUERY_REQUEST = 4; + */ + QUERY_REQUEST(4), + /** + * + * + *
+       * Table data was accessed using storage.CreateReadSession API.
+       * 
+ * + * CREATE_READ_SESSION = 5; + */ + CREATE_READ_SESSION(5), + /** + * + * + *
+       * Table data was accessed during a materialized view refresh.
+       * 
+ * + * MATERIALIZED_VIEW_REFRESH = 6; + */ + MATERIALIZED_VIEW_REFRESH(6), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Table was used as a source table during a BigQuery job.
+       * 
+ * + * JOB = 1; + */ + public static final int JOB_VALUE = 1; + /** + * + * + *
+       * Table data was accessed using the tabledata.list API.
+       * 
+ * + * TABLEDATA_LIST_REQUEST = 2; + */ + public static final int TABLEDATA_LIST_REQUEST_VALUE = 2; + /** + * + * + *
+       * Table data was accessed using the jobs.getQueryResults API.
+       * 
+ * + * GET_QUERY_RESULTS_REQUEST = 3; + */ + public static final int GET_QUERY_RESULTS_REQUEST_VALUE = 3; + /** + * + * + *
+       * Table data was accessed using the jobs.query RPC.
+       * 
+ * + * QUERY_REQUEST = 4; + */ + public static final int QUERY_REQUEST_VALUE = 4; + /** + * + * + *
+       * Table data was accessed using storage.CreateReadSession API.
+       * 
+ * + * CREATE_READ_SESSION = 5; + */ + public static final int CREATE_READ_SESSION_VALUE = 5; + /** + * + * + *
+       * Table data was accessed during a materialized view refresh.
+       * 
+ * + * MATERIALIZED_VIEW_REFRESH = 6; + */ + public static final int MATERIALIZED_VIEW_REFRESH_VALUE = 6; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return JOB; + case 2: + return TABLEDATA_LIST_REQUEST; + case 3: + return GET_QUERY_RESULTS_REQUEST; + case 4: + return QUERY_REQUEST; + case 5: + return CREATE_READ_SESSION; + case 6: + return MATERIALIZED_VIEW_REFRESH; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason) + } + + public static final int FIELDS_FIELD_NUMBER = 2; + private com.google.protobuf.LazyStringList fields_; + /** + * + * + *
+     * List of the accessed fields. Entire list is truncated if the record size
+     * exceeds 100K.
+     * 
+ * + * repeated string fields = 2; + * + * @return A list containing the fields. + */ + public com.google.protobuf.ProtocolStringList getFieldsList() { + return fields_; + } + /** + * + * + *
+     * List of the accessed fields. Entire list is truncated if the record size
+     * exceeds 100K.
+     * 
+ * + * repeated string fields = 2; + * + * @return The count of fields. + */ + public int getFieldsCount() { + return fields_.size(); + } + /** + * + * + *
+     * List of the accessed fields. Entire list is truncated if the record size
+     * exceeds 100K.
+     * 
+ * + * repeated string fields = 2; + * + * @param index The index of the element to return. + * @return The fields at the given index. + */ + public java.lang.String getFields(int index) { + return fields_.get(index); + } + /** + * + * + *
+     * List of the accessed fields. Entire list is truncated if the record size
+     * exceeds 100K.
+     * 
+ * + * repeated string fields = 2; + * + * @param index The index of the value to return. + * @return The bytes of the fields at the given index. + */ + public com.google.protobuf.ByteString getFieldsBytes(int index) { + return fields_.getByteString(index); + } + + public static final int FIELDS_TRUNCATED_FIELD_NUMBER = 8; + private boolean fieldsTruncated_; + /** + * + * + *
+     * True if the fields list was truncated.
+     * 
+ * + * bool fields_truncated = 8; + * + * @return The fieldsTruncated. + */ + @java.lang.Override + public boolean getFieldsTruncated() { + return fieldsTruncated_; + } + + public static final int POLICY_TAGS_FIELD_NUMBER = 9; + private com.google.protobuf.LazyStringList policyTags_; + /** + * + * + *
+     * List of the referenced policy tags. That is, policy tags attached to the
+     * accessed fields or their ancestors.
+     * Policy tag resource name is a string of the format:
+     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+     * 
+ * + * repeated string policy_tags = 9; + * + * @return A list containing the policyTags. + */ + public com.google.protobuf.ProtocolStringList getPolicyTagsList() { + return policyTags_; + } + /** + * + * + *
+     * List of the referenced policy tags. That is, policy tags attached to the
+     * accessed fields or their ancestors.
+     * Policy tag resource name is a string of the format:
+     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+     * 
+ * + * repeated string policy_tags = 9; + * + * @return The count of policyTags. + */ + public int getPolicyTagsCount() { + return policyTags_.size(); + } + /** + * + * + *
+     * List of the referenced policy tags. That is, policy tags attached to the
+     * accessed fields or their ancestors.
+     * Policy tag resource name is a string of the format:
+     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+     * 
+ * + * repeated string policy_tags = 9; + * + * @param index The index of the element to return. + * @return The policyTags at the given index. + */ + public java.lang.String getPolicyTags(int index) { + return policyTags_.get(index); + } + /** + * + * + *
+     * List of the referenced policy tags. That is, policy tags attached to the
+     * accessed fields or their ancestors.
+     * Policy tag resource name is a string of the format:
+     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+     * 
+ * + * repeated string policy_tags = 9; + * + * @param index The index of the value to return. + * @return The bytes of the policyTags at the given index. + */ + public com.google.protobuf.ByteString getPolicyTagsBytes(int index) { + return policyTags_.getByteString(index); + } + + public static final int POLICY_TAGS_TRUNCATED_FIELD_NUMBER = 10; + private boolean policyTagsTruncated_; + /** + * + * + *
+     * True if the policy tag list was truncated. At most 100 policy tags can be
+     * saved.
+     * 
+ * + * bool policy_tags_truncated = 10; + * + * @return The policyTagsTruncated. + */ + @java.lang.Override + public boolean getPolicyTagsTruncated() { + return policyTagsTruncated_; + } + + public static final int REASON_FIELD_NUMBER = 3; + private int reason_; + /** + * + * + *
+     * Describes how the table data was read.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the table data was read.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 4; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that read a table.
+     * Present if the reason is JOB but can be redacted for privacy reasons.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that read a table.
+     * Present if the reason is JOB but can be redacted for privacy reasons.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SESSION_NAME_FIELD_NUMBER = 5; + private volatile java.lang.Object sessionName_; + /** + * + * + *
+     * The URI of the read session that read a table.
+     * Present if the reason is CREATE_READ_SESSION.
+     * Format:
+     * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
+     * 
+ * + * string session_name = 5; + * + * @return The sessionName. + */ + @java.lang.Override + public java.lang.String getSessionName() { + java.lang.Object ref = sessionName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sessionName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the read session that read a table.
+     * Present if the reason is CREATE_READ_SESSION.
+     * Format:
+     * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
+     * 
+ * + * string session_name = 5; + * + * @return The bytes for sessionName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSessionNameBytes() { + java.lang.Object ref = sessionName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sessionName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < fields_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, fields_.getRaw(i)); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); + } + if (!getSessionNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, sessionName_); + } + if (fieldsTruncated_ != false) { + output.writeBool(8, fieldsTruncated_); + } + for (int i = 0; i < policyTags_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 9, policyTags_.getRaw(i)); + } + if (policyTagsTruncated_ != false) { + output.writeBool(10, policyTagsTruncated_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < fields_.size(); i++) { + dataSize += computeStringSizeNoTag(fields_.getRaw(i)); + } + size += dataSize; + size += 1 * getFieldsList().size(); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); + } + if (!getSessionNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, sessionName_); + } + if (fieldsTruncated_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, fieldsTruncated_); + } + { + int dataSize = 0; + for (int i = 0; i < policyTags_.size(); i++) { + dataSize += computeStringSizeNoTag(policyTags_.getRaw(i)); + } + size += dataSize; + size += 1 * getPolicyTagsList().size(); + } + if (policyTagsTruncated_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(10, policyTagsTruncated_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead other = + (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) obj; + + if (!getFieldsList().equals(other.getFieldsList())) return false; + if (getFieldsTruncated() != other.getFieldsTruncated()) return false; + if (!getPolicyTagsList().equals(other.getPolicyTagsList())) return false; + if (getPolicyTagsTruncated() != other.getPolicyTagsTruncated()) return false; + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!getSessionName().equals(other.getSessionName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getFieldsCount() > 0) { + hash = (37 * hash) + FIELDS_FIELD_NUMBER; + hash = (53 * hash) + getFieldsList().hashCode(); + } + hash = (37 * hash) + FIELDS_TRUNCATED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getFieldsTruncated()); + if (getPolicyTagsCount() > 0) { + hash = (37 * hash) + POLICY_TAGS_FIELD_NUMBER; + hash = (53 * hash) + getPolicyTagsList().hashCode(); + } + hash = (37 * hash) + POLICY_TAGS_TRUNCATED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPolicyTagsTruncated()); + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (37 * hash) + SESSION_NAME_FIELD_NUMBER; + hash = (53 * hash) + getSessionName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Table data read event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDataRead} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableDataRead) + com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + fields_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + fieldsTruncated_ = false; + + policyTags_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + policyTagsTruncated_ = false; + + reason_ = 0; + + jobName_ = ""; + + sessionName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead build() { + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead result = + new com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead(this); + int from_bitField0_ = bitField0_; + if (((bitField0_ & 0x00000001) != 0)) { + fields_ = fields_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.fields_ = fields_; + result.fieldsTruncated_ = fieldsTruncated_; + if (((bitField0_ & 0x00000002) != 0)) { + policyTags_ = policyTags_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.policyTags_ = policyTags_; + result.policyTagsTruncated_ = policyTagsTruncated_; + result.reason_ = reason_; + result.jobName_ = jobName_; + result.sessionName_ = sessionName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance()) + return this; + if (!other.fields_.isEmpty()) { + if (fields_.isEmpty()) { + fields_ = other.fields_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureFieldsIsMutable(); + fields_.addAll(other.fields_); + } + onChanged(); + } + if (other.getFieldsTruncated() != false) { + setFieldsTruncated(other.getFieldsTruncated()); + } + if (!other.policyTags_.isEmpty()) { + if (policyTags_.isEmpty()) { + policyTags_ = other.policyTags_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensurePolicyTagsIsMutable(); + policyTags_.addAll(other.policyTags_); + } + onChanged(); + } + if (other.getPolicyTagsTruncated() != false) { + setPolicyTagsTruncated(other.getPolicyTagsTruncated()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + if (!other.getSessionName().isEmpty()) { + sessionName_ = other.sessionName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringList fields_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureFieldsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + fields_ = new com.google.protobuf.LazyStringArrayList(fields_); + bitField0_ |= 0x00000001; + } + } + /** + * + * + *
+       * List of the accessed fields. Entire list is truncated if the record size
+       * exceeds 100K.
+       * 
+ * + * repeated string fields = 2; + * + * @return A list containing the fields. + */ + public com.google.protobuf.ProtocolStringList getFieldsList() { + return fields_.getUnmodifiableView(); + } + /** + * + * + *
+       * List of the accessed fields. Entire list is truncated if the record size
+       * exceeds 100K.
+       * 
+ * + * repeated string fields = 2; + * + * @return The count of fields. + */ + public int getFieldsCount() { + return fields_.size(); + } + /** + * + * + *
+       * List of the accessed fields. Entire list is truncated if the record size
+       * exceeds 100K.
+       * 
+ * + * repeated string fields = 2; + * + * @param index The index of the element to return. + * @return The fields at the given index. + */ + public java.lang.String getFields(int index) { + return fields_.get(index); + } + /** + * + * + *
+       * List of the accessed fields. Entire list is truncated if the record size
+       * exceeds 100K.
+       * 
+ * + * repeated string fields = 2; + * + * @param index The index of the value to return. + * @return The bytes of the fields at the given index. + */ + public com.google.protobuf.ByteString getFieldsBytes(int index) { + return fields_.getByteString(index); + } + /** + * + * + *
+       * List of the accessed fields. Entire list is truncated if the record size
+       * exceeds 100K.
+       * 
+ * + * repeated string fields = 2; + * + * @param index The index to set the value at. + * @param value The fields to set. + * @return This builder for chaining. + */ + public Builder setFields(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureFieldsIsMutable(); + fields_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+       * List of the accessed fields. Entire list is truncated if the record size
+       * exceeds 100K.
+       * 
+ * + * repeated string fields = 2; + * + * @param value The fields to add. + * @return This builder for chaining. + */ + public Builder addFields(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureFieldsIsMutable(); + fields_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+       * List of the accessed fields. Entire list is truncated if the record size
+       * exceeds 100K.
+       * 
+ * + * repeated string fields = 2; + * + * @param values The fields to add. + * @return This builder for chaining. + */ + public Builder addAllFields(java.lang.Iterable values) { + ensureFieldsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, fields_); + onChanged(); + return this; + } + /** + * + * + *
+       * List of the accessed fields. Entire list is truncated if the record size
+       * exceeds 100K.
+       * 
+ * + * repeated string fields = 2; + * + * @return This builder for chaining. + */ + public Builder clearFields() { + fields_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+       * List of the accessed fields. Entire list is truncated if the record size
+       * exceeds 100K.
+       * 
+ * + * repeated string fields = 2; + * + * @param value The bytes of the fields to add. + * @return This builder for chaining. + */ + public Builder addFieldsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureFieldsIsMutable(); + fields_.add(value); + onChanged(); + return this; + } + + private boolean fieldsTruncated_; + /** + * + * + *
+       * True if the fields list was truncated.
+       * 
+ * + * bool fields_truncated = 8; + * + * @return The fieldsTruncated. + */ + @java.lang.Override + public boolean getFieldsTruncated() { + return fieldsTruncated_; + } + /** + * + * + *
+       * True if the fields list was truncated.
+       * 
+ * + * bool fields_truncated = 8; + * + * @param value The fieldsTruncated to set. + * @return This builder for chaining. + */ + public Builder setFieldsTruncated(boolean value) { + + fieldsTruncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * True if the fields list was truncated.
+       * 
+ * + * bool fields_truncated = 8; + * + * @return This builder for chaining. + */ + public Builder clearFieldsTruncated() { + + fieldsTruncated_ = false; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringList policyTags_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensurePolicyTagsIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + policyTags_ = new com.google.protobuf.LazyStringArrayList(policyTags_); + bitField0_ |= 0x00000002; + } + } + /** + * + * + *
+       * List of the referenced policy tags. That is, policy tags attached to the
+       * accessed fields or their ancestors.
+       * Policy tag resource name is a string of the format:
+       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+       * 
+ * + * repeated string policy_tags = 9; + * + * @return A list containing the policyTags. + */ + public com.google.protobuf.ProtocolStringList getPolicyTagsList() { + return policyTags_.getUnmodifiableView(); + } + /** + * + * + *
+       * List of the referenced policy tags. That is, policy tags attached to the
+       * accessed fields or their ancestors.
+       * Policy tag resource name is a string of the format:
+       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+       * 
+ * + * repeated string policy_tags = 9; + * + * @return The count of policyTags. + */ + public int getPolicyTagsCount() { + return policyTags_.size(); + } + /** + * + * + *
+       * List of the referenced policy tags. That is, policy tags attached to the
+       * accessed fields or their ancestors.
+       * Policy tag resource name is a string of the format:
+       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+       * 
+ * + * repeated string policy_tags = 9; + * + * @param index The index of the element to return. + * @return The policyTags at the given index. + */ + public java.lang.String getPolicyTags(int index) { + return policyTags_.get(index); + } + /** + * + * + *
+       * List of the referenced policy tags. That is, policy tags attached to the
+       * accessed fields or their ancestors.
+       * Policy tag resource name is a string of the format:
+       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+       * 
+ * + * repeated string policy_tags = 9; + * + * @param index The index of the value to return. + * @return The bytes of the policyTags at the given index. + */ + public com.google.protobuf.ByteString getPolicyTagsBytes(int index) { + return policyTags_.getByteString(index); + } + /** + * + * + *
+       * List of the referenced policy tags. That is, policy tags attached to the
+       * accessed fields or their ancestors.
+       * Policy tag resource name is a string of the format:
+       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+       * 
+ * + * repeated string policy_tags = 9; + * + * @param index The index to set the value at. + * @param value The policyTags to set. + * @return This builder for chaining. + */ + public Builder setPolicyTags(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensurePolicyTagsIsMutable(); + policyTags_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+       * List of the referenced policy tags. That is, policy tags attached to the
+       * accessed fields or their ancestors.
+       * Policy tag resource name is a string of the format:
+       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+       * 
+ * + * repeated string policy_tags = 9; + * + * @param value The policyTags to add. + * @return This builder for chaining. + */ + public Builder addPolicyTags(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensurePolicyTagsIsMutable(); + policyTags_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+       * List of the referenced policy tags. That is, policy tags attached to the
+       * accessed fields or their ancestors.
+       * Policy tag resource name is a string of the format:
+       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+       * 
+ * + * repeated string policy_tags = 9; + * + * @param values The policyTags to add. + * @return This builder for chaining. + */ + public Builder addAllPolicyTags(java.lang.Iterable values) { + ensurePolicyTagsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, policyTags_); + onChanged(); + return this; + } + /** + * + * + *
+       * List of the referenced policy tags. That is, policy tags attached to the
+       * accessed fields or their ancestors.
+       * Policy tag resource name is a string of the format:
+       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+       * 
+ * + * repeated string policy_tags = 9; + * + * @return This builder for chaining. + */ + public Builder clearPolicyTags() { + policyTags_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + /** + * + * + *
+       * List of the referenced policy tags. That is, policy tags attached to the
+       * accessed fields or their ancestors.
+       * Policy tag resource name is a string of the format:
+       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
+       * 
+ * + * repeated string policy_tags = 9; + * + * @param value The bytes of the policyTags to add. + * @return This builder for chaining. + */ + public Builder addPolicyTagsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensurePolicyTagsIsMutable(); + policyTags_.add(value); + onChanged(); + return this; + } + + private boolean policyTagsTruncated_; + /** + * + * + *
+       * True if the policy tag list was truncated. At most 100 policy tags can be
+       * saved.
+       * 
+ * + * bool policy_tags_truncated = 10; + * + * @return The policyTagsTruncated. + */ + @java.lang.Override + public boolean getPolicyTagsTruncated() { + return policyTagsTruncated_; + } + /** + * + * + *
+       * True if the policy tag list was truncated. At most 100 policy tags can be
+       * saved.
+       * 
+ * + * bool policy_tags_truncated = 10; + * + * @param value The policyTagsTruncated to set. + * @return This builder for chaining. + */ + public Builder setPolicyTagsTruncated(boolean value) { + + policyTagsTruncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * True if the policy tag list was truncated. At most 100 policy tags can be
+       * saved.
+       * 
+ * + * bool policy_tags_truncated = 10; + * + * @return This builder for chaining. + */ + public Builder clearPolicyTagsTruncated() { + + policyTagsTruncated_ = false; + onChanged(); + return this; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the table data was read.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the table data was read.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the table data was read.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the table data was read.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the table data was read.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that read a table.
+       * Present if the reason is JOB but can be redacted for privacy reasons.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that read a table.
+       * Present if the reason is JOB but can be redacted for privacy reasons.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that read a table.
+       * Present if the reason is JOB but can be redacted for privacy reasons.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that read a table.
+       * Present if the reason is JOB but can be redacted for privacy reasons.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that read a table.
+       * Present if the reason is JOB but can be redacted for privacy reasons.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + private java.lang.Object sessionName_ = ""; + /** + * + * + *
+       * The URI of the read session that read a table.
+       * Present if the reason is CREATE_READ_SESSION.
+       * Format:
+       * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
+       * 
+ * + * string session_name = 5; + * + * @return The sessionName. + */ + public java.lang.String getSessionName() { + java.lang.Object ref = sessionName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + sessionName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the read session that read a table.
+       * Present if the reason is CREATE_READ_SESSION.
+       * Format:
+       * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
+       * 
+ * + * string session_name = 5; + * + * @return The bytes for sessionName. + */ + public com.google.protobuf.ByteString getSessionNameBytes() { + java.lang.Object ref = sessionName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + sessionName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the read session that read a table.
+       * Present if the reason is CREATE_READ_SESSION.
+       * Format:
+       * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
+       * 
+ * + * string session_name = 5; + * + * @param value The sessionName to set. + * @return This builder for chaining. + */ + public Builder setSessionName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + sessionName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the read session that read a table.
+       * Present if the reason is CREATE_READ_SESSION.
+       * Format:
+       * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
+       * 
+ * + * string session_name = 5; + * + * @return This builder for chaining. + */ + public Builder clearSessionName() { + + sessionName_ = getDefaultInstance().getSessionName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the read session that read a table.
+       * Present if the reason is CREATE_READ_SESSION.
+       * Format:
+       * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
+       * 
+ * + * string session_name = 5; + * + * @param value The bytes for sessionName to set. + * @return This builder for chaining. + */ + public Builder setSessionNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + sessionName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataRead) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataRead) + private static final com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public TableDataRead parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new TableDataRead(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface TableChangeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableChange) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Updated table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return Whether the table field is set. + */ + boolean hasTable(); + /** + * + * + *
+     * Updated table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return The table. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Table getTable(); + /** + * + * + *
+     * Updated table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder(); + + /** + * + * + *
+     * True if the table was truncated.
+     * 
+ * + * bool truncated = 4; + * + * @return The truncated. + */ + boolean getTruncated(); + + /** + * + * + *
+     * Describes how the table metadata was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the table metadata was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that changed a table.
+     * Present if the reason is JOB or QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 6; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that changed a table.
+     * Present if the reason is JOB or QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 6; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Table metadata change event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableChange} + */ + public static final class TableChange extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableChange) + TableChangeOrBuilder { + private static final long serialVersionUID = 0L; + // Use TableChange.newBuilder() to construct. + private TableChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private TableChange() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TableChange(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private TableChange( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder subBuilder = null; + if (table_ != null) { + subBuilder = table_.toBuilder(); + } + table_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Table.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(table_); + table_ = subBuilder.buildPartial(); + } + + break; + } + case 32: + { + truncated_ = input.readBool(); + break; + } + case 40: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder.class); + } + + /** + * + * + *
+     * Describes how the table metadata was changed.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Table metadata was updated using the tables.update or tables.patch API.
+       * 
+ * + * TABLE_UPDATE_REQUEST = 1; + */ + TABLE_UPDATE_REQUEST(1), + /** + * + * + *
+       * Table was used as a job destination table.
+       * 
+ * + * JOB = 2; + */ + JOB(2), + /** + * + * + *
+       * Table metadata was updated using a DML or DDL query.
+       * 
+ * + * QUERY = 3; + */ + QUERY(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Table metadata was updated using the tables.update or tables.patch API.
+       * 
+ * + * TABLE_UPDATE_REQUEST = 1; + */ + public static final int TABLE_UPDATE_REQUEST_VALUE = 1; + /** + * + * + *
+       * Table was used as a job destination table.
+       * 
+ * + * JOB = 2; + */ + public static final int JOB_VALUE = 2; + /** + * + * + *
+       * Table metadata was updated using a DML or DDL query.
+       * 
+ * + * QUERY = 3; + */ + public static final int QUERY_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return TABLE_UPDATE_REQUEST; + case 2: + return JOB; + case 3: + return QUERY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason) + } + + public static final int TABLE_FIELD_NUMBER = 1; + private com.google.cloud.audit.BigQueryAuditMetadata.Table table_; + /** + * + * + *
+     * Updated table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return Whether the table field is set. + */ + @java.lang.Override + public boolean hasTable() { + return table_ != null; + } + /** + * + * + *
+     * Updated table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return The table. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Table getTable() { + return table_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() + : table_; + } + /** + * + * + *
+     * Updated table metadata.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder() { + return getTable(); + } + + public static final int TRUNCATED_FIELD_NUMBER = 4; + private boolean truncated_; + /** + * + * + *
+     * True if the table was truncated.
+     * 
+ * + * bool truncated = 4; + * + * @return The truncated. + */ + @java.lang.Override + public boolean getTruncated() { + return truncated_; + } + + public static final int REASON_FIELD_NUMBER = 5; + private int reason_; + /** + * + * + *
+     * Describes how the table metadata was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the table metadata was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 6; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that changed a table.
+     * Present if the reason is JOB or QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 6; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that changed a table.
+     * Present if the reason is JOB or QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 6; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (table_ != null) { + output.writeMessage(1, getTable()); + } + if (truncated_ != false) { + output.writeBool(4, truncated_); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(5, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 6, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (table_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getTable()); + } + if (truncated_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, truncated_); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableChange)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.TableChange other = + (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) obj; + + if (hasTable() != other.hasTable()) return false; + if (hasTable()) { + if (!getTable().equals(other.getTable())) return false; + } + if (getTruncated() != other.getTruncated()) return false; + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasTable()) { + hash = (37 * hash) + TABLE_FIELD_NUMBER; + hash = (53 * hash) + getTable().hashCode(); + } + hash = (37 * hash) + TRUNCATED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getTruncated()); + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.TableChange prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Table metadata change event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableChange} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableChange) + com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableChange.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (tableBuilder_ == null) { + table_ = null; + } else { + table_ = null; + tableBuilder_ = null; + } + truncated_ = false; + + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableChange getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableChange build() { + com.google.cloud.audit.BigQueryAuditMetadata.TableChange result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableChange buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.TableChange result = + new com.google.cloud.audit.BigQueryAuditMetadata.TableChange(this); + if (tableBuilder_ == null) { + result.table_ = table_; + } else { + result.table_ = tableBuilder_.build(); + } + result.truncated_ = truncated_; + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableChange) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableChange) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableChange other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance()) + return this; + if (other.hasTable()) { + mergeTable(other.getTable()); + } + if (other.getTruncated() != false) { + setTruncated(other.getTruncated()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.TableChange parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Table table_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Table, + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder> + tableBuilder_; + /** + * + * + *
+       * Updated table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return Whether the table field is set. + */ + public boolean hasTable() { + return tableBuilder_ != null || table_ != null; + } + /** + * + * + *
+       * Updated table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + * + * @return The table. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Table getTable() { + if (tableBuilder_ == null) { + return table_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() + : table_; + } else { + return tableBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Updated table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public Builder setTable(com.google.cloud.audit.BigQueryAuditMetadata.Table value) { + if (tableBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + table_ = value; + onChanged(); + } else { + tableBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Updated table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public Builder setTable( + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder builderForValue) { + if (tableBuilder_ == null) { + table_ = builderForValue.build(); + onChanged(); + } else { + tableBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Updated table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public Builder mergeTable(com.google.cloud.audit.BigQueryAuditMetadata.Table value) { + if (tableBuilder_ == null) { + if (table_ != null) { + table_ = + com.google.cloud.audit.BigQueryAuditMetadata.Table.newBuilder(table_) + .mergeFrom(value) + .buildPartial(); + } else { + table_ = value; + } + onChanged(); + } else { + tableBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Updated table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public Builder clearTable() { + if (tableBuilder_ == null) { + table_ = null; + onChanged(); + } else { + table_ = null; + tableBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Updated table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder getTableBuilder() { + + onChanged(); + return getTableFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Updated table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder() { + if (tableBuilder_ != null) { + return tableBuilder_.getMessageOrBuilder(); + } else { + return table_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() + : table_; + } + } + /** + * + * + *
+       * Updated table metadata.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Table, + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder> + getTableFieldBuilder() { + if (tableBuilder_ == null) { + tableBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Table, + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder>( + getTable(), getParentForChildren(), isClean()); + table_ = null; + } + return tableBuilder_; + } + + private boolean truncated_; + /** + * + * + *
+       * True if the table was truncated.
+       * 
+ * + * bool truncated = 4; + * + * @return The truncated. + */ + @java.lang.Override + public boolean getTruncated() { + return truncated_; + } + /** + * + * + *
+       * True if the table was truncated.
+       * 
+ * + * bool truncated = 4; + * + * @param value The truncated to set. + * @return This builder for chaining. + */ + public Builder setTruncated(boolean value) { + + truncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * True if the table was truncated.
+       * 
+ * + * bool truncated = 4; + * + * @return This builder for chaining. + */ + public Builder clearTruncated() { + + truncated_ = false; + onChanged(); + return this; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the table metadata was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the table metadata was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the table metadata was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the table metadata was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the table metadata was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that changed a table.
+       * Present if the reason is JOB or QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 6; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that changed a table.
+       * Present if the reason is JOB or QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 6; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that changed a table.
+       * Present if the reason is JOB or QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 6; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that changed a table.
+       * Present if the reason is JOB or QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 6; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that changed a table.
+       * Present if the reason is JOB or QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 6; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableChange) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableChange) + private static final com.google.cloud.audit.BigQueryAuditMetadata.TableChange DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableChange(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public TableChange parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new TableChange(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableChange getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ModelMetadataChangeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Updated model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return Whether the model field is set. + */ + boolean hasModel(); + /** + * + * + *
+     * Updated model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return The model. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Model getModel(); + /** + * + * + *
+     * Updated model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder(); + + /** + * + * + *
+     * Describes how the model metadata was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the model metadata was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that changed the model metadata.
+     * Present if and only if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that changed the model metadata.
+     * Present if and only if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Model metadata change event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange} + */ + public static final class ModelMetadataChange extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) + ModelMetadataChangeOrBuilder { + private static final long serialVersionUID = 0L; + // Use ModelMetadataChange.newBuilder() to construct. + private ModelMetadataChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ModelMetadataChange() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ModelMetadataChange(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ModelMetadataChange( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder subBuilder = null; + if (model_ != null) { + subBuilder = model_.toBuilder(); + } + model_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Model.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(model_); + model_ = subBuilder.buildPartial(); + } + + break; + } + case 16: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder.class); + } + + /** + * + * + *
+     * Describes how the model metadata was changed.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Model metadata was updated using the models.patch API.
+       * 
+ * + * MODEL_PATCH_REQUEST = 1; + */ + MODEL_PATCH_REQUEST(1), + /** + * + * + *
+       * Model metadata was updated using a DDL query.
+       * 
+ * + * QUERY = 2; + */ + QUERY(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Model metadata was updated using the models.patch API.
+       * 
+ * + * MODEL_PATCH_REQUEST = 1; + */ + public static final int MODEL_PATCH_REQUEST_VALUE = 1; + /** + * + * + *
+       * Model metadata was updated using a DDL query.
+       * 
+ * + * QUERY = 2; + */ + public static final int QUERY_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return MODEL_PATCH_REQUEST; + case 2: + return QUERY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason) + } + + public static final int MODEL_FIELD_NUMBER = 1; + private com.google.cloud.audit.BigQueryAuditMetadata.Model model_; + /** + * + * + *
+     * Updated model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return Whether the model field is set. + */ + @java.lang.Override + public boolean hasModel() { + return model_ != null; + } + /** + * + * + *
+     * Updated model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return The model. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Model getModel() { + return model_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() + : model_; + } + /** + * + * + *
+     * Updated model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder() { + return getModel(); + } + + public static final int REASON_FIELD_NUMBER = 2; + private int reason_; + /** + * + * + *
+     * Describes how the model metadata was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the model metadata was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 3; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that changed the model metadata.
+     * Present if and only if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that changed the model metadata.
+     * Present if and only if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 3; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (model_ != null) { + output.writeMessage(1, getModel()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason + .REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(2, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (model_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getModel()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason + .REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange other = + (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) obj; + + if (hasModel() != other.hasModel()) return false; + if (hasModel()) { + if (!getModel().equals(other.getModel())) return false; + } + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasModel()) { + hash = (37 * hash) + MODEL_FIELD_NUMBER; + hash = (53 * hash) + getModel().hashCode(); + } + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Model metadata change event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder.class); + } + + // Construct using + // com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (modelBuilder_ == null) { + model_ = null; + } else { + model_ = null; + modelBuilder_ = null; + } + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange build() { + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange result = + new com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange(this); + if (modelBuilder_ == null) { + result.model_ = model_; + } else { + result.model_ = modelBuilder_.build(); + } + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) { + return mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + .getDefaultInstance()) return this; + if (other.hasModel()) { + mergeModel(other.getModel()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Model model_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Model, + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder> + modelBuilder_; + /** + * + * + *
+       * Updated model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return Whether the model field is set. + */ + public boolean hasModel() { + return modelBuilder_ != null || model_ != null; + } + /** + * + * + *
+       * Updated model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + * + * @return The model. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Model getModel() { + if (modelBuilder_ == null) { + return model_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() + : model_; + } else { + return modelBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Updated model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public Builder setModel(com.google.cloud.audit.BigQueryAuditMetadata.Model value) { + if (modelBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + model_ = value; + onChanged(); + } else { + modelBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Updated model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public Builder setModel( + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder builderForValue) { + if (modelBuilder_ == null) { + model_ = builderForValue.build(); + onChanged(); + } else { + modelBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Updated model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public Builder mergeModel(com.google.cloud.audit.BigQueryAuditMetadata.Model value) { + if (modelBuilder_ == null) { + if (model_ != null) { + model_ = + com.google.cloud.audit.BigQueryAuditMetadata.Model.newBuilder(model_) + .mergeFrom(value) + .buildPartial(); + } else { + model_ = value; + } + onChanged(); + } else { + modelBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Updated model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public Builder clearModel() { + if (modelBuilder_ == null) { + model_ = null; + onChanged(); + } else { + model_ = null; + modelBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Updated model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder getModelBuilder() { + + onChanged(); + return getModelFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Updated model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder() { + if (modelBuilder_ != null) { + return modelBuilder_.getMessageOrBuilder(); + } else { + return model_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() + : model_; + } + } + /** + * + * + *
+       * Updated model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Model, + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder> + getModelFieldBuilder() { + if (modelBuilder_ == null) { + modelBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Model, + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder>( + getModel(), getParentForChildren(), isClean()); + model_ = null; + } + return modelBuilder_; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the model metadata was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; + * + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the model metadata was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; + * + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the model metadata was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; + * + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason.valueOf( + reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the model metadata was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; + * + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the model metadata was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; + * + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that changed the model metadata.
+       * Present if and only if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that changed the model metadata.
+       * Present if and only if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that changed the model metadata.
+       * Present if and only if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that changed the model metadata.
+       * Present if and only if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that changed the model metadata.
+       * Present if and only if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 3; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) + private static final com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ModelMetadataChange parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ModelMetadataChange(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface RoutineChangeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.RoutineChange) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Updated routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return Whether the routine field is set. + */ + boolean hasRoutine(); + /** + * + * + *
+     * Updated routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return The routine. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine(); + /** + * + * + *
+     * Updated routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder(); + + /** + * + * + *
+     * Describes how the routine was updated.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the routine was updated.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that updated the routine.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that updated the routine.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Routine change event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineChange} + */ + public static final class RoutineChange extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineChange) + RoutineChangeOrBuilder { + private static final long serialVersionUID = 0L; + // Use RoutineChange.newBuilder() to construct. + private RoutineChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RoutineChange() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RoutineChange(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private RoutineChange( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder subBuilder = null; + if (routine_ != null) { + subBuilder = routine_.toBuilder(); + } + routine_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Routine.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(routine_); + routine_ = subBuilder.buildPartial(); + } + + break; + } + case 24: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder.class); + } + + /** + * + * + *
+     * Describes how the routine was updated.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Routine was updated using a DDL query.
+       * 
+ * + * QUERY = 1; + */ + QUERY(1), + /** + * + * + *
+       * Routine was updated using the routines.update or routines.patch API.
+       * 
+ * + * ROUTINE_UPDATE_REQUEST = 2; + */ + ROUTINE_UPDATE_REQUEST(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Routine was updated using a DDL query.
+       * 
+ * + * QUERY = 1; + */ + public static final int QUERY_VALUE = 1; + /** + * + * + *
+       * Routine was updated using the routines.update or routines.patch API.
+       * 
+ * + * ROUTINE_UPDATE_REQUEST = 2; + */ + public static final int ROUTINE_UPDATE_REQUEST_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return QUERY; + case 2: + return ROUTINE_UPDATE_REQUEST; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason) + } + + public static final int ROUTINE_FIELD_NUMBER = 1; + private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; + /** + * + * + *
+     * Updated routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return Whether the routine field is set. + */ + @java.lang.Override + public boolean hasRoutine() { + return routine_ != null; + } + /** + * + * + *
+     * Updated routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return The routine. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { + return routine_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() + : routine_; + } + /** + * + * + *
+     * Updated routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { + return getRoutine(); + } + + public static final int REASON_FIELD_NUMBER = 3; + private int reason_; + /** + * + * + *
+     * Describes how the routine was updated.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the routine was updated.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 4; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that updated the routine.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that updated the routine.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (routine_ != null) { + output.writeMessage(1, getRoutine()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (routine_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getRoutine()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange other = + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) obj; + + if (hasRoutine() != other.hasRoutine()) return false; + if (hasRoutine()) { + if (!getRoutine().equals(other.getRoutine())) return false; + } + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasRoutine()) { + hash = (37 * hash) + ROUTINE_FIELD_NUMBER; + hash = (53 * hash) + getRoutine().hashCode(); + } + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Routine change event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineChange} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineChange) + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (routineBuilder_ == null) { + routine_ = null; + } else { + routine_ = null; + routineBuilder_ = null; + } + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange build() { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange result = + new com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange(this); + if (routineBuilder_ == null) { + result.routine_ = routine_; + } else { + result.routine_ = routineBuilder_.build(); + } + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance()) + return this; + if (other.hasRoutine()) { + mergeRoutine(other.getRoutine()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Routine, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> + routineBuilder_; + /** + * + * + *
+       * Updated routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return Whether the routine field is set. + */ + public boolean hasRoutine() { + return routineBuilder_ != null || routine_ != null; + } + /** + * + * + *
+       * Updated routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return The routine. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { + if (routineBuilder_ == null) { + return routine_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() + : routine_; + } else { + return routineBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Updated routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder setRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { + if (routineBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + routine_ = value; + onChanged(); + } else { + routineBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Updated routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder setRoutine( + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder builderForValue) { + if (routineBuilder_ == null) { + routine_ = builderForValue.build(); + onChanged(); + } else { + routineBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Updated routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder mergeRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { + if (routineBuilder_ == null) { + if (routine_ != null) { + routine_ = + com.google.cloud.audit.BigQueryAuditMetadata.Routine.newBuilder(routine_) + .mergeFrom(value) + .buildPartial(); + } else { + routine_ = value; + } + onChanged(); + } else { + routineBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Updated routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder clearRoutine() { + if (routineBuilder_ == null) { + routine_ = null; + onChanged(); + } else { + routine_ = null; + routineBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Updated routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder getRoutineBuilder() { + + onChanged(); + return getRoutineFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Updated routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { + if (routineBuilder_ != null) { + return routineBuilder_.getMessageOrBuilder(); + } else { + return routine_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() + : routine_; + } + } + /** + * + * + *
+       * Updated routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Routine, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> + getRoutineFieldBuilder() { + if (routineBuilder_ == null) { + routineBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Routine, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder>( + getRoutine(), getParentForChildren(), isClean()); + routine_ = null; + } + return routineBuilder_; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the routine was updated.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the routine was updated.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the routine was updated.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the routine was updated.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the routine was updated.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that updated the routine.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that updated the routine.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that updated the routine.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that updated the routine.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that updated the routine.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineChange) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineChange) + private static final com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RoutineChange parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new RoutineChange(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface TableDataChangeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableDataChange) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Number of deleted rows.
+     * 
+ * + * int64 deleted_rows_count = 1; + * + * @return The deletedRowsCount. + */ + long getDeletedRowsCount(); + + /** + * + * + *
+     * Number of inserted rows.
+     * 
+ * + * int64 inserted_rows_count = 2; + * + * @return The insertedRowsCount. + */ + long getInsertedRowsCount(); + + /** + * + * + *
+     * True if the table was truncated.
+     * 
+ * + * bool truncated = 3; + * + * @return The truncated. + */ + boolean getTruncated(); + + /** + * + * + *
+     * Describes how the table data was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the table data was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that changed a table.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 5; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that changed a table.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 5; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + + /** + * + * + *
+     * If written from WRITE_API, the name of the stream.
+     * Format:
+     * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
+     * 
+ * + * string stream_name = 6; + * + * @return The streamName. + */ + java.lang.String getStreamName(); + /** + * + * + *
+     * If written from WRITE_API, the name of the stream.
+     * Format:
+     * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
+     * 
+ * + * string stream_name = 6; + * + * @return The bytes for streamName. + */ + com.google.protobuf.ByteString getStreamNameBytes(); + } + /** + * + * + *
+   * Table data change event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDataChange} + */ + public static final class TableDataChange extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableDataChange) + TableDataChangeOrBuilder { + private static final long serialVersionUID = 0L; + // Use TableDataChange.newBuilder() to construct. + private TableDataChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private TableDataChange() { + reason_ = 0; + jobName_ = ""; + streamName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TableDataChange(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private TableDataChange( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + deletedRowsCount_ = input.readInt64(); + break; + } + case 16: + { + insertedRowsCount_ = input.readInt64(); + break; + } + case 24: + { + truncated_ = input.readBool(); + break; + } + case 32: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + + streamName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder.class); + } + + /** + * + * + *
+     * Describes how the table data was changed.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Table was used as a job destination table.
+       * 
+ * + * JOB = 1; + */ + JOB(1), + /** + * + * + *
+       * Table data was updated using a DML or DDL query.
+       * 
+ * + * QUERY = 2; + */ + QUERY(2), + /** + * + * + *
+       * Table data was updated during a materialized view refresh.
+       * 
+ * + * MATERIALIZED_VIEW_REFRESH = 3; + */ + MATERIALIZED_VIEW_REFRESH(3), + /** + * + * + *
+       * Table data was added using the Write API.
+       * 
+ * + * WRITE_API = 4; + */ + WRITE_API(4), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Table was used as a job destination table.
+       * 
+ * + * JOB = 1; + */ + public static final int JOB_VALUE = 1; + /** + * + * + *
+       * Table data was updated using a DML or DDL query.
+       * 
+ * + * QUERY = 2; + */ + public static final int QUERY_VALUE = 2; + /** + * + * + *
+       * Table data was updated during a materialized view refresh.
+       * 
+ * + * MATERIALIZED_VIEW_REFRESH = 3; + */ + public static final int MATERIALIZED_VIEW_REFRESH_VALUE = 3; + /** + * + * + *
+       * Table data was added using the Write API.
+       * 
+ * + * WRITE_API = 4; + */ + public static final int WRITE_API_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return JOB; + case 2: + return QUERY; + case 3: + return MATERIALIZED_VIEW_REFRESH; + case 4: + return WRITE_API; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason) + } + + public static final int DELETED_ROWS_COUNT_FIELD_NUMBER = 1; + private long deletedRowsCount_; + /** + * + * + *
+     * Number of deleted rows.
+     * 
+ * + * int64 deleted_rows_count = 1; + * + * @return The deletedRowsCount. + */ + @java.lang.Override + public long getDeletedRowsCount() { + return deletedRowsCount_; + } + + public static final int INSERTED_ROWS_COUNT_FIELD_NUMBER = 2; + private long insertedRowsCount_; + /** + * + * + *
+     * Number of inserted rows.
+     * 
+ * + * int64 inserted_rows_count = 2; + * + * @return The insertedRowsCount. + */ + @java.lang.Override + public long getInsertedRowsCount() { + return insertedRowsCount_; + } + + public static final int TRUNCATED_FIELD_NUMBER = 3; + private boolean truncated_; + /** + * + * + *
+     * True if the table was truncated.
+     * 
+ * + * bool truncated = 3; + * + * @return The truncated. + */ + @java.lang.Override + public boolean getTruncated() { + return truncated_; + } + + public static final int REASON_FIELD_NUMBER = 4; + private int reason_; + /** + * + * + *
+     * Describes how the table data was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the table data was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 5; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that changed a table.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 5; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that changed a table.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 5; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STREAM_NAME_FIELD_NUMBER = 6; + private volatile java.lang.Object streamName_; + /** + * + * + *
+     * If written from WRITE_API, the name of the stream.
+     * Format:
+     * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
+     * 
+ * + * string stream_name = 6; + * + * @return The streamName. + */ + @java.lang.Override + public java.lang.String getStreamName() { + java.lang.Object ref = streamName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + streamName_ = s; + return s; + } + } + /** + * + * + *
+     * If written from WRITE_API, the name of the stream.
+     * Format:
+     * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
+     * 
+ * + * string stream_name = 6; + * + * @return The bytes for streamName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getStreamNameBytes() { + java.lang.Object ref = streamName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + streamName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (deletedRowsCount_ != 0L) { + output.writeInt64(1, deletedRowsCount_); + } + if (insertedRowsCount_ != 0L) { + output.writeInt64(2, insertedRowsCount_); + } + if (truncated_ != false) { + output.writeBool(3, truncated_); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, jobName_); + } + if (!getStreamNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 6, streamName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (deletedRowsCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, deletedRowsCount_); + } + if (insertedRowsCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, insertedRowsCount_); + } + if (truncated_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, truncated_); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, jobName_); + } + if (!getStreamNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, streamName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange other = + (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) obj; + + if (getDeletedRowsCount() != other.getDeletedRowsCount()) return false; + if (getInsertedRowsCount() != other.getInsertedRowsCount()) return false; + if (getTruncated() != other.getTruncated()) return false; + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!getStreamName().equals(other.getStreamName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + DELETED_ROWS_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getDeletedRowsCount()); + hash = (37 * hash) + INSERTED_ROWS_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getInsertedRowsCount()); + hash = (37 * hash) + TRUNCATED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getTruncated()); + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (37 * hash) + STREAM_NAME_FIELD_NUMBER; + hash = (53 * hash) + getStreamName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Table data change event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDataChange} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableDataChange) + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + deletedRowsCount_ = 0L; + + insertedRowsCount_ = 0L; + + truncated_ = false; + + reason_ = 0; + + jobName_ = ""; + + streamName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange build() { + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange result = + new com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange(this); + result.deletedRowsCount_ = deletedRowsCount_; + result.insertedRowsCount_ = insertedRowsCount_; + result.truncated_ = truncated_; + result.reason_ = reason_; + result.jobName_ = jobName_; + result.streamName_ = streamName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance()) + return this; + if (other.getDeletedRowsCount() != 0L) { + setDeletedRowsCount(other.getDeletedRowsCount()); + } + if (other.getInsertedRowsCount() != 0L) { + setInsertedRowsCount(other.getInsertedRowsCount()); + } + if (other.getTruncated() != false) { + setTruncated(other.getTruncated()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + if (!other.getStreamName().isEmpty()) { + streamName_ = other.streamName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private long deletedRowsCount_; + /** + * + * + *
+       * Number of deleted rows.
+       * 
+ * + * int64 deleted_rows_count = 1; + * + * @return The deletedRowsCount. + */ + @java.lang.Override + public long getDeletedRowsCount() { + return deletedRowsCount_; + } + /** + * + * + *
+       * Number of deleted rows.
+       * 
+ * + * int64 deleted_rows_count = 1; + * + * @param value The deletedRowsCount to set. + * @return This builder for chaining. + */ + public Builder setDeletedRowsCount(long value) { + + deletedRowsCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Number of deleted rows.
+       * 
+ * + * int64 deleted_rows_count = 1; + * + * @return This builder for chaining. + */ + public Builder clearDeletedRowsCount() { + + deletedRowsCount_ = 0L; + onChanged(); + return this; + } + + private long insertedRowsCount_; + /** + * + * + *
+       * Number of inserted rows.
+       * 
+ * + * int64 inserted_rows_count = 2; + * + * @return The insertedRowsCount. + */ + @java.lang.Override + public long getInsertedRowsCount() { + return insertedRowsCount_; + } + /** + * + * + *
+       * Number of inserted rows.
+       * 
+ * + * int64 inserted_rows_count = 2; + * + * @param value The insertedRowsCount to set. + * @return This builder for chaining. + */ + public Builder setInsertedRowsCount(long value) { + + insertedRowsCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Number of inserted rows.
+       * 
+ * + * int64 inserted_rows_count = 2; + * + * @return This builder for chaining. + */ + public Builder clearInsertedRowsCount() { + + insertedRowsCount_ = 0L; + onChanged(); + return this; + } + + private boolean truncated_; + /** + * + * + *
+       * True if the table was truncated.
+       * 
+ * + * bool truncated = 3; + * + * @return The truncated. + */ + @java.lang.Override + public boolean getTruncated() { + return truncated_; + } + /** + * + * + *
+       * True if the table was truncated.
+       * 
+ * + * bool truncated = 3; + * + * @param value The truncated to set. + * @return This builder for chaining. + */ + public Builder setTruncated(boolean value) { + + truncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * True if the table was truncated.
+       * 
+ * + * bool truncated = 3; + * + * @return This builder for chaining. + */ + public Builder clearTruncated() { + + truncated_ = false; + onChanged(); + return this; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the table data was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the table data was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the table data was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the table data was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the table data was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that changed a table.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 5; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that changed a table.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 5; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that changed a table.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 5; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that changed a table.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 5; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that changed a table.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 5; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + private java.lang.Object streamName_ = ""; + /** + * + * + *
+       * If written from WRITE_API, the name of the stream.
+       * Format:
+       * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
+       * 
+ * + * string stream_name = 6; + * + * @return The streamName. + */ + public java.lang.String getStreamName() { + java.lang.Object ref = streamName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + streamName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * If written from WRITE_API, the name of the stream.
+       * Format:
+       * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
+       * 
+ * + * string stream_name = 6; + * + * @return The bytes for streamName. + */ + public com.google.protobuf.ByteString getStreamNameBytes() { + java.lang.Object ref = streamName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + streamName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * If written from WRITE_API, the name of the stream.
+       * Format:
+       * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
+       * 
+ * + * string stream_name = 6; + * + * @param value The streamName to set. + * @return This builder for chaining. + */ + public Builder setStreamName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + streamName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * If written from WRITE_API, the name of the stream.
+       * Format:
+       * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
+       * 
+ * + * string stream_name = 6; + * + * @return This builder for chaining. + */ + public Builder clearStreamName() { + + streamName_ = getDefaultInstance().getStreamName(); + onChanged(); + return this; + } + /** + * + * + *
+       * If written from WRITE_API, the name of the stream.
+       * Format:
+       * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
+       * 
+ * + * string stream_name = 6; + * + * @param value The bytes for streamName to set. + * @return This builder for chaining. + */ + public Builder setStreamNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + streamName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataChange) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataChange) + private static final com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public TableDataChange parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new TableDataChange(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ModelDataChangeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Describes how the model data was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the model data was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that changed the model data.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that changed the model data.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Model data change event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataChange} + */ + public static final class ModelDataChange extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) + ModelDataChangeOrBuilder { + private static final long serialVersionUID = 0L; + // Use ModelDataChange.newBuilder() to construct. + private ModelDataChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ModelDataChange() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ModelDataChange(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ModelDataChange( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder.class); + } + + /** + * + * + *
+     * Describes how the model data was changed.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Model data was changed using a DDL query.
+       * 
+ * + * QUERY = 1; + */ + QUERY(1), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Model data was changed using a DDL query.
+       * 
+ * + * QUERY = 1; + */ + public static final int QUERY_VALUE = 1; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return QUERY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason) + } + + public static final int REASON_FIELD_NUMBER = 1; + private int reason_; + /** + * + * + *
+     * Describes how the model data was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the model data was changed.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 2; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that changed the model data.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that changed the model data.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange other = + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) obj; + + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Model data change event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataChange} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.class, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange build() { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange result = + new com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange(this); + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance()) + return this; + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the model data was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the model data was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the model data was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the model data was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the model data was changed.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that changed the model data.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that changed the model data.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that changed the model data.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that changed the model data.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that changed the model data.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) + private static final com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ModelDataChange parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ModelDataChange(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ModelDataReadOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Describes how the model data was read.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the model data was read.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that read the model data.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that read the model data.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Model data read event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataRead} + */ + public static final class ModelDataRead extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) + ModelDataReadOrBuilder { + private static final long serialVersionUID = 0L; + // Use ModelDataRead.newBuilder() to construct. + private ModelDataRead(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ModelDataRead() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ModelDataRead(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ModelDataRead( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.class, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder.class); + } + + /** + * + * + *
+     * Describes how the model data was read.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Model was used as a source model during a BigQuery job.
+       * 
+ * + * JOB = 1; + */ + JOB(1), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Model was used as a source model during a BigQuery job.
+       * 
+ * + * JOB = 1; + */ + public static final int JOB_VALUE = 1; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return JOB; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason) + } + + public static final int REASON_FIELD_NUMBER = 1; + private int reason_; + /** + * + * + *
+     * Describes how the model data was read.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the model data was read.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 2; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that read the model data.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that read the model data.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead other = + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) obj; + + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Model data read event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataRead} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.class, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead build() { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead result = + new com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead(this); + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance()) + return this; + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the model data was read.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the model data was read.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the model data was read.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the model data was read.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the model data was read.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that read the model data.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that read the model data.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that read the model data.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that read the model data.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that read the model data.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) + private static final com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ModelDataRead parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ModelDataRead(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface DatasetOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.Dataset) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Dataset URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>`.
+     * 
+ * + * string dataset_name = 1; + * + * @return The datasetName. + */ + java.lang.String getDatasetName(); + /** + * + * + *
+     * Dataset URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>`.
+     * 
+ * + * string dataset_name = 1; + * + * @return The bytes for datasetName. + */ + com.google.protobuf.ByteString getDatasetNameBytes(); + + /** + * + * + *
+     * Dataset creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 3; + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+     * Dataset creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 3; + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+     * Dataset creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 3; + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+     * Dataset metadata last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 4; + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + /** + * + * + *
+     * Dataset metadata last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 4; + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + * + * + *
+     * Dataset metadata last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 4; + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
+     * The access control list for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + * + * @return Whether the acl field is set. + */ + boolean hasAcl(); + /** + * + * + *
+     * The access control list for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + * + * @return The acl. + */ + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getAcl(); + /** + * + * + *
+     * The access control list for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + */ + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder getAclOrBuilder(); + + /** + * + * + *
+     * Default expiration time for tables in the dataset.
+     * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + * + * @return Whether the defaultTableExpireDuration field is set. + */ + boolean hasDefaultTableExpireDuration(); + /** + * + * + *
+     * Default expiration time for tables in the dataset.
+     * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + * + * @return The defaultTableExpireDuration. + */ + com.google.protobuf.Duration getDefaultTableExpireDuration(); + /** + * + * + *
+     * Default expiration time for tables in the dataset.
+     * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + */ + com.google.protobuf.DurationOrBuilder getDefaultTableExpireDurationOrBuilder(); + + /** + * + * + *
+     * User-provided metadata for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + * + * @return Whether the datasetInfo field is set. + */ + boolean hasDatasetInfo(); + /** + * + * + *
+     * User-provided metadata for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + * + * @return The datasetInfo. + */ + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDatasetInfo(); + /** + * + * + *
+     * User-provided metadata for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + */ + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder getDatasetInfoOrBuilder(); + + /** + * + * + *
+     * Default encryption for tables in the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + * @return Whether the defaultEncryption field is set. + */ + boolean hasDefaultEncryption(); + /** + * + * + *
+     * Default encryption for tables in the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + * @return The defaultEncryption. + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDefaultEncryption(); + /** + * + * + *
+     * Default encryption for tables in the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDefaultEncryptionOrBuilder(); + } + /** + * + * + *
+   * BigQuery dataset.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Dataset} + */ + public static final class Dataset extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.Dataset) + DatasetOrBuilder { + private static final long serialVersionUID = 0L; + // Use Dataset.newBuilder() to construct. + private Dataset(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Dataset() { + datasetName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Dataset(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Dataset( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + datasetName_ = s; + break; + } + case 26: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (createTime_ != null) { + subBuilder = createTime_.toBuilder(); + } + createTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(createTime_); + createTime_ = subBuilder.buildPartial(); + } + + break; + } + case 34: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (updateTime_ != null) { + subBuilder = updateTime_.toBuilder(); + } + updateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(updateTime_); + updateTime_ = subBuilder.buildPartial(); + } + + break; + } + case 42: + { + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder subBuilder = null; + if (acl_ != null) { + subBuilder = acl_.toBuilder(); + } + acl_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(acl_); + acl_ = subBuilder.buildPartial(); + } + + break; + } + case 50: + { + com.google.protobuf.Duration.Builder subBuilder = null; + if (defaultTableExpireDuration_ != null) { + subBuilder = defaultTableExpireDuration_.toBuilder(); + } + defaultTableExpireDuration_ = + input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(defaultTableExpireDuration_); + defaultTableExpireDuration_ = subBuilder.buildPartial(); + } + + break; + } + case 58: + { + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder subBuilder = null; + if (datasetInfo_ != null) { + subBuilder = datasetInfo_.toBuilder(); + } + datasetInfo_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(datasetInfo_); + datasetInfo_ = subBuilder.buildPartial(); + } + + break; + } + case 66: + { + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = + null; + if (defaultEncryption_ != null) { + subBuilder = defaultEncryption_.toBuilder(); + } + defaultEncryption_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(defaultEncryption_); + defaultEncryption_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.class, + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder.class); + } + + public static final int DATASET_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object datasetName_; + /** + * + * + *
+     * Dataset URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>`.
+     * 
+ * + * string dataset_name = 1; + * + * @return The datasetName. + */ + @java.lang.Override + public java.lang.String getDatasetName() { + java.lang.Object ref = datasetName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + datasetName_ = s; + return s; + } + } + /** + * + * + *
+     * Dataset URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>`.
+     * 
+ * + * string dataset_name = 1; + * + * @return The bytes for datasetName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDatasetNameBytes() { + java.lang.Object ref = datasetName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + datasetName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+     * Dataset creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 3; + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+     * Dataset creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 3; + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+     * Dataset creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 3; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 4; + private com.google.protobuf.Timestamp updateTime_; + /** + * + * + *
+     * Dataset metadata last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 4; + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + * + * + *
+     * Dataset metadata last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 4; + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + * + * + *
+     * Dataset metadata last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 4; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + public static final int ACL_FIELD_NUMBER = 5; + private com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl_; + /** + * + * + *
+     * The access control list for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + * + * @return Whether the acl field is set. + */ + @java.lang.Override + public boolean hasAcl() { + return acl_ != null; + } + /** + * + * + *
+     * The access control list for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + * + * @return The acl. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getAcl() { + return acl_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.getDefaultInstance() + : acl_; + } + /** + * + * + *
+     * The access control list for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder getAclOrBuilder() { + return getAcl(); + } + + public static final int DEFAULT_TABLE_EXPIRE_DURATION_FIELD_NUMBER = 6; + private com.google.protobuf.Duration defaultTableExpireDuration_; + /** + * + * + *
+     * Default expiration time for tables in the dataset.
+     * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + * + * @return Whether the defaultTableExpireDuration field is set. + */ + @java.lang.Override + public boolean hasDefaultTableExpireDuration() { + return defaultTableExpireDuration_ != null; + } + /** + * + * + *
+     * Default expiration time for tables in the dataset.
+     * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + * + * @return The defaultTableExpireDuration. + */ + @java.lang.Override + public com.google.protobuf.Duration getDefaultTableExpireDuration() { + return defaultTableExpireDuration_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : defaultTableExpireDuration_; + } + /** + * + * + *
+     * Default expiration time for tables in the dataset.
+     * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getDefaultTableExpireDurationOrBuilder() { + return getDefaultTableExpireDuration(); + } + + public static final int DATASET_INFO_FIELD_NUMBER = 7; + private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo datasetInfo_; + /** + * + * + *
+     * User-provided metadata for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + * + * @return Whether the datasetInfo field is set. + */ + @java.lang.Override + public boolean hasDatasetInfo() { + return datasetInfo_ != null; + } + /** + * + * + *
+     * User-provided metadata for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + * + * @return The datasetInfo. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDatasetInfo() { + return datasetInfo_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() + : datasetInfo_; + } + /** + * + * + *
+     * User-provided metadata for the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder + getDatasetInfoOrBuilder() { + return getDatasetInfo(); + } + + public static final int DEFAULT_ENCRYPTION_FIELD_NUMBER = 8; + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo defaultEncryption_; + /** + * + * + *
+     * Default encryption for tables in the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + * @return Whether the defaultEncryption field is set. + */ + @java.lang.Override + public boolean hasDefaultEncryption() { + return defaultEncryption_ != null; + } + /** + * + * + *
+     * Default encryption for tables in the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + * @return The defaultEncryption. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDefaultEncryption() { + return defaultEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : defaultEncryption_; + } + /** + * + * + *
+     * Default encryption for tables in the dataset.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDefaultEncryptionOrBuilder() { + return getDefaultEncryption(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getDatasetNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, datasetName_); + } + if (createTime_ != null) { + output.writeMessage(3, getCreateTime()); + } + if (updateTime_ != null) { + output.writeMessage(4, getUpdateTime()); + } + if (acl_ != null) { + output.writeMessage(5, getAcl()); + } + if (defaultTableExpireDuration_ != null) { + output.writeMessage(6, getDefaultTableExpireDuration()); + } + if (datasetInfo_ != null) { + output.writeMessage(7, getDatasetInfo()); + } + if (defaultEncryption_ != null) { + output.writeMessage(8, getDefaultEncryption()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getDatasetNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, datasetName_); + } + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCreateTime()); + } + if (updateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getUpdateTime()); + } + if (acl_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getAcl()); + } + if (defaultTableExpireDuration_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 6, getDefaultTableExpireDuration()); + } + if (datasetInfo_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getDatasetInfo()); + } + if (defaultEncryption_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getDefaultEncryption()); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.Dataset)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.Dataset other = + (com.google.cloud.audit.BigQueryAuditMetadata.Dataset) obj; + + if (!getDatasetName().equals(other.getDatasetName())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (hasAcl() != other.hasAcl()) return false; + if (hasAcl()) { + if (!getAcl().equals(other.getAcl())) return false; + } + if (hasDefaultTableExpireDuration() != other.hasDefaultTableExpireDuration()) return false; + if (hasDefaultTableExpireDuration()) { + if (!getDefaultTableExpireDuration().equals(other.getDefaultTableExpireDuration())) + return false; + } + if (hasDatasetInfo() != other.hasDatasetInfo()) return false; + if (hasDatasetInfo()) { + if (!getDatasetInfo().equals(other.getDatasetInfo())) return false; + } + if (hasDefaultEncryption() != other.hasDefaultEncryption()) return false; + if (hasDefaultEncryption()) { + if (!getDefaultEncryption().equals(other.getDefaultEncryption())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + DATASET_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDatasetName().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + if (hasAcl()) { + hash = (37 * hash) + ACL_FIELD_NUMBER; + hash = (53 * hash) + getAcl().hashCode(); + } + if (hasDefaultTableExpireDuration()) { + hash = (37 * hash) + DEFAULT_TABLE_EXPIRE_DURATION_FIELD_NUMBER; + hash = (53 * hash) + getDefaultTableExpireDuration().hashCode(); + } + if (hasDatasetInfo()) { + hash = (37 * hash) + DATASET_INFO_FIELD_NUMBER; + hash = (53 * hash) + getDatasetInfo().hashCode(); + } + if (hasDefaultEncryption()) { + hash = (37 * hash) + DEFAULT_ENCRYPTION_FIELD_NUMBER; + hash = (53 * hash) + getDefaultEncryption().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.Dataset prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * BigQuery dataset.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Dataset} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.Dataset) + com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.class, + com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.Dataset.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + datasetName_ = ""; + + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + if (aclBuilder_ == null) { + acl_ = null; + } else { + acl_ = null; + aclBuilder_ = null; + } + if (defaultTableExpireDurationBuilder_ == null) { + defaultTableExpireDuration_ = null; + } else { + defaultTableExpireDuration_ = null; + defaultTableExpireDurationBuilder_ = null; + } + if (datasetInfoBuilder_ == null) { + datasetInfo_ = null; + } else { + datasetInfo_ = null; + datasetInfoBuilder_ = null; + } + if (defaultEncryptionBuilder_ == null) { + defaultEncryption_ = null; + } else { + defaultEncryption_ = null; + defaultEncryptionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Dataset build() { + com.google.cloud.audit.BigQueryAuditMetadata.Dataset result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Dataset buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.Dataset result = + new com.google.cloud.audit.BigQueryAuditMetadata.Dataset(this); + result.datasetName_ = datasetName_; + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (updateTimeBuilder_ == null) { + result.updateTime_ = updateTime_; + } else { + result.updateTime_ = updateTimeBuilder_.build(); + } + if (aclBuilder_ == null) { + result.acl_ = acl_; + } else { + result.acl_ = aclBuilder_.build(); + } + if (defaultTableExpireDurationBuilder_ == null) { + result.defaultTableExpireDuration_ = defaultTableExpireDuration_; + } else { + result.defaultTableExpireDuration_ = defaultTableExpireDurationBuilder_.build(); + } + if (datasetInfoBuilder_ == null) { + result.datasetInfo_ = datasetInfo_; + } else { + result.datasetInfo_ = datasetInfoBuilder_.build(); + } + if (defaultEncryptionBuilder_ == null) { + result.defaultEncryption_ = defaultEncryption_; + } else { + result.defaultEncryption_ = defaultEncryptionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.Dataset) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.Dataset) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.Dataset other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance()) + return this; + if (!other.getDatasetName().isEmpty()) { + datasetName_ = other.datasetName_; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (other.hasAcl()) { + mergeAcl(other.getAcl()); + } + if (other.hasDefaultTableExpireDuration()) { + mergeDefaultTableExpireDuration(other.getDefaultTableExpireDuration()); + } + if (other.hasDatasetInfo()) { + mergeDatasetInfo(other.getDatasetInfo()); + } + if (other.hasDefaultEncryption()) { + mergeDefaultEncryption(other.getDefaultEncryption()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.Dataset parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.Dataset) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object datasetName_ = ""; + /** + * + * + *
+       * Dataset URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>`.
+       * 
+ * + * string dataset_name = 1; + * + * @return The datasetName. + */ + public java.lang.String getDatasetName() { + java.lang.Object ref = datasetName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + datasetName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * Dataset URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>`.
+       * 
+ * + * string dataset_name = 1; + * + * @return The bytes for datasetName. + */ + public com.google.protobuf.ByteString getDatasetNameBytes() { + java.lang.Object ref = datasetName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + datasetName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * Dataset URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>`.
+       * 
+ * + * string dataset_name = 1; + * + * @param value The datasetName to set. + * @return This builder for chaining. + */ + public Builder setDatasetName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + datasetName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Dataset URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>`.
+       * 
+ * + * string dataset_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearDatasetName() { + + datasetName_ = getDefaultInstance().getDatasetName(); + onChanged(); + return this; + } + /** + * + * + *
+       * Dataset URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>`.
+       * 
+ * + * string dataset_name = 1; + * + * @param value The bytes for datasetName to set. + * @return This builder for chaining. + */ + public Builder setDatasetNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + datasetName_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + /** + * + * + *
+       * Dataset creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 3; + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+       * Dataset creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 3; + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Dataset creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 3; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Dataset creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 3; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Dataset creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 3; + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_) + .mergeFrom(value) + .buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Dataset creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 3; + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Dataset creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 3; + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Dataset creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 3; + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+       * Dataset creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + /** + * + * + *
+       * Dataset metadata last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 4; + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + * + * + *
+       * Dataset metadata last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 4; + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Dataset metadata last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 4; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + onChanged(); + } else { + updateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Dataset metadata last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 4; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + onChanged(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Dataset metadata last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 4; + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (updateTime_ != null) { + updateTime_ = + com.google.protobuf.Timestamp.newBuilder(updateTime_) + .mergeFrom(value) + .buildPartial(); + } else { + updateTime_ = value; + } + onChanged(); + } else { + updateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Dataset metadata last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 4; + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Dataset metadata last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 4; + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Dataset metadata last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 4; + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + /** + * + * + *
+       * Dataset metadata last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl, + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder> + aclBuilder_; + /** + * + * + *
+       * The access control list for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + * + * @return Whether the acl field is set. + */ + public boolean hasAcl() { + return aclBuilder_ != null || acl_ != null; + } + /** + * + * + *
+       * The access control list for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + * + * @return The acl. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getAcl() { + if (aclBuilder_ == null) { + return acl_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.getDefaultInstance() + : acl_; + } else { + return aclBuilder_.getMessage(); + } + } + /** + * + * + *
+       * The access control list for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + */ + public Builder setAcl(com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl value) { + if (aclBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + acl_ = value; + onChanged(); + } else { + aclBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * The access control list for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + */ + public Builder setAcl( + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder builderForValue) { + if (aclBuilder_ == null) { + acl_ = builderForValue.build(); + onChanged(); + } else { + aclBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * The access control list for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + */ + public Builder mergeAcl(com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl value) { + if (aclBuilder_ == null) { + if (acl_ != null) { + acl_ = + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.newBuilder(acl_) + .mergeFrom(value) + .buildPartial(); + } else { + acl_ = value; + } + onChanged(); + } else { + aclBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * The access control list for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + */ + public Builder clearAcl() { + if (aclBuilder_ == null) { + acl_ = null; + onChanged(); + } else { + acl_ = null; + aclBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * The access control list for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder getAclBuilder() { + + onChanged(); + return getAclFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * The access control list for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder getAclOrBuilder() { + if (aclBuilder_ != null) { + return aclBuilder_.getMessageOrBuilder(); + } else { + return acl_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.getDefaultInstance() + : acl_; + } + } + /** + * + * + *
+       * The access control list for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl, + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder> + getAclFieldBuilder() { + if (aclBuilder_ == null) { + aclBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl, + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder>( + getAcl(), getParentForChildren(), isClean()); + acl_ = null; + } + return aclBuilder_; + } + + private com.google.protobuf.Duration defaultTableExpireDuration_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + defaultTableExpireDurationBuilder_; + /** + * + * + *
+       * Default expiration time for tables in the dataset.
+       * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + * + * @return Whether the defaultTableExpireDuration field is set. + */ + public boolean hasDefaultTableExpireDuration() { + return defaultTableExpireDurationBuilder_ != null || defaultTableExpireDuration_ != null; + } + /** + * + * + *
+       * Default expiration time for tables in the dataset.
+       * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + * + * @return The defaultTableExpireDuration. + */ + public com.google.protobuf.Duration getDefaultTableExpireDuration() { + if (defaultTableExpireDurationBuilder_ == null) { + return defaultTableExpireDuration_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : defaultTableExpireDuration_; + } else { + return defaultTableExpireDurationBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Default expiration time for tables in the dataset.
+       * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + */ + public Builder setDefaultTableExpireDuration(com.google.protobuf.Duration value) { + if (defaultTableExpireDurationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + defaultTableExpireDuration_ = value; + onChanged(); + } else { + defaultTableExpireDurationBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Default expiration time for tables in the dataset.
+       * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + */ + public Builder setDefaultTableExpireDuration( + com.google.protobuf.Duration.Builder builderForValue) { + if (defaultTableExpireDurationBuilder_ == null) { + defaultTableExpireDuration_ = builderForValue.build(); + onChanged(); + } else { + defaultTableExpireDurationBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Default expiration time for tables in the dataset.
+       * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + */ + public Builder mergeDefaultTableExpireDuration(com.google.protobuf.Duration value) { + if (defaultTableExpireDurationBuilder_ == null) { + if (defaultTableExpireDuration_ != null) { + defaultTableExpireDuration_ = + com.google.protobuf.Duration.newBuilder(defaultTableExpireDuration_) + .mergeFrom(value) + .buildPartial(); + } else { + defaultTableExpireDuration_ = value; + } + onChanged(); + } else { + defaultTableExpireDurationBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Default expiration time for tables in the dataset.
+       * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + */ + public Builder clearDefaultTableExpireDuration() { + if (defaultTableExpireDurationBuilder_ == null) { + defaultTableExpireDuration_ = null; + onChanged(); + } else { + defaultTableExpireDuration_ = null; + defaultTableExpireDurationBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Default expiration time for tables in the dataset.
+       * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + */ + public com.google.protobuf.Duration.Builder getDefaultTableExpireDurationBuilder() { + + onChanged(); + return getDefaultTableExpireDurationFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Default expiration time for tables in the dataset.
+       * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + */ + public com.google.protobuf.DurationOrBuilder getDefaultTableExpireDurationOrBuilder() { + if (defaultTableExpireDurationBuilder_ != null) { + return defaultTableExpireDurationBuilder_.getMessageOrBuilder(); + } else { + return defaultTableExpireDuration_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : defaultTableExpireDuration_; + } + } + /** + * + * + *
+       * Default expiration time for tables in the dataset.
+       * 
+ * + * .google.protobuf.Duration default_table_expire_duration = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + getDefaultTableExpireDurationFieldBuilder() { + if (defaultTableExpireDurationBuilder_ == null) { + defaultTableExpireDurationBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getDefaultTableExpireDuration(), getParentForChildren(), isClean()); + defaultTableExpireDuration_ = null; + } + return defaultTableExpireDurationBuilder_; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo datasetInfo_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> + datasetInfoBuilder_; + /** + * + * + *
+       * User-provided metadata for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + * + * @return Whether the datasetInfo field is set. + */ + public boolean hasDatasetInfo() { + return datasetInfoBuilder_ != null || datasetInfo_ != null; + } + /** + * + * + *
+       * User-provided metadata for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + * + * @return The datasetInfo. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDatasetInfo() { + if (datasetInfoBuilder_ == null) { + return datasetInfo_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() + : datasetInfo_; + } else { + return datasetInfoBuilder_.getMessage(); + } + } + /** + * + * + *
+       * User-provided metadata for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + */ + public Builder setDatasetInfo(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { + if (datasetInfoBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + datasetInfo_ = value; + onChanged(); + } else { + datasetInfoBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + */ + public Builder setDatasetInfo( + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder builderForValue) { + if (datasetInfoBuilder_ == null) { + datasetInfo_ = builderForValue.build(); + onChanged(); + } else { + datasetInfoBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + */ + public Builder mergeDatasetInfo( + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { + if (datasetInfoBuilder_ == null) { + if (datasetInfo_ != null) { + datasetInfo_ = + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.newBuilder(datasetInfo_) + .mergeFrom(value) + .buildPartial(); + } else { + datasetInfo_ = value; + } + onChanged(); + } else { + datasetInfoBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + */ + public Builder clearDatasetInfo() { + if (datasetInfoBuilder_ == null) { + datasetInfo_ = null; + onChanged(); + } else { + datasetInfo_ = null; + datasetInfoBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder + getDatasetInfoBuilder() { + + onChanged(); + return getDatasetInfoFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * User-provided metadata for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder + getDatasetInfoOrBuilder() { + if (datasetInfoBuilder_ != null) { + return datasetInfoBuilder_.getMessageOrBuilder(); + } else { + return datasetInfo_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() + : datasetInfo_; + } + } + /** + * + * + *
+       * User-provided metadata for the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> + getDatasetInfoFieldBuilder() { + if (datasetInfoBuilder_ == null) { + datasetInfoBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder>( + getDatasetInfo(), getParentForChildren(), isClean()); + datasetInfo_ = null; + } + return datasetInfoBuilder_; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo defaultEncryption_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + defaultEncryptionBuilder_; + /** + * + * + *
+       * Default encryption for tables in the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + * + * @return Whether the defaultEncryption field is set. + */ + public boolean hasDefaultEncryption() { + return defaultEncryptionBuilder_ != null || defaultEncryption_ != null; + } + /** + * + * + *
+       * Default encryption for tables in the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + * + * @return The defaultEncryption. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDefaultEncryption() { + if (defaultEncryptionBuilder_ == null) { + return defaultEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : defaultEncryption_; + } else { + return defaultEncryptionBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Default encryption for tables in the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + */ + public Builder setDefaultEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (defaultEncryptionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + defaultEncryption_ = value; + onChanged(); + } else { + defaultEncryptionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Default encryption for tables in the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + */ + public Builder setDefaultEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { + if (defaultEncryptionBuilder_ == null) { + defaultEncryption_ = builderForValue.build(); + onChanged(); + } else { + defaultEncryptionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Default encryption for tables in the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + */ + public Builder mergeDefaultEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (defaultEncryptionBuilder_ == null) { + if (defaultEncryption_ != null) { + defaultEncryption_ = + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder( + defaultEncryption_) + .mergeFrom(value) + .buildPartial(); + } else { + defaultEncryption_ = value; + } + onChanged(); + } else { + defaultEncryptionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Default encryption for tables in the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + */ + public Builder clearDefaultEncryption() { + if (defaultEncryptionBuilder_ == null) { + defaultEncryption_ = null; + onChanged(); + } else { + defaultEncryption_ = null; + defaultEncryptionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Default encryption for tables in the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder + getDefaultEncryptionBuilder() { + + onChanged(); + return getDefaultEncryptionFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Default encryption for tables in the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDefaultEncryptionOrBuilder() { + if (defaultEncryptionBuilder_ != null) { + return defaultEncryptionBuilder_.getMessageOrBuilder(); + } else { + return defaultEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : defaultEncryption_; + } + } + /** + * + * + *
+       * Default encryption for tables in the dataset.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + getDefaultEncryptionFieldBuilder() { + if (defaultEncryptionBuilder_ == null) { + defaultEncryptionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( + getDefaultEncryption(), getParentForChildren(), isClean()); + defaultEncryption_ = null; + } + return defaultEncryptionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.Dataset) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.Dataset) + private static final com.google.cloud.audit.BigQueryAuditMetadata.Dataset DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.Dataset(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Dataset parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Dataset(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface TableDeletionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableDeletion) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Describes how the table was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the table was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that deleted a table.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that deleted a table.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Table deletion event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDeletion} + */ + public static final class TableDeletion extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableDeletion) + TableDeletionOrBuilder { + private static final long serialVersionUID = 0L; + // Use TableDeletion.newBuilder() to construct. + private TableDeletion(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private TableDeletion() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TableDeletion(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private TableDeletion( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder.class); + } + + /** + * + * + *
+     * Describes how the table was deleted.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Table was deleted using the tables.delete API.
+       * 
+ * + * TABLE_DELETE_REQUEST = 2; + */ + TABLE_DELETE_REQUEST(2), + /** + * + * + *
+       * Table expired.
+       * 
+ * + * EXPIRED = 3; + */ + EXPIRED(3), + /** + * + * + *
+       * Table deleted using a DDL query.
+       * 
+ * + * QUERY = 4; + */ + QUERY(4), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Table was deleted using the tables.delete API.
+       * 
+ * + * TABLE_DELETE_REQUEST = 2; + */ + public static final int TABLE_DELETE_REQUEST_VALUE = 2; + /** + * + * + *
+       * Table expired.
+       * 
+ * + * EXPIRED = 3; + */ + public static final int EXPIRED_VALUE = 3; + /** + * + * + *
+       * Table deleted using a DDL query.
+       * 
+ * + * QUERY = 4; + */ + public static final int QUERY_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 2: + return TABLE_DELETE_REQUEST; + case 3: + return EXPIRED; + case 4: + return QUERY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason) + } + + public static final int REASON_FIELD_NUMBER = 1; + private int reason_; + /** + * + * + *
+     * Describes how the table was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the table was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 2; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that deleted a table.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that deleted a table.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion other = + (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) obj; + + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Table deletion event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDeletion} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableDeletion) + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion build() { + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion result = + new com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion(this); + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance()) + return this; + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the table was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the table was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the table was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the table was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the table was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that deleted a table.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that deleted a table.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that deleted a table.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that deleted a table.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that deleted a table.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableDeletion) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableDeletion) + private static final com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public TableDeletion parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new TableDeletion(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ModelDeletionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Describes how the model was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the model was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that deleted a model.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that deleted a model.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Model deletion event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDeletion} + */ + public static final class ModelDeletion extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) + ModelDeletionOrBuilder { + private static final long serialVersionUID = 0L; + // Use ModelDeletion.newBuilder() to construct. + private ModelDeletion(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ModelDeletion() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ModelDeletion(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ModelDeletion( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.class, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder.class); + } + + /** + * + * + *
+     * Describes how the model was deleted.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Model was deleted using the models.delete API.
+       * 
+ * + * MODEL_DELETE_REQUEST = 1; + */ + MODEL_DELETE_REQUEST(1), + /** + * + * + *
+       * Model expired.
+       * 
+ * + * EXPIRED = 2; + */ + EXPIRED(2), + /** + * + * + *
+       * Model was deleted using DDL query.
+       * 
+ * + * QUERY = 3; + */ + QUERY(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Model was deleted using the models.delete API.
+       * 
+ * + * MODEL_DELETE_REQUEST = 1; + */ + public static final int MODEL_DELETE_REQUEST_VALUE = 1; + /** + * + * + *
+       * Model expired.
+       * 
+ * + * EXPIRED = 2; + */ + public static final int EXPIRED_VALUE = 2; + /** + * + * + *
+       * Model was deleted using DDL query.
+       * 
+ * + * QUERY = 3; + */ + public static final int QUERY_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return MODEL_DELETE_REQUEST; + case 2: + return EXPIRED; + case 3: + return QUERY; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason) + } + + public static final int REASON_FIELD_NUMBER = 1; + private int reason_; + /** + * + * + *
+     * Describes how the model was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the model was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 2; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that deleted a model.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that deleted a model.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion other = + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) obj; + + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Model deletion event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDeletion} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.class, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion build() { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion result = + new com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion(this); + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance()) + return this; + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the model was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the model was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the model was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the model was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the model was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that deleted a model.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that deleted a model.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that deleted a model.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that deleted a model.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that deleted a model.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 2; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) + private static final com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ModelDeletion parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ModelDeletion(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ModelOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.Model) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Model URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
+     * 
+ * + * string model_name = 1; + * + * @return The modelName. + */ + java.lang.String getModelName(); + /** + * + * + *
+     * Model URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
+     * 
+ * + * string model_name = 1; + * + * @return The bytes for modelName. + */ + com.google.protobuf.ByteString getModelNameBytes(); + + /** + * + * + *
+     * User-provided metadata for the model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + * + * @return Whether the modelInfo field is set. + */ + boolean hasModelInfo(); + /** + * + * + *
+     * User-provided metadata for the model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + * + * @return The modelInfo. + */ + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getModelInfo(); + /** + * + * + *
+     * User-provided metadata for the model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + */ + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder getModelInfoOrBuilder(); + + /** + * + * + *
+     * Model expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return Whether the expireTime field is set. + */ + boolean hasExpireTime(); + /** + * + * + *
+     * Model expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return The expireTime. + */ + com.google.protobuf.Timestamp getExpireTime(); + /** + * + * + *
+     * Model expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder(); + + /** + * + * + *
+     * Model creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+     * Model creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+     * Model creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+     * Model last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + /** + * + * + *
+     * Model last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + * + * + *
+     * Model last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
+     * Model encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + * + * @return Whether the encryption field is set. + */ + boolean hasEncryption(); + /** + * + * + *
+     * Model encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + * + * @return The encryption. + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption(); + /** + * + * + *
+     * Model encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder getEncryptionOrBuilder(); + } + /** + * + * + *
+   * Trained BigQuery ML model.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Model} + */ + public static final class Model extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.Model) + ModelOrBuilder { + private static final long serialVersionUID = 0L; + // Use Model.newBuilder() to construct. + private Model(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Model() { + modelName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Model(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Model( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + modelName_ = s; + break; + } + case 18: + { + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder subBuilder = null; + if (modelInfo_ != null) { + subBuilder = modelInfo_.toBuilder(); + } + modelInfo_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(modelInfo_); + modelInfo_ = subBuilder.buildPartial(); + } + + break; + } + case 42: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (expireTime_ != null) { + subBuilder = expireTime_.toBuilder(); + } + expireTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(expireTime_); + expireTime_ = subBuilder.buildPartial(); + } + + break; + } + case 50: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (createTime_ != null) { + subBuilder = createTime_.toBuilder(); + } + createTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(createTime_); + createTime_ = subBuilder.buildPartial(); + } + + break; + } + case 58: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (updateTime_ != null) { + subBuilder = updateTime_.toBuilder(); + } + updateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(updateTime_); + updateTime_ = subBuilder.buildPartial(); + } + + break; + } + case 66: + { + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = + null; + if (encryption_ != null) { + subBuilder = encryption_.toBuilder(); + } + encryption_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(encryption_); + encryption_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.Model.class, + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder.class); + } + + public static final int MODEL_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object modelName_; + /** + * + * + *
+     * Model URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
+     * 
+ * + * string model_name = 1; + * + * @return The modelName. + */ + @java.lang.Override + public java.lang.String getModelName() { + java.lang.Object ref = modelName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + modelName_ = s; + return s; + } + } + /** + * + * + *
+     * Model URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
+     * 
+ * + * string model_name = 1; + * + * @return The bytes for modelName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getModelNameBytes() { + java.lang.Object ref = modelName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + modelName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int MODEL_INFO_FIELD_NUMBER = 2; + private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo modelInfo_; + /** + * + * + *
+     * User-provided metadata for the model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + * + * @return Whether the modelInfo field is set. + */ + @java.lang.Override + public boolean hasModelInfo() { + return modelInfo_ != null; + } + /** + * + * + *
+     * User-provided metadata for the model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + * + * @return The modelInfo. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getModelInfo() { + return modelInfo_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() + : modelInfo_; + } + /** + * + * + *
+     * User-provided metadata for the model.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder + getModelInfoOrBuilder() { + return getModelInfo(); + } + + public static final int EXPIRE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp expireTime_; + /** + * + * + *
+     * Model expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return Whether the expireTime field is set. + */ + @java.lang.Override + public boolean hasExpireTime() { + return expireTime_ != null; + } + /** + * + * + *
+     * Model expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return The expireTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getExpireTime() { + return expireTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : expireTime_; + } + /** + * + * + *
+     * Model expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder() { + return getExpireTime(); + } + + public static final int CREATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+     * Model creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+     * Model creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+     * Model creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 7; + private com.google.protobuf.Timestamp updateTime_; + /** + * + * + *
+     * Model last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + * + * + *
+     * Model last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + * + * + *
+     * Model last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + public static final int ENCRYPTION_FIELD_NUMBER = 8; + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption_; + /** + * + * + *
+     * Model encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + * + * @return Whether the encryption field is set. + */ + @java.lang.Override + public boolean hasEncryption() { + return encryption_ != null; + } + /** + * + * + *
+     * Model encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + * + * @return The encryption. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption() { + return encryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : encryption_; + } + /** + * + * + *
+     * Model encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getEncryptionOrBuilder() { + return getEncryption(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getModelNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, modelName_); + } + if (modelInfo_ != null) { + output.writeMessage(2, getModelInfo()); + } + if (expireTime_ != null) { + output.writeMessage(5, getExpireTime()); + } + if (createTime_ != null) { + output.writeMessage(6, getCreateTime()); + } + if (updateTime_ != null) { + output.writeMessage(7, getUpdateTime()); + } + if (encryption_ != null) { + output.writeMessage(8, getEncryption()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getModelNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, modelName_); + } + if (modelInfo_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getModelInfo()); + } + if (expireTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getExpireTime()); + } + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getCreateTime()); + } + if (updateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getUpdateTime()); + } + if (encryption_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getEncryption()); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.Model)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.Model other = + (com.google.cloud.audit.BigQueryAuditMetadata.Model) obj; + + if (!getModelName().equals(other.getModelName())) return false; + if (hasModelInfo() != other.hasModelInfo()) return false; + if (hasModelInfo()) { + if (!getModelInfo().equals(other.getModelInfo())) return false; + } + if (hasExpireTime() != other.hasExpireTime()) return false; + if (hasExpireTime()) { + if (!getExpireTime().equals(other.getExpireTime())) return false; + } + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (hasEncryption() != other.hasEncryption()) return false; + if (hasEncryption()) { + if (!getEncryption().equals(other.getEncryption())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + MODEL_NAME_FIELD_NUMBER; + hash = (53 * hash) + getModelName().hashCode(); + if (hasModelInfo()) { + hash = (37 * hash) + MODEL_INFO_FIELD_NUMBER; + hash = (53 * hash) + getModelInfo().hashCode(); + } + if (hasExpireTime()) { + hash = (37 * hash) + EXPIRE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getExpireTime().hashCode(); + } + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + if (hasEncryption()) { + hash = (37 * hash) + ENCRYPTION_FIELD_NUMBER; + hash = (53 * hash) + getEncryption().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.audit.BigQueryAuditMetadata.Model prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Trained BigQuery ML model.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Model} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.Model) + com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.Model.class, + com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.Model.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + modelName_ = ""; + + if (modelInfoBuilder_ == null) { + modelInfo_ = null; + } else { + modelInfo_ = null; + modelInfoBuilder_ = null; + } + if (expireTimeBuilder_ == null) { + expireTime_ = null; + } else { + expireTime_ = null; + expireTimeBuilder_ = null; + } + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + if (encryptionBuilder_ == null) { + encryption_ = null; + } else { + encryption_ = null; + encryptionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Model getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Model build() { + com.google.cloud.audit.BigQueryAuditMetadata.Model result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Model buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.Model result = + new com.google.cloud.audit.BigQueryAuditMetadata.Model(this); + result.modelName_ = modelName_; + if (modelInfoBuilder_ == null) { + result.modelInfo_ = modelInfo_; + } else { + result.modelInfo_ = modelInfoBuilder_.build(); + } + if (expireTimeBuilder_ == null) { + result.expireTime_ = expireTime_; + } else { + result.expireTime_ = expireTimeBuilder_.build(); + } + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (updateTimeBuilder_ == null) { + result.updateTime_ = updateTime_; + } else { + result.updateTime_ = updateTimeBuilder_.build(); + } + if (encryptionBuilder_ == null) { + result.encryption_ = encryption_; + } else { + result.encryption_ = encryptionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.Model) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.Model) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.Model other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance()) + return this; + if (!other.getModelName().isEmpty()) { + modelName_ = other.modelName_; + onChanged(); + } + if (other.hasModelInfo()) { + mergeModelInfo(other.getModelInfo()); + } + if (other.hasExpireTime()) { + mergeExpireTime(other.getExpireTime()); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (other.hasEncryption()) { + mergeEncryption(other.getEncryption()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.Model parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.Model) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object modelName_ = ""; + /** + * + * + *
+       * Model URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
+       * 
+ * + * string model_name = 1; + * + * @return The modelName. + */ + public java.lang.String getModelName() { + java.lang.Object ref = modelName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + modelName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * Model URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
+       * 
+ * + * string model_name = 1; + * + * @return The bytes for modelName. + */ + public com.google.protobuf.ByteString getModelNameBytes() { + java.lang.Object ref = modelName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + modelName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * Model URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
+       * 
+ * + * string model_name = 1; + * + * @param value The modelName to set. + * @return This builder for chaining. + */ + public Builder setModelName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + modelName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Model URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
+       * 
+ * + * string model_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearModelName() { + + modelName_ = getDefaultInstance().getModelName(); + onChanged(); + return this; + } + /** + * + * + *
+       * Model URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
+       * 
+ * + * string model_name = 1; + * + * @param value The bytes for modelName to set. + * @return This builder for chaining. + */ + public Builder setModelNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + modelName_ = value; + onChanged(); + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo modelInfo_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> + modelInfoBuilder_; + /** + * + * + *
+       * User-provided metadata for the model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + * + * @return Whether the modelInfo field is set. + */ + public boolean hasModelInfo() { + return modelInfoBuilder_ != null || modelInfo_ != null; + } + /** + * + * + *
+       * User-provided metadata for the model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + * + * @return The modelInfo. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getModelInfo() { + if (modelInfoBuilder_ == null) { + return modelInfo_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() + : modelInfo_; + } else { + return modelInfoBuilder_.getMessage(); + } + } + /** + * + * + *
+       * User-provided metadata for the model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + */ + public Builder setModelInfo(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { + if (modelInfoBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + modelInfo_ = value; + onChanged(); + } else { + modelInfoBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + */ + public Builder setModelInfo( + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder builderForValue) { + if (modelInfoBuilder_ == null) { + modelInfo_ = builderForValue.build(); + onChanged(); + } else { + modelInfoBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + */ + public Builder mergeModelInfo(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { + if (modelInfoBuilder_ == null) { + if (modelInfo_ != null) { + modelInfo_ = + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.newBuilder(modelInfo_) + .mergeFrom(value) + .buildPartial(); + } else { + modelInfo_ = value; + } + onChanged(); + } else { + modelInfoBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + */ + public Builder clearModelInfo() { + if (modelInfoBuilder_ == null) { + modelInfo_ = null; + onChanged(); + } else { + modelInfo_ = null; + modelInfoBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder getModelInfoBuilder() { + + onChanged(); + return getModelInfoFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * User-provided metadata for the model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder + getModelInfoOrBuilder() { + if (modelInfoBuilder_ != null) { + return modelInfoBuilder_.getMessageOrBuilder(); + } else { + return modelInfo_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() + : modelInfo_; + } + } + /** + * + * + *
+       * User-provided metadata for the model.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> + getModelInfoFieldBuilder() { + if (modelInfoBuilder_ == null) { + modelInfoBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder>( + getModelInfo(), getParentForChildren(), isClean()); + modelInfo_ = null; + } + return modelInfoBuilder_; + } + + private com.google.protobuf.Timestamp expireTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + expireTimeBuilder_; + /** + * + * + *
+       * Model expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return Whether the expireTime field is set. + */ + public boolean hasExpireTime() { + return expireTimeBuilder_ != null || expireTime_ != null; + } + /** + * + * + *
+       * Model expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return The expireTime. + */ + public com.google.protobuf.Timestamp getExpireTime() { + if (expireTimeBuilder_ == null) { + return expireTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : expireTime_; + } else { + return expireTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Model expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public Builder setExpireTime(com.google.protobuf.Timestamp value) { + if (expireTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expireTime_ = value; + onChanged(); + } else { + expireTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Model expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public Builder setExpireTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (expireTimeBuilder_ == null) { + expireTime_ = builderForValue.build(); + onChanged(); + } else { + expireTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Model expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public Builder mergeExpireTime(com.google.protobuf.Timestamp value) { + if (expireTimeBuilder_ == null) { + if (expireTime_ != null) { + expireTime_ = + com.google.protobuf.Timestamp.newBuilder(expireTime_) + .mergeFrom(value) + .buildPartial(); + } else { + expireTime_ = value; + } + onChanged(); + } else { + expireTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Model expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public Builder clearExpireTime() { + if (expireTimeBuilder_ == null) { + expireTime_ = null; + onChanged(); + } else { + expireTime_ = null; + expireTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Model expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public com.google.protobuf.Timestamp.Builder getExpireTimeBuilder() { + + onChanged(); + return getExpireTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Model expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder() { + if (expireTimeBuilder_ != null) { + return expireTimeBuilder_.getMessageOrBuilder(); + } else { + return expireTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : expireTime_; + } + } + /** + * + * + *
+       * Model expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getExpireTimeFieldBuilder() { + if (expireTimeBuilder_ == null) { + expireTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getExpireTime(), getParentForChildren(), isClean()); + expireTime_ = null; + } + return expireTimeBuilder_; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + /** + * + * + *
+       * Model creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+       * Model creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Model creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Model creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Model creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_) + .mergeFrom(value) + .buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Model creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Model creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Model creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+       * Model creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + /** + * + * + *
+       * Model last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + * + * + *
+       * Model last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Model last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + onChanged(); + } else { + updateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Model last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + onChanged(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Model last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (updateTime_ != null) { + updateTime_ = + com.google.protobuf.Timestamp.newBuilder(updateTime_) + .mergeFrom(value) + .buildPartial(); + } else { + updateTime_ = value; + } + onChanged(); + } else { + updateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Model last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Model last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Model last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + /** + * + * + *
+       * Model last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + encryptionBuilder_; + /** + * + * + *
+       * Model encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + * + * @return Whether the encryption field is set. + */ + public boolean hasEncryption() { + return encryptionBuilder_ != null || encryption_ != null; + } + /** + * + * + *
+       * Model encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + * + * @return The encryption. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption() { + if (encryptionBuilder_ == null) { + return encryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : encryption_; + } else { + return encryptionBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Model encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + */ + public Builder setEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (encryptionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + encryption_ = value; + onChanged(); + } else { + encryptionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Model encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + */ + public Builder setEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { + if (encryptionBuilder_ == null) { + encryption_ = builderForValue.build(); + onChanged(); + } else { + encryptionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Model encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + */ + public Builder mergeEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (encryptionBuilder_ == null) { + if (encryption_ != null) { + encryption_ = + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder(encryption_) + .mergeFrom(value) + .buildPartial(); + } else { + encryption_ = value; + } + onChanged(); + } else { + encryptionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Model encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + */ + public Builder clearEncryption() { + if (encryptionBuilder_ == null) { + encryption_ = null; + onChanged(); + } else { + encryption_ = null; + encryptionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Model encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder + getEncryptionBuilder() { + + onChanged(); + return getEncryptionFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Model encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getEncryptionOrBuilder() { + if (encryptionBuilder_ != null) { + return encryptionBuilder_.getMessageOrBuilder(); + } else { + return encryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : encryption_; + } + } + /** + * + * + *
+       * Model encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + getEncryptionFieldBuilder() { + if (encryptionBuilder_ == null) { + encryptionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( + getEncryption(), getParentForChildren(), isClean()); + encryption_ = null; + } + return encryptionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.Model) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.Model) + private static final com.google.cloud.audit.BigQueryAuditMetadata.Model DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.Model(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Model getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Model parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Model(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Model getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface RoutineDeletionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Deleted routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return Whether the routine field is set. + */ + boolean hasRoutine(); + /** + * + * + *
+     * Deleted routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return The routine. + */ + com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine(); + /** + * + * + *
+     * Deleted routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder(); + + /** + * + * + *
+     * Describes how the routine was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + int getReasonValue(); + /** + * + * + *
+     * Describes how the routine was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; + * + * @return The reason. + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason getReason(); + + /** + * + * + *
+     * The URI of the job that deleted the routine.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * The URI of the job that deleted the routine.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + } + /** + * + * + *
+   * Routine deletion event.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion} + */ + public static final class RoutineDeletion extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) + RoutineDeletionOrBuilder { + private static final long serialVersionUID = 0L; + // Use RoutineDeletion.newBuilder() to construct. + private RoutineDeletion(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RoutineDeletion() { + reason_ = 0; + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RoutineDeletion(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private RoutineDeletion( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder subBuilder = null; + if (routine_ != null) { + subBuilder = routine_.toBuilder(); + } + routine_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.Routine.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(routine_); + routine_ = subBuilder.buildPartial(); + } + + break; + } + case 24: + { + int rawValue = input.readEnum(); + + reason_ = rawValue; + break; + } + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.class, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder.class); + } + + /** + * + * + *
+     * Describes how the routine was deleted.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason} + */ + public enum Reason implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + REASON_UNSPECIFIED(0), + /** + * + * + *
+       * Routine was deleted using DDL query.
+       * 
+ * + * QUERY = 1; + */ + QUERY(1), + /** + * + * + *
+       * Routine was deleted using the API.
+       * 
+ * + * ROUTINE_DELETE_REQUEST = 2; + */ + ROUTINE_DELETE_REQUEST(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * REASON_UNSPECIFIED = 0; + */ + public static final int REASON_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Routine was deleted using DDL query.
+       * 
+ * + * QUERY = 1; + */ + public static final int QUERY_VALUE = 1; + /** + * + * + *
+       * Routine was deleted using the API.
+       * 
+ * + * ROUTINE_DELETE_REQUEST = 2; + */ + public static final int ROUTINE_DELETE_REQUEST_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Reason 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 Reason forNumber(int value) { + switch (value) { + case 0: + return REASON_UNSPECIFIED; + case 1: + return QUERY; + case 2: + return ROUTINE_DELETE_REQUEST; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Reason findValueByNumber(int number) { + return Reason.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Reason[] VALUES = values(); + + public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Reason(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason) + } + + public static final int ROUTINE_FIELD_NUMBER = 1; + private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; + /** + * + * + *
+     * Deleted routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return Whether the routine field is set. + */ + @java.lang.Override + public boolean hasRoutine() { + return routine_ != null; + } + /** + * + * + *
+     * Deleted routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return The routine. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { + return routine_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() + : routine_; + } + /** + * + * + *
+     * Deleted routine.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { + return getRoutine(); + } + + public static final int REASON_FIELD_NUMBER = 3; + private int reason_; + /** + * + * + *
+     * Describes how the routine was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+     * Describes how the routine was deleted.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.UNRECOGNIZED + : result; + } + + public static final int JOB_NAME_FIELD_NUMBER = 4; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * The URI of the job that deleted the routine.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * The URI of the job that deleted the routine.
+     * Present if the reason is QUERY.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (routine_ != null) { + output.writeMessage(1, getRoutine()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.REASON_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (routine_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getRoutine()); + } + if (reason_ + != com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.REASON_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); + } + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion other = + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) obj; + + if (hasRoutine() != other.hasRoutine()) return false; + if (hasRoutine()) { + if (!getRoutine().equals(other.getRoutine())) return false; + } + if (reason_ != other.reason_) return false; + if (!getJobName().equals(other.getJobName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasRoutine()) { + hash = (37 * hash) + ROUTINE_FIELD_NUMBER; + hash = (53 * hash) + getRoutine().hashCode(); + } + hash = (37 * hash) + REASON_FIELD_NUMBER; + hash = (53 * hash) + reason_; + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Routine deletion event.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.class, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (routineBuilder_ == null) { + routine_ = null; + } else { + routine_ = null; + routineBuilder_ = null; + } + reason_ = 0; + + jobName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion build() { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion result = + new com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion(this); + if (routineBuilder_ == null) { + result.routine_ = routine_; + } else { + result.routine_ = routineBuilder_.build(); + } + result.reason_ = reason_; + result.jobName_ = jobName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance()) + return this; + if (other.hasRoutine()) { + mergeRoutine(other.getRoutine()); + } + if (other.reason_ != 0) { + setReasonValue(other.getReasonValue()); + } + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Routine, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> + routineBuilder_; + /** + * + * + *
+       * Deleted routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return Whether the routine field is set. + */ + public boolean hasRoutine() { + return routineBuilder_ != null || routine_ != null; + } + /** + * + * + *
+       * Deleted routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + * + * @return The routine. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { + if (routineBuilder_ == null) { + return routine_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() + : routine_; + } else { + return routineBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Deleted routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder setRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { + if (routineBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + routine_ = value; + onChanged(); + } else { + routineBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Deleted routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder setRoutine( + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder builderForValue) { + if (routineBuilder_ == null) { + routine_ = builderForValue.build(); + onChanged(); + } else { + routineBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Deleted routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder mergeRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { + if (routineBuilder_ == null) { + if (routine_ != null) { + routine_ = + com.google.cloud.audit.BigQueryAuditMetadata.Routine.newBuilder(routine_) + .mergeFrom(value) + .buildPartial(); + } else { + routine_ = value; + } + onChanged(); + } else { + routineBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Deleted routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public Builder clearRoutine() { + if (routineBuilder_ == null) { + routine_ = null; + onChanged(); + } else { + routine_ = null; + routineBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Deleted routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder getRoutineBuilder() { + + onChanged(); + return getRoutineFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Deleted routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { + if (routineBuilder_ != null) { + return routineBuilder_.getMessageOrBuilder(); + } else { + return routine_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() + : routine_; + } + } + /** + * + * + *
+       * Deleted routine.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Routine, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> + getRoutineFieldBuilder() { + if (routineBuilder_ == null) { + routineBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.Routine, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder>( + getRoutine(), getParentForChildren(), isClean()); + routine_ = null; + } + return routineBuilder_; + } + + private int reason_ = 0; + /** + * + * + *
+       * Describes how the routine was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; + * + * @return The enum numeric value on the wire for reason. + */ + @java.lang.Override + public int getReasonValue() { + return reason_; + } + /** + * + * + *
+       * Describes how the routine was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; + * + * @param value The enum numeric value on the wire for reason to set. + * @return This builder for chaining. + */ + public Builder setReasonValue(int value) { + + reason_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the routine was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; + * + * @return The reason. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason getReason() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason result = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.valueOf(reason_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Describes how the routine was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; + * + * @param value The reason to set. + * @return This builder for chaining. + */ + public Builder setReason( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason value) { + if (value == null) { + throw new NullPointerException(); + } + + reason_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Describes how the routine was deleted.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; + * + * @return This builder for chaining. + */ + public Builder clearReason() { + + reason_ = 0; + onChanged(); + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * The URI of the job that deleted the routine.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The URI of the job that deleted the routine.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The URI of the job that deleted the routine.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that deleted the routine.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * The URI of the job that deleted the routine.
+       * Present if the reason is QUERY.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 4; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) + private static final com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RoutineDeletion parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new RoutineDeletion(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface JobOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.Job) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Job URI.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 1; + * + * @return The jobName. + */ + java.lang.String getJobName(); + /** + * + * + *
+     * Job URI.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 1; + * + * @return The bytes for jobName. + */ + com.google.protobuf.ByteString getJobNameBytes(); + + /** + * + * + *
+     * Job configuration.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + * + * @return Whether the jobConfig field is set. + */ + boolean hasJobConfig(); + /** + * + * + *
+     * Job configuration.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + * + * @return The jobConfig. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getJobConfig(); + /** + * + * + *
+     * Job configuration.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder getJobConfigOrBuilder(); + + /** + * + * + *
+     * Job status.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + * + * @return Whether the jobStatus field is set. + */ + boolean hasJobStatus(); + /** + * + * + *
+     * Job status.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + * + * @return The jobStatus. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getJobStatus(); + /** + * + * + *
+     * Job status.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder getJobStatusOrBuilder(); + + /** + * + * + *
+     * Job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + * + * @return Whether the jobStats field is set. + */ + boolean hasJobStats(); + /** + * + * + *
+     * Job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + * + * @return The jobStats. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStats getJobStats(); + /** + * + * + *
+     * Job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder getJobStatsOrBuilder(); + } + /** + * + * + *
+   * BigQuery job.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Job} + */ + public static final class Job extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.Job) + JobOrBuilder { + private static final long serialVersionUID = 0L; + // Use Job.newBuilder() to construct. + private Job(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Job() { + jobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Job(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Job( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + jobName_ = s; + break; + } + case 18: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder subBuilder = null; + if (jobConfig_ != null) { + subBuilder = jobConfig_.toBuilder(); + } + jobConfig_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(jobConfig_); + jobConfig_ = subBuilder.buildPartial(); + } + + break; + } + case 26: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder subBuilder = null; + if (jobStatus_ != null) { + subBuilder = jobStatus_.toBuilder(); + } + jobStatus_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(jobStatus_); + jobStatus_ = subBuilder.buildPartial(); + } + + break; + } + case 34: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder subBuilder = null; + if (jobStats_ != null) { + subBuilder = jobStats_.toBuilder(); + } + jobStats_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(jobStats_); + jobStats_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.Job.class, + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder.class); + } + + public static final int JOB_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object jobName_; + /** + * + * + *
+     * Job URI.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 1; + * + * @return The jobName. + */ + @java.lang.Override + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } + } + /** + * + * + *
+     * Job URI.
+     * Format: `projects/<project_id>/jobs/<job_id>`.
+     * 
+ * + * string job_name = 1; + * + * @return The bytes for jobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int JOB_CONFIG_FIELD_NUMBER = 2; + private com.google.cloud.audit.BigQueryAuditMetadata.JobConfig jobConfig_; + /** + * + * + *
+     * Job configuration.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + * + * @return Whether the jobConfig field is set. + */ + @java.lang.Override + public boolean hasJobConfig() { + return jobConfig_ != null; + } + /** + * + * + *
+     * Job configuration.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + * + * @return The jobConfig. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getJobConfig() { + return jobConfig_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDefaultInstance() + : jobConfig_; + } + /** + * + * + *
+     * Job configuration.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder getJobConfigOrBuilder() { + return getJobConfig(); + } + + public static final int JOB_STATUS_FIELD_NUMBER = 3; + private com.google.cloud.audit.BigQueryAuditMetadata.JobStatus jobStatus_; + /** + * + * + *
+     * Job status.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + * + * @return Whether the jobStatus field is set. + */ + @java.lang.Override + public boolean hasJobStatus() { + return jobStatus_ != null; + } + /** + * + * + *
+     * Job status.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + * + * @return The jobStatus. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getJobStatus() { + return jobStatus_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.getDefaultInstance() + : jobStatus_; + } + /** + * + * + *
+     * Job status.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder getJobStatusOrBuilder() { + return getJobStatus(); + } + + public static final int JOB_STATS_FIELD_NUMBER = 4; + private com.google.cloud.audit.BigQueryAuditMetadata.JobStats jobStats_; + /** + * + * + *
+     * Job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + * + * @return Whether the jobStats field is set. + */ + @java.lang.Override + public boolean hasJobStats() { + return jobStats_ != null; + } + /** + * + * + *
+     * Job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + * + * @return The jobStats. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats getJobStats() { + return jobStats_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobStats.getDefaultInstance() + : jobStats_; + } + /** + * + * + *
+     * Job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder getJobStatsOrBuilder() { + return getJobStats(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, jobName_); + } + if (jobConfig_ != null) { + output.writeMessage(2, getJobConfig()); + } + if (jobStatus_ != null) { + output.writeMessage(3, getJobStatus()); + } + if (jobStats_ != null) { + output.writeMessage(4, getJobStats()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, jobName_); + } + if (jobConfig_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getJobConfig()); + } + if (jobStatus_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getJobStatus()); + } + if (jobStats_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getJobStats()); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.Job)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.Job other = + (com.google.cloud.audit.BigQueryAuditMetadata.Job) obj; + + if (!getJobName().equals(other.getJobName())) return false; + if (hasJobConfig() != other.hasJobConfig()) return false; + if (hasJobConfig()) { + if (!getJobConfig().equals(other.getJobConfig())) return false; + } + if (hasJobStatus() != other.hasJobStatus()) return false; + if (hasJobStatus()) { + if (!getJobStatus().equals(other.getJobStatus())) return false; + } + if (hasJobStats() != other.hasJobStats()) return false; + if (hasJobStats()) { + if (!getJobStats().equals(other.getJobStats())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getJobName().hashCode(); + if (hasJobConfig()) { + hash = (37 * hash) + JOB_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getJobConfig().hashCode(); + } + if (hasJobStatus()) { + hash = (37 * hash) + JOB_STATUS_FIELD_NUMBER; + hash = (53 * hash) + getJobStatus().hashCode(); + } + if (hasJobStats()) { + hash = (37 * hash) + JOB_STATS_FIELD_NUMBER; + hash = (53 * hash) + getJobStats().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.audit.BigQueryAuditMetadata.Job prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * BigQuery job.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Job} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.Job) + com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.Job.class, + com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.Job.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + jobName_ = ""; + + if (jobConfigBuilder_ == null) { + jobConfig_ = null; + } else { + jobConfig_ = null; + jobConfigBuilder_ = null; + } + if (jobStatusBuilder_ == null) { + jobStatus_ = null; + } else { + jobStatus_ = null; + jobStatusBuilder_ = null; + } + if (jobStatsBuilder_ == null) { + jobStats_ = null; + } else { + jobStats_ = null; + jobStatsBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Job getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Job build() { + com.google.cloud.audit.BigQueryAuditMetadata.Job result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Job buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.Job result = + new com.google.cloud.audit.BigQueryAuditMetadata.Job(this); + result.jobName_ = jobName_; + if (jobConfigBuilder_ == null) { + result.jobConfig_ = jobConfig_; + } else { + result.jobConfig_ = jobConfigBuilder_.build(); + } + if (jobStatusBuilder_ == null) { + result.jobStatus_ = jobStatus_; + } else { + result.jobStatus_ = jobStatusBuilder_.build(); + } + if (jobStatsBuilder_ == null) { + result.jobStats_ = jobStats_; + } else { + result.jobStats_ = jobStatsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.Job) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.Job) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.Job other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance()) + return this; + if (!other.getJobName().isEmpty()) { + jobName_ = other.jobName_; + onChanged(); + } + if (other.hasJobConfig()) { + mergeJobConfig(other.getJobConfig()); + } + if (other.hasJobStatus()) { + mergeJobStatus(other.getJobStatus()); + } + if (other.hasJobStats()) { + mergeJobStats(other.getJobStats()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.Job parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.Job) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object jobName_ = ""; + /** + * + * + *
+       * Job URI.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 1; + * + * @return The jobName. + */ + public java.lang.String getJobName() { + java.lang.Object ref = jobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + jobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * Job URI.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 1; + * + * @return The bytes for jobName. + */ + public com.google.protobuf.ByteString getJobNameBytes() { + java.lang.Object ref = jobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + jobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * Job URI.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 1; + * + * @param value The jobName to set. + * @return This builder for chaining. + */ + public Builder setJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + jobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Job URI.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearJobName() { + + jobName_ = getDefaultInstance().getJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * Job URI.
+       * Format: `projects/<project_id>/jobs/<job_id>`.
+       * 
+ * + * string job_name = 1; + * + * @param value The bytes for jobName to set. + * @return This builder for chaining. + */ + public Builder setJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + jobName_ = value; + onChanged(); + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.JobConfig jobConfig_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder> + jobConfigBuilder_; + /** + * + * + *
+       * Job configuration.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + * + * @return Whether the jobConfig field is set. + */ + public boolean hasJobConfig() { + return jobConfigBuilder_ != null || jobConfig_ != null; + } + /** + * + * + *
+       * Job configuration.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + * + * @return The jobConfig. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getJobConfig() { + if (jobConfigBuilder_ == null) { + return jobConfig_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDefaultInstance() + : jobConfig_; + } else { + return jobConfigBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Job configuration.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + */ + public Builder setJobConfig(com.google.cloud.audit.BigQueryAuditMetadata.JobConfig value) { + if (jobConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + jobConfig_ = value; + onChanged(); + } else { + jobConfigBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Job configuration.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + */ + public Builder setJobConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder builderForValue) { + if (jobConfigBuilder_ == null) { + jobConfig_ = builderForValue.build(); + onChanged(); + } else { + jobConfigBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Job configuration.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + */ + public Builder mergeJobConfig(com.google.cloud.audit.BigQueryAuditMetadata.JobConfig value) { + if (jobConfigBuilder_ == null) { + if (jobConfig_ != null) { + jobConfig_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.newBuilder(jobConfig_) + .mergeFrom(value) + .buildPartial(); + } else { + jobConfig_ = value; + } + onChanged(); + } else { + jobConfigBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Job configuration.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + */ + public Builder clearJobConfig() { + if (jobConfigBuilder_ == null) { + jobConfig_ = null; + onChanged(); + } else { + jobConfig_ = null; + jobConfigBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Job configuration.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder getJobConfigBuilder() { + + onChanged(); + return getJobConfigFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Job configuration.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder + getJobConfigOrBuilder() { + if (jobConfigBuilder_ != null) { + return jobConfigBuilder_.getMessageOrBuilder(); + } else { + return jobConfig_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDefaultInstance() + : jobConfig_; + } + } + /** + * + * + *
+       * Job configuration.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder> + getJobConfigFieldBuilder() { + if (jobConfigBuilder_ == null) { + jobConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder>( + getJobConfig(), getParentForChildren(), isClean()); + jobConfig_ = null; + } + return jobConfigBuilder_; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.JobStatus jobStatus_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder> + jobStatusBuilder_; + /** + * + * + *
+       * Job status.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + * + * @return Whether the jobStatus field is set. + */ + public boolean hasJobStatus() { + return jobStatusBuilder_ != null || jobStatus_ != null; + } + /** + * + * + *
+       * Job status.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + * + * @return The jobStatus. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getJobStatus() { + if (jobStatusBuilder_ == null) { + return jobStatus_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.getDefaultInstance() + : jobStatus_; + } else { + return jobStatusBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Job status.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + */ + public Builder setJobStatus(com.google.cloud.audit.BigQueryAuditMetadata.JobStatus value) { + if (jobStatusBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + jobStatus_ = value; + onChanged(); + } else { + jobStatusBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Job status.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + */ + public Builder setJobStatus( + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder builderForValue) { + if (jobStatusBuilder_ == null) { + jobStatus_ = builderForValue.build(); + onChanged(); + } else { + jobStatusBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Job status.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + */ + public Builder mergeJobStatus(com.google.cloud.audit.BigQueryAuditMetadata.JobStatus value) { + if (jobStatusBuilder_ == null) { + if (jobStatus_ != null) { + jobStatus_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.newBuilder(jobStatus_) + .mergeFrom(value) + .buildPartial(); + } else { + jobStatus_ = value; + } + onChanged(); + } else { + jobStatusBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Job status.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + */ + public Builder clearJobStatus() { + if (jobStatusBuilder_ == null) { + jobStatus_ = null; + onChanged(); + } else { + jobStatus_ = null; + jobStatusBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Job status.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder getJobStatusBuilder() { + + onChanged(); + return getJobStatusFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Job status.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder + getJobStatusOrBuilder() { + if (jobStatusBuilder_ != null) { + return jobStatusBuilder_.getMessageOrBuilder(); + } else { + return jobStatus_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.getDefaultInstance() + : jobStatus_; + } + } + /** + * + * + *
+       * Job status.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder> + getJobStatusFieldBuilder() { + if (jobStatusBuilder_ == null) { + jobStatusBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder>( + getJobStatus(), getParentForChildren(), isClean()); + jobStatus_ = null; + } + return jobStatusBuilder_; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.JobStats jobStats_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder> + jobStatsBuilder_; + /** + * + * + *
+       * Job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + * + * @return Whether the jobStats field is set. + */ + public boolean hasJobStats() { + return jobStatsBuilder_ != null || jobStats_ != null; + } + /** + * + * + *
+       * Job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + * + * @return The jobStats. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats getJobStats() { + if (jobStatsBuilder_ == null) { + return jobStats_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobStats.getDefaultInstance() + : jobStats_; + } else { + return jobStatsBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + */ + public Builder setJobStats(com.google.cloud.audit.BigQueryAuditMetadata.JobStats value) { + if (jobStatsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + jobStats_ = value; + onChanged(); + } else { + jobStatsBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + */ + public Builder setJobStats( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder builderForValue) { + if (jobStatsBuilder_ == null) { + jobStats_ = builderForValue.build(); + onChanged(); + } else { + jobStatsBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + */ + public Builder mergeJobStats(com.google.cloud.audit.BigQueryAuditMetadata.JobStats value) { + if (jobStatsBuilder_ == null) { + if (jobStats_ != null) { + jobStats_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.newBuilder(jobStats_) + .mergeFrom(value) + .buildPartial(); + } else { + jobStats_ = value; + } + onChanged(); + } else { + jobStatsBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + */ + public Builder clearJobStats() { + if (jobStatsBuilder_ == null) { + jobStats_ = null; + onChanged(); + } else { + jobStats_ = null; + jobStatsBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder getJobStatsBuilder() { + + onChanged(); + return getJobStatsFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder getJobStatsOrBuilder() { + if (jobStatsBuilder_ != null) { + return jobStatsBuilder_.getMessageOrBuilder(); + } else { + return jobStats_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobStats.getDefaultInstance() + : jobStats_; + } + } + /** + * + * + *
+       * Job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder> + getJobStatsFieldBuilder() { + if (jobStatsBuilder_ == null) { + jobStatsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder>( + getJobStats(), getParentForChildren(), isClean()); + jobStats_ = null; + } + return jobStatsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.Job) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.Job) + private static final com.google.cloud.audit.BigQueryAuditMetadata.Job DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.Job(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Job getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Job parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Job(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Job getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface JobConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Job type.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; + * + * @return The enum numeric value on the wire for type. + */ + int getTypeValue(); + /** + * + * + *
+     * Job type.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; + * + * @return The type. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type getType(); + + /** + * + * + *
+     * Query job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + * + * @return Whether the queryConfig field is set. + */ + boolean hasQueryConfig(); + /** + * + * + *
+     * Query job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + * + * @return The queryConfig. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query getQueryConfig(); + /** + * + * + *
+     * Query job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder getQueryConfigOrBuilder(); + + /** + * + * + *
+     * Load job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + * + * @return Whether the loadConfig field is set. + */ + boolean hasLoadConfig(); + /** + * + * + *
+     * Load job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + * + * @return The loadConfig. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load getLoadConfig(); + /** + * + * + *
+     * Load job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder getLoadConfigOrBuilder(); + + /** + * + * + *
+     * Extract job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + * @return Whether the extractConfig field is set. + */ + boolean hasExtractConfig(); + /** + * + * + *
+     * Extract job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + * @return The extractConfig. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract getExtractConfig(); + /** + * + * + *
+     * Extract job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder + getExtractConfigOrBuilder(); + + /** + * + * + *
+     * TableCopy job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + * + * @return Whether the tableCopyConfig field is set. + */ + boolean hasTableCopyConfig(); + /** + * + * + *
+     * TableCopy job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + * + * @return The tableCopyConfig. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy getTableCopyConfig(); + /** + * + * + *
+     * TableCopy job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder + getTableCopyConfigOrBuilder(); + + /** + * + * + *
+     * Labels provided for the job.
+     * 
+ * + * map<string, string> labels = 6; + */ + int getLabelsCount(); + /** + * + * + *
+     * Labels provided for the job.
+     * 
+ * + * map<string, string> labels = 6; + */ + boolean containsLabels(java.lang.String key); + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getLabels(); + /** + * + * + *
+     * Labels provided for the job.
+     * 
+ * + * map<string, string> labels = 6; + */ + java.util.Map getLabelsMap(); + /** + * + * + *
+     * Labels provided for the job.
+     * 
+ * + * map<string, string> labels = 6; + */ + java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue); + /** + * + * + *
+     * Labels provided for the job.
+     * 
+ * + * map<string, string> labels = 6; + */ + java.lang.String getLabelsOrThrow(java.lang.String key); + + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ConfigCase getConfigCase(); + } + /** + * + * + *
+   * Job configuration.
+   * See the [Jobs](https://cloud.google.com/bigquery/docs/reference/v2/jobs)
+   * API resource for more details on individual fields.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig} + */ + public static final class JobConfig extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig) + JobConfigOrBuilder { + private static final long serialVersionUID = 0L; + // Use JobConfig.newBuilder() to construct. + private JobConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private JobConfig() { + type_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new JobConfig(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private JobConfig( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + type_ = rawValue; + break; + } + case 18: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder subBuilder = + null; + if (configCase_ == 2) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_) + .toBuilder(); + } + config_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_); + config_ = subBuilder.buildPartial(); + } + configCase_ = 2; + break; + } + case 26: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder subBuilder = + null; + if (configCase_ == 3) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_) + .toBuilder(); + } + config_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_); + config_ = subBuilder.buildPartial(); + } + configCase_ = 3; + break; + } + case 34: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder subBuilder = + null; + if (configCase_ == 4) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_) + .toBuilder(); + } + config_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_); + config_ = subBuilder.buildPartial(); + } + configCase_ = 4; + break; + } + case 42: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder + subBuilder = null; + if (configCase_ == 5) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_) + .toBuilder(); + } + config_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_); + config_ = subBuilder.buildPartial(); + } + configCase_ = 5; + break; + } + case 50: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + labels_ = + com.google.protobuf.MapField.newMapField( + LabelsDefaultEntryHolder.defaultEntry); + mutable_bitField0_ |= 0x00000001; + } + com.google.protobuf.MapEntry labels__ = + input.readMessage( + LabelsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + labels_.getMutableMap().put(labels__.getKey(), labels__.getValue()); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 6: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder.class); + } + + /** + * + * + *
+     * Job type.
+     * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type} + */ + public enum Type implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Unknown.
+       * 
+ * + * TYPE_UNSPECIFIED = 0; + */ + TYPE_UNSPECIFIED(0), + /** + * + * + *
+       * Query job.
+       * 
+ * + * QUERY = 1; + */ + QUERY(1), + /** + * + * + *
+       * Table copy job.
+       * 
+ * + * COPY = 2; + */ + COPY(2), + /** + * + * + *
+       * Export (extract) job.
+       * 
+ * + * EXPORT = 3; + */ + EXPORT(3), + /** + * + * + *
+       * Import (load) job.
+       * 
+ * + * IMPORT = 4; + */ + IMPORT(4), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Unknown.
+       * 
+ * + * TYPE_UNSPECIFIED = 0; + */ + public static final int TYPE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Query job.
+       * 
+ * + * QUERY = 1; + */ + public static final int QUERY_VALUE = 1; + /** + * + * + *
+       * Table copy job.
+       * 
+ * + * COPY = 2; + */ + public static final int COPY_VALUE = 2; + /** + * + * + *
+       * Export (extract) job.
+       * 
+ * + * EXPORT = 3; + */ + public static final int EXPORT_VALUE = 3; + /** + * + * + *
+       * Import (load) job.
+       * 
+ * + * IMPORT = 4; + */ + public static final int IMPORT_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Type 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 Type forNumber(int value) { + switch (value) { + case 0: + return TYPE_UNSPECIFIED; + case 1: + return QUERY; + case 2: + return COPY; + case 3: + return EXPORT; + case 4: + return IMPORT; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Type findValueByNumber(int number) { + return Type.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Type[] VALUES = values(); + + public static Type valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Type(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type) + } + + public interface QueryOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * The SQL query to run. Truncated if exceeds 50K.
+       * 
+ * + * string query = 1; + * + * @return The query. + */ + java.lang.String getQuery(); + /** + * + * + *
+       * The SQL query to run. Truncated if exceeds 50K.
+       * 
+ * + * string query = 1; + * + * @return The bytes for query. + */ + com.google.protobuf.ByteString getQueryBytes(); + + /** + * + * + *
+       * True if the query field was truncated.
+       * 
+ * + * bool query_truncated = 10; + * + * @return The queryTruncated. + */ + boolean getQueryTruncated(); + + /** + * + * + *
+       * The destination table for the query results.
+       * 
+ * + * string destination_table = 2; + * + * @return The destinationTable. + */ + java.lang.String getDestinationTable(); + /** + * + * + *
+       * The destination table for the query results.
+       * 
+ * + * string destination_table = 2; + * + * @return The bytes for destinationTable. + */ + com.google.protobuf.ByteString getDestinationTableBytes(); + + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The enum numeric value on the wire for createDisposition. + */ + int getCreateDispositionValue(); + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The createDisposition. + */ + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition(); + + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The enum numeric value on the wire for writeDisposition. + */ + int getWriteDispositionValue(); + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The writeDisposition. + */ + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition(); + + /** + * + * + *
+       * Default dataset for the query.
+       * 
+ * + * string default_dataset = 5; + * + * @return The defaultDataset. + */ + java.lang.String getDefaultDataset(); + /** + * + * + *
+       * Default dataset for the query.
+       * 
+ * + * string default_dataset = 5; + * + * @return The bytes for defaultDataset. + */ + com.google.protobuf.ByteString getDefaultDatasetBytes(); + + /** + * + * + *
+       * External data sources used in the query.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + java.util.List + getTableDefinitionsList(); + /** + * + * + *
+       * External data sources used in the query.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition getTableDefinitions(int index); + /** + * + * + *
+       * External data sources used in the query.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + int getTableDefinitionsCount(); + /** + * + * + *
+       * External data sources used in the query.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + java.util.List< + ? extends com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder> + getTableDefinitionsOrBuilderList(); + /** + * + * + *
+       * External data sources used in the query.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder + getTableDefinitionsOrBuilder(int index); + + /** + * + * + *
+       * Priority given to the query.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; + * + * + * @return The enum numeric value on the wire for priority. + */ + int getPriorityValue(); + /** + * + * + *
+       * Priority given to the query.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; + * + * + * @return The priority. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority getPriority(); + + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + * + * @return Whether the destinationTableEncryption field is set. + */ + boolean hasDestinationTableEncryption(); + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + * + * @return The destinationTableEncryption. + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDestinationTableEncryption(); + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDestinationTableEncryptionOrBuilder(); + + /** + * + * + *
+       * Type of the query.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; + * + * + * @return The enum numeric value on the wire for statementType. + */ + int getStatementTypeValue(); + /** + * + * + *
+       * Type of the query.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; + * + * + * @return The statementType. + */ + com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType getStatementType(); + } + /** + * + * + *
+     * Query job configuration.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query} + */ + public static final class Query extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) + QueryOrBuilder { + private static final long serialVersionUID = 0L; + // Use Query.newBuilder() to construct. + private Query(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Query() { + query_ = ""; + destinationTable_ = ""; + createDisposition_ = 0; + writeDisposition_ = 0; + defaultDataset_ = ""; + tableDefinitions_ = java.util.Collections.emptyList(); + priority_ = 0; + statementType_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Query(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Query( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + query_ = s; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + destinationTable_ = s; + break; + } + case 24: + { + int rawValue = input.readEnum(); + + createDisposition_ = rawValue; + break; + } + case 32: + { + int rawValue = input.readEnum(); + + writeDisposition_ = rawValue; + break; + } + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + + defaultDataset_ = s; + break; + } + case 50: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + tableDefinitions_ = + new java.util.ArrayList< + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition>(); + mutable_bitField0_ |= 0x00000001; + } + tableDefinitions_.add( + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.parser(), + extensionRegistry)); + break; + } + case 56: + { + int rawValue = input.readEnum(); + + priority_ = rawValue; + break; + } + case 66: + { + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = + null; + if (destinationTableEncryption_ != null) { + subBuilder = destinationTableEncryption_.toBuilder(); + } + destinationTableEncryption_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(destinationTableEncryption_); + destinationTableEncryption_ = subBuilder.buildPartial(); + } + + break; + } + case 72: + { + int rawValue = input.readEnum(); + + statementType_ = rawValue; + break; + } + case 80: + { + queryTruncated_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + tableDefinitions_ = java.util.Collections.unmodifiableList(tableDefinitions_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder.class); + } + + /** + * + * + *
+       * Priority given to the query.
+       * 
+ * + * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority} + */ + public enum Priority implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+         * Unknown.
+         * 
+ * + * PRIORITY_UNSPECIFIED = 0; + */ + PRIORITY_UNSPECIFIED(0), + /** + * + * + *
+         * Interactive query.
+         * 
+ * + * QUERY_INTERACTIVE = 1; + */ + QUERY_INTERACTIVE(1), + /** + * + * + *
+         * Batch query.
+         * 
+ * + * QUERY_BATCH = 2; + */ + QUERY_BATCH(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+         * Unknown.
+         * 
+ * + * PRIORITY_UNSPECIFIED = 0; + */ + public static final int PRIORITY_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+         * Interactive query.
+         * 
+ * + * QUERY_INTERACTIVE = 1; + */ + public static final int QUERY_INTERACTIVE_VALUE = 1; + /** + * + * + *
+         * Batch query.
+         * 
+ * + * QUERY_BATCH = 2; + */ + public static final int QUERY_BATCH_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static Priority valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static Priority forNumber(int value) { + switch (value) { + case 0: + return PRIORITY_UNSPECIFIED; + case 1: + return QUERY_INTERACTIVE; + case 2: + return QUERY_BATCH; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Priority findValueByNumber(int number) { + return Priority.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final Priority[] VALUES = values(); + + public static Priority valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException( + "EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private Priority(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority) + } + + public static final int QUERY_FIELD_NUMBER = 1; + private volatile java.lang.Object query_; + /** + * + * + *
+       * The SQL query to run. Truncated if exceeds 50K.
+       * 
+ * + * string query = 1; + * + * @return The query. + */ + @java.lang.Override + public java.lang.String getQuery() { + java.lang.Object ref = query_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + query_ = s; + return s; + } + } + /** + * + * + *
+       * The SQL query to run. Truncated if exceeds 50K.
+       * 
+ * + * string query = 1; + * + * @return The bytes for query. + */ + @java.lang.Override + public com.google.protobuf.ByteString getQueryBytes() { + java.lang.Object ref = query_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + query_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int QUERY_TRUNCATED_FIELD_NUMBER = 10; + private boolean queryTruncated_; + /** + * + * + *
+       * True if the query field was truncated.
+       * 
+ * + * bool query_truncated = 10; + * + * @return The queryTruncated. + */ + @java.lang.Override + public boolean getQueryTruncated() { + return queryTruncated_; + } + + public static final int DESTINATION_TABLE_FIELD_NUMBER = 2; + private volatile java.lang.Object destinationTable_; + /** + * + * + *
+       * The destination table for the query results.
+       * 
+ * + * string destination_table = 2; + * + * @return The destinationTable. + */ + @java.lang.Override + public java.lang.String getDestinationTable() { + java.lang.Object ref = destinationTable_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationTable_ = s; + return s; + } + } + /** + * + * + *
+       * The destination table for the query results.
+       * 
+ * + * string destination_table = 2; + * + * @return The bytes for destinationTable. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDestinationTableBytes() { + java.lang.Object ref = destinationTable_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationTable_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_DISPOSITION_FIELD_NUMBER = 3; + private int createDisposition_; + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The enum numeric value on the wire for createDisposition. + */ + @java.lang.Override + public int getCreateDispositionValue() { + return createDisposition_; + } + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The createDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( + createDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED + : result; + } + + public static final int WRITE_DISPOSITION_FIELD_NUMBER = 4; + private int writeDisposition_; + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The enum numeric value on the wire for writeDisposition. + */ + @java.lang.Override + public int getWriteDispositionValue() { + return writeDisposition_; + } + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The writeDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( + writeDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED + : result; + } + + public static final int DEFAULT_DATASET_FIELD_NUMBER = 5; + private volatile java.lang.Object defaultDataset_; + /** + * + * + *
+       * Default dataset for the query.
+       * 
+ * + * string default_dataset = 5; + * + * @return The defaultDataset. + */ + @java.lang.Override + public java.lang.String getDefaultDataset() { + java.lang.Object ref = defaultDataset_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + defaultDataset_ = s; + return s; + } + } + /** + * + * + *
+       * Default dataset for the query.
+       * 
+ * + * string default_dataset = 5; + * + * @return The bytes for defaultDataset. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDefaultDatasetBytes() { + java.lang.Object ref = defaultDataset_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + defaultDataset_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TABLE_DEFINITIONS_FIELD_NUMBER = 6; + private java.util.List + tableDefinitions_; + /** + * + * + *
+       * External data sources used in the query.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + @java.lang.Override + public java.util.List + getTableDefinitionsList() { + return tableDefinitions_; + } + /** + * + * + *
+       * External data sources used in the query.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder> + getTableDefinitionsOrBuilderList() { + return tableDefinitions_; + } + /** + * + * + *
+       * External data sources used in the query.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + @java.lang.Override + public int getTableDefinitionsCount() { + return tableDefinitions_.size(); + } + /** + * + * + *
+       * External data sources used in the query.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition getTableDefinitions( + int index) { + return tableDefinitions_.get(index); + } + /** + * + * + *
+       * External data sources used in the query.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder + getTableDefinitionsOrBuilder(int index) { + return tableDefinitions_.get(index); + } + + public static final int PRIORITY_FIELD_NUMBER = 7; + private int priority_; + /** + * + * + *
+       * Priority given to the query.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; + * + * + * @return The enum numeric value on the wire for priority. + */ + @java.lang.Override + public int getPriorityValue() { + return priority_; + } + /** + * + * + *
+       * Priority given to the query.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; + * + * + * @return The priority. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority getPriority() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority result = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority.valueOf( + priority_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority.UNRECOGNIZED + : result; + } + + public static final int DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER = 8; + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + destinationTableEncryption_; + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + * + * @return Whether the destinationTableEncryption field is set. + */ + @java.lang.Override + public boolean hasDestinationTableEncryption() { + return destinationTableEncryption_ != null; + } + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + * + * @return The destinationTableEncryption. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + getDestinationTableEncryption() { + return destinationTableEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : destinationTableEncryption_; + } + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDestinationTableEncryptionOrBuilder() { + return getDestinationTableEncryption(); + } + + public static final int STATEMENT_TYPE_FIELD_NUMBER = 9; + private int statementType_; + /** + * + * + *
+       * Type of the query.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; + * + * + * @return The enum numeric value on the wire for statementType. + */ + @java.lang.Override + public int getStatementTypeValue() { + return statementType_; + } + /** + * + * + *
+       * Type of the query.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; + * + * + * @return The statementType. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType getStatementType() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType result = + com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType.valueOf(statementType_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType.UNRECOGNIZED + : result; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getQueryBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, query_); + } + if (!getDestinationTableBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, destinationTable_); + } + if (createDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition + .CREATE_DISPOSITION_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, createDisposition_); + } + if (writeDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition + .WRITE_DISPOSITION_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, writeDisposition_); + } + if (!getDefaultDatasetBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, defaultDataset_); + } + for (int i = 0; i < tableDefinitions_.size(); i++) { + output.writeMessage(6, tableDefinitions_.get(i)); + } + if (priority_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority + .PRIORITY_UNSPECIFIED + .getNumber()) { + output.writeEnum(7, priority_); + } + if (destinationTableEncryption_ != null) { + output.writeMessage(8, getDestinationTableEncryption()); + } + if (statementType_ + != com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType + .QUERY_STATEMENT_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(9, statementType_); + } + if (queryTruncated_ != false) { + output.writeBool(10, queryTruncated_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getQueryBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, query_); + } + if (!getDestinationTableBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, destinationTable_); + } + if (createDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition + .CREATE_DISPOSITION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, createDisposition_); + } + if (writeDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition + .WRITE_DISPOSITION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, writeDisposition_); + } + if (!getDefaultDatasetBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, defaultDataset_); + } + for (int i = 0; i < tableDefinitions_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(6, tableDefinitions_.get(i)); + } + if (priority_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority + .PRIORITY_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, priority_); + } + if (destinationTableEncryption_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 8, getDestinationTableEncryption()); + } + if (statementType_ + != com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType + .QUERY_STATEMENT_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(9, statementType_); + } + if (queryTruncated_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(10, queryTruncated_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) obj; + + if (!getQuery().equals(other.getQuery())) return false; + if (getQueryTruncated() != other.getQueryTruncated()) return false; + if (!getDestinationTable().equals(other.getDestinationTable())) return false; + if (createDisposition_ != other.createDisposition_) return false; + if (writeDisposition_ != other.writeDisposition_) return false; + if (!getDefaultDataset().equals(other.getDefaultDataset())) return false; + if (!getTableDefinitionsList().equals(other.getTableDefinitionsList())) return false; + if (priority_ != other.priority_) return false; + if (hasDestinationTableEncryption() != other.hasDestinationTableEncryption()) return false; + if (hasDestinationTableEncryption()) { + if (!getDestinationTableEncryption().equals(other.getDestinationTableEncryption())) + return false; + } + if (statementType_ != other.statementType_) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + QUERY_FIELD_NUMBER; + hash = (53 * hash) + getQuery().hashCode(); + hash = (37 * hash) + QUERY_TRUNCATED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getQueryTruncated()); + hash = (37 * hash) + DESTINATION_TABLE_FIELD_NUMBER; + hash = (53 * hash) + getDestinationTable().hashCode(); + hash = (37 * hash) + CREATE_DISPOSITION_FIELD_NUMBER; + hash = (53 * hash) + createDisposition_; + hash = (37 * hash) + WRITE_DISPOSITION_FIELD_NUMBER; + hash = (53 * hash) + writeDisposition_; + hash = (37 * hash) + DEFAULT_DATASET_FIELD_NUMBER; + hash = (53 * hash) + getDefaultDataset().hashCode(); + if (getTableDefinitionsCount() > 0) { + hash = (37 * hash) + TABLE_DEFINITIONS_FIELD_NUMBER; + hash = (53 * hash) + getTableDefinitionsList().hashCode(); + } + hash = (37 * hash) + PRIORITY_FIELD_NUMBER; + hash = (53 * hash) + priority_; + if (hasDestinationTableEncryption()) { + hash = (37 * hash) + DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER; + hash = (53 * hash) + getDestinationTableEncryption().hashCode(); + } + hash = (37 * hash) + STATEMENT_TYPE_FIELD_NUMBER; + hash = (53 * hash) + statementType_; + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+       * Query job configuration.
+       * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getTableDefinitionsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + query_ = ""; + + queryTruncated_ = false; + + destinationTable_ = ""; + + createDisposition_ = 0; + + writeDisposition_ = 0; + + defaultDataset_ = ""; + + if (tableDefinitionsBuilder_ == null) { + tableDefinitions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + tableDefinitionsBuilder_.clear(); + } + priority_ = 0; + + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryption_ = null; + } else { + destinationTableEncryption_ = null; + destinationTableEncryptionBuilder_ = null; + } + statementType_ = 0; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query(this); + int from_bitField0_ = bitField0_; + result.query_ = query_; + result.queryTruncated_ = queryTruncated_; + result.destinationTable_ = destinationTable_; + result.createDisposition_ = createDisposition_; + result.writeDisposition_ = writeDisposition_; + result.defaultDataset_ = defaultDataset_; + if (tableDefinitionsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + tableDefinitions_ = java.util.Collections.unmodifiableList(tableDefinitions_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.tableDefinitions_ = tableDefinitions_; + } else { + result.tableDefinitions_ = tableDefinitionsBuilder_.build(); + } + result.priority_ = priority_; + if (destinationTableEncryptionBuilder_ == null) { + result.destinationTableEncryption_ = destinationTableEncryption_; + } else { + result.destinationTableEncryption_ = destinationTableEncryptionBuilder_.build(); + } + result.statementType_ = statementType_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance()) + return this; + if (!other.getQuery().isEmpty()) { + query_ = other.query_; + onChanged(); + } + if (other.getQueryTruncated() != false) { + setQueryTruncated(other.getQueryTruncated()); + } + if (!other.getDestinationTable().isEmpty()) { + destinationTable_ = other.destinationTable_; + onChanged(); + } + if (other.createDisposition_ != 0) { + setCreateDispositionValue(other.getCreateDispositionValue()); + } + if (other.writeDisposition_ != 0) { + setWriteDispositionValue(other.getWriteDispositionValue()); + } + if (!other.getDefaultDataset().isEmpty()) { + defaultDataset_ = other.defaultDataset_; + onChanged(); + } + if (tableDefinitionsBuilder_ == null) { + if (!other.tableDefinitions_.isEmpty()) { + if (tableDefinitions_.isEmpty()) { + tableDefinitions_ = other.tableDefinitions_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureTableDefinitionsIsMutable(); + tableDefinitions_.addAll(other.tableDefinitions_); + } + onChanged(); + } + } else { + if (!other.tableDefinitions_.isEmpty()) { + if (tableDefinitionsBuilder_.isEmpty()) { + tableDefinitionsBuilder_.dispose(); + tableDefinitionsBuilder_ = null; + tableDefinitions_ = other.tableDefinitions_; + bitField0_ = (bitField0_ & ~0x00000001); + tableDefinitionsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getTableDefinitionsFieldBuilder() + : null; + } else { + tableDefinitionsBuilder_.addAllMessages(other.tableDefinitions_); + } + } + } + if (other.priority_ != 0) { + setPriorityValue(other.getPriorityValue()); + } + if (other.hasDestinationTableEncryption()) { + mergeDestinationTableEncryption(other.getDestinationTableEncryption()); + } + if (other.statementType_ != 0) { + setStatementTypeValue(other.getStatementTypeValue()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object query_ = ""; + /** + * + * + *
+         * The SQL query to run. Truncated if exceeds 50K.
+         * 
+ * + * string query = 1; + * + * @return The query. + */ + public java.lang.String getQuery() { + java.lang.Object ref = query_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + query_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * The SQL query to run. Truncated if exceeds 50K.
+         * 
+ * + * string query = 1; + * + * @return The bytes for query. + */ + public com.google.protobuf.ByteString getQueryBytes() { + java.lang.Object ref = query_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + query_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * The SQL query to run. Truncated if exceeds 50K.
+         * 
+ * + * string query = 1; + * + * @param value The query to set. + * @return This builder for chaining. + */ + public Builder setQuery(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + query_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The SQL query to run. Truncated if exceeds 50K.
+         * 
+ * + * string query = 1; + * + * @return This builder for chaining. + */ + public Builder clearQuery() { + + query_ = getDefaultInstance().getQuery(); + onChanged(); + return this; + } + /** + * + * + *
+         * The SQL query to run. Truncated if exceeds 50K.
+         * 
+ * + * string query = 1; + * + * @param value The bytes for query to set. + * @return This builder for chaining. + */ + public Builder setQueryBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + query_ = value; + onChanged(); + return this; + } + + private boolean queryTruncated_; + /** + * + * + *
+         * True if the query field was truncated.
+         * 
+ * + * bool query_truncated = 10; + * + * @return The queryTruncated. + */ + @java.lang.Override + public boolean getQueryTruncated() { + return queryTruncated_; + } + /** + * + * + *
+         * True if the query field was truncated.
+         * 
+ * + * bool query_truncated = 10; + * + * @param value The queryTruncated to set. + * @return This builder for chaining. + */ + public Builder setQueryTruncated(boolean value) { + + queryTruncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * True if the query field was truncated.
+         * 
+ * + * bool query_truncated = 10; + * + * @return This builder for chaining. + */ + public Builder clearQueryTruncated() { + + queryTruncated_ = false; + onChanged(); + return this; + } + + private java.lang.Object destinationTable_ = ""; + /** + * + * + *
+         * The destination table for the query results.
+         * 
+ * + * string destination_table = 2; + * + * @return The destinationTable. + */ + public java.lang.String getDestinationTable() { + java.lang.Object ref = destinationTable_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationTable_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * The destination table for the query results.
+         * 
+ * + * string destination_table = 2; + * + * @return The bytes for destinationTable. + */ + public com.google.protobuf.ByteString getDestinationTableBytes() { + java.lang.Object ref = destinationTable_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationTable_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * The destination table for the query results.
+         * 
+ * + * string destination_table = 2; + * + * @param value The destinationTable to set. + * @return This builder for chaining. + */ + public Builder setDestinationTable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + destinationTable_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The destination table for the query results.
+         * 
+ * + * string destination_table = 2; + * + * @return This builder for chaining. + */ + public Builder clearDestinationTable() { + + destinationTable_ = getDefaultInstance().getDestinationTable(); + onChanged(); + return this; + } + /** + * + * + *
+         * The destination table for the query results.
+         * 
+ * + * string destination_table = 2; + * + * @param value The bytes for destinationTable to set. + * @return This builder for chaining. + */ + public Builder setDestinationTableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + destinationTable_ = value; + onChanged(); + return this; + } + + private int createDisposition_ = 0; + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The enum numeric value on the wire for createDisposition. + */ + @java.lang.Override + public int getCreateDispositionValue() { + return createDisposition_; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @param value The enum numeric value on the wire for createDisposition to set. + * @return This builder for chaining. + */ + public Builder setCreateDispositionValue(int value) { + + createDisposition_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The createDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition + getCreateDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( + createDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @param value The createDisposition to set. + * @return This builder for chaining. + */ + public Builder setCreateDisposition( + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition value) { + if (value == null) { + throw new NullPointerException(); + } + + createDisposition_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return This builder for chaining. + */ + public Builder clearCreateDisposition() { + + createDisposition_ = 0; + onChanged(); + return this; + } + + private int writeDisposition_ = 0; + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The enum numeric value on the wire for writeDisposition. + */ + @java.lang.Override + public int getWriteDispositionValue() { + return writeDisposition_; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @param value The enum numeric value on the wire for writeDisposition to set. + * @return This builder for chaining. + */ + public Builder setWriteDispositionValue(int value) { + + writeDisposition_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The writeDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( + writeDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @param value The writeDisposition to set. + * @return This builder for chaining. + */ + public Builder setWriteDisposition( + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition value) { + if (value == null) { + throw new NullPointerException(); + } + + writeDisposition_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return This builder for chaining. + */ + public Builder clearWriteDisposition() { + + writeDisposition_ = 0; + onChanged(); + return this; + } + + private java.lang.Object defaultDataset_ = ""; + /** + * + * + *
+         * Default dataset for the query.
+         * 
+ * + * string default_dataset = 5; + * + * @return The defaultDataset. + */ + public java.lang.String getDefaultDataset() { + java.lang.Object ref = defaultDataset_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + defaultDataset_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * Default dataset for the query.
+         * 
+ * + * string default_dataset = 5; + * + * @return The bytes for defaultDataset. + */ + public com.google.protobuf.ByteString getDefaultDatasetBytes() { + java.lang.Object ref = defaultDataset_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + defaultDataset_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * Default dataset for the query.
+         * 
+ * + * string default_dataset = 5; + * + * @param value The defaultDataset to set. + * @return This builder for chaining. + */ + public Builder setDefaultDataset(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + defaultDataset_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Default dataset for the query.
+         * 
+ * + * string default_dataset = 5; + * + * @return This builder for chaining. + */ + public Builder clearDefaultDataset() { + + defaultDataset_ = getDefaultInstance().getDefaultDataset(); + onChanged(); + return this; + } + /** + * + * + *
+         * Default dataset for the query.
+         * 
+ * + * string default_dataset = 5; + * + * @param value The bytes for defaultDataset to set. + * @return This builder for chaining. + */ + public Builder setDefaultDatasetBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + defaultDataset_ = value; + onChanged(); + return this; + } + + private java.util.List + tableDefinitions_ = java.util.Collections.emptyList(); + + private void ensureTableDefinitionsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + tableDefinitions_ = + new java.util.ArrayList< + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition>( + tableDefinitions_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder> + tableDefinitionsBuilder_; + + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public java.util.List + getTableDefinitionsList() { + if (tableDefinitionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(tableDefinitions_); + } else { + return tableDefinitionsBuilder_.getMessageList(); + } + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public int getTableDefinitionsCount() { + if (tableDefinitionsBuilder_ == null) { + return tableDefinitions_.size(); + } else { + return tableDefinitionsBuilder_.getCount(); + } + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition getTableDefinitions( + int index) { + if (tableDefinitionsBuilder_ == null) { + return tableDefinitions_.get(index); + } else { + return tableDefinitionsBuilder_.getMessage(index); + } + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public Builder setTableDefinitions( + int index, com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition value) { + if (tableDefinitionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTableDefinitionsIsMutable(); + tableDefinitions_.set(index, value); + onChanged(); + } else { + tableDefinitionsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public Builder setTableDefinitions( + int index, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder builderForValue) { + if (tableDefinitionsBuilder_ == null) { + ensureTableDefinitionsIsMutable(); + tableDefinitions_.set(index, builderForValue.build()); + onChanged(); + } else { + tableDefinitionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public Builder addTableDefinitions( + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition value) { + if (tableDefinitionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTableDefinitionsIsMutable(); + tableDefinitions_.add(value); + onChanged(); + } else { + tableDefinitionsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public Builder addTableDefinitions( + int index, com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition value) { + if (tableDefinitionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTableDefinitionsIsMutable(); + tableDefinitions_.add(index, value); + onChanged(); + } else { + tableDefinitionsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public Builder addTableDefinitions( + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder builderForValue) { + if (tableDefinitionsBuilder_ == null) { + ensureTableDefinitionsIsMutable(); + tableDefinitions_.add(builderForValue.build()); + onChanged(); + } else { + tableDefinitionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public Builder addTableDefinitions( + int index, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder builderForValue) { + if (tableDefinitionsBuilder_ == null) { + ensureTableDefinitionsIsMutable(); + tableDefinitions_.add(index, builderForValue.build()); + onChanged(); + } else { + tableDefinitionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public Builder addAllTableDefinitions( + java.lang.Iterable< + ? extends com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition> + values) { + if (tableDefinitionsBuilder_ == null) { + ensureTableDefinitionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, tableDefinitions_); + onChanged(); + } else { + tableDefinitionsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public Builder clearTableDefinitions() { + if (tableDefinitionsBuilder_ == null) { + tableDefinitions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + tableDefinitionsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public Builder removeTableDefinitions(int index) { + if (tableDefinitionsBuilder_ == null) { + ensureTableDefinitionsIsMutable(); + tableDefinitions_.remove(index); + onChanged(); + } else { + tableDefinitionsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder + getTableDefinitionsBuilder(int index) { + return getTableDefinitionsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder + getTableDefinitionsOrBuilder(int index) { + if (tableDefinitionsBuilder_ == null) { + return tableDefinitions_.get(index); + } else { + return tableDefinitionsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public java.util.List< + ? extends com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder> + getTableDefinitionsOrBuilderList() { + if (tableDefinitionsBuilder_ != null) { + return tableDefinitionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(tableDefinitions_); + } + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder + addTableDefinitionsBuilder() { + return getTableDefinitionsFieldBuilder() + .addBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition + .getDefaultInstance()); + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder + addTableDefinitionsBuilder(int index) { + return getTableDefinitionsFieldBuilder() + .addBuilder( + index, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition + .getDefaultInstance()); + } + /** + * + * + *
+         * External data sources used in the query.
+         * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; + * + */ + public java.util.List + getTableDefinitionsBuilderList() { + return getTableDefinitionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder> + getTableDefinitionsFieldBuilder() { + if (tableDefinitionsBuilder_ == null) { + tableDefinitionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder>( + tableDefinitions_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + tableDefinitions_ = null; + } + return tableDefinitionsBuilder_; + } + + private int priority_ = 0; + /** + * + * + *
+         * Priority given to the query.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; + * + * + * @return The enum numeric value on the wire for priority. + */ + @java.lang.Override + public int getPriorityValue() { + return priority_; + } + /** + * + * + *
+         * Priority given to the query.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; + * + * + * @param value The enum numeric value on the wire for priority to set. + * @return This builder for chaining. + */ + public Builder setPriorityValue(int value) { + + priority_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Priority given to the query.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; + * + * + * @return The priority. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority getPriority() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority result = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority.valueOf( + priority_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * Priority given to the query.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; + * + * + * @param value The priority to set. + * @return This builder for chaining. + */ + public Builder setPriority( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority value) { + if (value == null) { + throw new NullPointerException(); + } + + priority_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * Priority given to the query.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; + * + * + * @return This builder for chaining. + */ + public Builder clearPriority() { + + priority_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + destinationTableEncryption_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + destinationTableEncryptionBuilder_; + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + * + * @return Whether the destinationTableEncryption field is set. + */ + public boolean hasDestinationTableEncryption() { + return destinationTableEncryptionBuilder_ != null || destinationTableEncryption_ != null; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + * + * @return The destinationTableEncryption. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + getDestinationTableEncryption() { + if (destinationTableEncryptionBuilder_ == null) { + return destinationTableEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : destinationTableEncryption_; + } else { + return destinationTableEncryptionBuilder_.getMessage(); + } + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + */ + public Builder setDestinationTableEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (destinationTableEncryptionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + destinationTableEncryption_ = value; + onChanged(); + } else { + destinationTableEncryptionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + */ + public Builder setDestinationTableEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryption_ = builderForValue.build(); + onChanged(); + } else { + destinationTableEncryptionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + */ + public Builder mergeDestinationTableEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (destinationTableEncryptionBuilder_ == null) { + if (destinationTableEncryption_ != null) { + destinationTableEncryption_ = + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder( + destinationTableEncryption_) + .mergeFrom(value) + .buildPartial(); + } else { + destinationTableEncryption_ = value; + } + onChanged(); + } else { + destinationTableEncryptionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + */ + public Builder clearDestinationTableEncryption() { + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryption_ = null; + onChanged(); + } else { + destinationTableEncryption_ = null; + destinationTableEncryptionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder + getDestinationTableEncryptionBuilder() { + + onChanged(); + return getDestinationTableEncryptionFieldBuilder().getBuilder(); + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDestinationTableEncryptionOrBuilder() { + if (destinationTableEncryptionBuilder_ != null) { + return destinationTableEncryptionBuilder_.getMessageOrBuilder(); + } else { + return destinationTableEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : destinationTableEncryption_; + } + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + getDestinationTableEncryptionFieldBuilder() { + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryptionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( + getDestinationTableEncryption(), getParentForChildren(), isClean()); + destinationTableEncryption_ = null; + } + return destinationTableEncryptionBuilder_; + } + + private int statementType_ = 0; + /** + * + * + *
+         * Type of the query.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; + * + * + * @return The enum numeric value on the wire for statementType. + */ + @java.lang.Override + public int getStatementTypeValue() { + return statementType_; + } + /** + * + * + *
+         * Type of the query.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; + * + * + * @param value The enum numeric value on the wire for statementType to set. + * @return This builder for chaining. + */ + public Builder setStatementTypeValue(int value) { + + statementType_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Type of the query.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; + * + * + * @return The statementType. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType getStatementType() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType result = + com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType.valueOf( + statementType_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * Type of the query.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; + * + * + * @param value The statementType to set. + * @return This builder for chaining. + */ + public Builder setStatementType( + com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType value) { + if (value == null) { + throw new NullPointerException(); + } + + statementType_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * Type of the query.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; + * + * + * @return This builder for chaining. + */ + public Builder clearStatementType() { + + statementType_ = 0; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Query parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Query(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface LoadOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * URIs for the data to be imported. Entire list is truncated if exceeds
+       * 40K.
+       * 
+ * + * repeated string source_uris = 1; + * + * @return A list containing the sourceUris. + */ + java.util.List getSourceUrisList(); + /** + * + * + *
+       * URIs for the data to be imported. Entire list is truncated if exceeds
+       * 40K.
+       * 
+ * + * repeated string source_uris = 1; + * + * @return The count of sourceUris. + */ + int getSourceUrisCount(); + /** + * + * + *
+       * URIs for the data to be imported. Entire list is truncated if exceeds
+       * 40K.
+       * 
+ * + * repeated string source_uris = 1; + * + * @param index The index of the element to return. + * @return The sourceUris at the given index. + */ + java.lang.String getSourceUris(int index); + /** + * + * + *
+       * URIs for the data to be imported. Entire list is truncated if exceeds
+       * 40K.
+       * 
+ * + * repeated string source_uris = 1; + * + * @param index The index of the value to return. + * @return The bytes of the sourceUris at the given index. + */ + com.google.protobuf.ByteString getSourceUrisBytes(int index); + + /** + * + * + *
+       * True if the source_URIs field was truncated.
+       * 
+ * + * bool source_uris_truncated = 7; + * + * @return The sourceUrisTruncated. + */ + boolean getSourceUrisTruncated(); + + /** + * + * + *
+       * The table schema in JSON format. Entire field is truncated if exceeds
+       * 40K.
+       * 
+ * + * string schema_json = 2; + * + * @return The schemaJson. + */ + java.lang.String getSchemaJson(); + /** + * + * + *
+       * The table schema in JSON format. Entire field is truncated if exceeds
+       * 40K.
+       * 
+ * + * string schema_json = 2; + * + * @return The bytes for schemaJson. + */ + com.google.protobuf.ByteString getSchemaJsonBytes(); + + /** + * + * + *
+       * True if the schema_json field was truncated.
+       * 
+ * + * bool schema_json_truncated = 8; + * + * @return The schemaJsonTruncated. + */ + boolean getSchemaJsonTruncated(); + + /** + * + * + *
+       * The destination table for the import.
+       * 
+ * + * string destination_table = 3; + * + * @return The destinationTable. + */ + java.lang.String getDestinationTable(); + /** + * + * + *
+       * The destination table for the import.
+       * 
+ * + * string destination_table = 3; + * + * @return The bytes for destinationTable. + */ + com.google.protobuf.ByteString getDestinationTableBytes(); + + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; + * + * + * @return The enum numeric value on the wire for createDisposition. + */ + int getCreateDispositionValue(); + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; + * + * + * @return The createDisposition. + */ + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition(); + + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; + * + * + * @return The enum numeric value on the wire for writeDisposition. + */ + int getWriteDispositionValue(); + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; + * + * + * @return The writeDisposition. + */ + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition(); + + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + * + * @return Whether the destinationTableEncryption field is set. + */ + boolean hasDestinationTableEncryption(); + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + * + * @return The destinationTableEncryption. + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDestinationTableEncryption(); + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDestinationTableEncryptionOrBuilder(); + } + /** + * + * + *
+     * Load job configuration.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load} + */ + public static final class Load extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) + LoadOrBuilder { + private static final long serialVersionUID = 0L; + // Use Load.newBuilder() to construct. + private Load(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Load() { + sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; + schemaJson_ = ""; + destinationTable_ = ""; + createDisposition_ = 0; + writeDisposition_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Load(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Load( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + sourceUris_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + sourceUris_.add(s); + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + schemaJson_ = s; + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + destinationTable_ = s; + break; + } + case 32: + { + int rawValue = input.readEnum(); + + createDisposition_ = rawValue; + break; + } + case 40: + { + int rawValue = input.readEnum(); + + writeDisposition_ = rawValue; + break; + } + case 50: + { + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = + null; + if (destinationTableEncryption_ != null) { + subBuilder = destinationTableEncryption_.toBuilder(); + } + destinationTableEncryption_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(destinationTableEncryption_); + destinationTableEncryption_ = subBuilder.buildPartial(); + } + + break; + } + case 56: + { + sourceUrisTruncated_ = input.readBool(); + break; + } + case 64: + { + schemaJsonTruncated_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + sourceUris_ = sourceUris_.getUnmodifiableView(); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder.class); + } + + public static final int SOURCE_URIS_FIELD_NUMBER = 1; + private com.google.protobuf.LazyStringList sourceUris_; + /** + * + * + *
+       * URIs for the data to be imported. Entire list is truncated if exceeds
+       * 40K.
+       * 
+ * + * repeated string source_uris = 1; + * + * @return A list containing the sourceUris. + */ + public com.google.protobuf.ProtocolStringList getSourceUrisList() { + return sourceUris_; + } + /** + * + * + *
+       * URIs for the data to be imported. Entire list is truncated if exceeds
+       * 40K.
+       * 
+ * + * repeated string source_uris = 1; + * + * @return The count of sourceUris. + */ + public int getSourceUrisCount() { + return sourceUris_.size(); + } + /** + * + * + *
+       * URIs for the data to be imported. Entire list is truncated if exceeds
+       * 40K.
+       * 
+ * + * repeated string source_uris = 1; + * + * @param index The index of the element to return. + * @return The sourceUris at the given index. + */ + public java.lang.String getSourceUris(int index) { + return sourceUris_.get(index); + } + /** + * + * + *
+       * URIs for the data to be imported. Entire list is truncated if exceeds
+       * 40K.
+       * 
+ * + * repeated string source_uris = 1; + * + * @param index The index of the value to return. + * @return The bytes of the sourceUris at the given index. + */ + public com.google.protobuf.ByteString getSourceUrisBytes(int index) { + return sourceUris_.getByteString(index); + } + + public static final int SOURCE_URIS_TRUNCATED_FIELD_NUMBER = 7; + private boolean sourceUrisTruncated_; + /** + * + * + *
+       * True if the source_URIs field was truncated.
+       * 
+ * + * bool source_uris_truncated = 7; + * + * @return The sourceUrisTruncated. + */ + @java.lang.Override + public boolean getSourceUrisTruncated() { + return sourceUrisTruncated_; + } + + public static final int SCHEMA_JSON_FIELD_NUMBER = 2; + private volatile java.lang.Object schemaJson_; + /** + * + * + *
+       * The table schema in JSON format. Entire field is truncated if exceeds
+       * 40K.
+       * 
+ * + * string schema_json = 2; + * + * @return The schemaJson. + */ + @java.lang.Override + public java.lang.String getSchemaJson() { + java.lang.Object ref = schemaJson_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + schemaJson_ = s; + return s; + } + } + /** + * + * + *
+       * The table schema in JSON format. Entire field is truncated if exceeds
+       * 40K.
+       * 
+ * + * string schema_json = 2; + * + * @return The bytes for schemaJson. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSchemaJsonBytes() { + java.lang.Object ref = schemaJson_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + schemaJson_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SCHEMA_JSON_TRUNCATED_FIELD_NUMBER = 8; + private boolean schemaJsonTruncated_; + /** + * + * + *
+       * True if the schema_json field was truncated.
+       * 
+ * + * bool schema_json_truncated = 8; + * + * @return The schemaJsonTruncated. + */ + @java.lang.Override + public boolean getSchemaJsonTruncated() { + return schemaJsonTruncated_; + } + + public static final int DESTINATION_TABLE_FIELD_NUMBER = 3; + private volatile java.lang.Object destinationTable_; + /** + * + * + *
+       * The destination table for the import.
+       * 
+ * + * string destination_table = 3; + * + * @return The destinationTable. + */ + @java.lang.Override + public java.lang.String getDestinationTable() { + java.lang.Object ref = destinationTable_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationTable_ = s; + return s; + } + } + /** + * + * + *
+       * The destination table for the import.
+       * 
+ * + * string destination_table = 3; + * + * @return The bytes for destinationTable. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDestinationTableBytes() { + java.lang.Object ref = destinationTable_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationTable_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_DISPOSITION_FIELD_NUMBER = 4; + private int createDisposition_; + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; + * + * + * @return The enum numeric value on the wire for createDisposition. + */ + @java.lang.Override + public int getCreateDispositionValue() { + return createDisposition_; + } + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; + * + * + * @return The createDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( + createDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED + : result; + } + + public static final int WRITE_DISPOSITION_FIELD_NUMBER = 5; + private int writeDisposition_; + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; + * + * + * @return The enum numeric value on the wire for writeDisposition. + */ + @java.lang.Override + public int getWriteDispositionValue() { + return writeDisposition_; + } + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; + * + * + * @return The writeDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( + writeDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED + : result; + } + + public static final int DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER = 6; + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + destinationTableEncryption_; + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + * + * @return Whether the destinationTableEncryption field is set. + */ + @java.lang.Override + public boolean hasDestinationTableEncryption() { + return destinationTableEncryption_ != null; + } + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + * + * @return The destinationTableEncryption. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + getDestinationTableEncryption() { + return destinationTableEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : destinationTableEncryption_; + } + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDestinationTableEncryptionOrBuilder() { + return getDestinationTableEncryption(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < sourceUris_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, sourceUris_.getRaw(i)); + } + if (!getSchemaJsonBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, schemaJson_); + } + if (!getDestinationTableBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, destinationTable_); + } + if (createDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition + .CREATE_DISPOSITION_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, createDisposition_); + } + if (writeDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition + .WRITE_DISPOSITION_UNSPECIFIED + .getNumber()) { + output.writeEnum(5, writeDisposition_); + } + if (destinationTableEncryption_ != null) { + output.writeMessage(6, getDestinationTableEncryption()); + } + if (sourceUrisTruncated_ != false) { + output.writeBool(7, sourceUrisTruncated_); + } + if (schemaJsonTruncated_ != false) { + output.writeBool(8, schemaJsonTruncated_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < sourceUris_.size(); i++) { + dataSize += computeStringSizeNoTag(sourceUris_.getRaw(i)); + } + size += dataSize; + size += 1 * getSourceUrisList().size(); + } + if (!getSchemaJsonBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, schemaJson_); + } + if (!getDestinationTableBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, destinationTable_); + } + if (createDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition + .CREATE_DISPOSITION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, createDisposition_); + } + if (writeDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition + .WRITE_DISPOSITION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, writeDisposition_); + } + if (destinationTableEncryption_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 6, getDestinationTableEncryption()); + } + if (sourceUrisTruncated_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(7, sourceUrisTruncated_); + } + if (schemaJsonTruncated_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, schemaJsonTruncated_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) obj; + + if (!getSourceUrisList().equals(other.getSourceUrisList())) return false; + if (getSourceUrisTruncated() != other.getSourceUrisTruncated()) return false; + if (!getSchemaJson().equals(other.getSchemaJson())) return false; + if (getSchemaJsonTruncated() != other.getSchemaJsonTruncated()) return false; + if (!getDestinationTable().equals(other.getDestinationTable())) return false; + if (createDisposition_ != other.createDisposition_) return false; + if (writeDisposition_ != other.writeDisposition_) return false; + if (hasDestinationTableEncryption() != other.hasDestinationTableEncryption()) return false; + if (hasDestinationTableEncryption()) { + if (!getDestinationTableEncryption().equals(other.getDestinationTableEncryption())) + return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getSourceUrisCount() > 0) { + hash = (37 * hash) + SOURCE_URIS_FIELD_NUMBER; + hash = (53 * hash) + getSourceUrisList().hashCode(); + } + hash = (37 * hash) + SOURCE_URIS_TRUNCATED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSourceUrisTruncated()); + hash = (37 * hash) + SCHEMA_JSON_FIELD_NUMBER; + hash = (53 * hash) + getSchemaJson().hashCode(); + hash = (37 * hash) + SCHEMA_JSON_TRUNCATED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSchemaJsonTruncated()); + hash = (37 * hash) + DESTINATION_TABLE_FIELD_NUMBER; + hash = (53 * hash) + getDestinationTable().hashCode(); + hash = (37 * hash) + CREATE_DISPOSITION_FIELD_NUMBER; + hash = (53 * hash) + createDisposition_; + hash = (37 * hash) + WRITE_DISPOSITION_FIELD_NUMBER; + hash = (53 * hash) + writeDisposition_; + if (hasDestinationTableEncryption()) { + hash = (37 * hash) + DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER; + hash = (53 * hash) + getDestinationTableEncryption().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+       * Load job configuration.
+       * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + sourceUrisTruncated_ = false; + + schemaJson_ = ""; + + schemaJsonTruncated_ = false; + + destinationTable_ = ""; + + createDisposition_ = 0; + + writeDisposition_ = 0; + + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryption_ = null; + } else { + destinationTableEncryption_ = null; + destinationTableEncryptionBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load(this); + int from_bitField0_ = bitField0_; + if (((bitField0_ & 0x00000001) != 0)) { + sourceUris_ = sourceUris_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.sourceUris_ = sourceUris_; + result.sourceUrisTruncated_ = sourceUrisTruncated_; + result.schemaJson_ = schemaJson_; + result.schemaJsonTruncated_ = schemaJsonTruncated_; + result.destinationTable_ = destinationTable_; + result.createDisposition_ = createDisposition_; + result.writeDisposition_ = writeDisposition_; + if (destinationTableEncryptionBuilder_ == null) { + result.destinationTableEncryption_ = destinationTableEncryption_; + } else { + result.destinationTableEncryption_ = destinationTableEncryptionBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance()) + return this; + if (!other.sourceUris_.isEmpty()) { + if (sourceUris_.isEmpty()) { + sourceUris_ = other.sourceUris_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureSourceUrisIsMutable(); + sourceUris_.addAll(other.sourceUris_); + } + onChanged(); + } + if (other.getSourceUrisTruncated() != false) { + setSourceUrisTruncated(other.getSourceUrisTruncated()); + } + if (!other.getSchemaJson().isEmpty()) { + schemaJson_ = other.schemaJson_; + onChanged(); + } + if (other.getSchemaJsonTruncated() != false) { + setSchemaJsonTruncated(other.getSchemaJsonTruncated()); + } + if (!other.getDestinationTable().isEmpty()) { + destinationTable_ = other.destinationTable_; + onChanged(); + } + if (other.createDisposition_ != 0) { + setCreateDispositionValue(other.getCreateDispositionValue()); + } + if (other.writeDisposition_ != 0) { + setWriteDispositionValue(other.getWriteDispositionValue()); + } + if (other.hasDestinationTableEncryption()) { + mergeDestinationTableEncryption(other.getDestinationTableEncryption()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringList sourceUris_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureSourceUrisIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + sourceUris_ = new com.google.protobuf.LazyStringArrayList(sourceUris_); + bitField0_ |= 0x00000001; + } + } + /** + * + * + *
+         * URIs for the data to be imported. Entire list is truncated if exceeds
+         * 40K.
+         * 
+ * + * repeated string source_uris = 1; + * + * @return A list containing the sourceUris. + */ + public com.google.protobuf.ProtocolStringList getSourceUrisList() { + return sourceUris_.getUnmodifiableView(); + } + /** + * + * + *
+         * URIs for the data to be imported. Entire list is truncated if exceeds
+         * 40K.
+         * 
+ * + * repeated string source_uris = 1; + * + * @return The count of sourceUris. + */ + public int getSourceUrisCount() { + return sourceUris_.size(); + } + /** + * + * + *
+         * URIs for the data to be imported. Entire list is truncated if exceeds
+         * 40K.
+         * 
+ * + * repeated string source_uris = 1; + * + * @param index The index of the element to return. + * @return The sourceUris at the given index. + */ + public java.lang.String getSourceUris(int index) { + return sourceUris_.get(index); + } + /** + * + * + *
+         * URIs for the data to be imported. Entire list is truncated if exceeds
+         * 40K.
+         * 
+ * + * repeated string source_uris = 1; + * + * @param index The index of the value to return. + * @return The bytes of the sourceUris at the given index. + */ + public com.google.protobuf.ByteString getSourceUrisBytes(int index) { + return sourceUris_.getByteString(index); + } + /** + * + * + *
+         * URIs for the data to be imported. Entire list is truncated if exceeds
+         * 40K.
+         * 
+ * + * repeated string source_uris = 1; + * + * @param index The index to set the value at. + * @param value The sourceUris to set. + * @return This builder for chaining. + */ + public Builder setSourceUris(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSourceUrisIsMutable(); + sourceUris_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+         * URIs for the data to be imported. Entire list is truncated if exceeds
+         * 40K.
+         * 
+ * + * repeated string source_uris = 1; + * + * @param value The sourceUris to add. + * @return This builder for chaining. + */ + public Builder addSourceUris(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSourceUrisIsMutable(); + sourceUris_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+         * URIs for the data to be imported. Entire list is truncated if exceeds
+         * 40K.
+         * 
+ * + * repeated string source_uris = 1; + * + * @param values The sourceUris to add. + * @return This builder for chaining. + */ + public Builder addAllSourceUris(java.lang.Iterable values) { + ensureSourceUrisIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, sourceUris_); + onChanged(); + return this; + } + /** + * + * + *
+         * URIs for the data to be imported. Entire list is truncated if exceeds
+         * 40K.
+         * 
+ * + * repeated string source_uris = 1; + * + * @return This builder for chaining. + */ + public Builder clearSourceUris() { + sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+         * URIs for the data to be imported. Entire list is truncated if exceeds
+         * 40K.
+         * 
+ * + * repeated string source_uris = 1; + * + * @param value The bytes of the sourceUris to add. + * @return This builder for chaining. + */ + public Builder addSourceUrisBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureSourceUrisIsMutable(); + sourceUris_.add(value); + onChanged(); + return this; + } + + private boolean sourceUrisTruncated_; + /** + * + * + *
+         * True if the source_URIs field was truncated.
+         * 
+ * + * bool source_uris_truncated = 7; + * + * @return The sourceUrisTruncated. + */ + @java.lang.Override + public boolean getSourceUrisTruncated() { + return sourceUrisTruncated_; + } + /** + * + * + *
+         * True if the source_URIs field was truncated.
+         * 
+ * + * bool source_uris_truncated = 7; + * + * @param value The sourceUrisTruncated to set. + * @return This builder for chaining. + */ + public Builder setSourceUrisTruncated(boolean value) { + + sourceUrisTruncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * True if the source_URIs field was truncated.
+         * 
+ * + * bool source_uris_truncated = 7; + * + * @return This builder for chaining. + */ + public Builder clearSourceUrisTruncated() { + + sourceUrisTruncated_ = false; + onChanged(); + return this; + } + + private java.lang.Object schemaJson_ = ""; + /** + * + * + *
+         * The table schema in JSON format. Entire field is truncated if exceeds
+         * 40K.
+         * 
+ * + * string schema_json = 2; + * + * @return The schemaJson. + */ + public java.lang.String getSchemaJson() { + java.lang.Object ref = schemaJson_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + schemaJson_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * The table schema in JSON format. Entire field is truncated if exceeds
+         * 40K.
+         * 
+ * + * string schema_json = 2; + * + * @return The bytes for schemaJson. + */ + public com.google.protobuf.ByteString getSchemaJsonBytes() { + java.lang.Object ref = schemaJson_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + schemaJson_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * The table schema in JSON format. Entire field is truncated if exceeds
+         * 40K.
+         * 
+ * + * string schema_json = 2; + * + * @param value The schemaJson to set. + * @return This builder for chaining. + */ + public Builder setSchemaJson(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + schemaJson_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The table schema in JSON format. Entire field is truncated if exceeds
+         * 40K.
+         * 
+ * + * string schema_json = 2; + * + * @return This builder for chaining. + */ + public Builder clearSchemaJson() { + + schemaJson_ = getDefaultInstance().getSchemaJson(); + onChanged(); + return this; + } + /** + * + * + *
+         * The table schema in JSON format. Entire field is truncated if exceeds
+         * 40K.
+         * 
+ * + * string schema_json = 2; + * + * @param value The bytes for schemaJson to set. + * @return This builder for chaining. + */ + public Builder setSchemaJsonBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + schemaJson_ = value; + onChanged(); + return this; + } + + private boolean schemaJsonTruncated_; + /** + * + * + *
+         * True if the schema_json field was truncated.
+         * 
+ * + * bool schema_json_truncated = 8; + * + * @return The schemaJsonTruncated. + */ + @java.lang.Override + public boolean getSchemaJsonTruncated() { + return schemaJsonTruncated_; + } + /** + * + * + *
+         * True if the schema_json field was truncated.
+         * 
+ * + * bool schema_json_truncated = 8; + * + * @param value The schemaJsonTruncated to set. + * @return This builder for chaining. + */ + public Builder setSchemaJsonTruncated(boolean value) { + + schemaJsonTruncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * True if the schema_json field was truncated.
+         * 
+ * + * bool schema_json_truncated = 8; + * + * @return This builder for chaining. + */ + public Builder clearSchemaJsonTruncated() { + + schemaJsonTruncated_ = false; + onChanged(); + return this; + } + + private java.lang.Object destinationTable_ = ""; + /** + * + * + *
+         * The destination table for the import.
+         * 
+ * + * string destination_table = 3; + * + * @return The destinationTable. + */ + public java.lang.String getDestinationTable() { + java.lang.Object ref = destinationTable_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationTable_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * The destination table for the import.
+         * 
+ * + * string destination_table = 3; + * + * @return The bytes for destinationTable. + */ + public com.google.protobuf.ByteString getDestinationTableBytes() { + java.lang.Object ref = destinationTable_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationTable_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * The destination table for the import.
+         * 
+ * + * string destination_table = 3; + * + * @param value The destinationTable to set. + * @return This builder for chaining. + */ + public Builder setDestinationTable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + destinationTable_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The destination table for the import.
+         * 
+ * + * string destination_table = 3; + * + * @return This builder for chaining. + */ + public Builder clearDestinationTable() { + + destinationTable_ = getDefaultInstance().getDestinationTable(); + onChanged(); + return this; + } + /** + * + * + *
+         * The destination table for the import.
+         * 
+ * + * string destination_table = 3; + * + * @param value The bytes for destinationTable to set. + * @return This builder for chaining. + */ + public Builder setDestinationTableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + destinationTable_ = value; + onChanged(); + return this; + } + + private int createDisposition_ = 0; + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; + * + * + * @return The enum numeric value on the wire for createDisposition. + */ + @java.lang.Override + public int getCreateDispositionValue() { + return createDisposition_; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; + * + * + * @param value The enum numeric value on the wire for createDisposition to set. + * @return This builder for chaining. + */ + public Builder setCreateDispositionValue(int value) { + + createDisposition_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; + * + * + * @return The createDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition + getCreateDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( + createDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; + * + * + * @param value The createDisposition to set. + * @return This builder for chaining. + */ + public Builder setCreateDisposition( + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition value) { + if (value == null) { + throw new NullPointerException(); + } + + createDisposition_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; + * + * + * @return This builder for chaining. + */ + public Builder clearCreateDisposition() { + + createDisposition_ = 0; + onChanged(); + return this; + } + + private int writeDisposition_ = 0; + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; + * + * + * @return The enum numeric value on the wire for writeDisposition. + */ + @java.lang.Override + public int getWriteDispositionValue() { + return writeDisposition_; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; + * + * + * @param value The enum numeric value on the wire for writeDisposition to set. + * @return This builder for chaining. + */ + public Builder setWriteDispositionValue(int value) { + + writeDisposition_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; + * + * + * @return The writeDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( + writeDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; + * + * + * @param value The writeDisposition to set. + * @return This builder for chaining. + */ + public Builder setWriteDisposition( + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition value) { + if (value == null) { + throw new NullPointerException(); + } + + writeDisposition_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; + * + * + * @return This builder for chaining. + */ + public Builder clearWriteDisposition() { + + writeDisposition_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + destinationTableEncryption_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + destinationTableEncryptionBuilder_; + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + * + * @return Whether the destinationTableEncryption field is set. + */ + public boolean hasDestinationTableEncryption() { + return destinationTableEncryptionBuilder_ != null || destinationTableEncryption_ != null; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + * + * @return The destinationTableEncryption. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + getDestinationTableEncryption() { + if (destinationTableEncryptionBuilder_ == null) { + return destinationTableEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : destinationTableEncryption_; + } else { + return destinationTableEncryptionBuilder_.getMessage(); + } + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + */ + public Builder setDestinationTableEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (destinationTableEncryptionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + destinationTableEncryption_ = value; + onChanged(); + } else { + destinationTableEncryptionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + */ + public Builder setDestinationTableEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryption_ = builderForValue.build(); + onChanged(); + } else { + destinationTableEncryptionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + */ + public Builder mergeDestinationTableEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (destinationTableEncryptionBuilder_ == null) { + if (destinationTableEncryption_ != null) { + destinationTableEncryption_ = + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder( + destinationTableEncryption_) + .mergeFrom(value) + .buildPartial(); + } else { + destinationTableEncryption_ = value; + } + onChanged(); + } else { + destinationTableEncryptionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + */ + public Builder clearDestinationTableEncryption() { + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryption_ = null; + onChanged(); + } else { + destinationTableEncryption_ = null; + destinationTableEncryptionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder + getDestinationTableEncryptionBuilder() { + + onChanged(); + return getDestinationTableEncryptionFieldBuilder().getBuilder(); + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDestinationTableEncryptionOrBuilder() { + if (destinationTableEncryptionBuilder_ != null) { + return destinationTableEncryptionBuilder_.getMessageOrBuilder(); + } else { + return destinationTableEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : destinationTableEncryption_; + } + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + getDestinationTableEncryptionFieldBuilder() { + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryptionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( + getDestinationTableEncryption(), getParentForChildren(), isClean()); + destinationTableEncryption_ = null; + } + return destinationTableEncryptionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Load parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Load(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ExtractOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * URIs where extracted data should be written. Entire list is truncated
+       * if exceeds 50K.
+       * 
+ * + * repeated string destination_uris = 1; + * + * @return A list containing the destinationUris. + */ + java.util.List getDestinationUrisList(); + /** + * + * + *
+       * URIs where extracted data should be written. Entire list is truncated
+       * if exceeds 50K.
+       * 
+ * + * repeated string destination_uris = 1; + * + * @return The count of destinationUris. + */ + int getDestinationUrisCount(); + /** + * + * + *
+       * URIs where extracted data should be written. Entire list is truncated
+       * if exceeds 50K.
+       * 
+ * + * repeated string destination_uris = 1; + * + * @param index The index of the element to return. + * @return The destinationUris at the given index. + */ + java.lang.String getDestinationUris(int index); + /** + * + * + *
+       * URIs where extracted data should be written. Entire list is truncated
+       * if exceeds 50K.
+       * 
+ * + * repeated string destination_uris = 1; + * + * @param index The index of the value to return. + * @return The bytes of the destinationUris at the given index. + */ + com.google.protobuf.ByteString getDestinationUrisBytes(int index); + + /** + * + * + *
+       * True if the destination_URIs field was truncated.
+       * 
+ * + * bool destination_uris_truncated = 3; + * + * @return The destinationUrisTruncated. + */ + boolean getDestinationUrisTruncated(); + + /** + * + * + *
+       * The source table.
+       * 
+ * + * string source_table = 2; + * + * @return Whether the sourceTable field is set. + */ + boolean hasSourceTable(); + /** + * + * + *
+       * The source table.
+       * 
+ * + * string source_table = 2; + * + * @return The sourceTable. + */ + java.lang.String getSourceTable(); + /** + * + * + *
+       * The source table.
+       * 
+ * + * string source_table = 2; + * + * @return The bytes for sourceTable. + */ + com.google.protobuf.ByteString getSourceTableBytes(); + + /** + * + * + *
+       * The source model.
+       * 
+ * + * string source_model = 4; + * + * @return Whether the sourceModel field is set. + */ + boolean hasSourceModel(); + /** + * + * + *
+       * The source model.
+       * 
+ * + * string source_model = 4; + * + * @return The sourceModel. + */ + java.lang.String getSourceModel(); + /** + * + * + *
+       * The source model.
+       * 
+ * + * string source_model = 4; + * + * @return The bytes for sourceModel. + */ + com.google.protobuf.ByteString getSourceModelBytes(); + + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.SourceCase + getSourceCase(); + } + /** + * + * + *
+     * Extract job configuration.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract} + */ + public static final class Extract extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) + ExtractOrBuilder { + private static final long serialVersionUID = 0L; + // Use Extract.newBuilder() to construct. + private Extract(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Extract() { + destinationUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Extract(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Extract( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + destinationUris_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + destinationUris_.add(s); + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + sourceCase_ = 2; + source_ = s; + break; + } + case 24: + { + destinationUrisTruncated_ = input.readBool(); + break; + } + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + sourceCase_ = 4; + source_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + destinationUris_ = destinationUris_.getUnmodifiableView(); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder.class); + } + + private int sourceCase_ = 0; + private java.lang.Object source_; + + public enum SourceCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + SOURCE_TABLE(2), + SOURCE_MODEL(4), + SOURCE_NOT_SET(0); + private final int value; + + private SourceCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static SourceCase valueOf(int value) { + return forNumber(value); + } + + public static SourceCase forNumber(int value) { + switch (value) { + case 2: + return SOURCE_TABLE; + case 4: + return SOURCE_MODEL; + case 0: + return SOURCE_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public SourceCase getSourceCase() { + return SourceCase.forNumber(sourceCase_); + } + + public static final int DESTINATION_URIS_FIELD_NUMBER = 1; + private com.google.protobuf.LazyStringList destinationUris_; + /** + * + * + *
+       * URIs where extracted data should be written. Entire list is truncated
+       * if exceeds 50K.
+       * 
+ * + * repeated string destination_uris = 1; + * + * @return A list containing the destinationUris. + */ + public com.google.protobuf.ProtocolStringList getDestinationUrisList() { + return destinationUris_; + } + /** + * + * + *
+       * URIs where extracted data should be written. Entire list is truncated
+       * if exceeds 50K.
+       * 
+ * + * repeated string destination_uris = 1; + * + * @return The count of destinationUris. + */ + public int getDestinationUrisCount() { + return destinationUris_.size(); + } + /** + * + * + *
+       * URIs where extracted data should be written. Entire list is truncated
+       * if exceeds 50K.
+       * 
+ * + * repeated string destination_uris = 1; + * + * @param index The index of the element to return. + * @return The destinationUris at the given index. + */ + public java.lang.String getDestinationUris(int index) { + return destinationUris_.get(index); + } + /** + * + * + *
+       * URIs where extracted data should be written. Entire list is truncated
+       * if exceeds 50K.
+       * 
+ * + * repeated string destination_uris = 1; + * + * @param index The index of the value to return. + * @return The bytes of the destinationUris at the given index. + */ + public com.google.protobuf.ByteString getDestinationUrisBytes(int index) { + return destinationUris_.getByteString(index); + } + + public static final int DESTINATION_URIS_TRUNCATED_FIELD_NUMBER = 3; + private boolean destinationUrisTruncated_; + /** + * + * + *
+       * True if the destination_URIs field was truncated.
+       * 
+ * + * bool destination_uris_truncated = 3; + * + * @return The destinationUrisTruncated. + */ + @java.lang.Override + public boolean getDestinationUrisTruncated() { + return destinationUrisTruncated_; + } + + public static final int SOURCE_TABLE_FIELD_NUMBER = 2; + /** + * + * + *
+       * The source table.
+       * 
+ * + * string source_table = 2; + * + * @return Whether the sourceTable field is set. + */ + public boolean hasSourceTable() { + return sourceCase_ == 2; + } + /** + * + * + *
+       * The source table.
+       * 
+ * + * string source_table = 2; + * + * @return The sourceTable. + */ + public java.lang.String getSourceTable() { + java.lang.Object ref = ""; + if (sourceCase_ == 2) { + ref = source_; + } + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (sourceCase_ == 2) { + source_ = s; + } + return s; + } + } + /** + * + * + *
+       * The source table.
+       * 
+ * + * string source_table = 2; + * + * @return The bytes for sourceTable. + */ + public com.google.protobuf.ByteString getSourceTableBytes() { + java.lang.Object ref = ""; + if (sourceCase_ == 2) { + ref = source_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (sourceCase_ == 2) { + source_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SOURCE_MODEL_FIELD_NUMBER = 4; + /** + * + * + *
+       * The source model.
+       * 
+ * + * string source_model = 4; + * + * @return Whether the sourceModel field is set. + */ + public boolean hasSourceModel() { + return sourceCase_ == 4; + } + /** + * + * + *
+       * The source model.
+       * 
+ * + * string source_model = 4; + * + * @return The sourceModel. + */ + public java.lang.String getSourceModel() { + java.lang.Object ref = ""; + if (sourceCase_ == 4) { + ref = source_; + } + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (sourceCase_ == 4) { + source_ = s; + } + return s; + } + } + /** + * + * + *
+       * The source model.
+       * 
+ * + * string source_model = 4; + * + * @return The bytes for sourceModel. + */ + public com.google.protobuf.ByteString getSourceModelBytes() { + java.lang.Object ref = ""; + if (sourceCase_ == 4) { + ref = source_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (sourceCase_ == 4) { + source_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < destinationUris_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, destinationUris_.getRaw(i)); + } + if (sourceCase_ == 2) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, source_); + } + if (destinationUrisTruncated_ != false) { + output.writeBool(3, destinationUrisTruncated_); + } + if (sourceCase_ == 4) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, source_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < destinationUris_.size(); i++) { + dataSize += computeStringSizeNoTag(destinationUris_.getRaw(i)); + } + size += dataSize; + size += 1 * getDestinationUrisList().size(); + } + if (sourceCase_ == 2) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, source_); + } + if (destinationUrisTruncated_ != false) { + size += + com.google.protobuf.CodedOutputStream.computeBoolSize(3, destinationUrisTruncated_); + } + if (sourceCase_ == 4) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, source_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) obj; + + if (!getDestinationUrisList().equals(other.getDestinationUrisList())) return false; + if (getDestinationUrisTruncated() != other.getDestinationUrisTruncated()) return false; + if (!getSourceCase().equals(other.getSourceCase())) return false; + switch (sourceCase_) { + case 2: + if (!getSourceTable().equals(other.getSourceTable())) return false; + break; + case 4: + if (!getSourceModel().equals(other.getSourceModel())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getDestinationUrisCount() > 0) { + hash = (37 * hash) + DESTINATION_URIS_FIELD_NUMBER; + hash = (53 * hash) + getDestinationUrisList().hashCode(); + } + hash = (37 * hash) + DESTINATION_URIS_TRUNCATED_FIELD_NUMBER; + hash = + (53 * hash) + com.google.protobuf.Internal.hashBoolean(getDestinationUrisTruncated()); + switch (sourceCase_) { + case 2: + hash = (37 * hash) + SOURCE_TABLE_FIELD_NUMBER; + hash = (53 * hash) + getSourceTable().hashCode(); + break; + case 4: + hash = (37 * hash) + SOURCE_MODEL_FIELD_NUMBER; + hash = (53 * hash) + getSourceModel().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+       * Extract job configuration.
+       * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder.class); + } + + // Construct using + // com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + destinationUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + destinationUrisTruncated_ = false; + + sourceCase_ = 0; + source_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract(this); + int from_bitField0_ = bitField0_; + if (((bitField0_ & 0x00000001) != 0)) { + destinationUris_ = destinationUris_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.destinationUris_ = destinationUris_; + result.destinationUrisTruncated_ = destinationUrisTruncated_; + if (sourceCase_ == 2) { + result.source_ = source_; + } + if (sourceCase_ == 4) { + result.source_ = source_; + } + result.sourceCase_ = sourceCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) { + return mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + .getDefaultInstance()) return this; + if (!other.destinationUris_.isEmpty()) { + if (destinationUris_.isEmpty()) { + destinationUris_ = other.destinationUris_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureDestinationUrisIsMutable(); + destinationUris_.addAll(other.destinationUris_); + } + onChanged(); + } + if (other.getDestinationUrisTruncated() != false) { + setDestinationUrisTruncated(other.getDestinationUrisTruncated()); + } + switch (other.getSourceCase()) { + case SOURCE_TABLE: + { + sourceCase_ = 2; + source_ = other.source_; + onChanged(); + break; + } + case SOURCE_MODEL: + { + sourceCase_ = 4; + source_ = other.source_; + onChanged(); + break; + } + case SOURCE_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int sourceCase_ = 0; + private java.lang.Object source_; + + public SourceCase getSourceCase() { + return SourceCase.forNumber(sourceCase_); + } + + public Builder clearSource() { + sourceCase_ = 0; + source_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringList destinationUris_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureDestinationUrisIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + destinationUris_ = new com.google.protobuf.LazyStringArrayList(destinationUris_); + bitField0_ |= 0x00000001; + } + } + /** + * + * + *
+         * URIs where extracted data should be written. Entire list is truncated
+         * if exceeds 50K.
+         * 
+ * + * repeated string destination_uris = 1; + * + * @return A list containing the destinationUris. + */ + public com.google.protobuf.ProtocolStringList getDestinationUrisList() { + return destinationUris_.getUnmodifiableView(); + } + /** + * + * + *
+         * URIs where extracted data should be written. Entire list is truncated
+         * if exceeds 50K.
+         * 
+ * + * repeated string destination_uris = 1; + * + * @return The count of destinationUris. + */ + public int getDestinationUrisCount() { + return destinationUris_.size(); + } + /** + * + * + *
+         * URIs where extracted data should be written. Entire list is truncated
+         * if exceeds 50K.
+         * 
+ * + * repeated string destination_uris = 1; + * + * @param index The index of the element to return. + * @return The destinationUris at the given index. + */ + public java.lang.String getDestinationUris(int index) { + return destinationUris_.get(index); + } + /** + * + * + *
+         * URIs where extracted data should be written. Entire list is truncated
+         * if exceeds 50K.
+         * 
+ * + * repeated string destination_uris = 1; + * + * @param index The index of the value to return. + * @return The bytes of the destinationUris at the given index. + */ + public com.google.protobuf.ByteString getDestinationUrisBytes(int index) { + return destinationUris_.getByteString(index); + } + /** + * + * + *
+         * URIs where extracted data should be written. Entire list is truncated
+         * if exceeds 50K.
+         * 
+ * + * repeated string destination_uris = 1; + * + * @param index The index to set the value at. + * @param value The destinationUris to set. + * @return This builder for chaining. + */ + public Builder setDestinationUris(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDestinationUrisIsMutable(); + destinationUris_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+         * URIs where extracted data should be written. Entire list is truncated
+         * if exceeds 50K.
+         * 
+ * + * repeated string destination_uris = 1; + * + * @param value The destinationUris to add. + * @return This builder for chaining. + */ + public Builder addDestinationUris(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureDestinationUrisIsMutable(); + destinationUris_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+         * URIs where extracted data should be written. Entire list is truncated
+         * if exceeds 50K.
+         * 
+ * + * repeated string destination_uris = 1; + * + * @param values The destinationUris to add. + * @return This builder for chaining. + */ + public Builder addAllDestinationUris(java.lang.Iterable values) { + ensureDestinationUrisIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, destinationUris_); + onChanged(); + return this; + } + /** + * + * + *
+         * URIs where extracted data should be written. Entire list is truncated
+         * if exceeds 50K.
+         * 
+ * + * repeated string destination_uris = 1; + * + * @return This builder for chaining. + */ + public Builder clearDestinationUris() { + destinationUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+         * URIs where extracted data should be written. Entire list is truncated
+         * if exceeds 50K.
+         * 
+ * + * repeated string destination_uris = 1; + * + * @param value The bytes of the destinationUris to add. + * @return This builder for chaining. + */ + public Builder addDestinationUrisBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureDestinationUrisIsMutable(); + destinationUris_.add(value); + onChanged(); + return this; + } + + private boolean destinationUrisTruncated_; + /** + * + * + *
+         * True if the destination_URIs field was truncated.
+         * 
+ * + * bool destination_uris_truncated = 3; + * + * @return The destinationUrisTruncated. + */ + @java.lang.Override + public boolean getDestinationUrisTruncated() { + return destinationUrisTruncated_; + } + /** + * + * + *
+         * True if the destination_URIs field was truncated.
+         * 
+ * + * bool destination_uris_truncated = 3; + * + * @param value The destinationUrisTruncated to set. + * @return This builder for chaining. + */ + public Builder setDestinationUrisTruncated(boolean value) { + + destinationUrisTruncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * True if the destination_URIs field was truncated.
+         * 
+ * + * bool destination_uris_truncated = 3; + * + * @return This builder for chaining. + */ + public Builder clearDestinationUrisTruncated() { + + destinationUrisTruncated_ = false; + onChanged(); + return this; + } + + /** + * + * + *
+         * The source table.
+         * 
+ * + * string source_table = 2; + * + * @return Whether the sourceTable field is set. + */ + @java.lang.Override + public boolean hasSourceTable() { + return sourceCase_ == 2; + } + /** + * + * + *
+         * The source table.
+         * 
+ * + * string source_table = 2; + * + * @return The sourceTable. + */ + @java.lang.Override + public java.lang.String getSourceTable() { + java.lang.Object ref = ""; + if (sourceCase_ == 2) { + ref = source_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (sourceCase_ == 2) { + source_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * The source table.
+         * 
+ * + * string source_table = 2; + * + * @return The bytes for sourceTable. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSourceTableBytes() { + java.lang.Object ref = ""; + if (sourceCase_ == 2) { + ref = source_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (sourceCase_ == 2) { + source_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * The source table.
+         * 
+ * + * string source_table = 2; + * + * @param value The sourceTable to set. + * @return This builder for chaining. + */ + public Builder setSourceTable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sourceCase_ = 2; + source_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The source table.
+         * 
+ * + * string source_table = 2; + * + * @return This builder for chaining. + */ + public Builder clearSourceTable() { + if (sourceCase_ == 2) { + sourceCase_ = 0; + source_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+         * The source table.
+         * 
+ * + * string source_table = 2; + * + * @param value The bytes for sourceTable to set. + * @return This builder for chaining. + */ + public Builder setSourceTableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sourceCase_ = 2; + source_ = value; + onChanged(); + return this; + } + + /** + * + * + *
+         * The source model.
+         * 
+ * + * string source_model = 4; + * + * @return Whether the sourceModel field is set. + */ + @java.lang.Override + public boolean hasSourceModel() { + return sourceCase_ == 4; + } + /** + * + * + *
+         * The source model.
+         * 
+ * + * string source_model = 4; + * + * @return The sourceModel. + */ + @java.lang.Override + public java.lang.String getSourceModel() { + java.lang.Object ref = ""; + if (sourceCase_ == 4) { + ref = source_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (sourceCase_ == 4) { + source_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * The source model.
+         * 
+ * + * string source_model = 4; + * + * @return The bytes for sourceModel. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSourceModelBytes() { + java.lang.Object ref = ""; + if (sourceCase_ == 4) { + ref = source_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (sourceCase_ == 4) { + source_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * The source model.
+         * 
+ * + * string source_model = 4; + * + * @param value The sourceModel to set. + * @return This builder for chaining. + */ + public Builder setSourceModel(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + sourceCase_ = 4; + source_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The source model.
+         * 
+ * + * string source_model = 4; + * + * @return This builder for chaining. + */ + public Builder clearSourceModel() { + if (sourceCase_ == 4) { + sourceCase_ = 0; + source_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+         * The source model.
+         * 
+ * + * string source_model = 4; + * + * @param value The bytes for sourceModel to set. + * @return This builder for chaining. + */ + public Builder setSourceModelBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + sourceCase_ = 4; + source_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Extract parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Extract(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface TableCopyOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * Source tables. Entire list is truncated if exceeds 50K.
+       * 
+ * + * repeated string source_tables = 1; + * + * @return A list containing the sourceTables. + */ + java.util.List getSourceTablesList(); + /** + * + * + *
+       * Source tables. Entire list is truncated if exceeds 50K.
+       * 
+ * + * repeated string source_tables = 1; + * + * @return The count of sourceTables. + */ + int getSourceTablesCount(); + /** + * + * + *
+       * Source tables. Entire list is truncated if exceeds 50K.
+       * 
+ * + * repeated string source_tables = 1; + * + * @param index The index of the element to return. + * @return The sourceTables at the given index. + */ + java.lang.String getSourceTables(int index); + /** + * + * + *
+       * Source tables. Entire list is truncated if exceeds 50K.
+       * 
+ * + * repeated string source_tables = 1; + * + * @param index The index of the value to return. + * @return The bytes of the sourceTables at the given index. + */ + com.google.protobuf.ByteString getSourceTablesBytes(int index); + + /** + * + * + *
+       * True if the source_tables field was truncated.
+       * 
+ * + * bool source_tables_truncated = 6; + * + * @return The sourceTablesTruncated. + */ + boolean getSourceTablesTruncated(); + + /** + * + * + *
+       * Destination table.
+       * 
+ * + * string destination_table = 2; + * + * @return The destinationTable. + */ + java.lang.String getDestinationTable(); + /** + * + * + *
+       * Destination table.
+       * 
+ * + * string destination_table = 2; + * + * @return The bytes for destinationTable. + */ + com.google.protobuf.ByteString getDestinationTableBytes(); + + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The enum numeric value on the wire for createDisposition. + */ + int getCreateDispositionValue(); + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The createDisposition. + */ + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition(); + + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The enum numeric value on the wire for writeDisposition. + */ + int getWriteDispositionValue(); + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The writeDisposition. + */ + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition(); + + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + * + * @return Whether the destinationTableEncryption field is set. + */ + boolean hasDestinationTableEncryption(); + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + * + * @return The destinationTableEncryption. + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDestinationTableEncryption(); + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDestinationTableEncryptionOrBuilder(); + + /** + * + * + *
+       * Supported operation types in the table copy job.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; + * + * @return The enum numeric value on the wire for operationType. + */ + int getOperationTypeValue(); + /** + * + * + *
+       * Supported operation types in the table copy job.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; + * + * @return The operationType. + */ + com.google.cloud.audit.BigQueryAuditMetadata.OperationType getOperationType(); + + /** + * + * + *
+       * Expiration time set on the destination table. Expired tables will be
+       * deleted and their storage reclaimed.
+       * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + * + * @return Whether the destinationExpirationTime field is set. + */ + boolean hasDestinationExpirationTime(); + /** + * + * + *
+       * Expiration time set on the destination table. Expired tables will be
+       * deleted and their storage reclaimed.
+       * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + * + * @return The destinationExpirationTime. + */ + com.google.protobuf.Timestamp getDestinationExpirationTime(); + /** + * + * + *
+       * Expiration time set on the destination table. Expired tables will be
+       * deleted and their storage reclaimed.
+       * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + */ + com.google.protobuf.TimestampOrBuilder getDestinationExpirationTimeOrBuilder(); + } + /** + * + * + *
+     * Table copy job configuration.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy} + */ + public static final class TableCopy extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) + TableCopyOrBuilder { + private static final long serialVersionUID = 0L; + // Use TableCopy.newBuilder() to construct. + private TableCopy(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private TableCopy() { + sourceTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; + destinationTable_ = ""; + createDisposition_ = 0; + writeDisposition_ = 0; + operationType_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TableCopy(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private TableCopy( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + sourceTables_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + sourceTables_.add(s); + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + destinationTable_ = s; + break; + } + case 24: + { + int rawValue = input.readEnum(); + + createDisposition_ = rawValue; + break; + } + case 32: + { + int rawValue = input.readEnum(); + + writeDisposition_ = rawValue; + break; + } + case 42: + { + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = + null; + if (destinationTableEncryption_ != null) { + subBuilder = destinationTableEncryption_.toBuilder(); + } + destinationTableEncryption_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(destinationTableEncryption_); + destinationTableEncryption_ = subBuilder.buildPartial(); + } + + break; + } + case 48: + { + sourceTablesTruncated_ = input.readBool(); + break; + } + case 56: + { + int rawValue = input.readEnum(); + + operationType_ = rawValue; + break; + } + case 66: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (destinationExpirationTime_ != null) { + subBuilder = destinationExpirationTime_.toBuilder(); + } + destinationExpirationTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(destinationExpirationTime_); + destinationExpirationTime_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + sourceTables_ = sourceTables_.getUnmodifiableView(); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder.class); + } + + public static final int SOURCE_TABLES_FIELD_NUMBER = 1; + private com.google.protobuf.LazyStringList sourceTables_; + /** + * + * + *
+       * Source tables. Entire list is truncated if exceeds 50K.
+       * 
+ * + * repeated string source_tables = 1; + * + * @return A list containing the sourceTables. + */ + public com.google.protobuf.ProtocolStringList getSourceTablesList() { + return sourceTables_; + } + /** + * + * + *
+       * Source tables. Entire list is truncated if exceeds 50K.
+       * 
+ * + * repeated string source_tables = 1; + * + * @return The count of sourceTables. + */ + public int getSourceTablesCount() { + return sourceTables_.size(); + } + /** + * + * + *
+       * Source tables. Entire list is truncated if exceeds 50K.
+       * 
+ * + * repeated string source_tables = 1; + * + * @param index The index of the element to return. + * @return The sourceTables at the given index. + */ + public java.lang.String getSourceTables(int index) { + return sourceTables_.get(index); + } + /** + * + * + *
+       * Source tables. Entire list is truncated if exceeds 50K.
+       * 
+ * + * repeated string source_tables = 1; + * + * @param index The index of the value to return. + * @return The bytes of the sourceTables at the given index. + */ + public com.google.protobuf.ByteString getSourceTablesBytes(int index) { + return sourceTables_.getByteString(index); + } + + public static final int SOURCE_TABLES_TRUNCATED_FIELD_NUMBER = 6; + private boolean sourceTablesTruncated_; + /** + * + * + *
+       * True if the source_tables field was truncated.
+       * 
+ * + * bool source_tables_truncated = 6; + * + * @return The sourceTablesTruncated. + */ + @java.lang.Override + public boolean getSourceTablesTruncated() { + return sourceTablesTruncated_; + } + + public static final int DESTINATION_TABLE_FIELD_NUMBER = 2; + private volatile java.lang.Object destinationTable_; + /** + * + * + *
+       * Destination table.
+       * 
+ * + * string destination_table = 2; + * + * @return The destinationTable. + */ + @java.lang.Override + public java.lang.String getDestinationTable() { + java.lang.Object ref = destinationTable_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationTable_ = s; + return s; + } + } + /** + * + * + *
+       * Destination table.
+       * 
+ * + * string destination_table = 2; + * + * @return The bytes for destinationTable. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDestinationTableBytes() { + java.lang.Object ref = destinationTable_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationTable_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_DISPOSITION_FIELD_NUMBER = 3; + private int createDisposition_; + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The enum numeric value on the wire for createDisposition. + */ + @java.lang.Override + public int getCreateDispositionValue() { + return createDisposition_; + } + /** + * + * + *
+       * Destination table create disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The createDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( + createDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED + : result; + } + + public static final int WRITE_DISPOSITION_FIELD_NUMBER = 4; + private int writeDisposition_; + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The enum numeric value on the wire for writeDisposition. + */ + @java.lang.Override + public int getWriteDispositionValue() { + return writeDisposition_; + } + /** + * + * + *
+       * Destination table write disposition.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The writeDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( + writeDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED + : result; + } + + public static final int DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER = 5; + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + destinationTableEncryption_; + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + * + * @return Whether the destinationTableEncryption field is set. + */ + @java.lang.Override + public boolean hasDestinationTableEncryption() { + return destinationTableEncryption_ != null; + } + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + * + * @return The destinationTableEncryption. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + getDestinationTableEncryption() { + return destinationTableEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : destinationTableEncryption_; + } + /** + * + * + *
+       * Result table encryption information. Set when non-default encryption is
+       * used.
+       * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDestinationTableEncryptionOrBuilder() { + return getDestinationTableEncryption(); + } + + public static final int OPERATION_TYPE_FIELD_NUMBER = 7; + private int operationType_; + /** + * + * + *
+       * Supported operation types in the table copy job.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; + * + * @return The enum numeric value on the wire for operationType. + */ + @java.lang.Override + public int getOperationTypeValue() { + return operationType_; + } + /** + * + * + *
+       * Supported operation types in the table copy job.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; + * + * @return The operationType. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.OperationType getOperationType() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.OperationType result = + com.google.cloud.audit.BigQueryAuditMetadata.OperationType.valueOf(operationType_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.OperationType.UNRECOGNIZED + : result; + } + + public static final int DESTINATION_EXPIRATION_TIME_FIELD_NUMBER = 8; + private com.google.protobuf.Timestamp destinationExpirationTime_; + /** + * + * + *
+       * Expiration time set on the destination table. Expired tables will be
+       * deleted and their storage reclaimed.
+       * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + * + * @return Whether the destinationExpirationTime field is set. + */ + @java.lang.Override + public boolean hasDestinationExpirationTime() { + return destinationExpirationTime_ != null; + } + /** + * + * + *
+       * Expiration time set on the destination table. Expired tables will be
+       * deleted and their storage reclaimed.
+       * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + * + * @return The destinationExpirationTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getDestinationExpirationTime() { + return destinationExpirationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : destinationExpirationTime_; + } + /** + * + * + *
+       * Expiration time set on the destination table. Expired tables will be
+       * deleted and their storage reclaimed.
+       * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getDestinationExpirationTimeOrBuilder() { + return getDestinationExpirationTime(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < sourceTables_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, sourceTables_.getRaw(i)); + } + if (!getDestinationTableBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, destinationTable_); + } + if (createDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition + .CREATE_DISPOSITION_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, createDisposition_); + } + if (writeDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition + .WRITE_DISPOSITION_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, writeDisposition_); + } + if (destinationTableEncryption_ != null) { + output.writeMessage(5, getDestinationTableEncryption()); + } + if (sourceTablesTruncated_ != false) { + output.writeBool(6, sourceTablesTruncated_); + } + if (operationType_ + != com.google.cloud.audit.BigQueryAuditMetadata.OperationType.OPERATION_TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(7, operationType_); + } + if (destinationExpirationTime_ != null) { + output.writeMessage(8, getDestinationExpirationTime()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + for (int i = 0; i < sourceTables_.size(); i++) { + dataSize += computeStringSizeNoTag(sourceTables_.getRaw(i)); + } + size += dataSize; + size += 1 * getSourceTablesList().size(); + } + if (!getDestinationTableBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, destinationTable_); + } + if (createDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition + .CREATE_DISPOSITION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, createDisposition_); + } + if (writeDisposition_ + != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition + .WRITE_DISPOSITION_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, writeDisposition_); + } + if (destinationTableEncryption_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, getDestinationTableEncryption()); + } + if (sourceTablesTruncated_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, sourceTablesTruncated_); + } + if (operationType_ + != com.google.cloud.audit.BigQueryAuditMetadata.OperationType.OPERATION_TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, operationType_); + } + if (destinationExpirationTime_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 8, getDestinationExpirationTime()); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) obj; + + if (!getSourceTablesList().equals(other.getSourceTablesList())) return false; + if (getSourceTablesTruncated() != other.getSourceTablesTruncated()) return false; + if (!getDestinationTable().equals(other.getDestinationTable())) return false; + if (createDisposition_ != other.createDisposition_) return false; + if (writeDisposition_ != other.writeDisposition_) return false; + if (hasDestinationTableEncryption() != other.hasDestinationTableEncryption()) return false; + if (hasDestinationTableEncryption()) { + if (!getDestinationTableEncryption().equals(other.getDestinationTableEncryption())) + return false; + } + if (operationType_ != other.operationType_) return false; + if (hasDestinationExpirationTime() != other.hasDestinationExpirationTime()) return false; + if (hasDestinationExpirationTime()) { + if (!getDestinationExpirationTime().equals(other.getDestinationExpirationTime())) + return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getSourceTablesCount() > 0) { + hash = (37 * hash) + SOURCE_TABLES_FIELD_NUMBER; + hash = (53 * hash) + getSourceTablesList().hashCode(); + } + hash = (37 * hash) + SOURCE_TABLES_TRUNCATED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSourceTablesTruncated()); + hash = (37 * hash) + DESTINATION_TABLE_FIELD_NUMBER; + hash = (53 * hash) + getDestinationTable().hashCode(); + hash = (37 * hash) + CREATE_DISPOSITION_FIELD_NUMBER; + hash = (53 * hash) + createDisposition_; + hash = (37 * hash) + WRITE_DISPOSITION_FIELD_NUMBER; + hash = (53 * hash) + writeDisposition_; + if (hasDestinationTableEncryption()) { + hash = (37 * hash) + DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER; + hash = (53 * hash) + getDestinationTableEncryption().hashCode(); + } + hash = (37 * hash) + OPERATION_TYPE_FIELD_NUMBER; + hash = (53 * hash) + operationType_; + if (hasDestinationExpirationTime()) { + hash = (37 * hash) + DESTINATION_EXPIRATION_TIME_FIELD_NUMBER; + hash = (53 * hash) + getDestinationExpirationTime().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+       * Table copy job configuration.
+       * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder.class); + } + + // Construct using + // com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + sourceTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + sourceTablesTruncated_ = false; + + destinationTable_ = ""; + + createDisposition_ = 0; + + writeDisposition_ = 0; + + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryption_ = null; + } else { + destinationTableEncryption_ = null; + destinationTableEncryptionBuilder_ = null; + } + operationType_ = 0; + + if (destinationExpirationTimeBuilder_ == null) { + destinationExpirationTime_ = null; + } else { + destinationExpirationTime_ = null; + destinationExpirationTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy(this); + int from_bitField0_ = bitField0_; + if (((bitField0_ & 0x00000001) != 0)) { + sourceTables_ = sourceTables_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.sourceTables_ = sourceTables_; + result.sourceTablesTruncated_ = sourceTablesTruncated_; + result.destinationTable_ = destinationTable_; + result.createDisposition_ = createDisposition_; + result.writeDisposition_ = writeDisposition_; + if (destinationTableEncryptionBuilder_ == null) { + result.destinationTableEncryption_ = destinationTableEncryption_; + } else { + result.destinationTableEncryption_ = destinationTableEncryptionBuilder_.build(); + } + result.operationType_ = operationType_; + if (destinationExpirationTimeBuilder_ == null) { + result.destinationExpirationTime_ = destinationExpirationTime_; + } else { + result.destinationExpirationTime_ = destinationExpirationTimeBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) { + return mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + .getDefaultInstance()) return this; + if (!other.sourceTables_.isEmpty()) { + if (sourceTables_.isEmpty()) { + sourceTables_ = other.sourceTables_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureSourceTablesIsMutable(); + sourceTables_.addAll(other.sourceTables_); + } + onChanged(); + } + if (other.getSourceTablesTruncated() != false) { + setSourceTablesTruncated(other.getSourceTablesTruncated()); + } + if (!other.getDestinationTable().isEmpty()) { + destinationTable_ = other.destinationTable_; + onChanged(); + } + if (other.createDisposition_ != 0) { + setCreateDispositionValue(other.getCreateDispositionValue()); + } + if (other.writeDisposition_ != 0) { + setWriteDispositionValue(other.getWriteDispositionValue()); + } + if (other.hasDestinationTableEncryption()) { + mergeDestinationTableEncryption(other.getDestinationTableEncryption()); + } + if (other.operationType_ != 0) { + setOperationTypeValue(other.getOperationTypeValue()); + } + if (other.hasDestinationExpirationTime()) { + mergeDestinationExpirationTime(other.getDestinationExpirationTime()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private com.google.protobuf.LazyStringList sourceTables_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureSourceTablesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + sourceTables_ = new com.google.protobuf.LazyStringArrayList(sourceTables_); + bitField0_ |= 0x00000001; + } + } + /** + * + * + *
+         * Source tables. Entire list is truncated if exceeds 50K.
+         * 
+ * + * repeated string source_tables = 1; + * + * @return A list containing the sourceTables. + */ + public com.google.protobuf.ProtocolStringList getSourceTablesList() { + return sourceTables_.getUnmodifiableView(); + } + /** + * + * + *
+         * Source tables. Entire list is truncated if exceeds 50K.
+         * 
+ * + * repeated string source_tables = 1; + * + * @return The count of sourceTables. + */ + public int getSourceTablesCount() { + return sourceTables_.size(); + } + /** + * + * + *
+         * Source tables. Entire list is truncated if exceeds 50K.
+         * 
+ * + * repeated string source_tables = 1; + * + * @param index The index of the element to return. + * @return The sourceTables at the given index. + */ + public java.lang.String getSourceTables(int index) { + return sourceTables_.get(index); + } + /** + * + * + *
+         * Source tables. Entire list is truncated if exceeds 50K.
+         * 
+ * + * repeated string source_tables = 1; + * + * @param index The index of the value to return. + * @return The bytes of the sourceTables at the given index. + */ + public com.google.protobuf.ByteString getSourceTablesBytes(int index) { + return sourceTables_.getByteString(index); + } + /** + * + * + *
+         * Source tables. Entire list is truncated if exceeds 50K.
+         * 
+ * + * repeated string source_tables = 1; + * + * @param index The index to set the value at. + * @param value The sourceTables to set. + * @return This builder for chaining. + */ + public Builder setSourceTables(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSourceTablesIsMutable(); + sourceTables_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+         * Source tables. Entire list is truncated if exceeds 50K.
+         * 
+ * + * repeated string source_tables = 1; + * + * @param value The sourceTables to add. + * @return This builder for chaining. + */ + public Builder addSourceTables(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSourceTablesIsMutable(); + sourceTables_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+         * Source tables. Entire list is truncated if exceeds 50K.
+         * 
+ * + * repeated string source_tables = 1; + * + * @param values The sourceTables to add. + * @return This builder for chaining. + */ + public Builder addAllSourceTables(java.lang.Iterable values) { + ensureSourceTablesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, sourceTables_); + onChanged(); + return this; + } + /** + * + * + *
+         * Source tables. Entire list is truncated if exceeds 50K.
+         * 
+ * + * repeated string source_tables = 1; + * + * @return This builder for chaining. + */ + public Builder clearSourceTables() { + sourceTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+         * Source tables. Entire list is truncated if exceeds 50K.
+         * 
+ * + * repeated string source_tables = 1; + * + * @param value The bytes of the sourceTables to add. + * @return This builder for chaining. + */ + public Builder addSourceTablesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureSourceTablesIsMutable(); + sourceTables_.add(value); + onChanged(); + return this; + } + + private boolean sourceTablesTruncated_; + /** + * + * + *
+         * True if the source_tables field was truncated.
+         * 
+ * + * bool source_tables_truncated = 6; + * + * @return The sourceTablesTruncated. + */ + @java.lang.Override + public boolean getSourceTablesTruncated() { + return sourceTablesTruncated_; + } + /** + * + * + *
+         * True if the source_tables field was truncated.
+         * 
+ * + * bool source_tables_truncated = 6; + * + * @param value The sourceTablesTruncated to set. + * @return This builder for chaining. + */ + public Builder setSourceTablesTruncated(boolean value) { + + sourceTablesTruncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * True if the source_tables field was truncated.
+         * 
+ * + * bool source_tables_truncated = 6; + * + * @return This builder for chaining. + */ + public Builder clearSourceTablesTruncated() { + + sourceTablesTruncated_ = false; + onChanged(); + return this; + } + + private java.lang.Object destinationTable_ = ""; + /** + * + * + *
+         * Destination table.
+         * 
+ * + * string destination_table = 2; + * + * @return The destinationTable. + */ + public java.lang.String getDestinationTable() { + java.lang.Object ref = destinationTable_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + destinationTable_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * Destination table.
+         * 
+ * + * string destination_table = 2; + * + * @return The bytes for destinationTable. + */ + public com.google.protobuf.ByteString getDestinationTableBytes() { + java.lang.Object ref = destinationTable_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + destinationTable_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * Destination table.
+         * 
+ * + * string destination_table = 2; + * + * @param value The destinationTable to set. + * @return This builder for chaining. + */ + public Builder setDestinationTable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + destinationTable_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table.
+         * 
+ * + * string destination_table = 2; + * + * @return This builder for chaining. + */ + public Builder clearDestinationTable() { + + destinationTable_ = getDefaultInstance().getDestinationTable(); + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table.
+         * 
+ * + * string destination_table = 2; + * + * @param value The bytes for destinationTable to set. + * @return This builder for chaining. + */ + public Builder setDestinationTableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + destinationTable_ = value; + onChanged(); + return this; + } + + private int createDisposition_ = 0; + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The enum numeric value on the wire for createDisposition. + */ + @java.lang.Override + public int getCreateDispositionValue() { + return createDisposition_; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @param value The enum numeric value on the wire for createDisposition to set. + * @return This builder for chaining. + */ + public Builder setCreateDispositionValue(int value) { + + createDisposition_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return The createDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition + getCreateDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( + createDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @param value The createDisposition to set. + * @return This builder for chaining. + */ + public Builder setCreateDisposition( + com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition value) { + if (value == null) { + throw new NullPointerException(); + } + + createDisposition_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table create disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; + * + * + * @return This builder for chaining. + */ + public Builder clearCreateDisposition() { + + createDisposition_ = 0; + onChanged(); + return this; + } + + private int writeDisposition_ = 0; + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The enum numeric value on the wire for writeDisposition. + */ + @java.lang.Override + public int getWriteDispositionValue() { + return writeDisposition_; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @param value The enum numeric value on the wire for writeDisposition to set. + * @return This builder for chaining. + */ + public Builder setWriteDispositionValue(int value) { + + writeDisposition_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return The writeDisposition. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( + writeDisposition_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @param value The writeDisposition to set. + * @return This builder for chaining. + */ + public Builder setWriteDisposition( + com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition value) { + if (value == null) { + throw new NullPointerException(); + } + + writeDisposition_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * Destination table write disposition.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; + * + * + * @return This builder for chaining. + */ + public Builder clearWriteDisposition() { + + writeDisposition_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + destinationTableEncryption_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + destinationTableEncryptionBuilder_; + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + * + * @return Whether the destinationTableEncryption field is set. + */ + public boolean hasDestinationTableEncryption() { + return destinationTableEncryptionBuilder_ != null || destinationTableEncryption_ != null; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + * + * @return The destinationTableEncryption. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + getDestinationTableEncryption() { + if (destinationTableEncryptionBuilder_ == null) { + return destinationTableEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : destinationTableEncryption_; + } else { + return destinationTableEncryptionBuilder_.getMessage(); + } + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + */ + public Builder setDestinationTableEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (destinationTableEncryptionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + destinationTableEncryption_ = value; + onChanged(); + } else { + destinationTableEncryptionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + */ + public Builder setDestinationTableEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryption_ = builderForValue.build(); + onChanged(); + } else { + destinationTableEncryptionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + */ + public Builder mergeDestinationTableEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (destinationTableEncryptionBuilder_ == null) { + if (destinationTableEncryption_ != null) { + destinationTableEncryption_ = + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder( + destinationTableEncryption_) + .mergeFrom(value) + .buildPartial(); + } else { + destinationTableEncryption_ = value; + } + onChanged(); + } else { + destinationTableEncryptionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + */ + public Builder clearDestinationTableEncryption() { + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryption_ = null; + onChanged(); + } else { + destinationTableEncryption_ = null; + destinationTableEncryptionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder + getDestinationTableEncryptionBuilder() { + + onChanged(); + return getDestinationTableEncryptionFieldBuilder().getBuilder(); + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getDestinationTableEncryptionOrBuilder() { + if (destinationTableEncryptionBuilder_ != null) { + return destinationTableEncryptionBuilder_.getMessageOrBuilder(); + } else { + return destinationTableEncryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : destinationTableEncryption_; + } + } + /** + * + * + *
+         * Result table encryption information. Set when non-default encryption is
+         * used.
+         * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + getDestinationTableEncryptionFieldBuilder() { + if (destinationTableEncryptionBuilder_ == null) { + destinationTableEncryptionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( + getDestinationTableEncryption(), getParentForChildren(), isClean()); + destinationTableEncryption_ = null; + } + return destinationTableEncryptionBuilder_; + } + + private int operationType_ = 0; + /** + * + * + *
+         * Supported operation types in the table copy job.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; + * + * @return The enum numeric value on the wire for operationType. + */ + @java.lang.Override + public int getOperationTypeValue() { + return operationType_; + } + /** + * + * + *
+         * Supported operation types in the table copy job.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; + * + * @param value The enum numeric value on the wire for operationType to set. + * @return This builder for chaining. + */ + public Builder setOperationTypeValue(int value) { + + operationType_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Supported operation types in the table copy job.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; + * + * @return The operationType. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.OperationType getOperationType() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.OperationType result = + com.google.cloud.audit.BigQueryAuditMetadata.OperationType.valueOf(operationType_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.OperationType.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * Supported operation types in the table copy job.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; + * + * @param value The operationType to set. + * @return This builder for chaining. + */ + public Builder setOperationType( + com.google.cloud.audit.BigQueryAuditMetadata.OperationType value) { + if (value == null) { + throw new NullPointerException(); + } + + operationType_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * Supported operation types in the table copy job.
+         * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; + * + * @return This builder for chaining. + */ + public Builder clearOperationType() { + + operationType_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp destinationExpirationTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + destinationExpirationTimeBuilder_; + /** + * + * + *
+         * Expiration time set on the destination table. Expired tables will be
+         * deleted and their storage reclaimed.
+         * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + * + * @return Whether the destinationExpirationTime field is set. + */ + public boolean hasDestinationExpirationTime() { + return destinationExpirationTimeBuilder_ != null || destinationExpirationTime_ != null; + } + /** + * + * + *
+         * Expiration time set on the destination table. Expired tables will be
+         * deleted and their storage reclaimed.
+         * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + * + * @return The destinationExpirationTime. + */ + public com.google.protobuf.Timestamp getDestinationExpirationTime() { + if (destinationExpirationTimeBuilder_ == null) { + return destinationExpirationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : destinationExpirationTime_; + } else { + return destinationExpirationTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+         * Expiration time set on the destination table. Expired tables will be
+         * deleted and their storage reclaimed.
+         * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + */ + public Builder setDestinationExpirationTime(com.google.protobuf.Timestamp value) { + if (destinationExpirationTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + destinationExpirationTime_ = value; + onChanged(); + } else { + destinationExpirationTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+         * Expiration time set on the destination table. Expired tables will be
+         * deleted and their storage reclaimed.
+         * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + */ + public Builder setDestinationExpirationTime( + com.google.protobuf.Timestamp.Builder builderForValue) { + if (destinationExpirationTimeBuilder_ == null) { + destinationExpirationTime_ = builderForValue.build(); + onChanged(); + } else { + destinationExpirationTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+         * Expiration time set on the destination table. Expired tables will be
+         * deleted and their storage reclaimed.
+         * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + */ + public Builder mergeDestinationExpirationTime(com.google.protobuf.Timestamp value) { + if (destinationExpirationTimeBuilder_ == null) { + if (destinationExpirationTime_ != null) { + destinationExpirationTime_ = + com.google.protobuf.Timestamp.newBuilder(destinationExpirationTime_) + .mergeFrom(value) + .buildPartial(); + } else { + destinationExpirationTime_ = value; + } + onChanged(); + } else { + destinationExpirationTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+         * Expiration time set on the destination table. Expired tables will be
+         * deleted and their storage reclaimed.
+         * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + */ + public Builder clearDestinationExpirationTime() { + if (destinationExpirationTimeBuilder_ == null) { + destinationExpirationTime_ = null; + onChanged(); + } else { + destinationExpirationTime_ = null; + destinationExpirationTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+         * Expiration time set on the destination table. Expired tables will be
+         * deleted and their storage reclaimed.
+         * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + */ + public com.google.protobuf.Timestamp.Builder getDestinationExpirationTimeBuilder() { + + onChanged(); + return getDestinationExpirationTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+         * Expiration time set on the destination table. Expired tables will be
+         * deleted and their storage reclaimed.
+         * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + */ + public com.google.protobuf.TimestampOrBuilder getDestinationExpirationTimeOrBuilder() { + if (destinationExpirationTimeBuilder_ != null) { + return destinationExpirationTimeBuilder_.getMessageOrBuilder(); + } else { + return destinationExpirationTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : destinationExpirationTime_; + } + } + /** + * + * + *
+         * Expiration time set on the destination table. Expired tables will be
+         * deleted and their storage reclaimed.
+         * 
+ * + * .google.protobuf.Timestamp destination_expiration_time = 8; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getDestinationExpirationTimeFieldBuilder() { + if (destinationExpirationTimeBuilder_ == null) { + destinationExpirationTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getDestinationExpirationTime(), getParentForChildren(), isClean()); + destinationExpirationTime_ = null; + } + return destinationExpirationTimeBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public TableCopy parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new TableCopy(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int configCase_ = 0; + private java.lang.Object config_; + + public enum ConfigCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + QUERY_CONFIG(2), + LOAD_CONFIG(3), + EXTRACT_CONFIG(4), + TABLE_COPY_CONFIG(5), + CONFIG_NOT_SET(0); + private final int value; + + private ConfigCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ConfigCase valueOf(int value) { + return forNumber(value); + } + + public static ConfigCase forNumber(int value) { + switch (value) { + case 2: + return QUERY_CONFIG; + case 3: + return LOAD_CONFIG; + case 4: + return EXTRACT_CONFIG; + case 5: + return TABLE_COPY_CONFIG; + case 0: + return CONFIG_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + public static final int TYPE_FIELD_NUMBER = 1; + private int type_; + /** + * + * + *
+     * Job type.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + /** + * + * + *
+     * Job type.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; + * + * @return The type. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type getType() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type result = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.valueOf(type_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.UNRECOGNIZED + : result; + } + + public static final int QUERY_CONFIG_FIELD_NUMBER = 2; + /** + * + * + *
+     * Query job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + * + * @return Whether the queryConfig field is set. + */ + @java.lang.Override + public boolean hasQueryConfig() { + return configCase_ == 2; + } + /** + * + * + *
+     * Query job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + * + * @return The queryConfig. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query getQueryConfig() { + if (configCase_ == 2) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); + } + /** + * + * + *
+     * Query job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder + getQueryConfigOrBuilder() { + if (configCase_ == 2) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); + } + + public static final int LOAD_CONFIG_FIELD_NUMBER = 3; + /** + * + * + *
+     * Load job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + * + * @return Whether the loadConfig field is set. + */ + @java.lang.Override + public boolean hasLoadConfig() { + return configCase_ == 3; + } + /** + * + * + *
+     * Load job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + * + * @return The loadConfig. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load getLoadConfig() { + if (configCase_ == 3) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); + } + /** + * + * + *
+     * Load job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder + getLoadConfigOrBuilder() { + if (configCase_ == 3) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); + } + + public static final int EXTRACT_CONFIG_FIELD_NUMBER = 4; + /** + * + * + *
+     * Extract job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + * @return Whether the extractConfig field is set. + */ + @java.lang.Override + public boolean hasExtractConfig() { + return configCase_ == 4; + } + /** + * + * + *
+     * Extract job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + * @return The extractConfig. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract getExtractConfig() { + if (configCase_ == 4) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.getDefaultInstance(); + } + /** + * + * + *
+     * Extract job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder + getExtractConfigOrBuilder() { + if (configCase_ == 4) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.getDefaultInstance(); + } + + public static final int TABLE_COPY_CONFIG_FIELD_NUMBER = 5; + /** + * + * + *
+     * TableCopy job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + * + * @return Whether the tableCopyConfig field is set. + */ + @java.lang.Override + public boolean hasTableCopyConfig() { + return configCase_ == 5; + } + /** + * + * + *
+     * TableCopy job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + * + * @return The tableCopyConfig. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy getTableCopyConfig() { + if (configCase_ == 5) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.getDefaultInstance(); + } + /** + * + * + *
+     * TableCopy job information.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder + getTableCopyConfigOrBuilder() { + if (configCase_ == 5) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.getDefaultInstance(); + } + + public static final int LABELS_FIELD_NUMBER = 6; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + /** + * + * + *
+     * Labels provided for the job.
+     * 
+ * + * map<string, string> labels = 6; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + return internalGetLabels().getMap().containsKey(key); + } + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + /** + * + * + *
+     * Labels provided for the job.
+     * 
+ * + * map<string, string> labels = 6; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + /** + * + * + *
+     * Labels provided for the job.
+     * 
+ * + * map<string, string> labels = 6; + */ + @java.lang.Override + public java.lang.String getLabelsOrDefault( + java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+     * Labels provided for the job.
+     * 
+ * + * map<string, string> labels = 6; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (type_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.TYPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, type_); + } + if (configCase_ == 2) { + output.writeMessage( + 2, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_); + } + if (configCase_ == 3) { + output.writeMessage( + 3, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_); + } + if (configCase_ == 4) { + output.writeMessage( + 4, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_); + } + if (configCase_ == 5) { + output.writeMessage( + 5, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 6); + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (type_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.TYPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, type_); + } + if (configCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_); + } + if (configCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_); + } + if (configCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_); + } + if (configCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_); + } + for (java.util.Map.Entry entry : + internalGetLabels().getMap().entrySet()) { + com.google.protobuf.MapEntry labels__ = + LabelsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, labels__); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig) obj; + + if (type_ != other.type_) return false; + if (!internalGetLabels().equals(other.internalGetLabels())) return false; + if (!getConfigCase().equals(other.getConfigCase())) return false; + switch (configCase_) { + case 2: + if (!getQueryConfig().equals(other.getQueryConfig())) return false; + break; + case 3: + if (!getLoadConfig().equals(other.getLoadConfig())) return false; + break; + case 4: + if (!getExtractConfig().equals(other.getExtractConfig())) return false; + break; + case 5: + if (!getTableCopyConfig().equals(other.getTableCopyConfig())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + type_; + if (!internalGetLabels().getMap().isEmpty()) { + hash = (37 * hash) + LABELS_FIELD_NUMBER; + hash = (53 * hash) + internalGetLabels().hashCode(); + } + switch (configCase_) { + case 2: + hash = (37 * hash) + QUERY_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getQueryConfig().hashCode(); + break; + case 3: + hash = (37 * hash) + LOAD_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getLoadConfig().hashCode(); + break; + case 4: + hash = (37 * hash) + EXTRACT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getExtractConfig().hashCode(); + break; + case 5: + hash = (37 * hash) + TABLE_COPY_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getTableCopyConfig().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Job configuration.
+     * See the [Jobs](https://cloud.google.com/bigquery/docs/reference/v2/jobs)
+     * API resource for more details on individual fields.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig) + com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 6: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMutableMapField(int number) { + switch (number) { + case 6: + return internalGetMutableLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + type_ = 0; + + internalGetMutableLabels().clear(); + configCase_ = 0; + config_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig(this); + int from_bitField0_ = bitField0_; + result.type_ = type_; + if (configCase_ == 2) { + if (queryConfigBuilder_ == null) { + result.config_ = config_; + } else { + result.config_ = queryConfigBuilder_.build(); + } + } + if (configCase_ == 3) { + if (loadConfigBuilder_ == null) { + result.config_ = config_; + } else { + result.config_ = loadConfigBuilder_.build(); + } + } + if (configCase_ == 4) { + if (extractConfigBuilder_ == null) { + result.config_ = config_; + } else { + result.config_ = extractConfigBuilder_.build(); + } + } + if (configCase_ == 5) { + if (tableCopyConfigBuilder_ == null) { + result.config_ = config_; + } else { + result.config_ = tableCopyConfigBuilder_.build(); + } + } + result.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); + result.configCase_ = configCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobConfig other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDefaultInstance()) + return this; + if (other.type_ != 0) { + setTypeValue(other.getTypeValue()); + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); + switch (other.getConfigCase()) { + case QUERY_CONFIG: + { + mergeQueryConfig(other.getQueryConfig()); + break; + } + case LOAD_CONFIG: + { + mergeLoadConfig(other.getLoadConfig()); + break; + } + case EXTRACT_CONFIG: + { + mergeExtractConfig(other.getExtractConfig()); + break; + } + case TABLE_COPY_CONFIG: + { + mergeTableCopyConfig(other.getTableCopyConfig()); + break; + } + case CONFIG_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int configCase_ = 0; + private java.lang.Object config_; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + public Builder clearConfig() { + configCase_ = 0; + config_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private int type_ = 0; + /** + * + * + *
+       * Job type.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + /** + * + * + *
+       * Job type.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; + * + * @param value The enum numeric value on the wire for type to set. + * @return This builder for chaining. + */ + public Builder setTypeValue(int value) { + + type_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Job type.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; + * + * @return The type. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type getType() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type result = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.valueOf(type_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * Job type.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType(com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type value) { + if (value == null) { + throw new NullPointerException(); + } + + type_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * Job type.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; + * + * @return This builder for chaining. + */ + public Builder clearType() { + + type_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder> + queryConfigBuilder_; + /** + * + * + *
+       * Query job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + * + * @return Whether the queryConfig field is set. + */ + @java.lang.Override + public boolean hasQueryConfig() { + return configCase_ == 2; + } + /** + * + * + *
+       * Query job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + * + * @return The queryConfig. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query getQueryConfig() { + if (queryConfigBuilder_ == null) { + if (configCase_ == 2) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); + } else { + if (configCase_ == 2) { + return queryConfigBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); + } + } + /** + * + * + *
+       * Query job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + */ + public Builder setQueryConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query value) { + if (queryConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + queryConfigBuilder_.setMessage(value); + } + configCase_ = 2; + return this; + } + /** + * + * + *
+       * Query job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + */ + public Builder setQueryConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder builderForValue) { + if (queryConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + queryConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 2; + return this; + } + /** + * + * + *
+       * Query job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + */ + public Builder mergeQueryConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query value) { + if (queryConfigBuilder_ == null) { + if (configCase_ == 2 + && config_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query + .getDefaultInstance()) { + config_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 2) { + queryConfigBuilder_.mergeFrom(value); + } + queryConfigBuilder_.setMessage(value); + } + configCase_ = 2; + return this; + } + /** + * + * + *
+       * Query job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + */ + public Builder clearQueryConfig() { + if (queryConfigBuilder_ == null) { + if (configCase_ == 2) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 2) { + configCase_ = 0; + config_ = null; + } + queryConfigBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * Query job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder + getQueryConfigBuilder() { + return getQueryConfigFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Query job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder + getQueryConfigOrBuilder() { + if ((configCase_ == 2) && (queryConfigBuilder_ != null)) { + return queryConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 2) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); + } + } + /** + * + * + *
+       * Query job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder> + getQueryConfigFieldBuilder() { + if (queryConfigBuilder_ == null) { + if (!(configCase_ == 2)) { + config_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); + } + queryConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 2; + onChanged(); + ; + return queryConfigBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder> + loadConfigBuilder_; + /** + * + * + *
+       * Load job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + * + * @return Whether the loadConfig field is set. + */ + @java.lang.Override + public boolean hasLoadConfig() { + return configCase_ == 3; + } + /** + * + * + *
+       * Load job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + * + * @return The loadConfig. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load getLoadConfig() { + if (loadConfigBuilder_ == null) { + if (configCase_ == 3) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); + } else { + if (configCase_ == 3) { + return loadConfigBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); + } + } + /** + * + * + *
+       * Load job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + */ + public Builder setLoadConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load value) { + if (loadConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + loadConfigBuilder_.setMessage(value); + } + configCase_ = 3; + return this; + } + /** + * + * + *
+       * Load job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + */ + public Builder setLoadConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder builderForValue) { + if (loadConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + loadConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 3; + return this; + } + /** + * + * + *
+       * Load job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + */ + public Builder mergeLoadConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load value) { + if (loadConfigBuilder_ == null) { + if (configCase_ == 3 + && config_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load + .getDefaultInstance()) { + config_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 3) { + loadConfigBuilder_.mergeFrom(value); + } + loadConfigBuilder_.setMessage(value); + } + configCase_ = 3; + return this; + } + /** + * + * + *
+       * Load job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + */ + public Builder clearLoadConfig() { + if (loadConfigBuilder_ == null) { + if (configCase_ == 3) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 3) { + configCase_ = 0; + config_ = null; + } + loadConfigBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * Load job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder + getLoadConfigBuilder() { + return getLoadConfigFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Load job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder + getLoadConfigOrBuilder() { + if ((configCase_ == 3) && (loadConfigBuilder_ != null)) { + return loadConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 3) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); + } + } + /** + * + * + *
+       * Load job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder> + getLoadConfigFieldBuilder() { + if (loadConfigBuilder_ == null) { + if (!(configCase_ == 3)) { + config_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); + } + loadConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 3; + onChanged(); + ; + return loadConfigBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder> + extractConfigBuilder_; + /** + * + * + *
+       * Extract job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + * + * @return Whether the extractConfig field is set. + */ + @java.lang.Override + public boolean hasExtractConfig() { + return configCase_ == 4; + } + /** + * + * + *
+       * Extract job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + * + * @return The extractConfig. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract getExtractConfig() { + if (extractConfigBuilder_ == null) { + if (configCase_ == 4) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + .getDefaultInstance(); + } else { + if (configCase_ == 4) { + return extractConfigBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + .getDefaultInstance(); + } + } + /** + * + * + *
+       * Extract job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + */ + public Builder setExtractConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract value) { + if (extractConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + extractConfigBuilder_.setMessage(value); + } + configCase_ = 4; + return this; + } + /** + * + * + *
+       * Extract job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + */ + public Builder setExtractConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder builderForValue) { + if (extractConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + extractConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 4; + return this; + } + /** + * + * + *
+       * Extract job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + */ + public Builder mergeExtractConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract value) { + if (extractConfigBuilder_ == null) { + if (configCase_ == 4 + && config_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + .getDefaultInstance()) { + config_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 4) { + extractConfigBuilder_.mergeFrom(value); + } + extractConfigBuilder_.setMessage(value); + } + configCase_ = 4; + return this; + } + /** + * + * + *
+       * Extract job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + */ + public Builder clearExtractConfig() { + if (extractConfigBuilder_ == null) { + if (configCase_ == 4) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 4) { + configCase_ = 0; + config_ = null; + } + extractConfigBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * Extract job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder + getExtractConfigBuilder() { + return getExtractConfigFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Extract job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder + getExtractConfigOrBuilder() { + if ((configCase_ == 4) && (extractConfigBuilder_ != null)) { + return extractConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 4) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract + .getDefaultInstance(); + } + } + /** + * + * + *
+       * Extract job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder> + getExtractConfigFieldBuilder() { + if (extractConfigBuilder_ == null) { + if (!(configCase_ == 4)) { + config_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.getDefaultInstance(); + } + extractConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 4; + onChanged(); + ; + return extractConfigBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder> + tableCopyConfigBuilder_; + /** + * + * + *
+       * TableCopy job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + * + * @return Whether the tableCopyConfig field is set. + */ + @java.lang.Override + public boolean hasTableCopyConfig() { + return configCase_ == 5; + } + /** + * + * + *
+       * TableCopy job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + * + * @return The tableCopyConfig. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy getTableCopyConfig() { + if (tableCopyConfigBuilder_ == null) { + if (configCase_ == 5) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + .getDefaultInstance(); + } else { + if (configCase_ == 5) { + return tableCopyConfigBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + .getDefaultInstance(); + } + } + /** + * + * + *
+       * TableCopy job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + */ + public Builder setTableCopyConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy value) { + if (tableCopyConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + config_ = value; + onChanged(); + } else { + tableCopyConfigBuilder_.setMessage(value); + } + configCase_ = 5; + return this; + } + /** + * + * + *
+       * TableCopy job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + */ + public Builder setTableCopyConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder + builderForValue) { + if (tableCopyConfigBuilder_ == null) { + config_ = builderForValue.build(); + onChanged(); + } else { + tableCopyConfigBuilder_.setMessage(builderForValue.build()); + } + configCase_ = 5; + return this; + } + /** + * + * + *
+       * TableCopy job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + */ + public Builder mergeTableCopyConfig( + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy value) { + if (tableCopyConfigBuilder_ == null) { + if (configCase_ == 5 + && config_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + .getDefaultInstance()) { + config_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_) + .mergeFrom(value) + .buildPartial(); + } else { + config_ = value; + } + onChanged(); + } else { + if (configCase_ == 5) { + tableCopyConfigBuilder_.mergeFrom(value); + } + tableCopyConfigBuilder_.setMessage(value); + } + configCase_ = 5; + return this; + } + /** + * + * + *
+       * TableCopy job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + */ + public Builder clearTableCopyConfig() { + if (tableCopyConfigBuilder_ == null) { + if (configCase_ == 5) { + configCase_ = 0; + config_ = null; + onChanged(); + } + } else { + if (configCase_ == 5) { + configCase_ = 0; + config_ = null; + } + tableCopyConfigBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * TableCopy job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder + getTableCopyConfigBuilder() { + return getTableCopyConfigFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * TableCopy job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder + getTableCopyConfigOrBuilder() { + if ((configCase_ == 5) && (tableCopyConfigBuilder_ != null)) { + return tableCopyConfigBuilder_.getMessageOrBuilder(); + } else { + if (configCase_ == 5) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + .getDefaultInstance(); + } + } + /** + * + * + *
+       * TableCopy job information.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder> + getTableCopyConfigFieldBuilder() { + if (tableCopyConfigBuilder_ == null) { + if (!(configCase_ == 5)) { + config_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy + .getDefaultInstance(); + } + tableCopyConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_, + getParentForChildren(), + isClean()); + config_ = null; + } + configCase_ = 5; + onChanged(); + ; + return tableCopyConfigBuilder_; + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + private com.google.protobuf.MapField + internalGetMutableLabels() { + onChanged(); + ; + if (labels_ == null) { + labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); + } + if (!labels_.isMutable()) { + labels_ = labels_.copy(); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + /** + * + * + *
+       * Labels provided for the job.
+       * 
+ * + * map<string, string> labels = 6; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + return internalGetLabels().getMap().containsKey(key); + } + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + /** + * + * + *
+       * Labels provided for the job.
+       * 
+ * + * map<string, string> labels = 6; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + /** + * + * + *
+       * Labels provided for the job.
+       * 
+ * + * map<string, string> labels = 6; + */ + @java.lang.Override + public java.lang.String getLabelsOrDefault( + java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+       * Labels provided for the job.
+       * 
+ * + * map<string, string> labels = 6; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearLabels() { + internalGetMutableLabels().getMutableMap().clear(); + return this; + } + /** + * + * + *
+       * Labels provided for the job.
+       * 
+ * + * map<string, string> labels = 6; + */ + public Builder removeLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + internalGetMutableLabels().getMutableMap().remove(key); + return this; + } + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableLabels() { + return internalGetMutableLabels().getMutableMap(); + } + /** + * + * + *
+       * Labels provided for the job.
+       * 
+ * + * map<string, string> labels = 6; + */ + public Builder putLabels(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + if (value == null) { + throw new java.lang.NullPointerException(); + } + internalGetMutableLabels().getMutableMap().put(key, value); + return this; + } + /** + * + * + *
+       * Labels provided for the job.
+       * 
+ * + * map<string, string> labels = 6; + */ + public Builder putAllLabels(java.util.Map values) { + internalGetMutableLabels().getMutableMap().putAll(values); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public JobConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new JobConfig(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface TableDefinitionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableDefinition) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Name of the table, used in queries.
+     * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+     * Name of the table, used in queries.
+     * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+     * URIs for the data.
+     * 
+ * + * repeated string source_uris = 2; + * + * @return A list containing the sourceUris. + */ + java.util.List getSourceUrisList(); + /** + * + * + *
+     * URIs for the data.
+     * 
+ * + * repeated string source_uris = 2; + * + * @return The count of sourceUris. + */ + int getSourceUrisCount(); + /** + * + * + *
+     * URIs for the data.
+     * 
+ * + * repeated string source_uris = 2; + * + * @param index The index of the element to return. + * @return The sourceUris at the given index. + */ + java.lang.String getSourceUris(int index); + /** + * + * + *
+     * URIs for the data.
+     * 
+ * + * repeated string source_uris = 2; + * + * @param index The index of the value to return. + * @return The bytes of the sourceUris at the given index. + */ + com.google.protobuf.ByteString getSourceUrisBytes(int index); + } + /** + * + * + *
+   * Definition of an external data source used in a query.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDefinition} + */ + public static final class TableDefinition extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableDefinition) + TableDefinitionOrBuilder { + private static final long serialVersionUID = 0L; + // Use TableDefinition.newBuilder() to construct. + private TableDefinition(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private TableDefinition() { + name_ = ""; + sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TableDefinition(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private TableDefinition( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + sourceUris_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + sourceUris_.add(s); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + sourceUris_ = sourceUris_.getUnmodifiableView(); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+     * Name of the table, used in queries.
+     * 
+ * + * string name = 1; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+     * Name of the table, used in queries.
+     * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SOURCE_URIS_FIELD_NUMBER = 2; + private com.google.protobuf.LazyStringList sourceUris_; + /** + * + * + *
+     * URIs for the data.
+     * 
+ * + * repeated string source_uris = 2; + * + * @return A list containing the sourceUris. + */ + public com.google.protobuf.ProtocolStringList getSourceUrisList() { + return sourceUris_; + } + /** + * + * + *
+     * URIs for the data.
+     * 
+ * + * repeated string source_uris = 2; + * + * @return The count of sourceUris. + */ + public int getSourceUrisCount() { + return sourceUris_.size(); + } + /** + * + * + *
+     * URIs for the data.
+     * 
+ * + * repeated string source_uris = 2; + * + * @param index The index of the element to return. + * @return The sourceUris at the given index. + */ + public java.lang.String getSourceUris(int index) { + return sourceUris_.get(index); + } + /** + * + * + *
+     * URIs for the data.
+     * 
+ * + * repeated string source_uris = 2; + * + * @param index The index of the value to return. + * @return The bytes of the sourceUris at the given index. + */ + public com.google.protobuf.ByteString getSourceUrisBytes(int index) { + return sourceUris_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + for (int i = 0; i < sourceUris_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, sourceUris_.getRaw(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + { + int dataSize = 0; + for (int i = 0; i < sourceUris_.size(); i++) { + dataSize += computeStringSizeNoTag(sourceUris_.getRaw(i)); + } + size += dataSize; + size += 1 * getSourceUrisList().size(); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition other = + (com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition) obj; + + if (!getName().equals(other.getName())) return false; + if (!getSourceUrisList().equals(other.getSourceUrisList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + if (getSourceUrisCount() > 0) { + hash = (37 * hash) + SOURCE_URIS_FIELD_NUMBER; + hash = (53 * hash) + getSourceUrisList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Definition of an external data source used in a query.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDefinition} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableDefinition) + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition build() { + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition result = + new com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition(this); + int from_bitField0_ = bitField0_; + result.name_ = name_; + if (((bitField0_ & 0x00000001) != 0)) { + sourceUris_ = sourceUris_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.sourceUris_ = sourceUris_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (!other.sourceUris_.isEmpty()) { + if (sourceUris_.isEmpty()) { + sourceUris_ = other.sourceUris_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureSourceUrisIsMutable(); + sourceUris_.addAll(other.sourceUris_); + } + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + /** + * + * + *
+       * Name of the table, used in queries.
+       * 
+ * + * string name = 1; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * Name of the table, used in queries.
+       * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * Name of the table, used in queries.
+       * 
+ * + * string name = 1; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Name of the table, used in queries.
+       * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+       * Name of the table, used in queries.
+       * 
+ * + * string name = 1; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringList sourceUris_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureSourceUrisIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + sourceUris_ = new com.google.protobuf.LazyStringArrayList(sourceUris_); + bitField0_ |= 0x00000001; + } + } + /** + * + * + *
+       * URIs for the data.
+       * 
+ * + * repeated string source_uris = 2; + * + * @return A list containing the sourceUris. + */ + public com.google.protobuf.ProtocolStringList getSourceUrisList() { + return sourceUris_.getUnmodifiableView(); + } + /** + * + * + *
+       * URIs for the data.
+       * 
+ * + * repeated string source_uris = 2; + * + * @return The count of sourceUris. + */ + public int getSourceUrisCount() { + return sourceUris_.size(); + } + /** + * + * + *
+       * URIs for the data.
+       * 
+ * + * repeated string source_uris = 2; + * + * @param index The index of the element to return. + * @return The sourceUris at the given index. + */ + public java.lang.String getSourceUris(int index) { + return sourceUris_.get(index); + } + /** + * + * + *
+       * URIs for the data.
+       * 
+ * + * repeated string source_uris = 2; + * + * @param index The index of the value to return. + * @return The bytes of the sourceUris at the given index. + */ + public com.google.protobuf.ByteString getSourceUrisBytes(int index) { + return sourceUris_.getByteString(index); + } + /** + * + * + *
+       * URIs for the data.
+       * 
+ * + * repeated string source_uris = 2; + * + * @param index The index to set the value at. + * @param value The sourceUris to set. + * @return This builder for chaining. + */ + public Builder setSourceUris(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSourceUrisIsMutable(); + sourceUris_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+       * URIs for the data.
+       * 
+ * + * repeated string source_uris = 2; + * + * @param value The sourceUris to add. + * @return This builder for chaining. + */ + public Builder addSourceUris(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSourceUrisIsMutable(); + sourceUris_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+       * URIs for the data.
+       * 
+ * + * repeated string source_uris = 2; + * + * @param values The sourceUris to add. + * @return This builder for chaining. + */ + public Builder addAllSourceUris(java.lang.Iterable values) { + ensureSourceUrisIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, sourceUris_); + onChanged(); + return this; + } + /** + * + * + *
+       * URIs for the data.
+       * 
+ * + * repeated string source_uris = 2; + * + * @return This builder for chaining. + */ + public Builder clearSourceUris() { + sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+       * URIs for the data.
+       * 
+ * + * repeated string source_uris = 2; + * + * @param value The bytes of the sourceUris to add. + * @return This builder for chaining. + */ + public Builder addSourceUrisBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureSourceUrisIsMutable(); + sourceUris_.add(value); + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableDefinition) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableDefinition) + private static final com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public TableDefinition parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new TableDefinition(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface JobStatusOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStatus) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * State of the job.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; + * + * @return The enum numeric value on the wire for jobState. + */ + int getJobStateValue(); + /** + * + * + *
+     * State of the job.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; + * + * @return The jobState. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobState getJobState(); + + /** + * + * + *
+     * Job error, if the job failed.
+     * 
+ * + * .google.rpc.Status error_result = 2; + * + * @return Whether the errorResult field is set. + */ + boolean hasErrorResult(); + /** + * + * + *
+     * Job error, if the job failed.
+     * 
+ * + * .google.rpc.Status error_result = 2; + * + * @return The errorResult. + */ + com.google.rpc.Status getErrorResult(); + /** + * + * + *
+     * Job error, if the job failed.
+     * 
+ * + * .google.rpc.Status error_result = 2; + */ + com.google.rpc.StatusOrBuilder getErrorResultOrBuilder(); + + /** + * + * + *
+     * Errors encountered during the running of the job. Does not necessarily
+     * mean that the job has completed or was unsuccessful.
+     * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + java.util.List getErrorsList(); + /** + * + * + *
+     * Errors encountered during the running of the job. Does not necessarily
+     * mean that the job has completed or was unsuccessful.
+     * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + com.google.rpc.Status getErrors(int index); + /** + * + * + *
+     * Errors encountered during the running of the job. Does not necessarily
+     * mean that the job has completed or was unsuccessful.
+     * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + int getErrorsCount(); + /** + * + * + *
+     * Errors encountered during the running of the job. Does not necessarily
+     * mean that the job has completed or was unsuccessful.
+     * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + java.util.List getErrorsOrBuilderList(); + /** + * + * + *
+     * Errors encountered during the running of the job. Does not necessarily
+     * mean that the job has completed or was unsuccessful.
+     * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + com.google.rpc.StatusOrBuilder getErrorsOrBuilder(int index); + } + /** + * + * + *
+   * Status of a job.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStatus} + */ + public static final class JobStatus extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStatus) + JobStatusOrBuilder { + private static final long serialVersionUID = 0L; + // Use JobStatus.newBuilder() to construct. + private JobStatus(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private JobStatus() { + jobState_ = 0; + errors_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new JobStatus(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private JobStatus( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + jobState_ = rawValue; + break; + } + case 18: + { + com.google.rpc.Status.Builder subBuilder = null; + if (errorResult_ != null) { + subBuilder = errorResult_.toBuilder(); + } + errorResult_ = input.readMessage(com.google.rpc.Status.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(errorResult_); + errorResult_ = subBuilder.buildPartial(); + } + + break; + } + case 26: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + errors_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + errors_.add(input.readMessage(com.google.rpc.Status.parser(), extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + errors_ = java.util.Collections.unmodifiableList(errors_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder.class); + } + + public static final int JOB_STATE_FIELD_NUMBER = 1; + private int jobState_; + /** + * + * + *
+     * State of the job.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; + * + * @return The enum numeric value on the wire for jobState. + */ + @java.lang.Override + public int getJobStateValue() { + return jobState_; + } + /** + * + * + *
+     * State of the job.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; + * + * @return The jobState. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobState getJobState() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobState result = + com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(jobState_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED + : result; + } + + public static final int ERROR_RESULT_FIELD_NUMBER = 2; + private com.google.rpc.Status errorResult_; + /** + * + * + *
+     * Job error, if the job failed.
+     * 
+ * + * .google.rpc.Status error_result = 2; + * + * @return Whether the errorResult field is set. + */ + @java.lang.Override + public boolean hasErrorResult() { + return errorResult_ != null; + } + /** + * + * + *
+     * Job error, if the job failed.
+     * 
+ * + * .google.rpc.Status error_result = 2; + * + * @return The errorResult. + */ + @java.lang.Override + public com.google.rpc.Status getErrorResult() { + return errorResult_ == null ? com.google.rpc.Status.getDefaultInstance() : errorResult_; + } + /** + * + * + *
+     * Job error, if the job failed.
+     * 
+ * + * .google.rpc.Status error_result = 2; + */ + @java.lang.Override + public com.google.rpc.StatusOrBuilder getErrorResultOrBuilder() { + return getErrorResult(); + } + + public static final int ERRORS_FIELD_NUMBER = 3; + private java.util.List errors_; + /** + * + * + *
+     * Errors encountered during the running of the job. Does not necessarily
+     * mean that the job has completed or was unsuccessful.
+     * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + @java.lang.Override + public java.util.List getErrorsList() { + return errors_; + } + /** + * + * + *
+     * Errors encountered during the running of the job. Does not necessarily
+     * mean that the job has completed or was unsuccessful.
+     * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + @java.lang.Override + public java.util.List getErrorsOrBuilderList() { + return errors_; + } + /** + * + * + *
+     * Errors encountered during the running of the job. Does not necessarily
+     * mean that the job has completed or was unsuccessful.
+     * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + @java.lang.Override + public int getErrorsCount() { + return errors_.size(); + } + /** + * + * + *
+     * Errors encountered during the running of the job. Does not necessarily
+     * mean that the job has completed or was unsuccessful.
+     * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + @java.lang.Override + public com.google.rpc.Status getErrors(int index) { + return errors_.get(index); + } + /** + * + * + *
+     * Errors encountered during the running of the job. Does not necessarily
+     * mean that the job has completed or was unsuccessful.
+     * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + @java.lang.Override + public com.google.rpc.StatusOrBuilder getErrorsOrBuilder(int index) { + return errors_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (jobState_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, jobState_); + } + if (errorResult_ != null) { + output.writeMessage(2, getErrorResult()); + } + for (int i = 0; i < errors_.size(); i++) { + output.writeMessage(3, errors_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (jobState_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, jobState_); + } + if (errorResult_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getErrorResult()); + } + for (int i = 0; i < errors_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, errors_.get(i)); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStatus)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStatus) obj; + + if (jobState_ != other.jobState_) return false; + if (hasErrorResult() != other.hasErrorResult()) return false; + if (hasErrorResult()) { + if (!getErrorResult().equals(other.getErrorResult())) return false; + } + if (!getErrorsList().equals(other.getErrorsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + JOB_STATE_FIELD_NUMBER; + hash = (53 * hash) + jobState_; + if (hasErrorResult()) { + hash = (37 * hash) + ERROR_RESULT_FIELD_NUMBER; + hash = (53 * hash) + getErrorResult().hashCode(); + } + if (getErrorsCount() > 0) { + hash = (37 * hash) + ERRORS_FIELD_NUMBER; + hash = (53 * hash) + getErrorsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Status of a job.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStatus} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStatus) + com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getErrorsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + jobState_ = 0; + + if (errorResultBuilder_ == null) { + errorResult_ = null; + } else { + errorResult_ = null; + errorResultBuilder_ = null; + } + if (errorsBuilder_ == null) { + errors_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + errorsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobStatus(this); + int from_bitField0_ = bitField0_; + result.jobState_ = jobState_; + if (errorResultBuilder_ == null) { + result.errorResult_ = errorResult_; + } else { + result.errorResult_ = errorResultBuilder_.build(); + } + if (errorsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + errors_ = java.util.Collections.unmodifiableList(errors_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.errors_ = errors_; + } else { + result.errors_ = errorsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStatus) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobStatus) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobStatus other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.getDefaultInstance()) + return this; + if (other.jobState_ != 0) { + setJobStateValue(other.getJobStateValue()); + } + if (other.hasErrorResult()) { + mergeErrorResult(other.getErrorResult()); + } + if (errorsBuilder_ == null) { + if (!other.errors_.isEmpty()) { + if (errors_.isEmpty()) { + errors_ = other.errors_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureErrorsIsMutable(); + errors_.addAll(other.errors_); + } + onChanged(); + } + } else { + if (!other.errors_.isEmpty()) { + if (errorsBuilder_.isEmpty()) { + errorsBuilder_.dispose(); + errorsBuilder_ = null; + errors_ = other.errors_; + bitField0_ = (bitField0_ & ~0x00000001); + errorsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getErrorsFieldBuilder() + : null; + } else { + errorsBuilder_.addAllMessages(other.errors_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStatus) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private int jobState_ = 0; + /** + * + * + *
+       * State of the job.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; + * + * @return The enum numeric value on the wire for jobState. + */ + @java.lang.Override + public int getJobStateValue() { + return jobState_; + } + /** + * + * + *
+       * State of the job.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; + * + * @param value The enum numeric value on the wire for jobState to set. + * @return This builder for chaining. + */ + public Builder setJobStateValue(int value) { + + jobState_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * State of the job.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; + * + * @return The jobState. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobState getJobState() { + @SuppressWarnings("deprecation") + com.google.cloud.audit.BigQueryAuditMetadata.JobState result = + com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(jobState_); + return result == null + ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED + : result; + } + /** + * + * + *
+       * State of the job.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; + * + * @param value The jobState to set. + * @return This builder for chaining. + */ + public Builder setJobState(com.google.cloud.audit.BigQueryAuditMetadata.JobState value) { + if (value == null) { + throw new NullPointerException(); + } + + jobState_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+       * State of the job.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; + * + * @return This builder for chaining. + */ + public Builder clearJobState() { + + jobState_ = 0; + onChanged(); + return this; + } + + private com.google.rpc.Status errorResult_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> + errorResultBuilder_; + /** + * + * + *
+       * Job error, if the job failed.
+       * 
+ * + * .google.rpc.Status error_result = 2; + * + * @return Whether the errorResult field is set. + */ + public boolean hasErrorResult() { + return errorResultBuilder_ != null || errorResult_ != null; + } + /** + * + * + *
+       * Job error, if the job failed.
+       * 
+ * + * .google.rpc.Status error_result = 2; + * + * @return The errorResult. + */ + public com.google.rpc.Status getErrorResult() { + if (errorResultBuilder_ == null) { + return errorResult_ == null ? com.google.rpc.Status.getDefaultInstance() : errorResult_; + } else { + return errorResultBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Job error, if the job failed.
+       * 
+ * + * .google.rpc.Status error_result = 2; + */ + public Builder setErrorResult(com.google.rpc.Status value) { + if (errorResultBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + errorResult_ = value; + onChanged(); + } else { + errorResultBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Job error, if the job failed.
+       * 
+ * + * .google.rpc.Status error_result = 2; + */ + public Builder setErrorResult(com.google.rpc.Status.Builder builderForValue) { + if (errorResultBuilder_ == null) { + errorResult_ = builderForValue.build(); + onChanged(); + } else { + errorResultBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Job error, if the job failed.
+       * 
+ * + * .google.rpc.Status error_result = 2; + */ + public Builder mergeErrorResult(com.google.rpc.Status value) { + if (errorResultBuilder_ == null) { + if (errorResult_ != null) { + errorResult_ = + com.google.rpc.Status.newBuilder(errorResult_).mergeFrom(value).buildPartial(); + } else { + errorResult_ = value; + } + onChanged(); + } else { + errorResultBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Job error, if the job failed.
+       * 
+ * + * .google.rpc.Status error_result = 2; + */ + public Builder clearErrorResult() { + if (errorResultBuilder_ == null) { + errorResult_ = null; + onChanged(); + } else { + errorResult_ = null; + errorResultBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Job error, if the job failed.
+       * 
+ * + * .google.rpc.Status error_result = 2; + */ + public com.google.rpc.Status.Builder getErrorResultBuilder() { + + onChanged(); + return getErrorResultFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Job error, if the job failed.
+       * 
+ * + * .google.rpc.Status error_result = 2; + */ + public com.google.rpc.StatusOrBuilder getErrorResultOrBuilder() { + if (errorResultBuilder_ != null) { + return errorResultBuilder_.getMessageOrBuilder(); + } else { + return errorResult_ == null ? com.google.rpc.Status.getDefaultInstance() : errorResult_; + } + } + /** + * + * + *
+       * Job error, if the job failed.
+       * 
+ * + * .google.rpc.Status error_result = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> + getErrorResultFieldBuilder() { + if (errorResultBuilder_ == null) { + errorResultBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.rpc.Status, + com.google.rpc.Status.Builder, + com.google.rpc.StatusOrBuilder>( + getErrorResult(), getParentForChildren(), isClean()); + errorResult_ = null; + } + return errorResultBuilder_; + } + + private java.util.List errors_ = java.util.Collections.emptyList(); + + private void ensureErrorsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + errors_ = new java.util.ArrayList(errors_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> + errorsBuilder_; + + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public java.util.List getErrorsList() { + if (errorsBuilder_ == null) { + return java.util.Collections.unmodifiableList(errors_); + } else { + return errorsBuilder_.getMessageList(); + } + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public int getErrorsCount() { + if (errorsBuilder_ == null) { + return errors_.size(); + } else { + return errorsBuilder_.getCount(); + } + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public com.google.rpc.Status getErrors(int index) { + if (errorsBuilder_ == null) { + return errors_.get(index); + } else { + return errorsBuilder_.getMessage(index); + } + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public Builder setErrors(int index, com.google.rpc.Status value) { + if (errorsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureErrorsIsMutable(); + errors_.set(index, value); + onChanged(); + } else { + errorsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public Builder setErrors(int index, com.google.rpc.Status.Builder builderForValue) { + if (errorsBuilder_ == null) { + ensureErrorsIsMutable(); + errors_.set(index, builderForValue.build()); + onChanged(); + } else { + errorsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public Builder addErrors(com.google.rpc.Status value) { + if (errorsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureErrorsIsMutable(); + errors_.add(value); + onChanged(); + } else { + errorsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public Builder addErrors(int index, com.google.rpc.Status value) { + if (errorsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureErrorsIsMutable(); + errors_.add(index, value); + onChanged(); + } else { + errorsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public Builder addErrors(com.google.rpc.Status.Builder builderForValue) { + if (errorsBuilder_ == null) { + ensureErrorsIsMutable(); + errors_.add(builderForValue.build()); + onChanged(); + } else { + errorsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public Builder addErrors(int index, com.google.rpc.Status.Builder builderForValue) { + if (errorsBuilder_ == null) { + ensureErrorsIsMutable(); + errors_.add(index, builderForValue.build()); + onChanged(); + } else { + errorsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public Builder addAllErrors(java.lang.Iterable values) { + if (errorsBuilder_ == null) { + ensureErrorsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, errors_); + onChanged(); + } else { + errorsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public Builder clearErrors() { + if (errorsBuilder_ == null) { + errors_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + errorsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public Builder removeErrors(int index) { + if (errorsBuilder_ == null) { + ensureErrorsIsMutable(); + errors_.remove(index); + onChanged(); + } else { + errorsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public com.google.rpc.Status.Builder getErrorsBuilder(int index) { + return getErrorsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public com.google.rpc.StatusOrBuilder getErrorsOrBuilder(int index) { + if (errorsBuilder_ == null) { + return errors_.get(index); + } else { + return errorsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public java.util.List getErrorsOrBuilderList() { + if (errorsBuilder_ != null) { + return errorsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(errors_); + } + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public com.google.rpc.Status.Builder addErrorsBuilder() { + return getErrorsFieldBuilder().addBuilder(com.google.rpc.Status.getDefaultInstance()); + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public com.google.rpc.Status.Builder addErrorsBuilder(int index) { + return getErrorsFieldBuilder() + .addBuilder(index, com.google.rpc.Status.getDefaultInstance()); + } + /** + * + * + *
+       * Errors encountered during the running of the job. Does not necessarily
+       * mean that the job has completed or was unsuccessful.
+       * 
+ * + * repeated .google.rpc.Status errors = 3; + */ + public java.util.List getErrorsBuilderList() { + return getErrorsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> + getErrorsFieldBuilder() { + if (errorsBuilder_ == null) { + errorsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.rpc.Status, + com.google.rpc.Status.Builder, + com.google.rpc.StatusOrBuilder>( + errors_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + errors_ = null; + } + return errorsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStatus) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStatus) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStatus DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobStatus(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public JobStatus parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new JobStatus(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface JobStatsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStats) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Job creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 1; + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+     * Job creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 1; + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+     * Job creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 1; + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+     * Job execution start time.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return Whether the startTime field is set. + */ + boolean hasStartTime(); + /** + * + * + *
+     * Job execution start time.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return The startTime. + */ + com.google.protobuf.Timestamp getStartTime(); + /** + * + * + *
+     * Job execution start time.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder(); + + /** + * + * + *
+     * Job completion time.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return Whether the endTime field is set. + */ + boolean hasEndTime(); + /** + * + * + *
+     * Job completion time.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return The endTime. + */ + com.google.protobuf.Timestamp getEndTime(); + /** + * + * + *
+     * Job completion time.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); + + /** + * + * + *
+     * Query job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + * + * @return Whether the queryStats field is set. + */ + boolean hasQueryStats(); + /** + * + * + *
+     * Query job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + * + * @return The queryStats. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query getQueryStats(); + /** + * + * + *
+     * Query job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder getQueryStatsOrBuilder(); + + /** + * + * + *
+     * Load job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + * + * @return Whether the loadStats field is set. + */ + boolean hasLoadStats(); + /** + * + * + *
+     * Load job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + * + * @return The loadStats. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load getLoadStats(); + /** + * + * + *
+     * Load job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder getLoadStatsOrBuilder(); + + /** + * + * + *
+     * Extract job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + * + * @return Whether the extractStats field is set. + */ + boolean hasExtractStats(); + /** + * + * + *
+     * Extract job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + * + * @return The extractStats. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract getExtractStats(); + /** + * + * + *
+     * Extract job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder + getExtractStatsOrBuilder(); + + /** + * + * + *
+     * The total number of slot-ms consumed by the query job.
+     * 
+ * + * int64 total_slot_ms = 10; + * + * @return The totalSlotMs. + */ + long getTotalSlotMs(); + + /** + * + * + *
+     * Reservation usage attributed from each tier of a reservation hierarchy.
+     * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + java.util.List + getReservationUsageList(); + /** + * + * + *
+     * Reservation usage attributed from each tier of a reservation hierarchy.
+     * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + getReservationUsage(int index); + /** + * + * + *
+     * Reservation usage attributed from each tier of a reservation hierarchy.
+     * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + int getReservationUsageCount(); + /** + * + * + *
+     * Reservation usage attributed from each tier of a reservation hierarchy.
+     * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + java.util.List< + ? extends + com.google.cloud.audit.BigQueryAuditMetadata.JobStats + .ReservationResourceUsageOrBuilder> + getReservationUsageOrBuilderList(); + /** + * + * + *
+     * Reservation usage attributed from each tier of a reservation hierarchy.
+     * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsageOrBuilder + getReservationUsageOrBuilder(int index); + + /** + * + * + *
+     * Parent job name. Only present for child jobs.
+     * 
+ * + * string parent_job_name = 12; + * + * @return The parentJobName. + */ + java.lang.String getParentJobName(); + /** + * + * + *
+     * Parent job name. Only present for child jobs.
+     * 
+ * + * string parent_job_name = 12; + * + * @return The bytes for parentJobName. + */ + com.google.protobuf.ByteString getParentJobNameBytes(); + + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtendedCase getExtendedCase(); + } + /** + * + * + *
+   * Job statistics.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats} + */ + public static final class JobStats extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats) + JobStatsOrBuilder { + private static final long serialVersionUID = 0L; + // Use JobStats.newBuilder() to construct. + private JobStats(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private JobStats() { + reservationUsage_ = java.util.Collections.emptyList(); + parentJobName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new JobStats(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private JobStats( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (createTime_ != null) { + subBuilder = createTime_.toBuilder(); + } + createTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(createTime_); + createTime_ = subBuilder.buildPartial(); + } + + break; + } + case 18: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (startTime_ != null) { + subBuilder = startTime_.toBuilder(); + } + startTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(startTime_); + startTime_ = subBuilder.buildPartial(); + } + + break; + } + case 26: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (endTime_ != null) { + subBuilder = endTime_.toBuilder(); + } + endTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(endTime_); + endTime_ = subBuilder.buildPartial(); + } + + break; + } + case 66: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder subBuilder = + null; + if (extendedCase_ == 8) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_) + .toBuilder(); + } + extended_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_); + extended_ = subBuilder.buildPartial(); + } + extendedCase_ = 8; + break; + } + case 74: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder subBuilder = + null; + if (extendedCase_ == 9) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_) + .toBuilder(); + } + extended_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_); + extended_ = subBuilder.buildPartial(); + } + extendedCase_ = 9; + break; + } + case 80: + { + totalSlotMs_ = input.readInt64(); + break; + } + case 90: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + reservationUsage_ = + new java.util.ArrayList< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats + .ReservationResourceUsage>(); + mutable_bitField0_ |= 0x00000001; + } + reservationUsage_.add( + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats + .ReservationResourceUsage.parser(), + extensionRegistry)); + break; + } + case 98: + { + java.lang.String s = input.readStringRequireUtf8(); + + parentJobName_ = s; + break; + } + case 106: + { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder subBuilder = + null; + if (extendedCase_ == 13) { + subBuilder = + ((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_) + .toBuilder(); + } + extended_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_); + extended_ = subBuilder.buildPartial(); + } + extendedCase_ = 13; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + reservationUsage_ = java.util.Collections.unmodifiableList(reservationUsage_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder.class); + } + + public interface QueryOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * Total bytes processed by the query job.
+       * 
+ * + * int64 total_processed_bytes = 1; + * + * @return The totalProcessedBytes. + */ + long getTotalProcessedBytes(); + + /** + * + * + *
+       * Total bytes billed by the query job.
+       * 
+ * + * int64 total_billed_bytes = 2; + * + * @return The totalBilledBytes. + */ + long getTotalBilledBytes(); + + /** + * + * + *
+       * The tier assigned by the CPU-based billing.
+       * 
+ * + * int32 billing_tier = 3; + * + * @return The billingTier. + */ + int getBillingTier(); + + /** + * + * + *
+       * Tables accessed by the query job.
+       * 
+ * + * repeated string referenced_tables = 6; + * + * @return A list containing the referencedTables. + */ + java.util.List getReferencedTablesList(); + /** + * + * + *
+       * Tables accessed by the query job.
+       * 
+ * + * repeated string referenced_tables = 6; + * + * @return The count of referencedTables. + */ + int getReferencedTablesCount(); + /** + * + * + *
+       * Tables accessed by the query job.
+       * 
+ * + * repeated string referenced_tables = 6; + * + * @param index The index of the element to return. + * @return The referencedTables at the given index. + */ + java.lang.String getReferencedTables(int index); + /** + * + * + *
+       * Tables accessed by the query job.
+       * 
+ * + * repeated string referenced_tables = 6; + * + * @param index The index of the value to return. + * @return The bytes of the referencedTables at the given index. + */ + com.google.protobuf.ByteString getReferencedTablesBytes(int index); + + /** + * + * + *
+       * Views accessed by the query job.
+       * 
+ * + * repeated string referenced_views = 7; + * + * @return A list containing the referencedViews. + */ + java.util.List getReferencedViewsList(); + /** + * + * + *
+       * Views accessed by the query job.
+       * 
+ * + * repeated string referenced_views = 7; + * + * @return The count of referencedViews. + */ + int getReferencedViewsCount(); + /** + * + * + *
+       * Views accessed by the query job.
+       * 
+ * + * repeated string referenced_views = 7; + * + * @param index The index of the element to return. + * @return The referencedViews at the given index. + */ + java.lang.String getReferencedViews(int index); + /** + * + * + *
+       * Views accessed by the query job.
+       * 
+ * + * repeated string referenced_views = 7; + * + * @param index The index of the value to return. + * @return The bytes of the referencedViews at the given index. + */ + com.google.protobuf.ByteString getReferencedViewsBytes(int index); + + /** + * + * + *
+       * Routines accessed by the query job.
+       * 
+ * + * repeated string referenced_routines = 10; + * + * @return A list containing the referencedRoutines. + */ + java.util.List getReferencedRoutinesList(); + /** + * + * + *
+       * Routines accessed by the query job.
+       * 
+ * + * repeated string referenced_routines = 10; + * + * @return The count of referencedRoutines. + */ + int getReferencedRoutinesCount(); + /** + * + * + *
+       * Routines accessed by the query job.
+       * 
+ * + * repeated string referenced_routines = 10; + * + * @param index The index of the element to return. + * @return The referencedRoutines at the given index. + */ + java.lang.String getReferencedRoutines(int index); + /** + * + * + *
+       * Routines accessed by the query job.
+       * 
+ * + * repeated string referenced_routines = 10; + * + * @param index The index of the value to return. + * @return The bytes of the referencedRoutines at the given index. + */ + com.google.protobuf.ByteString getReferencedRoutinesBytes(int index); + + /** + * + * + *
+       * Number of output rows produced by the query job.
+       * 
+ * + * int64 output_row_count = 8; + * + * @return The outputRowCount. + */ + long getOutputRowCount(); + + /** + * + * + *
+       * True if the query job results were read from the query cache.
+       * 
+ * + * bool cache_hit = 9; + * + * @return The cacheHit. + */ + boolean getCacheHit(); + } + /** + * + * + *
+     * Query job statistics.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Query} + */ + public static final class Query extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) + QueryOrBuilder { + private static final long serialVersionUID = 0L; + // Use Query.newBuilder() to construct. + private Query(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Query() { + referencedTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; + referencedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; + referencedRoutines_ = com.google.protobuf.LazyStringArrayList.EMPTY; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Query(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Query( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + totalProcessedBytes_ = input.readInt64(); + break; + } + case 16: + { + totalBilledBytes_ = input.readInt64(); + break; + } + case 24: + { + billingTier_ = input.readInt32(); + break; + } + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + referencedTables_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + referencedTables_.add(s); + break; + } + case 58: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + referencedViews_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000002; + } + referencedViews_.add(s); + break; + } + case 64: + { + outputRowCount_ = input.readInt64(); + break; + } + case 72: + { + cacheHit_ = input.readBool(); + break; + } + case 82: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000004) != 0)) { + referencedRoutines_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000004; + } + referencedRoutines_.add(s); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + referencedTables_ = referencedTables_.getUnmodifiableView(); + } + if (((mutable_bitField0_ & 0x00000002) != 0)) { + referencedViews_ = referencedViews_.getUnmodifiableView(); + } + if (((mutable_bitField0_ & 0x00000004) != 0)) { + referencedRoutines_ = referencedRoutines_.getUnmodifiableView(); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder.class); + } + + public static final int TOTAL_PROCESSED_BYTES_FIELD_NUMBER = 1; + private long totalProcessedBytes_; + /** + * + * + *
+       * Total bytes processed by the query job.
+       * 
+ * + * int64 total_processed_bytes = 1; + * + * @return The totalProcessedBytes. + */ + @java.lang.Override + public long getTotalProcessedBytes() { + return totalProcessedBytes_; + } + + public static final int TOTAL_BILLED_BYTES_FIELD_NUMBER = 2; + private long totalBilledBytes_; + /** + * + * + *
+       * Total bytes billed by the query job.
+       * 
+ * + * int64 total_billed_bytes = 2; + * + * @return The totalBilledBytes. + */ + @java.lang.Override + public long getTotalBilledBytes() { + return totalBilledBytes_; + } + + public static final int BILLING_TIER_FIELD_NUMBER = 3; + private int billingTier_; + /** + * + * + *
+       * The tier assigned by the CPU-based billing.
+       * 
+ * + * int32 billing_tier = 3; + * + * @return The billingTier. + */ + @java.lang.Override + public int getBillingTier() { + return billingTier_; + } + + public static final int REFERENCED_TABLES_FIELD_NUMBER = 6; + private com.google.protobuf.LazyStringList referencedTables_; + /** + * + * + *
+       * Tables accessed by the query job.
+       * 
+ * + * repeated string referenced_tables = 6; + * + * @return A list containing the referencedTables. + */ + public com.google.protobuf.ProtocolStringList getReferencedTablesList() { + return referencedTables_; + } + /** + * + * + *
+       * Tables accessed by the query job.
+       * 
+ * + * repeated string referenced_tables = 6; + * + * @return The count of referencedTables. + */ + public int getReferencedTablesCount() { + return referencedTables_.size(); + } + /** + * + * + *
+       * Tables accessed by the query job.
+       * 
+ * + * repeated string referenced_tables = 6; + * + * @param index The index of the element to return. + * @return The referencedTables at the given index. + */ + public java.lang.String getReferencedTables(int index) { + return referencedTables_.get(index); + } + /** + * + * + *
+       * Tables accessed by the query job.
+       * 
+ * + * repeated string referenced_tables = 6; + * + * @param index The index of the value to return. + * @return The bytes of the referencedTables at the given index. + */ + public com.google.protobuf.ByteString getReferencedTablesBytes(int index) { + return referencedTables_.getByteString(index); + } + + public static final int REFERENCED_VIEWS_FIELD_NUMBER = 7; + private com.google.protobuf.LazyStringList referencedViews_; + /** + * + * + *
+       * Views accessed by the query job.
+       * 
+ * + * repeated string referenced_views = 7; + * + * @return A list containing the referencedViews. + */ + public com.google.protobuf.ProtocolStringList getReferencedViewsList() { + return referencedViews_; + } + /** + * + * + *
+       * Views accessed by the query job.
+       * 
+ * + * repeated string referenced_views = 7; + * + * @return The count of referencedViews. + */ + public int getReferencedViewsCount() { + return referencedViews_.size(); + } + /** + * + * + *
+       * Views accessed by the query job.
+       * 
+ * + * repeated string referenced_views = 7; + * + * @param index The index of the element to return. + * @return The referencedViews at the given index. + */ + public java.lang.String getReferencedViews(int index) { + return referencedViews_.get(index); + } + /** + * + * + *
+       * Views accessed by the query job.
+       * 
+ * + * repeated string referenced_views = 7; + * + * @param index The index of the value to return. + * @return The bytes of the referencedViews at the given index. + */ + public com.google.protobuf.ByteString getReferencedViewsBytes(int index) { + return referencedViews_.getByteString(index); + } + + public static final int REFERENCED_ROUTINES_FIELD_NUMBER = 10; + private com.google.protobuf.LazyStringList referencedRoutines_; + /** + * + * + *
+       * Routines accessed by the query job.
+       * 
+ * + * repeated string referenced_routines = 10; + * + * @return A list containing the referencedRoutines. + */ + public com.google.protobuf.ProtocolStringList getReferencedRoutinesList() { + return referencedRoutines_; + } + /** + * + * + *
+       * Routines accessed by the query job.
+       * 
+ * + * repeated string referenced_routines = 10; + * + * @return The count of referencedRoutines. + */ + public int getReferencedRoutinesCount() { + return referencedRoutines_.size(); + } + /** + * + * + *
+       * Routines accessed by the query job.
+       * 
+ * + * repeated string referenced_routines = 10; + * + * @param index The index of the element to return. + * @return The referencedRoutines at the given index. + */ + public java.lang.String getReferencedRoutines(int index) { + return referencedRoutines_.get(index); + } + /** + * + * + *
+       * Routines accessed by the query job.
+       * 
+ * + * repeated string referenced_routines = 10; + * + * @param index The index of the value to return. + * @return The bytes of the referencedRoutines at the given index. + */ + public com.google.protobuf.ByteString getReferencedRoutinesBytes(int index) { + return referencedRoutines_.getByteString(index); + } + + public static final int OUTPUT_ROW_COUNT_FIELD_NUMBER = 8; + private long outputRowCount_; + /** + * + * + *
+       * Number of output rows produced by the query job.
+       * 
+ * + * int64 output_row_count = 8; + * + * @return The outputRowCount. + */ + @java.lang.Override + public long getOutputRowCount() { + return outputRowCount_; + } + + public static final int CACHE_HIT_FIELD_NUMBER = 9; + private boolean cacheHit_; + /** + * + * + *
+       * True if the query job results were read from the query cache.
+       * 
+ * + * bool cache_hit = 9; + * + * @return The cacheHit. + */ + @java.lang.Override + public boolean getCacheHit() { + return cacheHit_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (totalProcessedBytes_ != 0L) { + output.writeInt64(1, totalProcessedBytes_); + } + if (totalBilledBytes_ != 0L) { + output.writeInt64(2, totalBilledBytes_); + } + if (billingTier_ != 0) { + output.writeInt32(3, billingTier_); + } + for (int i = 0; i < referencedTables_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString( + output, 6, referencedTables_.getRaw(i)); + } + for (int i = 0; i < referencedViews_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 7, referencedViews_.getRaw(i)); + } + if (outputRowCount_ != 0L) { + output.writeInt64(8, outputRowCount_); + } + if (cacheHit_ != false) { + output.writeBool(9, cacheHit_); + } + for (int i = 0; i < referencedRoutines_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString( + output, 10, referencedRoutines_.getRaw(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (totalProcessedBytes_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, totalProcessedBytes_); + } + if (totalBilledBytes_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, totalBilledBytes_); + } + if (billingTier_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, billingTier_); + } + { + int dataSize = 0; + for (int i = 0; i < referencedTables_.size(); i++) { + dataSize += computeStringSizeNoTag(referencedTables_.getRaw(i)); + } + size += dataSize; + size += 1 * getReferencedTablesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < referencedViews_.size(); i++) { + dataSize += computeStringSizeNoTag(referencedViews_.getRaw(i)); + } + size += dataSize; + size += 1 * getReferencedViewsList().size(); + } + if (outputRowCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(8, outputRowCount_); + } + if (cacheHit_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(9, cacheHit_); + } + { + int dataSize = 0; + for (int i = 0; i < referencedRoutines_.size(); i++) { + dataSize += computeStringSizeNoTag(referencedRoutines_.getRaw(i)); + } + size += dataSize; + size += 1 * getReferencedRoutinesList().size(); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) obj; + + if (getTotalProcessedBytes() != other.getTotalProcessedBytes()) return false; + if (getTotalBilledBytes() != other.getTotalBilledBytes()) return false; + if (getBillingTier() != other.getBillingTier()) return false; + if (!getReferencedTablesList().equals(other.getReferencedTablesList())) return false; + if (!getReferencedViewsList().equals(other.getReferencedViewsList())) return false; + if (!getReferencedRoutinesList().equals(other.getReferencedRoutinesList())) return false; + if (getOutputRowCount() != other.getOutputRowCount()) return false; + if (getCacheHit() != other.getCacheHit()) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TOTAL_PROCESSED_BYTES_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalProcessedBytes()); + hash = (37 * hash) + TOTAL_BILLED_BYTES_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalBilledBytes()); + hash = (37 * hash) + BILLING_TIER_FIELD_NUMBER; + hash = (53 * hash) + getBillingTier(); + if (getReferencedTablesCount() > 0) { + hash = (37 * hash) + REFERENCED_TABLES_FIELD_NUMBER; + hash = (53 * hash) + getReferencedTablesList().hashCode(); + } + if (getReferencedViewsCount() > 0) { + hash = (37 * hash) + REFERENCED_VIEWS_FIELD_NUMBER; + hash = (53 * hash) + getReferencedViewsList().hashCode(); + } + if (getReferencedRoutinesCount() > 0) { + hash = (37 * hash) + REFERENCED_ROUTINES_FIELD_NUMBER; + hash = (53 * hash) + getReferencedRoutinesList().hashCode(); + } + hash = (37 * hash) + OUTPUT_ROW_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getOutputRowCount()); + hash = (37 * hash) + CACHE_HIT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getCacheHit()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+       * Query job statistics.
+       * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Query} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + totalProcessedBytes_ = 0L; + + totalBilledBytes_ = 0L; + + billingTier_ = 0; + + referencedTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + referencedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + referencedRoutines_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000004); + outputRowCount_ = 0L; + + cacheHit_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query(this); + int from_bitField0_ = bitField0_; + result.totalProcessedBytes_ = totalProcessedBytes_; + result.totalBilledBytes_ = totalBilledBytes_; + result.billingTier_ = billingTier_; + if (((bitField0_ & 0x00000001) != 0)) { + referencedTables_ = referencedTables_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.referencedTables_ = referencedTables_; + if (((bitField0_ & 0x00000002) != 0)) { + referencedViews_ = referencedViews_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.referencedViews_ = referencedViews_; + if (((bitField0_ & 0x00000004) != 0)) { + referencedRoutines_ = referencedRoutines_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000004); + } + result.referencedRoutines_ = referencedRoutines_; + result.outputRowCount_ = outputRowCount_; + result.cacheHit_ = cacheHit_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance()) + return this; + if (other.getTotalProcessedBytes() != 0L) { + setTotalProcessedBytes(other.getTotalProcessedBytes()); + } + if (other.getTotalBilledBytes() != 0L) { + setTotalBilledBytes(other.getTotalBilledBytes()); + } + if (other.getBillingTier() != 0) { + setBillingTier(other.getBillingTier()); + } + if (!other.referencedTables_.isEmpty()) { + if (referencedTables_.isEmpty()) { + referencedTables_ = other.referencedTables_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureReferencedTablesIsMutable(); + referencedTables_.addAll(other.referencedTables_); + } + onChanged(); + } + if (!other.referencedViews_.isEmpty()) { + if (referencedViews_.isEmpty()) { + referencedViews_ = other.referencedViews_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureReferencedViewsIsMutable(); + referencedViews_.addAll(other.referencedViews_); + } + onChanged(); + } + if (!other.referencedRoutines_.isEmpty()) { + if (referencedRoutines_.isEmpty()) { + referencedRoutines_ = other.referencedRoutines_; + bitField0_ = (bitField0_ & ~0x00000004); + } else { + ensureReferencedRoutinesIsMutable(); + referencedRoutines_.addAll(other.referencedRoutines_); + } + onChanged(); + } + if (other.getOutputRowCount() != 0L) { + setOutputRowCount(other.getOutputRowCount()); + } + if (other.getCacheHit() != false) { + setCacheHit(other.getCacheHit()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private long totalProcessedBytes_; + /** + * + * + *
+         * Total bytes processed by the query job.
+         * 
+ * + * int64 total_processed_bytes = 1; + * + * @return The totalProcessedBytes. + */ + @java.lang.Override + public long getTotalProcessedBytes() { + return totalProcessedBytes_; + } + /** + * + * + *
+         * Total bytes processed by the query job.
+         * 
+ * + * int64 total_processed_bytes = 1; + * + * @param value The totalProcessedBytes to set. + * @return This builder for chaining. + */ + public Builder setTotalProcessedBytes(long value) { + + totalProcessedBytes_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Total bytes processed by the query job.
+         * 
+ * + * int64 total_processed_bytes = 1; + * + * @return This builder for chaining. + */ + public Builder clearTotalProcessedBytes() { + + totalProcessedBytes_ = 0L; + onChanged(); + return this; + } + + private long totalBilledBytes_; + /** + * + * + *
+         * Total bytes billed by the query job.
+         * 
+ * + * int64 total_billed_bytes = 2; + * + * @return The totalBilledBytes. + */ + @java.lang.Override + public long getTotalBilledBytes() { + return totalBilledBytes_; + } + /** + * + * + *
+         * Total bytes billed by the query job.
+         * 
+ * + * int64 total_billed_bytes = 2; + * + * @param value The totalBilledBytes to set. + * @return This builder for chaining. + */ + public Builder setTotalBilledBytes(long value) { + + totalBilledBytes_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Total bytes billed by the query job.
+         * 
+ * + * int64 total_billed_bytes = 2; + * + * @return This builder for chaining. + */ + public Builder clearTotalBilledBytes() { + + totalBilledBytes_ = 0L; + onChanged(); + return this; + } + + private int billingTier_; + /** + * + * + *
+         * The tier assigned by the CPU-based billing.
+         * 
+ * + * int32 billing_tier = 3; + * + * @return The billingTier. + */ + @java.lang.Override + public int getBillingTier() { + return billingTier_; + } + /** + * + * + *
+         * The tier assigned by the CPU-based billing.
+         * 
+ * + * int32 billing_tier = 3; + * + * @param value The billingTier to set. + * @return This builder for chaining. + */ + public Builder setBillingTier(int value) { + + billingTier_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The tier assigned by the CPU-based billing.
+         * 
+ * + * int32 billing_tier = 3; + * + * @return This builder for chaining. + */ + public Builder clearBillingTier() { + + billingTier_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringList referencedTables_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureReferencedTablesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + referencedTables_ = new com.google.protobuf.LazyStringArrayList(referencedTables_); + bitField0_ |= 0x00000001; + } + } + /** + * + * + *
+         * Tables accessed by the query job.
+         * 
+ * + * repeated string referenced_tables = 6; + * + * @return A list containing the referencedTables. + */ + public com.google.protobuf.ProtocolStringList getReferencedTablesList() { + return referencedTables_.getUnmodifiableView(); + } + /** + * + * + *
+         * Tables accessed by the query job.
+         * 
+ * + * repeated string referenced_tables = 6; + * + * @return The count of referencedTables. + */ + public int getReferencedTablesCount() { + return referencedTables_.size(); + } + /** + * + * + *
+         * Tables accessed by the query job.
+         * 
+ * + * repeated string referenced_tables = 6; + * + * @param index The index of the element to return. + * @return The referencedTables at the given index. + */ + public java.lang.String getReferencedTables(int index) { + return referencedTables_.get(index); + } + /** + * + * + *
+         * Tables accessed by the query job.
+         * 
+ * + * repeated string referenced_tables = 6; + * + * @param index The index of the value to return. + * @return The bytes of the referencedTables at the given index. + */ + public com.google.protobuf.ByteString getReferencedTablesBytes(int index) { + return referencedTables_.getByteString(index); + } + /** + * + * + *
+         * Tables accessed by the query job.
+         * 
+ * + * repeated string referenced_tables = 6; + * + * @param index The index to set the value at. + * @param value The referencedTables to set. + * @return This builder for chaining. + */ + public Builder setReferencedTables(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReferencedTablesIsMutable(); + referencedTables_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+         * Tables accessed by the query job.
+         * 
+ * + * repeated string referenced_tables = 6; + * + * @param value The referencedTables to add. + * @return This builder for chaining. + */ + public Builder addReferencedTables(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReferencedTablesIsMutable(); + referencedTables_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+         * Tables accessed by the query job.
+         * 
+ * + * repeated string referenced_tables = 6; + * + * @param values The referencedTables to add. + * @return This builder for chaining. + */ + public Builder addAllReferencedTables(java.lang.Iterable values) { + ensureReferencedTablesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, referencedTables_); + onChanged(); + return this; + } + /** + * + * + *
+         * Tables accessed by the query job.
+         * 
+ * + * repeated string referenced_tables = 6; + * + * @return This builder for chaining. + */ + public Builder clearReferencedTables() { + referencedTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+         * Tables accessed by the query job.
+         * 
+ * + * repeated string referenced_tables = 6; + * + * @param value The bytes of the referencedTables to add. + * @return This builder for chaining. + */ + public Builder addReferencedTablesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureReferencedTablesIsMutable(); + referencedTables_.add(value); + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringList referencedViews_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureReferencedViewsIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + referencedViews_ = new com.google.protobuf.LazyStringArrayList(referencedViews_); + bitField0_ |= 0x00000002; + } + } + /** + * + * + *
+         * Views accessed by the query job.
+         * 
+ * + * repeated string referenced_views = 7; + * + * @return A list containing the referencedViews. + */ + public com.google.protobuf.ProtocolStringList getReferencedViewsList() { + return referencedViews_.getUnmodifiableView(); + } + /** + * + * + *
+         * Views accessed by the query job.
+         * 
+ * + * repeated string referenced_views = 7; + * + * @return The count of referencedViews. + */ + public int getReferencedViewsCount() { + return referencedViews_.size(); + } + /** + * + * + *
+         * Views accessed by the query job.
+         * 
+ * + * repeated string referenced_views = 7; + * + * @param index The index of the element to return. + * @return The referencedViews at the given index. + */ + public java.lang.String getReferencedViews(int index) { + return referencedViews_.get(index); + } + /** + * + * + *
+         * Views accessed by the query job.
+         * 
+ * + * repeated string referenced_views = 7; + * + * @param index The index of the value to return. + * @return The bytes of the referencedViews at the given index. + */ + public com.google.protobuf.ByteString getReferencedViewsBytes(int index) { + return referencedViews_.getByteString(index); + } + /** + * + * + *
+         * Views accessed by the query job.
+         * 
+ * + * repeated string referenced_views = 7; + * + * @param index The index to set the value at. + * @param value The referencedViews to set. + * @return This builder for chaining. + */ + public Builder setReferencedViews(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReferencedViewsIsMutable(); + referencedViews_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+         * Views accessed by the query job.
+         * 
+ * + * repeated string referenced_views = 7; + * + * @param value The referencedViews to add. + * @return This builder for chaining. + */ + public Builder addReferencedViews(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReferencedViewsIsMutable(); + referencedViews_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+         * Views accessed by the query job.
+         * 
+ * + * repeated string referenced_views = 7; + * + * @param values The referencedViews to add. + * @return This builder for chaining. + */ + public Builder addAllReferencedViews(java.lang.Iterable values) { + ensureReferencedViewsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, referencedViews_); + onChanged(); + return this; + } + /** + * + * + *
+         * Views accessed by the query job.
+         * 
+ * + * repeated string referenced_views = 7; + * + * @return This builder for chaining. + */ + public Builder clearReferencedViews() { + referencedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + /** + * + * + *
+         * Views accessed by the query job.
+         * 
+ * + * repeated string referenced_views = 7; + * + * @param value The bytes of the referencedViews to add. + * @return This builder for chaining. + */ + public Builder addReferencedViewsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureReferencedViewsIsMutable(); + referencedViews_.add(value); + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringList referencedRoutines_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureReferencedRoutinesIsMutable() { + if (!((bitField0_ & 0x00000004) != 0)) { + referencedRoutines_ = new com.google.protobuf.LazyStringArrayList(referencedRoutines_); + bitField0_ |= 0x00000004; + } + } + /** + * + * + *
+         * Routines accessed by the query job.
+         * 
+ * + * repeated string referenced_routines = 10; + * + * @return A list containing the referencedRoutines. + */ + public com.google.protobuf.ProtocolStringList getReferencedRoutinesList() { + return referencedRoutines_.getUnmodifiableView(); + } + /** + * + * + *
+         * Routines accessed by the query job.
+         * 
+ * + * repeated string referenced_routines = 10; + * + * @return The count of referencedRoutines. + */ + public int getReferencedRoutinesCount() { + return referencedRoutines_.size(); + } + /** + * + * + *
+         * Routines accessed by the query job.
+         * 
+ * + * repeated string referenced_routines = 10; + * + * @param index The index of the element to return. + * @return The referencedRoutines at the given index. + */ + public java.lang.String getReferencedRoutines(int index) { + return referencedRoutines_.get(index); + } + /** + * + * + *
+         * Routines accessed by the query job.
+         * 
+ * + * repeated string referenced_routines = 10; + * + * @param index The index of the value to return. + * @return The bytes of the referencedRoutines at the given index. + */ + public com.google.protobuf.ByteString getReferencedRoutinesBytes(int index) { + return referencedRoutines_.getByteString(index); + } + /** + * + * + *
+         * Routines accessed by the query job.
+         * 
+ * + * repeated string referenced_routines = 10; + * + * @param index The index to set the value at. + * @param value The referencedRoutines to set. + * @return This builder for chaining. + */ + public Builder setReferencedRoutines(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReferencedRoutinesIsMutable(); + referencedRoutines_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+         * Routines accessed by the query job.
+         * 
+ * + * repeated string referenced_routines = 10; + * + * @param value The referencedRoutines to add. + * @return This builder for chaining. + */ + public Builder addReferencedRoutines(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReferencedRoutinesIsMutable(); + referencedRoutines_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+         * Routines accessed by the query job.
+         * 
+ * + * repeated string referenced_routines = 10; + * + * @param values The referencedRoutines to add. + * @return This builder for chaining. + */ + public Builder addAllReferencedRoutines(java.lang.Iterable values) { + ensureReferencedRoutinesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, referencedRoutines_); + onChanged(); + return this; + } + /** + * + * + *
+         * Routines accessed by the query job.
+         * 
+ * + * repeated string referenced_routines = 10; + * + * @return This builder for chaining. + */ + public Builder clearReferencedRoutines() { + referencedRoutines_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + /** + * + * + *
+         * Routines accessed by the query job.
+         * 
+ * + * repeated string referenced_routines = 10; + * + * @param value The bytes of the referencedRoutines to add. + * @return This builder for chaining. + */ + public Builder addReferencedRoutinesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureReferencedRoutinesIsMutable(); + referencedRoutines_.add(value); + onChanged(); + return this; + } + + private long outputRowCount_; + /** + * + * + *
+         * Number of output rows produced by the query job.
+         * 
+ * + * int64 output_row_count = 8; + * + * @return The outputRowCount. + */ + @java.lang.Override + public long getOutputRowCount() { + return outputRowCount_; + } + /** + * + * + *
+         * Number of output rows produced by the query job.
+         * 
+ * + * int64 output_row_count = 8; + * + * @param value The outputRowCount to set. + * @return This builder for chaining. + */ + public Builder setOutputRowCount(long value) { + + outputRowCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Number of output rows produced by the query job.
+         * 
+ * + * int64 output_row_count = 8; + * + * @return This builder for chaining. + */ + public Builder clearOutputRowCount() { + + outputRowCount_ = 0L; + onChanged(); + return this; + } + + private boolean cacheHit_; + /** + * + * + *
+         * True if the query job results were read from the query cache.
+         * 
+ * + * bool cache_hit = 9; + * + * @return The cacheHit. + */ + @java.lang.Override + public boolean getCacheHit() { + return cacheHit_; + } + /** + * + * + *
+         * True if the query job results were read from the query cache.
+         * 
+ * + * bool cache_hit = 9; + * + * @param value The cacheHit to set. + * @return This builder for chaining. + */ + public Builder setCacheHit(boolean value) { + + cacheHit_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * True if the query job results were read from the query cache.
+         * 
+ * + * bool cache_hit = 9; + * + * @return This builder for chaining. + */ + public Builder clearCacheHit() { + + cacheHit_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Query parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Query(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface LoadOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * Total bytes loaded by the import job.
+       * 
+ * + * int64 total_output_bytes = 1; + * + * @return The totalOutputBytes. + */ + long getTotalOutputBytes(); + } + /** + * + * + *
+     * Load job statistics.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Load} + */ + public static final class Load extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) + LoadOrBuilder { + private static final long serialVersionUID = 0L; + // Use Load.newBuilder() to construct. + private Load(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Load() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Load(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Load( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + totalOutputBytes_ = input.readInt64(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder.class); + } + + public static final int TOTAL_OUTPUT_BYTES_FIELD_NUMBER = 1; + private long totalOutputBytes_; + /** + * + * + *
+       * Total bytes loaded by the import job.
+       * 
+ * + * int64 total_output_bytes = 1; + * + * @return The totalOutputBytes. + */ + @java.lang.Override + public long getTotalOutputBytes() { + return totalOutputBytes_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (totalOutputBytes_ != 0L) { + output.writeInt64(1, totalOutputBytes_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (totalOutputBytes_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, totalOutputBytes_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) obj; + + if (getTotalOutputBytes() != other.getTotalOutputBytes()) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TOTAL_OUTPUT_BYTES_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalOutputBytes()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+       * Load job statistics.
+       * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Load} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + totalOutputBytes_ = 0L; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load(this); + result.totalOutputBytes_ = totalOutputBytes_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance()) + return this; + if (other.getTotalOutputBytes() != 0L) { + setTotalOutputBytes(other.getTotalOutputBytes()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private long totalOutputBytes_; + /** + * + * + *
+         * Total bytes loaded by the import job.
+         * 
+ * + * int64 total_output_bytes = 1; + * + * @return The totalOutputBytes. + */ + @java.lang.Override + public long getTotalOutputBytes() { + return totalOutputBytes_; + } + /** + * + * + *
+         * Total bytes loaded by the import job.
+         * 
+ * + * int64 total_output_bytes = 1; + * + * @param value The totalOutputBytes to set. + * @return This builder for chaining. + */ + public Builder setTotalOutputBytes(long value) { + + totalOutputBytes_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Total bytes loaded by the import job.
+         * 
+ * + * int64 total_output_bytes = 1; + * + * @return This builder for chaining. + */ + public Builder clearTotalOutputBytes() { + + totalOutputBytes_ = 0L; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Load parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Load(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ExtractOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * Total bytes exported by the extract job.
+       * 
+ * + * int64 total_input_bytes = 1; + * + * @return The totalInputBytes. + */ + long getTotalInputBytes(); + } + /** + * + * + *
+     * Extract job statistics.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract} + */ + public static final class Extract extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) + ExtractOrBuilder { + private static final long serialVersionUID = 0L; + // Use Extract.newBuilder() to construct. + private Extract(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Extract() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Extract(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Extract( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + totalInputBytes_ = input.readInt64(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder.class); + } + + public static final int TOTAL_INPUT_BYTES_FIELD_NUMBER = 1; + private long totalInputBytes_; + /** + * + * + *
+       * Total bytes exported by the extract job.
+       * 
+ * + * int64 total_input_bytes = 1; + * + * @return The totalInputBytes. + */ + @java.lang.Override + public long getTotalInputBytes() { + return totalInputBytes_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (totalInputBytes_ != 0L) { + output.writeInt64(1, totalInputBytes_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (totalInputBytes_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, totalInputBytes_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) obj; + + if (getTotalInputBytes() != other.getTotalInputBytes()) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TOTAL_INPUT_BYTES_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalInputBytes()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+       * Extract job statistics.
+       * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder.class); + } + + // Construct using + // com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + totalInputBytes_ = 0L; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract(this); + result.totalInputBytes_ = totalInputBytes_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance()) + return this; + if (other.getTotalInputBytes() != 0L) { + setTotalInputBytes(other.getTotalInputBytes()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private long totalInputBytes_; + /** + * + * + *
+         * Total bytes exported by the extract job.
+         * 
+ * + * int64 total_input_bytes = 1; + * + * @return The totalInputBytes. + */ + @java.lang.Override + public long getTotalInputBytes() { + return totalInputBytes_; + } + /** + * + * + *
+         * Total bytes exported by the extract job.
+         * 
+ * + * int64 total_input_bytes = 1; + * + * @param value The totalInputBytes to set. + * @return This builder for chaining. + */ + public Builder setTotalInputBytes(long value) { + + totalInputBytes_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Total bytes exported by the extract job.
+         * 
+ * + * int64 total_input_bytes = 1; + * + * @return This builder for chaining. + */ + public Builder clearTotalInputBytes() { + + totalInputBytes_ = 0L; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Extract parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Extract(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ReservationResourceUsageOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * Reservation name or "unreserved" for on-demand resources usage.
+       * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+       * Reservation name or "unreserved" for on-demand resources usage.
+       * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+       * Total slot milliseconds used by the reservation for a particular job.
+       * 
+ * + * int64 slot_ms = 2; + * + * @return The slotMs. + */ + long getSlotMs(); + } + /** + * + * + *
+     * Job resource usage breakdown by reservation.
+     * 
+ * + * Protobuf type {@code + * google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage} + */ + public static final class ReservationResourceUsage + extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) + ReservationResourceUsageOrBuilder { + private static final long serialVersionUID = 0L; + // Use ReservationResourceUsage.newBuilder() to construct. + private ReservationResourceUsage(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ReservationResourceUsage() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ReservationResourceUsage(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ReservationResourceUsage( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + case 16: + { + slotMs_ = input.readInt64(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+       * Reservation name or "unreserved" for on-demand resources usage.
+       * 
+ * + * string name = 1; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+       * Reservation name or "unreserved" for on-demand resources usage.
+       * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SLOT_MS_FIELD_NUMBER = 2; + private long slotMs_; + /** + * + * + *
+       * Total slot milliseconds used by the reservation for a particular job.
+       * 
+ * + * int64 slot_ms = 2; + * + * @return The slotMs. + */ + @java.lang.Override + public long getSlotMs() { + return slotMs_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (slotMs_ != 0L) { + output.writeInt64(2, slotMs_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (slotMs_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, slotMs_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) obj; + + if (!getName().equals(other.getName())) return false; + if (getSlotMs() != other.getSlotMs()) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + SLOT_MS_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getSlotMs()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+       * Job resource usage breakdown by reservation.
+       * 
+ * + * Protobuf type {@code + * google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsageOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .Builder.class); + } + + // Construct using + // com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + slotMs_ = 0L; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage( + this); + result.name_ = name_; + result.slotMs_ = slotMs_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) { + return mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (other.getSlotMs() != 0L) { + setSlotMs(other.getSlotMs()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+         * Reservation name or "unreserved" for on-demand resources usage.
+         * 
+ * + * string name = 1; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * Reservation name or "unreserved" for on-demand resources usage.
+         * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * Reservation name or "unreserved" for on-demand resources usage.
+         * 
+ * + * string name = 1; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Reservation name or "unreserved" for on-demand resources usage.
+         * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+         * Reservation name or "unreserved" for on-demand resources usage.
+         * 
+ * + * string name = 1; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private long slotMs_; + /** + * + * + *
+         * Total slot milliseconds used by the reservation for a particular job.
+         * 
+ * + * int64 slot_ms = 2; + * + * @return The slotMs. + */ + @java.lang.Override + public long getSlotMs() { + return slotMs_; + } + /** + * + * + *
+         * Total slot milliseconds used by the reservation for a particular job.
+         * 
+ * + * int64 slot_ms = 2; + * + * @param value The slotMs to set. + * @return This builder for chaining. + */ + public Builder setSlotMs(long value) { + + slotMs_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Total slot milliseconds used by the reservation for a particular job.
+         * 
+ * + * int64 slot_ms = 2; + * + * @return This builder for chaining. + */ + public Builder clearSlotMs() { + + slotMs_ = 0L; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStats + .ReservationResourceUsage + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ReservationResourceUsage parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ReservationResourceUsage(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int extendedCase_ = 0; + private java.lang.Object extended_; + + public enum ExtendedCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + QUERY_STATS(8), + LOAD_STATS(9), + EXTRACT_STATS(13), + EXTENDED_NOT_SET(0); + private final int value; + + private ExtendedCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ExtendedCase valueOf(int value) { + return forNumber(value); + } + + public static ExtendedCase forNumber(int value) { + switch (value) { + case 8: + return QUERY_STATS; + case 9: + return LOAD_STATS; + case 13: + return EXTRACT_STATS; + case 0: + return EXTENDED_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ExtendedCase getExtendedCase() { + return ExtendedCase.forNumber(extendedCase_); + } + + public static final int CREATE_TIME_FIELD_NUMBER = 1; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+     * Job creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 1; + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+     * Job creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 1; + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+     * Job creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 1; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int START_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp startTime_; + /** + * + * + *
+     * Job execution start time.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return Whether the startTime field is set. + */ + @java.lang.Override + public boolean hasStartTime() { + return startTime_ != null; + } + /** + * + * + *
+     * Job execution start time.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return The startTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getStartTime() { + return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; + } + /** + * + * + *
+     * Job execution start time.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { + return getStartTime(); + } + + public static final int END_TIME_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp endTime_; + /** + * + * + *
+     * Job completion time.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return Whether the endTime field is set. + */ + @java.lang.Override + public boolean hasEndTime() { + return endTime_ != null; + } + /** + * + * + *
+     * Job completion time.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return The endTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getEndTime() { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + /** + * + * + *
+     * Job completion time.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + return getEndTime(); + } + + public static final int QUERY_STATS_FIELD_NUMBER = 8; + /** + * + * + *
+     * Query job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + * + * @return Whether the queryStats field is set. + */ + @java.lang.Override + public boolean hasQueryStats() { + return extendedCase_ == 8; + } + /** + * + * + *
+     * Query job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + * + * @return The queryStats. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query getQueryStats() { + if (extendedCase_ == 8) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); + } + /** + * + * + *
+     * Query job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder + getQueryStatsOrBuilder() { + if (extendedCase_ == 8) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); + } + + public static final int LOAD_STATS_FIELD_NUMBER = 9; + /** + * + * + *
+     * Load job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + * + * @return Whether the loadStats field is set. + */ + @java.lang.Override + public boolean hasLoadStats() { + return extendedCase_ == 9; + } + /** + * + * + *
+     * Load job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + * + * @return The loadStats. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load getLoadStats() { + if (extendedCase_ == 9) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); + } + /** + * + * + *
+     * Load job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder + getLoadStatsOrBuilder() { + if (extendedCase_ == 9) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); + } + + public static final int EXTRACT_STATS_FIELD_NUMBER = 13; + /** + * + * + *
+     * Extract job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + * + * @return Whether the extractStats field is set. + */ + @java.lang.Override + public boolean hasExtractStats() { + return extendedCase_ == 13; + } + /** + * + * + *
+     * Extract job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + * + * @return The extractStats. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract getExtractStats() { + if (extendedCase_ == 13) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); + } + /** + * + * + *
+     * Extract job statistics.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder + getExtractStatsOrBuilder() { + if (extendedCase_ == 13) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); + } + + public static final int TOTAL_SLOT_MS_FIELD_NUMBER = 10; + private long totalSlotMs_; + /** + * + * + *
+     * The total number of slot-ms consumed by the query job.
+     * 
+ * + * int64 total_slot_ms = 10; + * + * @return The totalSlotMs. + */ + @java.lang.Override + public long getTotalSlotMs() { + return totalSlotMs_; + } + + public static final int RESERVATION_USAGE_FIELD_NUMBER = 11; + private java.util.List< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage> + reservationUsage_; + /** + * + * + *
+     * Reservation usage attributed from each tier of a reservation hierarchy.
+     * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + @java.lang.Override + public java.util.List< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage> + getReservationUsageList() { + return reservationUsage_; + } + /** + * + * + *
+     * Reservation usage attributed from each tier of a reservation hierarchy.
+     * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + @java.lang.Override + public java.util.List< + ? extends + com.google.cloud.audit.BigQueryAuditMetadata.JobStats + .ReservationResourceUsageOrBuilder> + getReservationUsageOrBuilderList() { + return reservationUsage_; + } + /** + * + * + *
+     * Reservation usage attributed from each tier of a reservation hierarchy.
+     * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + @java.lang.Override + public int getReservationUsageCount() { + return reservationUsage_.size(); + } + /** + * + * + *
+     * Reservation usage attributed from each tier of a reservation hierarchy.
+     * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + getReservationUsage(int index) { + return reservationUsage_.get(index); + } + /** + * + * + *
+     * Reservation usage attributed from each tier of a reservation hierarchy.
+     * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsageOrBuilder + getReservationUsageOrBuilder(int index) { + return reservationUsage_.get(index); + } + + public static final int PARENT_JOB_NAME_FIELD_NUMBER = 12; + private volatile java.lang.Object parentJobName_; + /** + * + * + *
+     * Parent job name. Only present for child jobs.
+     * 
+ * + * string parent_job_name = 12; + * + * @return The parentJobName. + */ + @java.lang.Override + public java.lang.String getParentJobName() { + java.lang.Object ref = parentJobName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parentJobName_ = s; + return s; + } + } + /** + * + * + *
+     * Parent job name. Only present for child jobs.
+     * 
+ * + * string parent_job_name = 12; + * + * @return The bytes for parentJobName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentJobNameBytes() { + java.lang.Object ref = parentJobName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parentJobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (createTime_ != null) { + output.writeMessage(1, getCreateTime()); + } + if (startTime_ != null) { + output.writeMessage(2, getStartTime()); + } + if (endTime_ != null) { + output.writeMessage(3, getEndTime()); + } + if (extendedCase_ == 8) { + output.writeMessage( + 8, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_); + } + if (extendedCase_ == 9) { + output.writeMessage( + 9, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_); + } + if (totalSlotMs_ != 0L) { + output.writeInt64(10, totalSlotMs_); + } + for (int i = 0; i < reservationUsage_.size(); i++) { + output.writeMessage(11, reservationUsage_.get(i)); + } + if (!getParentJobNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 12, parentJobName_); + } + if (extendedCase_ == 13) { + output.writeMessage( + 13, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getCreateTime()); + } + if (startTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getStartTime()); + } + if (endTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getEndTime()); + } + if (extendedCase_ == 8) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 8, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_); + } + if (extendedCase_ == 9) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 9, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_); + } + if (totalSlotMs_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(10, totalSlotMs_); + } + for (int i = 0; i < reservationUsage_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(11, reservationUsage_.get(i)); + } + if (!getParentJobNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(12, parentJobName_); + } + if (extendedCase_ == 13) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 13, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.JobStats other = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats) obj; + + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasStartTime() != other.hasStartTime()) return false; + if (hasStartTime()) { + if (!getStartTime().equals(other.getStartTime())) return false; + } + if (hasEndTime() != other.hasEndTime()) return false; + if (hasEndTime()) { + if (!getEndTime().equals(other.getEndTime())) return false; + } + if (getTotalSlotMs() != other.getTotalSlotMs()) return false; + if (!getReservationUsageList().equals(other.getReservationUsageList())) return false; + if (!getParentJobName().equals(other.getParentJobName())) return false; + if (!getExtendedCase().equals(other.getExtendedCase())) return false; + switch (extendedCase_) { + case 8: + if (!getQueryStats().equals(other.getQueryStats())) return false; + break; + case 9: + if (!getLoadStats().equals(other.getLoadStats())) return false; + break; + case 13: + if (!getExtractStats().equals(other.getExtractStats())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasStartTime()) { + hash = (37 * hash) + START_TIME_FIELD_NUMBER; + hash = (53 * hash) + getStartTime().hashCode(); + } + if (hasEndTime()) { + hash = (37 * hash) + END_TIME_FIELD_NUMBER; + hash = (53 * hash) + getEndTime().hashCode(); + } + hash = (37 * hash) + TOTAL_SLOT_MS_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalSlotMs()); + if (getReservationUsageCount() > 0) { + hash = (37 * hash) + RESERVATION_USAGE_FIELD_NUMBER; + hash = (53 * hash) + getReservationUsageList().hashCode(); + } + hash = (37 * hash) + PARENT_JOB_NAME_FIELD_NUMBER; + hash = (53 * hash) + getParentJobName().hashCode(); + switch (extendedCase_) { + case 8: + hash = (37 * hash) + QUERY_STATS_FIELD_NUMBER; + hash = (53 * hash) + getQueryStats().hashCode(); + break; + case 9: + hash = (37 * hash) + LOAD_STATS_FIELD_NUMBER; + hash = (53 * hash) + getLoadStats().hashCode(); + break; + case 13: + hash = (37 * hash) + EXTRACT_STATS_FIELD_NUMBER; + hash = (53 * hash) + getExtractStats().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Job statistics.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats) + com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.class, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobStats.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getReservationUsageFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (startTimeBuilder_ == null) { + startTime_ = null; + } else { + startTime_ = null; + startTimeBuilder_ = null; + } + if (endTimeBuilder_ == null) { + endTime_ = null; + } else { + endTime_ = null; + endTimeBuilder_ = null; + } + totalSlotMs_ = 0L; + + if (reservationUsageBuilder_ == null) { + reservationUsage_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + reservationUsageBuilder_.clear(); + } + parentJobName_ = ""; + + extendedCase_ = 0; + extended_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats build() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats result = + new com.google.cloud.audit.BigQueryAuditMetadata.JobStats(this); + int from_bitField0_ = bitField0_; + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (startTimeBuilder_ == null) { + result.startTime_ = startTime_; + } else { + result.startTime_ = startTimeBuilder_.build(); + } + if (endTimeBuilder_ == null) { + result.endTime_ = endTime_; + } else { + result.endTime_ = endTimeBuilder_.build(); + } + if (extendedCase_ == 8) { + if (queryStatsBuilder_ == null) { + result.extended_ = extended_; + } else { + result.extended_ = queryStatsBuilder_.build(); + } + } + if (extendedCase_ == 9) { + if (loadStatsBuilder_ == null) { + result.extended_ = extended_; + } else { + result.extended_ = loadStatsBuilder_.build(); + } + } + if (extendedCase_ == 13) { + if (extractStatsBuilder_ == null) { + result.extended_ = extended_; + } else { + result.extended_ = extractStatsBuilder_.build(); + } + } + result.totalSlotMs_ = totalSlotMs_; + if (reservationUsageBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + reservationUsage_ = java.util.Collections.unmodifiableList(reservationUsage_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.reservationUsage_ = reservationUsage_; + } else { + result.reservationUsage_ = reservationUsageBuilder_.build(); + } + result.parentJobName_ = parentJobName_; + result.extendedCase_ = extendedCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobStats) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobStats other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.JobStats.getDefaultInstance()) + return this; + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasStartTime()) { + mergeStartTime(other.getStartTime()); + } + if (other.hasEndTime()) { + mergeEndTime(other.getEndTime()); + } + if (other.getTotalSlotMs() != 0L) { + setTotalSlotMs(other.getTotalSlotMs()); + } + if (reservationUsageBuilder_ == null) { + if (!other.reservationUsage_.isEmpty()) { + if (reservationUsage_.isEmpty()) { + reservationUsage_ = other.reservationUsage_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureReservationUsageIsMutable(); + reservationUsage_.addAll(other.reservationUsage_); + } + onChanged(); + } + } else { + if (!other.reservationUsage_.isEmpty()) { + if (reservationUsageBuilder_.isEmpty()) { + reservationUsageBuilder_.dispose(); + reservationUsageBuilder_ = null; + reservationUsage_ = other.reservationUsage_; + bitField0_ = (bitField0_ & ~0x00000001); + reservationUsageBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getReservationUsageFieldBuilder() + : null; + } else { + reservationUsageBuilder_.addAllMessages(other.reservationUsage_); + } + } + } + if (!other.getParentJobName().isEmpty()) { + parentJobName_ = other.parentJobName_; + onChanged(); + } + switch (other.getExtendedCase()) { + case QUERY_STATS: + { + mergeQueryStats(other.getQueryStats()); + break; + } + case LOAD_STATS: + { + mergeLoadStats(other.getLoadStats()); + break; + } + case EXTRACT_STATS: + { + mergeExtractStats(other.getExtractStats()); + break; + } + case EXTENDED_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.JobStats parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int extendedCase_ = 0; + private java.lang.Object extended_; + + public ExtendedCase getExtendedCase() { + return ExtendedCase.forNumber(extendedCase_); + } + + public Builder clearExtended() { + extendedCase_ = 0; + extended_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + /** + * + * + *
+       * Job creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 1; + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+       * Job creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 1; + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Job creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 1; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Job creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 1; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Job creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 1; + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_) + .mergeFrom(value) + .buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Job creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 1; + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Job creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 1; + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Job creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 1; + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+       * Job creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp startTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + startTimeBuilder_; + /** + * + * + *
+       * Job execution start time.
+       * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return Whether the startTime field is set. + */ + public boolean hasStartTime() { + return startTimeBuilder_ != null || startTime_ != null; + } + /** + * + * + *
+       * Job execution start time.
+       * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return The startTime. + */ + public com.google.protobuf.Timestamp getStartTime() { + if (startTimeBuilder_ == null) { + return startTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : startTime_; + } else { + return startTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Job execution start time.
+       * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public Builder setStartTime(com.google.protobuf.Timestamp value) { + if (startTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + startTime_ = value; + onChanged(); + } else { + startTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Job execution start time.
+       * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public Builder setStartTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (startTimeBuilder_ == null) { + startTime_ = builderForValue.build(); + onChanged(); + } else { + startTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Job execution start time.
+       * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public Builder mergeStartTime(com.google.protobuf.Timestamp value) { + if (startTimeBuilder_ == null) { + if (startTime_ != null) { + startTime_ = + com.google.protobuf.Timestamp.newBuilder(startTime_) + .mergeFrom(value) + .buildPartial(); + } else { + startTime_ = value; + } + onChanged(); + } else { + startTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Job execution start time.
+       * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public Builder clearStartTime() { + if (startTimeBuilder_ == null) { + startTime_ = null; + onChanged(); + } else { + startTime_ = null; + startTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Job execution start time.
+       * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public com.google.protobuf.Timestamp.Builder getStartTimeBuilder() { + + onChanged(); + return getStartTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Job execution start time.
+       * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { + if (startTimeBuilder_ != null) { + return startTimeBuilder_.getMessageOrBuilder(); + } else { + return startTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : startTime_; + } + } + /** + * + * + *
+       * Job execution start time.
+       * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getStartTimeFieldBuilder() { + if (startTimeBuilder_ == null) { + startTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getStartTime(), getParentForChildren(), isClean()); + startTime_ = null; + } + return startTimeBuilder_; + } + + private com.google.protobuf.Timestamp endTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + endTimeBuilder_; + /** + * + * + *
+       * Job completion time.
+       * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return Whether the endTime field is set. + */ + public boolean hasEndTime() { + return endTimeBuilder_ != null || endTime_ != null; + } + /** + * + * + *
+       * Job completion time.
+       * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return The endTime. + */ + public com.google.protobuf.Timestamp getEndTime() { + if (endTimeBuilder_ == null) { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } else { + return endTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Job completion time.
+       * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public Builder setEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + endTime_ = value; + onChanged(); + } else { + endTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Job completion time.
+       * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (endTimeBuilder_ == null) { + endTime_ = builderForValue.build(); + onChanged(); + } else { + endTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Job completion time.
+       * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public Builder mergeEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (endTime_ != null) { + endTime_ = + com.google.protobuf.Timestamp.newBuilder(endTime_).mergeFrom(value).buildPartial(); + } else { + endTime_ = value; + } + onChanged(); + } else { + endTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Job completion time.
+       * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public Builder clearEndTime() { + if (endTimeBuilder_ == null) { + endTime_ = null; + onChanged(); + } else { + endTime_ = null; + endTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Job completion time.
+       * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public com.google.protobuf.Timestamp.Builder getEndTimeBuilder() { + + onChanged(); + return getEndTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Job completion time.
+       * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + if (endTimeBuilder_ != null) { + return endTimeBuilder_.getMessageOrBuilder(); + } else { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + } + /** + * + * + *
+       * Job completion time.
+       * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getEndTimeFieldBuilder() { + if (endTimeBuilder_ == null) { + endTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getEndTime(), getParentForChildren(), isClean()); + endTime_ = null; + } + return endTimeBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder> + queryStatsBuilder_; + /** + * + * + *
+       * Query job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + * + * @return Whether the queryStats field is set. + */ + @java.lang.Override + public boolean hasQueryStats() { + return extendedCase_ == 8; + } + /** + * + * + *
+       * Query job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + * + * @return The queryStats. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query getQueryStats() { + if (queryStatsBuilder_ == null) { + if (extendedCase_ == 8) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); + } else { + if (extendedCase_ == 8) { + return queryStatsBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); + } + } + /** + * + * + *
+       * Query job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + */ + public Builder setQueryStats( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query value) { + if (queryStatsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + extended_ = value; + onChanged(); + } else { + queryStatsBuilder_.setMessage(value); + } + extendedCase_ = 8; + return this; + } + /** + * + * + *
+       * Query job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + */ + public Builder setQueryStats( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder builderForValue) { + if (queryStatsBuilder_ == null) { + extended_ = builderForValue.build(); + onChanged(); + } else { + queryStatsBuilder_.setMessage(builderForValue.build()); + } + extendedCase_ = 8; + return this; + } + /** + * + * + *
+       * Query job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + */ + public Builder mergeQueryStats( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query value) { + if (queryStatsBuilder_ == null) { + if (extendedCase_ == 8 + && extended_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query + .getDefaultInstance()) { + extended_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_) + .mergeFrom(value) + .buildPartial(); + } else { + extended_ = value; + } + onChanged(); + } else { + if (extendedCase_ == 8) { + queryStatsBuilder_.mergeFrom(value); + } + queryStatsBuilder_.setMessage(value); + } + extendedCase_ = 8; + return this; + } + /** + * + * + *
+       * Query job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + */ + public Builder clearQueryStats() { + if (queryStatsBuilder_ == null) { + if (extendedCase_ == 8) { + extendedCase_ = 0; + extended_ = null; + onChanged(); + } + } else { + if (extendedCase_ == 8) { + extendedCase_ = 0; + extended_ = null; + } + queryStatsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * Query job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder + getQueryStatsBuilder() { + return getQueryStatsFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Query job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder + getQueryStatsOrBuilder() { + if ((extendedCase_ == 8) && (queryStatsBuilder_ != null)) { + return queryStatsBuilder_.getMessageOrBuilder(); + } else { + if (extendedCase_ == 8) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); + } + } + /** + * + * + *
+       * Query job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder> + getQueryStatsFieldBuilder() { + if (queryStatsBuilder_ == null) { + if (!(extendedCase_ == 8)) { + extended_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); + } + queryStatsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_, + getParentForChildren(), + isClean()); + extended_ = null; + } + extendedCase_ = 8; + onChanged(); + ; + return queryStatsBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder> + loadStatsBuilder_; + /** + * + * + *
+       * Load job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + * + * @return Whether the loadStats field is set. + */ + @java.lang.Override + public boolean hasLoadStats() { + return extendedCase_ == 9; + } + /** + * + * + *
+       * Load job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + * + * @return The loadStats. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load getLoadStats() { + if (loadStatsBuilder_ == null) { + if (extendedCase_ == 9) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); + } else { + if (extendedCase_ == 9) { + return loadStatsBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); + } + } + /** + * + * + *
+       * Load job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + */ + public Builder setLoadStats( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load value) { + if (loadStatsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + extended_ = value; + onChanged(); + } else { + loadStatsBuilder_.setMessage(value); + } + extendedCase_ = 9; + return this; + } + /** + * + * + *
+       * Load job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + */ + public Builder setLoadStats( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder builderForValue) { + if (loadStatsBuilder_ == null) { + extended_ = builderForValue.build(); + onChanged(); + } else { + loadStatsBuilder_.setMessage(builderForValue.build()); + } + extendedCase_ = 9; + return this; + } + /** + * + * + *
+       * Load job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + */ + public Builder mergeLoadStats( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load value) { + if (loadStatsBuilder_ == null) { + if (extendedCase_ == 9 + && extended_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load + .getDefaultInstance()) { + extended_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_) + .mergeFrom(value) + .buildPartial(); + } else { + extended_ = value; + } + onChanged(); + } else { + if (extendedCase_ == 9) { + loadStatsBuilder_.mergeFrom(value); + } + loadStatsBuilder_.setMessage(value); + } + extendedCase_ = 9; + return this; + } + /** + * + * + *
+       * Load job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + */ + public Builder clearLoadStats() { + if (loadStatsBuilder_ == null) { + if (extendedCase_ == 9) { + extendedCase_ = 0; + extended_ = null; + onChanged(); + } + } else { + if (extendedCase_ == 9) { + extendedCase_ = 0; + extended_ = null; + } + loadStatsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * Load job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder + getLoadStatsBuilder() { + return getLoadStatsFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Load job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder + getLoadStatsOrBuilder() { + if ((extendedCase_ == 9) && (loadStatsBuilder_ != null)) { + return loadStatsBuilder_.getMessageOrBuilder(); + } else { + if (extendedCase_ == 9) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); + } + } + /** + * + * + *
+       * Load job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder> + getLoadStatsFieldBuilder() { + if (loadStatsBuilder_ == null) { + if (!(extendedCase_ == 9)) { + extended_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); + } + loadStatsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_, + getParentForChildren(), + isClean()); + extended_ = null; + } + extendedCase_ = 9; + onChanged(); + ; + return loadStatsBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder> + extractStatsBuilder_; + /** + * + * + *
+       * Extract job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + * + * @return Whether the extractStats field is set. + */ + @java.lang.Override + public boolean hasExtractStats() { + return extendedCase_ == 13; + } + /** + * + * + *
+       * Extract job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + * + * @return The extractStats. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract getExtractStats() { + if (extractStatsBuilder_ == null) { + if (extendedCase_ == 13) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); + } else { + if (extendedCase_ == 13) { + return extractStatsBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); + } + } + /** + * + * + *
+       * Extract job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + */ + public Builder setExtractStats( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract value) { + if (extractStatsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + extended_ = value; + onChanged(); + } else { + extractStatsBuilder_.setMessage(value); + } + extendedCase_ = 13; + return this; + } + /** + * + * + *
+       * Extract job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + */ + public Builder setExtractStats( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder builderForValue) { + if (extractStatsBuilder_ == null) { + extended_ = builderForValue.build(); + onChanged(); + } else { + extractStatsBuilder_.setMessage(builderForValue.build()); + } + extendedCase_ = 13; + return this; + } + /** + * + * + *
+       * Extract job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + */ + public Builder mergeExtractStats( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract value) { + if (extractStatsBuilder_ == null) { + if (extendedCase_ == 13 + && extended_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract + .getDefaultInstance()) { + extended_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_) + .mergeFrom(value) + .buildPartial(); + } else { + extended_ = value; + } + onChanged(); + } else { + if (extendedCase_ == 13) { + extractStatsBuilder_.mergeFrom(value); + } + extractStatsBuilder_.setMessage(value); + } + extendedCase_ = 13; + return this; + } + /** + * + * + *
+       * Extract job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + */ + public Builder clearExtractStats() { + if (extractStatsBuilder_ == null) { + if (extendedCase_ == 13) { + extendedCase_ = 0; + extended_ = null; + onChanged(); + } + } else { + if (extendedCase_ == 13) { + extendedCase_ = 0; + extended_ = null; + } + extractStatsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * Extract job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder + getExtractStatsBuilder() { + return getExtractStatsFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Extract job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder + getExtractStatsOrBuilder() { + if ((extendedCase_ == 13) && (extractStatsBuilder_ != null)) { + return extractStatsBuilder_.getMessageOrBuilder(); + } else { + if (extendedCase_ == 13) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); + } + } + /** + * + * + *
+       * Extract job statistics.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder> + getExtractStatsFieldBuilder() { + if (extractStatsBuilder_ == null) { + if (!(extendedCase_ == 13)) { + extended_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); + } + extractStatsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_, + getParentForChildren(), + isClean()); + extended_ = null; + } + extendedCase_ = 13; + onChanged(); + ; + return extractStatsBuilder_; + } + + private long totalSlotMs_; + /** + * + * + *
+       * The total number of slot-ms consumed by the query job.
+       * 
+ * + * int64 total_slot_ms = 10; + * + * @return The totalSlotMs. + */ + @java.lang.Override + public long getTotalSlotMs() { + return totalSlotMs_; + } + /** + * + * + *
+       * The total number of slot-ms consumed by the query job.
+       * 
+ * + * int64 total_slot_ms = 10; + * + * @param value The totalSlotMs to set. + * @return This builder for chaining. + */ + public Builder setTotalSlotMs(long value) { + + totalSlotMs_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The total number of slot-ms consumed by the query job.
+       * 
+ * + * int64 total_slot_ms = 10; + * + * @return This builder for chaining. + */ + public Builder clearTotalSlotMs() { + + totalSlotMs_ = 0L; + onChanged(); + return this; + } + + private java.util.List< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage> + reservationUsage_ = java.util.Collections.emptyList(); + + private void ensureReservationUsageIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + reservationUsage_ = + new java.util.ArrayList< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage>( + reservationUsage_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats + .ReservationResourceUsageOrBuilder> + reservationUsageBuilder_; + + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public java.util.List< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage> + getReservationUsageList() { + if (reservationUsageBuilder_ == null) { + return java.util.Collections.unmodifiableList(reservationUsage_); + } else { + return reservationUsageBuilder_.getMessageList(); + } + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public int getReservationUsageCount() { + if (reservationUsageBuilder_ == null) { + return reservationUsage_.size(); + } else { + return reservationUsageBuilder_.getCount(); + } + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + getReservationUsage(int index) { + if (reservationUsageBuilder_ == null) { + return reservationUsage_.get(index); + } else { + return reservationUsageBuilder_.getMessage(index); + } + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public Builder setReservationUsage( + int index, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage value) { + if (reservationUsageBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureReservationUsageIsMutable(); + reservationUsage_.set(index, value); + onChanged(); + } else { + reservationUsageBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public Builder setReservationUsage( + int index, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder + builderForValue) { + if (reservationUsageBuilder_ == null) { + ensureReservationUsageIsMutable(); + reservationUsage_.set(index, builderForValue.build()); + onChanged(); + } else { + reservationUsageBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public Builder addReservationUsage( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage value) { + if (reservationUsageBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureReservationUsageIsMutable(); + reservationUsage_.add(value); + onChanged(); + } else { + reservationUsageBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public Builder addReservationUsage( + int index, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage value) { + if (reservationUsageBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureReservationUsageIsMutable(); + reservationUsage_.add(index, value); + onChanged(); + } else { + reservationUsageBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public Builder addReservationUsage( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder + builderForValue) { + if (reservationUsageBuilder_ == null) { + ensureReservationUsageIsMutable(); + reservationUsage_.add(builderForValue.build()); + onChanged(); + } else { + reservationUsageBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public Builder addReservationUsage( + int index, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder + builderForValue) { + if (reservationUsageBuilder_ == null) { + ensureReservationUsageIsMutable(); + reservationUsage_.add(index, builderForValue.build()); + onChanged(); + } else { + reservationUsageBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public Builder addAllReservationUsage( + java.lang.Iterable< + ? extends + com.google.cloud.audit.BigQueryAuditMetadata.JobStats + .ReservationResourceUsage> + values) { + if (reservationUsageBuilder_ == null) { + ensureReservationUsageIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, reservationUsage_); + onChanged(); + } else { + reservationUsageBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public Builder clearReservationUsage() { + if (reservationUsageBuilder_ == null) { + reservationUsage_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + reservationUsageBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public Builder removeReservationUsage(int index) { + if (reservationUsageBuilder_ == null) { + ensureReservationUsageIsMutable(); + reservationUsage_.remove(index); + onChanged(); + } else { + reservationUsageBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder + getReservationUsageBuilder(int index) { + return getReservationUsageFieldBuilder().getBuilder(index); + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsageOrBuilder + getReservationUsageOrBuilder(int index) { + if (reservationUsageBuilder_ == null) { + return reservationUsage_.get(index); + } else { + return reservationUsageBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public java.util.List< + ? extends + com.google.cloud.audit.BigQueryAuditMetadata.JobStats + .ReservationResourceUsageOrBuilder> + getReservationUsageOrBuilderList() { + if (reservationUsageBuilder_ != null) { + return reservationUsageBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(reservationUsage_); + } + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder + addReservationUsageBuilder() { + return getReservationUsageFieldBuilder() + .addBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .getDefaultInstance()); + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder + addReservationUsageBuilder(int index) { + return getReservationUsageFieldBuilder() + .addBuilder( + index, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .getDefaultInstance()); + } + /** + * + * + *
+       * Reservation usage attributed from each tier of a reservation hierarchy.
+       * 
+ * + * + * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; + * + */ + public java.util.List< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .Builder> + getReservationUsageBuilderList() { + return getReservationUsageFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats + .ReservationResourceUsageOrBuilder> + getReservationUsageFieldBuilder() { + if (reservationUsageBuilder_ == null) { + reservationUsageBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage + .Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobStats + .ReservationResourceUsageOrBuilder>( + reservationUsage_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + reservationUsage_ = null; + } + return reservationUsageBuilder_; + } + + private java.lang.Object parentJobName_ = ""; + /** + * + * + *
+       * Parent job name. Only present for child jobs.
+       * 
+ * + * string parent_job_name = 12; + * + * @return The parentJobName. + */ + public java.lang.String getParentJobName() { + java.lang.Object ref = parentJobName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parentJobName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * Parent job name. Only present for child jobs.
+       * 
+ * + * string parent_job_name = 12; + * + * @return The bytes for parentJobName. + */ + public com.google.protobuf.ByteString getParentJobNameBytes() { + java.lang.Object ref = parentJobName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parentJobName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * Parent job name. Only present for child jobs.
+       * 
+ * + * string parent_job_name = 12; + * + * @param value The parentJobName to set. + * @return This builder for chaining. + */ + public Builder setParentJobName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + parentJobName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Parent job name. Only present for child jobs.
+       * 
+ * + * string parent_job_name = 12; + * + * @return This builder for chaining. + */ + public Builder clearParentJobName() { + + parentJobName_ = getDefaultInstance().getParentJobName(); + onChanged(); + return this; + } + /** + * + * + *
+       * Parent job name. Only present for child jobs.
+       * 
+ * + * string parent_job_name = 12; + * + * @param value The bytes for parentJobName to set. + * @return This builder for chaining. + */ + public Builder setParentJobNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + parentJobName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats) + private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStats DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobStats(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public JobStats parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new JobStats(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobStats getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface TableOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.Table) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Table URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
+     * 
+ * + * string table_name = 1; + * + * @return The tableName. + */ + java.lang.String getTableName(); + /** + * + * + *
+     * Table URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
+     * 
+ * + * string table_name = 1; + * + * @return The bytes for tableName. + */ + com.google.protobuf.ByteString getTableNameBytes(); + + /** + * + * + *
+     * A JSON representation of the table's schema. Entire field is truncated
+     * if exceeds 40K.
+     * 
+ * + * string schema_json = 3; + * + * @return The schemaJson. + */ + java.lang.String getSchemaJson(); + /** + * + * + *
+     * A JSON representation of the table's schema. Entire field is truncated
+     * if exceeds 40K.
+     * 
+ * + * string schema_json = 3; + * + * @return The bytes for schemaJson. + */ + com.google.protobuf.ByteString getSchemaJsonBytes(); + + /** + * + * + *
+     * True if the schema_json field was truncated.
+     * 
+ * + * bool schema_json_truncated = 11; + * + * @return The schemaJsonTruncated. + */ + boolean getSchemaJsonTruncated(); + + /** + * + * + *
+     * View metadata. Only present for views.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + * + * @return Whether the view field is set. + */ + boolean hasView(); + /** + * + * + *
+     * View metadata. Only present for views.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + * + * @return The view. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition getView(); + /** + * + * + *
+     * View metadata. Only present for views.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder getViewOrBuilder(); + + /** + * + * + *
+     * Table expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return Whether the expireTime field is set. + */ + boolean hasExpireTime(); + /** + * + * + *
+     * Table expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return The expireTime. + */ + com.google.protobuf.Timestamp getExpireTime(); + /** + * + * + *
+     * Table expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder(); + + /** + * + * + *
+     * The table creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+     * The table creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+     * The table creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+     * The last time metadata update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + /** + * + * + *
+     * The last time metadata update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + * + * + *
+     * The last time metadata update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
+     * The last table truncation time.
+     * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + * + * @return Whether the truncateTime field is set. + */ + boolean hasTruncateTime(); + /** + * + * + *
+     * The last table truncation time.
+     * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + * + * @return The truncateTime. + */ + com.google.protobuf.Timestamp getTruncateTime(); + /** + * + * + *
+     * The last table truncation time.
+     * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + */ + com.google.protobuf.TimestampOrBuilder getTruncateTimeOrBuilder(); + + /** + * + * + *
+     * Table encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + * + * @return Whether the encryption field is set. + */ + boolean hasEncryption(); + /** + * + * + *
+     * Table encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + * + * @return The encryption. + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption(); + /** + * + * + *
+     * Table encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + */ + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder getEncryptionOrBuilder(); + + /** + * + * + *
+     * User-provided metadata for the table.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + * + * @return Whether the tableInfo field is set. + */ + boolean hasTableInfo(); + /** + * + * + *
+     * User-provided metadata for the table.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + * + * @return The tableInfo. + */ + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getTableInfo(); + /** + * + * + *
+     * User-provided metadata for the table.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + */ + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder getTableInfoOrBuilder(); + } + /** + * + * + *
+   * BigQuery table.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Table} + */ + public static final class Table extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.Table) + TableOrBuilder { + private static final long serialVersionUID = 0L; + // Use Table.newBuilder() to construct. + private Table(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Table() { + tableName_ = ""; + schemaJson_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Table(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Table( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + tableName_ = s; + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + schemaJson_ = s; + break; + } + case 34: + { + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder + subBuilder = null; + if (view_ != null) { + subBuilder = view_.toBuilder(); + } + view_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(view_); + view_ = subBuilder.buildPartial(); + } + + break; + } + case 42: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (expireTime_ != null) { + subBuilder = expireTime_.toBuilder(); + } + expireTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(expireTime_); + expireTime_ = subBuilder.buildPartial(); + } + + break; + } + case 50: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (createTime_ != null) { + subBuilder = createTime_.toBuilder(); + } + createTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(createTime_); + createTime_ = subBuilder.buildPartial(); + } + + break; + } + case 58: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (updateTime_ != null) { + subBuilder = updateTime_.toBuilder(); + } + updateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(updateTime_); + updateTime_ = subBuilder.buildPartial(); + } + + break; + } + case 66: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (truncateTime_ != null) { + subBuilder = truncateTime_.toBuilder(); + } + truncateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(truncateTime_); + truncateTime_ = subBuilder.buildPartial(); + } + + break; + } + case 74: + { + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = + null; + if (encryption_ != null) { + subBuilder = encryption_.toBuilder(); + } + encryption_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(encryption_); + encryption_ = subBuilder.buildPartial(); + } + + break; + } + case 82: + { + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder subBuilder = null; + if (tableInfo_ != null) { + subBuilder = tableInfo_.toBuilder(); + } + tableInfo_ = + input.readMessage( + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(tableInfo_); + tableInfo_ = subBuilder.buildPartial(); + } + + break; + } + case 88: + { + schemaJsonTruncated_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.Table.class, + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder.class); + } + + public static final int TABLE_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object tableName_; + /** + * + * + *
+     * Table URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
+     * 
+ * + * string table_name = 1; + * + * @return The tableName. + */ + @java.lang.Override + public java.lang.String getTableName() { + java.lang.Object ref = tableName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + tableName_ = s; + return s; + } + } + /** + * + * + *
+     * Table URI.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
+     * 
+ * + * string table_name = 1; + * + * @return The bytes for tableName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTableNameBytes() { + java.lang.Object ref = tableName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + tableName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SCHEMA_JSON_FIELD_NUMBER = 3; + private volatile java.lang.Object schemaJson_; + /** + * + * + *
+     * A JSON representation of the table's schema. Entire field is truncated
+     * if exceeds 40K.
+     * 
+ * + * string schema_json = 3; + * + * @return The schemaJson. + */ + @java.lang.Override + public java.lang.String getSchemaJson() { + java.lang.Object ref = schemaJson_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + schemaJson_ = s; + return s; + } + } + /** + * + * + *
+     * A JSON representation of the table's schema. Entire field is truncated
+     * if exceeds 40K.
+     * 
+ * + * string schema_json = 3; + * + * @return The bytes for schemaJson. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSchemaJsonBytes() { + java.lang.Object ref = schemaJson_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + schemaJson_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SCHEMA_JSON_TRUNCATED_FIELD_NUMBER = 11; + private boolean schemaJsonTruncated_; + /** + * + * + *
+     * True if the schema_json field was truncated.
+     * 
+ * + * bool schema_json_truncated = 11; + * + * @return The schemaJsonTruncated. + */ + @java.lang.Override + public boolean getSchemaJsonTruncated() { + return schemaJsonTruncated_; + } + + public static final int VIEW_FIELD_NUMBER = 4; + private com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view_; + /** + * + * + *
+     * View metadata. Only present for views.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + * + * @return Whether the view field is set. + */ + @java.lang.Override + public boolean hasView() { + return view_ != null; + } + /** + * + * + *
+     * View metadata. Only present for views.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + * + * @return The view. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition getView() { + return view_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.getDefaultInstance() + : view_; + } + /** + * + * + *
+     * View metadata. Only present for views.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder + getViewOrBuilder() { + return getView(); + } + + public static final int EXPIRE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp expireTime_; + /** + * + * + *
+     * Table expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return Whether the expireTime field is set. + */ + @java.lang.Override + public boolean hasExpireTime() { + return expireTime_ != null; + } + /** + * + * + *
+     * Table expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return The expireTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getExpireTime() { + return expireTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : expireTime_; + } + /** + * + * + *
+     * Table expiration time.
+     * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder() { + return getExpireTime(); + } + + public static final int CREATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+     * The table creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+     * The table creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+     * The table creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 7; + private com.google.protobuf.Timestamp updateTime_; + /** + * + * + *
+     * The last time metadata update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + * + * + *
+     * The last time metadata update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + * + * + *
+     * The last time metadata update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + public static final int TRUNCATE_TIME_FIELD_NUMBER = 8; + private com.google.protobuf.Timestamp truncateTime_; + /** + * + * + *
+     * The last table truncation time.
+     * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + * + * @return Whether the truncateTime field is set. + */ + @java.lang.Override + public boolean hasTruncateTime() { + return truncateTime_ != null; + } + /** + * + * + *
+     * The last table truncation time.
+     * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + * + * @return The truncateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getTruncateTime() { + return truncateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : truncateTime_; + } + /** + * + * + *
+     * The last table truncation time.
+     * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getTruncateTimeOrBuilder() { + return getTruncateTime(); + } + + public static final int ENCRYPTION_FIELD_NUMBER = 9; + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption_; + /** + * + * + *
+     * Table encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + * + * @return Whether the encryption field is set. + */ + @java.lang.Override + public boolean hasEncryption() { + return encryption_ != null; + } + /** + * + * + *
+     * Table encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + * + * @return The encryption. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption() { + return encryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : encryption_; + } + /** + * + * + *
+     * Table encryption information. Set when non-default encryption is used.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getEncryptionOrBuilder() { + return getEncryption(); + } + + public static final int TABLE_INFO_FIELD_NUMBER = 10; + private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo tableInfo_; + /** + * + * + *
+     * User-provided metadata for the table.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + * + * @return Whether the tableInfo field is set. + */ + @java.lang.Override + public boolean hasTableInfo() { + return tableInfo_ != null; + } + /** + * + * + *
+     * User-provided metadata for the table.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + * + * @return The tableInfo. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getTableInfo() { + return tableInfo_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() + : tableInfo_; + } + /** + * + * + *
+     * User-provided metadata for the table.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder + getTableInfoOrBuilder() { + return getTableInfo(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getTableNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, tableName_); + } + if (!getSchemaJsonBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, schemaJson_); + } + if (view_ != null) { + output.writeMessage(4, getView()); + } + if (expireTime_ != null) { + output.writeMessage(5, getExpireTime()); + } + if (createTime_ != null) { + output.writeMessage(6, getCreateTime()); + } + if (updateTime_ != null) { + output.writeMessage(7, getUpdateTime()); + } + if (truncateTime_ != null) { + output.writeMessage(8, getTruncateTime()); + } + if (encryption_ != null) { + output.writeMessage(9, getEncryption()); + } + if (tableInfo_ != null) { + output.writeMessage(10, getTableInfo()); + } + if (schemaJsonTruncated_ != false) { + output.writeBool(11, schemaJsonTruncated_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getTableNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, tableName_); + } + if (!getSchemaJsonBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, schemaJson_); + } + if (view_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getView()); + } + if (expireTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getExpireTime()); + } + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getCreateTime()); + } + if (updateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getUpdateTime()); + } + if (truncateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getTruncateTime()); + } + if (encryption_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getEncryption()); + } + if (tableInfo_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getTableInfo()); + } + if (schemaJsonTruncated_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(11, schemaJsonTruncated_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.Table)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.Table other = + (com.google.cloud.audit.BigQueryAuditMetadata.Table) obj; + + if (!getTableName().equals(other.getTableName())) return false; + if (!getSchemaJson().equals(other.getSchemaJson())) return false; + if (getSchemaJsonTruncated() != other.getSchemaJsonTruncated()) return false; + if (hasView() != other.hasView()) return false; + if (hasView()) { + if (!getView().equals(other.getView())) return false; + } + if (hasExpireTime() != other.hasExpireTime()) return false; + if (hasExpireTime()) { + if (!getExpireTime().equals(other.getExpireTime())) return false; + } + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (hasTruncateTime() != other.hasTruncateTime()) return false; + if (hasTruncateTime()) { + if (!getTruncateTime().equals(other.getTruncateTime())) return false; + } + if (hasEncryption() != other.hasEncryption()) return false; + if (hasEncryption()) { + if (!getEncryption().equals(other.getEncryption())) return false; + } + if (hasTableInfo() != other.hasTableInfo()) return false; + if (hasTableInfo()) { + if (!getTableInfo().equals(other.getTableInfo())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TABLE_NAME_FIELD_NUMBER; + hash = (53 * hash) + getTableName().hashCode(); + hash = (37 * hash) + SCHEMA_JSON_FIELD_NUMBER; + hash = (53 * hash) + getSchemaJson().hashCode(); + hash = (37 * hash) + SCHEMA_JSON_TRUNCATED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSchemaJsonTruncated()); + if (hasView()) { + hash = (37 * hash) + VIEW_FIELD_NUMBER; + hash = (53 * hash) + getView().hashCode(); + } + if (hasExpireTime()) { + hash = (37 * hash) + EXPIRE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getExpireTime().hashCode(); + } + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + if (hasTruncateTime()) { + hash = (37 * hash) + TRUNCATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getTruncateTime().hashCode(); + } + if (hasEncryption()) { + hash = (37 * hash) + ENCRYPTION_FIELD_NUMBER; + hash = (53 * hash) + getEncryption().hashCode(); + } + if (hasTableInfo()) { + hash = (37 * hash) + TABLE_INFO_FIELD_NUMBER; + hash = (53 * hash) + getTableInfo().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.audit.BigQueryAuditMetadata.Table prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * BigQuery table.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Table} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.Table) + com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.Table.class, + com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.Table.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + tableName_ = ""; + + schemaJson_ = ""; + + schemaJsonTruncated_ = false; + + if (viewBuilder_ == null) { + view_ = null; + } else { + view_ = null; + viewBuilder_ = null; + } + if (expireTimeBuilder_ == null) { + expireTime_ = null; + } else { + expireTime_ = null; + expireTimeBuilder_ = null; + } + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + if (truncateTimeBuilder_ == null) { + truncateTime_ = null; + } else { + truncateTime_ = null; + truncateTimeBuilder_ = null; + } + if (encryptionBuilder_ == null) { + encryption_ = null; + } else { + encryption_ = null; + encryptionBuilder_ = null; + } + if (tableInfoBuilder_ == null) { + tableInfo_ = null; + } else { + tableInfo_ = null; + tableInfoBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Table getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Table build() { + com.google.cloud.audit.BigQueryAuditMetadata.Table result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Table buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.Table result = + new com.google.cloud.audit.BigQueryAuditMetadata.Table(this); + result.tableName_ = tableName_; + result.schemaJson_ = schemaJson_; + result.schemaJsonTruncated_ = schemaJsonTruncated_; + if (viewBuilder_ == null) { + result.view_ = view_; + } else { + result.view_ = viewBuilder_.build(); + } + if (expireTimeBuilder_ == null) { + result.expireTime_ = expireTime_; + } else { + result.expireTime_ = expireTimeBuilder_.build(); + } + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (updateTimeBuilder_ == null) { + result.updateTime_ = updateTime_; + } else { + result.updateTime_ = updateTimeBuilder_.build(); + } + if (truncateTimeBuilder_ == null) { + result.truncateTime_ = truncateTime_; + } else { + result.truncateTime_ = truncateTimeBuilder_.build(); + } + if (encryptionBuilder_ == null) { + result.encryption_ = encryption_; + } else { + result.encryption_ = encryptionBuilder_.build(); + } + if (tableInfoBuilder_ == null) { + result.tableInfo_ = tableInfo_; + } else { + result.tableInfo_ = tableInfoBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.Table) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.Table) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.Table other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance()) + return this; + if (!other.getTableName().isEmpty()) { + tableName_ = other.tableName_; + onChanged(); + } + if (!other.getSchemaJson().isEmpty()) { + schemaJson_ = other.schemaJson_; + onChanged(); + } + if (other.getSchemaJsonTruncated() != false) { + setSchemaJsonTruncated(other.getSchemaJsonTruncated()); + } + if (other.hasView()) { + mergeView(other.getView()); + } + if (other.hasExpireTime()) { + mergeExpireTime(other.getExpireTime()); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (other.hasTruncateTime()) { + mergeTruncateTime(other.getTruncateTime()); + } + if (other.hasEncryption()) { + mergeEncryption(other.getEncryption()); + } + if (other.hasTableInfo()) { + mergeTableInfo(other.getTableInfo()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.Table parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.Table) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object tableName_ = ""; + /** + * + * + *
+       * Table URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
+       * 
+ * + * string table_name = 1; + * + * @return The tableName. + */ + public java.lang.String getTableName() { + java.lang.Object ref = tableName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + tableName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * Table URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
+       * 
+ * + * string table_name = 1; + * + * @return The bytes for tableName. + */ + public com.google.protobuf.ByteString getTableNameBytes() { + java.lang.Object ref = tableName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + tableName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * Table URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
+       * 
+ * + * string table_name = 1; + * + * @param value The tableName to set. + * @return This builder for chaining. + */ + public Builder setTableName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + tableName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Table URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
+       * 
+ * + * string table_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearTableName() { + + tableName_ = getDefaultInstance().getTableName(); + onChanged(); + return this; + } + /** + * + * + *
+       * Table URI.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
+       * 
+ * + * string table_name = 1; + * + * @param value The bytes for tableName to set. + * @return This builder for chaining. + */ + public Builder setTableNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + tableName_ = value; + onChanged(); + return this; + } + + private java.lang.Object schemaJson_ = ""; + /** + * + * + *
+       * A JSON representation of the table's schema. Entire field is truncated
+       * if exceeds 40K.
+       * 
+ * + * string schema_json = 3; + * + * @return The schemaJson. + */ + public java.lang.String getSchemaJson() { + java.lang.Object ref = schemaJson_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + schemaJson_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * A JSON representation of the table's schema. Entire field is truncated
+       * if exceeds 40K.
+       * 
+ * + * string schema_json = 3; + * + * @return The bytes for schemaJson. + */ + public com.google.protobuf.ByteString getSchemaJsonBytes() { + java.lang.Object ref = schemaJson_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + schemaJson_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * A JSON representation of the table's schema. Entire field is truncated
+       * if exceeds 40K.
+       * 
+ * + * string schema_json = 3; + * + * @param value The schemaJson to set. + * @return This builder for chaining. + */ + public Builder setSchemaJson(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + schemaJson_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * A JSON representation of the table's schema. Entire field is truncated
+       * if exceeds 40K.
+       * 
+ * + * string schema_json = 3; + * + * @return This builder for chaining. + */ + public Builder clearSchemaJson() { + + schemaJson_ = getDefaultInstance().getSchemaJson(); + onChanged(); + return this; + } + /** + * + * + *
+       * A JSON representation of the table's schema. Entire field is truncated
+       * if exceeds 40K.
+       * 
+ * + * string schema_json = 3; + * + * @param value The bytes for schemaJson to set. + * @return This builder for chaining. + */ + public Builder setSchemaJsonBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + schemaJson_ = value; + onChanged(); + return this; + } + + private boolean schemaJsonTruncated_; + /** + * + * + *
+       * True if the schema_json field was truncated.
+       * 
+ * + * bool schema_json_truncated = 11; + * + * @return The schemaJsonTruncated. + */ + @java.lang.Override + public boolean getSchemaJsonTruncated() { + return schemaJsonTruncated_; + } + /** + * + * + *
+       * True if the schema_json field was truncated.
+       * 
+ * + * bool schema_json_truncated = 11; + * + * @param value The schemaJsonTruncated to set. + * @return This builder for chaining. + */ + public Builder setSchemaJsonTruncated(boolean value) { + + schemaJsonTruncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * True if the schema_json field was truncated.
+       * 
+ * + * bool schema_json_truncated = 11; + * + * @return This builder for chaining. + */ + public Builder clearSchemaJsonTruncated() { + + schemaJsonTruncated_ = false; + onChanged(); + return this; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition, + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder> + viewBuilder_; + /** + * + * + *
+       * View metadata. Only present for views.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + * + * @return Whether the view field is set. + */ + public boolean hasView() { + return viewBuilder_ != null || view_ != null; + } + /** + * + * + *
+       * View metadata. Only present for views.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + * + * @return The view. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition getView() { + if (viewBuilder_ == null) { + return view_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition + .getDefaultInstance() + : view_; + } else { + return viewBuilder_.getMessage(); + } + } + /** + * + * + *
+       * View metadata. Only present for views.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + */ + public Builder setView( + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition value) { + if (viewBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + view_ = value; + onChanged(); + } else { + viewBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * View metadata. Only present for views.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + */ + public Builder setView( + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder + builderForValue) { + if (viewBuilder_ == null) { + view_ = builderForValue.build(); + onChanged(); + } else { + viewBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * View metadata. Only present for views.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + */ + public Builder mergeView( + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition value) { + if (viewBuilder_ == null) { + if (view_ != null) { + view_ = + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.newBuilder(view_) + .mergeFrom(value) + .buildPartial(); + } else { + view_ = value; + } + onChanged(); + } else { + viewBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * View metadata. Only present for views.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + */ + public Builder clearView() { + if (viewBuilder_ == null) { + view_ = null; + onChanged(); + } else { + view_ = null; + viewBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * View metadata. Only present for views.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder + getViewBuilder() { + + onChanged(); + return getViewFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * View metadata. Only present for views.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder + getViewOrBuilder() { + if (viewBuilder_ != null) { + return viewBuilder_.getMessageOrBuilder(); + } else { + return view_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition + .getDefaultInstance() + : view_; + } + } + /** + * + * + *
+       * View metadata. Only present for views.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition, + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder> + getViewFieldBuilder() { + if (viewBuilder_ == null) { + viewBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition, + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder>( + getView(), getParentForChildren(), isClean()); + view_ = null; + } + return viewBuilder_; + } + + private com.google.protobuf.Timestamp expireTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + expireTimeBuilder_; + /** + * + * + *
+       * Table expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return Whether the expireTime field is set. + */ + public boolean hasExpireTime() { + return expireTimeBuilder_ != null || expireTime_ != null; + } + /** + * + * + *
+       * Table expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + * + * @return The expireTime. + */ + public com.google.protobuf.Timestamp getExpireTime() { + if (expireTimeBuilder_ == null) { + return expireTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : expireTime_; + } else { + return expireTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Table expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public Builder setExpireTime(com.google.protobuf.Timestamp value) { + if (expireTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expireTime_ = value; + onChanged(); + } else { + expireTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Table expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public Builder setExpireTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (expireTimeBuilder_ == null) { + expireTime_ = builderForValue.build(); + onChanged(); + } else { + expireTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Table expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public Builder mergeExpireTime(com.google.protobuf.Timestamp value) { + if (expireTimeBuilder_ == null) { + if (expireTime_ != null) { + expireTime_ = + com.google.protobuf.Timestamp.newBuilder(expireTime_) + .mergeFrom(value) + .buildPartial(); + } else { + expireTime_ = value; + } + onChanged(); + } else { + expireTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Table expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public Builder clearExpireTime() { + if (expireTimeBuilder_ == null) { + expireTime_ = null; + onChanged(); + } else { + expireTime_ = null; + expireTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Table expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public com.google.protobuf.Timestamp.Builder getExpireTimeBuilder() { + + onChanged(); + return getExpireTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Table expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder() { + if (expireTimeBuilder_ != null) { + return expireTimeBuilder_.getMessageOrBuilder(); + } else { + return expireTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : expireTime_; + } + } + /** + * + * + *
+       * Table expiration time.
+       * 
+ * + * .google.protobuf.Timestamp expire_time = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getExpireTimeFieldBuilder() { + if (expireTimeBuilder_ == null) { + expireTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getExpireTime(), getParentForChildren(), isClean()); + expireTime_ = null; + } + return expireTimeBuilder_; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + /** + * + * + *
+       * The table creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+       * The table creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * The table creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * The table creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * The table creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_) + .mergeFrom(value) + .buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * The table creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * The table creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * The table creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+       * The table creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + /** + * + * + *
+       * The last time metadata update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + * + * + *
+       * The last time metadata update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * The last time metadata update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + onChanged(); + } else { + updateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * The last time metadata update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + onChanged(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * The last time metadata update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (updateTime_ != null) { + updateTime_ = + com.google.protobuf.Timestamp.newBuilder(updateTime_) + .mergeFrom(value) + .buildPartial(); + } else { + updateTime_ = value; + } + onChanged(); + } else { + updateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * The last time metadata update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * The last time metadata update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * The last time metadata update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + /** + * + * + *
+       * The last time metadata update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 7; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private com.google.protobuf.Timestamp truncateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + truncateTimeBuilder_; + /** + * + * + *
+       * The last table truncation time.
+       * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + * + * @return Whether the truncateTime field is set. + */ + public boolean hasTruncateTime() { + return truncateTimeBuilder_ != null || truncateTime_ != null; + } + /** + * + * + *
+       * The last table truncation time.
+       * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + * + * @return The truncateTime. + */ + public com.google.protobuf.Timestamp getTruncateTime() { + if (truncateTimeBuilder_ == null) { + return truncateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : truncateTime_; + } else { + return truncateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * The last table truncation time.
+       * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + */ + public Builder setTruncateTime(com.google.protobuf.Timestamp value) { + if (truncateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + truncateTime_ = value; + onChanged(); + } else { + truncateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * The last table truncation time.
+       * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + */ + public Builder setTruncateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (truncateTimeBuilder_ == null) { + truncateTime_ = builderForValue.build(); + onChanged(); + } else { + truncateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * The last table truncation time.
+       * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + */ + public Builder mergeTruncateTime(com.google.protobuf.Timestamp value) { + if (truncateTimeBuilder_ == null) { + if (truncateTime_ != null) { + truncateTime_ = + com.google.protobuf.Timestamp.newBuilder(truncateTime_) + .mergeFrom(value) + .buildPartial(); + } else { + truncateTime_ = value; + } + onChanged(); + } else { + truncateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * The last table truncation time.
+       * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + */ + public Builder clearTruncateTime() { + if (truncateTimeBuilder_ == null) { + truncateTime_ = null; + onChanged(); + } else { + truncateTime_ = null; + truncateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * The last table truncation time.
+       * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + */ + public com.google.protobuf.Timestamp.Builder getTruncateTimeBuilder() { + + onChanged(); + return getTruncateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * The last table truncation time.
+       * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + */ + public com.google.protobuf.TimestampOrBuilder getTruncateTimeOrBuilder() { + if (truncateTimeBuilder_ != null) { + return truncateTimeBuilder_.getMessageOrBuilder(); + } else { + return truncateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : truncateTime_; + } + } + /** + * + * + *
+       * The last table truncation time.
+       * 
+ * + * .google.protobuf.Timestamp truncate_time = 8; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getTruncateTimeFieldBuilder() { + if (truncateTimeBuilder_ == null) { + truncateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getTruncateTime(), getParentForChildren(), isClean()); + truncateTime_ = null; + } + return truncateTimeBuilder_; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + encryptionBuilder_; + /** + * + * + *
+       * Table encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + * + * @return Whether the encryption field is set. + */ + public boolean hasEncryption() { + return encryptionBuilder_ != null || encryption_ != null; + } + /** + * + * + *
+       * Table encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + * + * @return The encryption. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption() { + if (encryptionBuilder_ == null) { + return encryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : encryption_; + } else { + return encryptionBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Table encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + */ + public Builder setEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (encryptionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + encryption_ = value; + onChanged(); + } else { + encryptionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Table encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + */ + public Builder setEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { + if (encryptionBuilder_ == null) { + encryption_ = builderForValue.build(); + onChanged(); + } else { + encryptionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Table encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + */ + public Builder mergeEncryption( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { + if (encryptionBuilder_ == null) { + if (encryption_ != null) { + encryption_ = + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder(encryption_) + .mergeFrom(value) + .buildPartial(); + } else { + encryption_ = value; + } + onChanged(); + } else { + encryptionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Table encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + */ + public Builder clearEncryption() { + if (encryptionBuilder_ == null) { + encryption_ = null; + onChanged(); + } else { + encryption_ = null; + encryptionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Table encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder + getEncryptionBuilder() { + + onChanged(); + return getEncryptionFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Table encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder + getEncryptionOrBuilder() { + if (encryptionBuilder_ != null) { + return encryptionBuilder_.getMessageOrBuilder(); + } else { + return encryption_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() + : encryption_; + } + } + /** + * + * + *
+       * Table encryption information. Set when non-default encryption is used.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> + getEncryptionFieldBuilder() { + if (encryptionBuilder_ == null) { + encryptionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( + getEncryption(), getParentForChildren(), isClean()); + encryption_ = null; + } + return encryptionBuilder_; + } + + private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo tableInfo_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> + tableInfoBuilder_; + /** + * + * + *
+       * User-provided metadata for the table.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + * + * @return Whether the tableInfo field is set. + */ + public boolean hasTableInfo() { + return tableInfoBuilder_ != null || tableInfo_ != null; + } + /** + * + * + *
+       * User-provided metadata for the table.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + * + * @return The tableInfo. + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getTableInfo() { + if (tableInfoBuilder_ == null) { + return tableInfo_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() + : tableInfo_; + } else { + return tableInfoBuilder_.getMessage(); + } + } + /** + * + * + *
+       * User-provided metadata for the table.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + */ + public Builder setTableInfo(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { + if (tableInfoBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + tableInfo_ = value; + onChanged(); + } else { + tableInfoBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the table.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + */ + public Builder setTableInfo( + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder builderForValue) { + if (tableInfoBuilder_ == null) { + tableInfo_ = builderForValue.build(); + onChanged(); + } else { + tableInfoBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the table.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + */ + public Builder mergeTableInfo(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { + if (tableInfoBuilder_ == null) { + if (tableInfo_ != null) { + tableInfo_ = + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.newBuilder(tableInfo_) + .mergeFrom(value) + .buildPartial(); + } else { + tableInfo_ = value; + } + onChanged(); + } else { + tableInfoBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the table.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + */ + public Builder clearTableInfo() { + if (tableInfoBuilder_ == null) { + tableInfo_ = null; + onChanged(); + } else { + tableInfo_ = null; + tableInfoBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * User-provided metadata for the table.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder getTableInfoBuilder() { + + onChanged(); + return getTableInfoFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * User-provided metadata for the table.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder + getTableInfoOrBuilder() { + if (tableInfoBuilder_ != null) { + return tableInfoBuilder_.getMessageOrBuilder(); + } else { + return tableInfo_ == null + ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() + : tableInfo_; + } + } + /** + * + * + *
+       * User-provided metadata for the table.
+       * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> + getTableInfoFieldBuilder() { + if (tableInfoBuilder_ == null) { + tableInfoBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder>( + getTableInfo(), getParentForChildren(), isClean()); + tableInfo_ = null; + } + return tableInfoBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.Table) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.Table) + private static final com.google.cloud.audit.BigQueryAuditMetadata.Table DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.Table(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Table getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser
() { + @java.lang.Override + public Table parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Table(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser
parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser
getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Table getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface RoutineOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.Routine) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Routine URI.
+     * Format:
+     * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
+     * 
+ * + * string routine_name = 1; + * + * @return The routineName. + */ + java.lang.String getRoutineName(); + /** + * + * + *
+     * Routine URI.
+     * Format:
+     * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
+     * 
+ * + * string routine_name = 1; + * + * @return The bytes for routineName. + */ + com.google.protobuf.ByteString getRoutineNameBytes(); + + /** + * + * + *
+     * Routine creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 5; + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+     * Routine creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 5; + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+     * Routine creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+     * Routine last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 6; + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + /** + * + * + *
+     * Routine last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 6; + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + * + * + *
+     * Routine last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + } + /** + * + * + *
+   * User Defined Function (UDF) or Stored Procedure.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Routine} + */ + public static final class Routine extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.Routine) + RoutineOrBuilder { + private static final long serialVersionUID = 0L; + // Use Routine.newBuilder() to construct. + private Routine(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Routine() { + routineName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Routine(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Routine( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + routineName_ = s; + break; + } + case 42: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (createTime_ != null) { + subBuilder = createTime_.toBuilder(); + } + createTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(createTime_); + createTime_ = subBuilder.buildPartial(); + } + + break; + } + case 50: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (updateTime_ != null) { + subBuilder = updateTime_.toBuilder(); + } + updateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(updateTime_); + updateTime_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.Routine.class, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder.class); + } + + public static final int ROUTINE_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object routineName_; + /** + * + * + *
+     * Routine URI.
+     * Format:
+     * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
+     * 
+ * + * string routine_name = 1; + * + * @return The routineName. + */ + @java.lang.Override + public java.lang.String getRoutineName() { + java.lang.Object ref = routineName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + routineName_ = s; + return s; + } + } + /** + * + * + *
+     * Routine URI.
+     * Format:
+     * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
+     * 
+ * + * string routine_name = 1; + * + * @return The bytes for routineName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRoutineNameBytes() { + java.lang.Object ref = routineName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + routineName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+     * Routine creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 5; + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+     * Routine creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 5; + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+     * Routine creation time.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp updateTime_; + /** + * + * + *
+     * Routine last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 6; + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + * + * + *
+     * Routine last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 6; + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + * + * + *
+     * Routine last update time.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getRoutineNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, routineName_); + } + if (createTime_ != null) { + output.writeMessage(5, getCreateTime()); + } + if (updateTime_ != null) { + output.writeMessage(6, getUpdateTime()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getRoutineNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, routineName_); + } + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); + } + if (updateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.Routine)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.Routine other = + (com.google.cloud.audit.BigQueryAuditMetadata.Routine) obj; + + if (!getRoutineName().equals(other.getRoutineName())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ROUTINE_NAME_FIELD_NUMBER; + hash = (53 * hash) + getRoutineName().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.Routine prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * User Defined Function (UDF) or Stored Procedure.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Routine} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.Routine) + com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.Routine.class, + com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.Routine.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + routineName_ = ""; + + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Routine getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Routine build() { + com.google.cloud.audit.BigQueryAuditMetadata.Routine result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Routine buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.Routine result = + new com.google.cloud.audit.BigQueryAuditMetadata.Routine(this); + result.routineName_ = routineName_; + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (updateTimeBuilder_ == null) { + result.updateTime_ = updateTime_; + } else { + result.updateTime_ = updateTimeBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.Routine) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.Routine) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.Routine other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance()) + return this; + if (!other.getRoutineName().isEmpty()) { + routineName_ = other.routineName_; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.Routine parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.Routine) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object routineName_ = ""; + /** + * + * + *
+       * Routine URI.
+       * Format:
+       * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
+       * 
+ * + * string routine_name = 1; + * + * @return The routineName. + */ + public java.lang.String getRoutineName() { + java.lang.Object ref = routineName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + routineName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * Routine URI.
+       * Format:
+       * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
+       * 
+ * + * string routine_name = 1; + * + * @return The bytes for routineName. + */ + public com.google.protobuf.ByteString getRoutineNameBytes() { + java.lang.Object ref = routineName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + routineName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * Routine URI.
+       * Format:
+       * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
+       * 
+ * + * string routine_name = 1; + * + * @param value The routineName to set. + * @return This builder for chaining. + */ + public Builder setRoutineName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + routineName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Routine URI.
+       * Format:
+       * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
+       * 
+ * + * string routine_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearRoutineName() { + + routineName_ = getDefaultInstance().getRoutineName(); + onChanged(); + return this; + } + /** + * + * + *
+       * Routine URI.
+       * Format:
+       * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
+       * 
+ * + * string routine_name = 1; + * + * @param value The bytes for routineName to set. + * @return This builder for chaining. + */ + public Builder setRoutineNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + routineName_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + /** + * + * + *
+       * Routine creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 5; + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+       * Routine creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 5; + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Routine creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Routine creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Routine creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_) + .mergeFrom(value) + .buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Routine creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Routine creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Routine creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+       * Routine creation time.
+       * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + /** + * + * + *
+       * Routine last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 6; + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + * + * + *
+       * Routine last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 6; + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * Routine last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + onChanged(); + } else { + updateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * Routine last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + onChanged(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * Routine last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (updateTime_ != null) { + updateTime_ = + com.google.protobuf.Timestamp.newBuilder(updateTime_) + .mergeFrom(value) + .buildPartial(); + } else { + updateTime_ = value; + } + onChanged(); + } else { + updateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * Routine last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * Routine last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * Routine last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + /** + * + * + *
+       * Routine last update time.
+       * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.Routine) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.Routine) + private static final com.google.cloud.audit.BigQueryAuditMetadata.Routine DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.Routine(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.Routine getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Routine parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Routine(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.Routine getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface EntityInfoOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.EntityInfo) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * A short name for the entity.
+     * 
+ * + * string friendly_name = 1; + * + * @return The friendlyName. + */ + java.lang.String getFriendlyName(); + /** + * + * + *
+     * A short name for the entity.
+     * 
+ * + * string friendly_name = 1; + * + * @return The bytes for friendlyName. + */ + com.google.protobuf.ByteString getFriendlyNameBytes(); + + /** + * + * + *
+     * A long description for the entity.
+     * 
+ * + * string description = 2; + * + * @return The description. + */ + java.lang.String getDescription(); + /** + * + * + *
+     * A long description for the entity.
+     * 
+ * + * string description = 2; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
+     * Labels provided for the entity.
+     * 
+ * + * map<string, string> labels = 3; + */ + int getLabelsCount(); + /** + * + * + *
+     * Labels provided for the entity.
+     * 
+ * + * map<string, string> labels = 3; + */ + boolean containsLabels(java.lang.String key); + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getLabels(); + /** + * + * + *
+     * Labels provided for the entity.
+     * 
+ * + * map<string, string> labels = 3; + */ + java.util.Map getLabelsMap(); + /** + * + * + *
+     * Labels provided for the entity.
+     * 
+ * + * map<string, string> labels = 3; + */ + java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue); + /** + * + * + *
+     * Labels provided for the entity.
+     * 
+ * + * map<string, string> labels = 3; + */ + java.lang.String getLabelsOrThrow(java.lang.String key); + } + /** + * + * + *
+   * User-provided metadata for an entity, for e.g. dataset, table or model.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.EntityInfo} + */ + public static final class EntityInfo extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.EntityInfo) + EntityInfoOrBuilder { + private static final long serialVersionUID = 0L; + // Use EntityInfo.newBuilder() to construct. + private EntityInfo(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private EntityInfo() { + friendlyName_ = ""; + description_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EntityInfo(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private EntityInfo( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + friendlyName_ = s; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + description_ = s; + break; + } + case 26: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + labels_ = + com.google.protobuf.MapField.newMapField( + LabelsDefaultEntryHolder.defaultEntry); + mutable_bitField0_ |= 0x00000001; + } + com.google.protobuf.MapEntry labels__ = + input.readMessage( + LabelsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + labels_.getMutableMap().put(labels__.getKey(), labels__.getValue()); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 3: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.class, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder.class); + } + + public static final int FRIENDLY_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object friendlyName_; + /** + * + * + *
+     * A short name for the entity.
+     * 
+ * + * string friendly_name = 1; + * + * @return The friendlyName. + */ + @java.lang.Override + public java.lang.String getFriendlyName() { + java.lang.Object ref = friendlyName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + friendlyName_ = s; + return s; + } + } + /** + * + * + *
+     * A short name for the entity.
+     * 
+ * + * string friendly_name = 1; + * + * @return The bytes for friendlyName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFriendlyNameBytes() { + java.lang.Object ref = friendlyName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + friendlyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 2; + private volatile java.lang.Object description_; + /** + * + * + *
+     * A long description for the entity.
+     * 
+ * + * string description = 2; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + /** + * + * + *
+     * A long description for the entity.
+     * 
+ * + * string description = 2; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int LABELS_FIELD_NUMBER = 3; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + /** + * + * + *
+     * Labels provided for the entity.
+     * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + return internalGetLabels().getMap().containsKey(key); + } + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + /** + * + * + *
+     * Labels provided for the entity.
+     * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + /** + * + * + *
+     * Labels provided for the entity.
+     * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.lang.String getLabelsOrDefault( + java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+     * Labels provided for the entity.
+     * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getFriendlyNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, friendlyName_); + } + if (!getDescriptionBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 3); + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getFriendlyNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, friendlyName_); + } + if (!getDescriptionBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); + } + for (java.util.Map.Entry entry : + internalGetLabels().getMap().entrySet()) { + com.google.protobuf.MapEntry labels__ = + LabelsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, labels__); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo other = + (com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo) obj; + + if (!getFriendlyName().equals(other.getFriendlyName())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (!internalGetLabels().equals(other.internalGetLabels())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + FRIENDLY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getFriendlyName().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + if (!internalGetLabels().getMap().isEmpty()) { + hash = (37 * hash) + LABELS_FIELD_NUMBER; + hash = (53 * hash) + internalGetLabels().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * User-provided metadata for an entity, for e.g. dataset, table or model.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.EntityInfo} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.EntityInfo) + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 3: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMutableMapField(int number) { + switch (number) { + case 3: + return internalGetMutableLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.class, + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + friendlyName_ = ""; + + description_ = ""; + + internalGetMutableLabels().clear(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo build() { + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo result = + new com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo(this); + int from_bitField0_ = bitField0_; + result.friendlyName_ = friendlyName_; + result.description_ = description_; + result.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance()) + return this; + if (!other.getFriendlyName().isEmpty()) { + friendlyName_ = other.friendlyName_; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + onChanged(); + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object friendlyName_ = ""; + /** + * + * + *
+       * A short name for the entity.
+       * 
+ * + * string friendly_name = 1; + * + * @return The friendlyName. + */ + public java.lang.String getFriendlyName() { + java.lang.Object ref = friendlyName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + friendlyName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * A short name for the entity.
+       * 
+ * + * string friendly_name = 1; + * + * @return The bytes for friendlyName. + */ + public com.google.protobuf.ByteString getFriendlyNameBytes() { + java.lang.Object ref = friendlyName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + friendlyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * A short name for the entity.
+       * 
+ * + * string friendly_name = 1; + * + * @param value The friendlyName to set. + * @return This builder for chaining. + */ + public Builder setFriendlyName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + friendlyName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * A short name for the entity.
+       * 
+ * + * string friendly_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearFriendlyName() { + + friendlyName_ = getDefaultInstance().getFriendlyName(); + onChanged(); + return this; + } + /** + * + * + *
+       * A short name for the entity.
+       * 
+ * + * string friendly_name = 1; + * + * @param value The bytes for friendlyName to set. + * @return This builder for chaining. + */ + public Builder setFriendlyNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + friendlyName_ = value; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + /** + * + * + *
+       * A long description for the entity.
+       * 
+ * + * string description = 2; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * A long description for the entity.
+       * 
+ * + * string description = 2; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * A long description for the entity.
+       * 
+ * + * string description = 2; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + description_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * A long description for the entity.
+       * 
+ * + * string description = 2; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + + description_ = getDefaultInstance().getDescription(); + onChanged(); + return this; + } + /** + * + * + *
+       * A long description for the entity.
+       * 
+ * + * string description = 2; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + description_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + private com.google.protobuf.MapField + internalGetMutableLabels() { + onChanged(); + ; + if (labels_ == null) { + labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); + } + if (!labels_.isMutable()) { + labels_ = labels_.copy(); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + /** + * + * + *
+       * Labels provided for the entity.
+       * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + return internalGetLabels().getMap().containsKey(key); + } + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + /** + * + * + *
+       * Labels provided for the entity.
+       * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + /** + * + * + *
+       * Labels provided for the entity.
+       * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.lang.String getLabelsOrDefault( + java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+       * Labels provided for the entity.
+       * 
+ * + * map<string, string> labels = 3; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearLabels() { + internalGetMutableLabels().getMutableMap().clear(); + return this; + } + /** + * + * + *
+       * Labels provided for the entity.
+       * 
+ * + * map<string, string> labels = 3; + */ + public Builder removeLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + internalGetMutableLabels().getMutableMap().remove(key); + return this; + } + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableLabels() { + return internalGetMutableLabels().getMutableMap(); + } + /** + * + * + *
+       * Labels provided for the entity.
+       * 
+ * + * map<string, string> labels = 3; + */ + public Builder putLabels(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + if (value == null) { + throw new java.lang.NullPointerException(); + } + internalGetMutableLabels().getMutableMap().put(key, value); + return this; + } + /** + * + * + *
+       * Labels provided for the entity.
+       * 
+ * + * map<string, string> labels = 3; + */ + public Builder putAllLabels(java.util.Map values) { + internalGetMutableLabels().getMutableMap().putAll(values); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.EntityInfo) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.EntityInfo) + private static final com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EntityInfo parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new EntityInfo(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface TableViewDefinitionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * SQL query defining the view. Truncated if exceeds 40K.
+     * 
+ * + * string query = 1; + * + * @return The query. + */ + java.lang.String getQuery(); + /** + * + * + *
+     * SQL query defining the view. Truncated if exceeds 40K.
+     * 
+ * + * string query = 1; + * + * @return The bytes for query. + */ + com.google.protobuf.ByteString getQueryBytes(); + + /** + * + * + *
+     * True if the schema_json field was truncated.
+     * 
+ * + * bool query_truncated = 2; + * + * @return The queryTruncated. + */ + boolean getQueryTruncated(); + } + /** + * + * + *
+   * View definition.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition} + */ + public static final class TableViewDefinition extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) + TableViewDefinitionOrBuilder { + private static final long serialVersionUID = 0L; + // Use TableViewDefinition.newBuilder() to construct. + private TableViewDefinition(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private TableViewDefinition() { + query_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TableViewDefinition(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private TableViewDefinition( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + query_ = s; + break; + } + case 16: + { + queryTruncated_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder.class); + } + + public static final int QUERY_FIELD_NUMBER = 1; + private volatile java.lang.Object query_; + /** + * + * + *
+     * SQL query defining the view. Truncated if exceeds 40K.
+     * 
+ * + * string query = 1; + * + * @return The query. + */ + @java.lang.Override + public java.lang.String getQuery() { + java.lang.Object ref = query_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + query_ = s; + return s; + } + } + /** + * + * + *
+     * SQL query defining the view. Truncated if exceeds 40K.
+     * 
+ * + * string query = 1; + * + * @return The bytes for query. + */ + @java.lang.Override + public com.google.protobuf.ByteString getQueryBytes() { + java.lang.Object ref = query_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + query_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int QUERY_TRUNCATED_FIELD_NUMBER = 2; + private boolean queryTruncated_; + /** + * + * + *
+     * True if the schema_json field was truncated.
+     * 
+ * + * bool query_truncated = 2; + * + * @return The queryTruncated. + */ + @java.lang.Override + public boolean getQueryTruncated() { + return queryTruncated_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getQueryBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, query_); + } + if (queryTruncated_ != false) { + output.writeBool(2, queryTruncated_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getQueryBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, query_); + } + if (queryTruncated_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, queryTruncated_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition other = + (com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) obj; + + if (!getQuery().equals(other.getQuery())) return false; + if (getQueryTruncated() != other.getQueryTruncated()) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + QUERY_FIELD_NUMBER; + hash = (53 * hash) + getQuery().hashCode(); + hash = (37 * hash) + QUERY_TRUNCATED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getQueryTruncated()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * View definition.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.class, + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder.class); + } + + // Construct using + // com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + query_ = ""; + + queryTruncated_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition build() { + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition result = + new com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition(this); + result.query_ = query_; + result.queryTruncated_ = queryTruncated_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) { + return mergeFrom( + (com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition + .getDefaultInstance()) return this; + if (!other.getQuery().isEmpty()) { + query_ = other.query_; + onChanged(); + } + if (other.getQueryTruncated() != false) { + setQueryTruncated(other.getQueryTruncated()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object query_ = ""; + /** + * + * + *
+       * SQL query defining the view. Truncated if exceeds 40K.
+       * 
+ * + * string query = 1; + * + * @return The query. + */ + public java.lang.String getQuery() { + java.lang.Object ref = query_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + query_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * SQL query defining the view. Truncated if exceeds 40K.
+       * 
+ * + * string query = 1; + * + * @return The bytes for query. + */ + public com.google.protobuf.ByteString getQueryBytes() { + java.lang.Object ref = query_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + query_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * SQL query defining the view. Truncated if exceeds 40K.
+       * 
+ * + * string query = 1; + * + * @param value The query to set. + * @return This builder for chaining. + */ + public Builder setQuery(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + query_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * SQL query defining the view. Truncated if exceeds 40K.
+       * 
+ * + * string query = 1; + * + * @return This builder for chaining. + */ + public Builder clearQuery() { + + query_ = getDefaultInstance().getQuery(); + onChanged(); + return this; + } + /** + * + * + *
+       * SQL query defining the view. Truncated if exceeds 40K.
+       * 
+ * + * string query = 1; + * + * @param value The bytes for query to set. + * @return This builder for chaining. + */ + public Builder setQueryBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + query_ = value; + onChanged(); + return this; + } + + private boolean queryTruncated_; + /** + * + * + *
+       * True if the schema_json field was truncated.
+       * 
+ * + * bool query_truncated = 2; + * + * @return The queryTruncated. + */ + @java.lang.Override + public boolean getQueryTruncated() { + return queryTruncated_; + } + /** + * + * + *
+       * True if the schema_json field was truncated.
+       * 
+ * + * bool query_truncated = 2; + * + * @param value The queryTruncated to set. + * @return This builder for chaining. + */ + public Builder setQueryTruncated(boolean value) { + + queryTruncated_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * True if the schema_json field was truncated.
+       * 
+ * + * bool query_truncated = 2; + * + * @return This builder for chaining. + */ + public Builder clearQueryTruncated() { + + queryTruncated_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) + private static final com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public TableViewDefinition parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new TableViewDefinition(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface BigQueryAclOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * IAM policy for the resource.
+     * 
+ * + * .google.iam.v1.Policy policy = 1; + * + * @return Whether the policy field is set. + */ + boolean hasPolicy(); + /** + * + * + *
+     * IAM policy for the resource.
+     * 
+ * + * .google.iam.v1.Policy policy = 1; + * + * @return The policy. + */ + com.google.iam.v1.Policy getPolicy(); + /** + * + * + *
+     * IAM policy for the resource.
+     * 
+ * + * .google.iam.v1.Policy policy = 1; + */ + com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder(); + + /** + * + * + *
+     * List of authorized views for a dataset.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+     * 
+ * + * repeated string authorized_views = 2; + * + * @return A list containing the authorizedViews. + */ + java.util.List getAuthorizedViewsList(); + /** + * + * + *
+     * List of authorized views for a dataset.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+     * 
+ * + * repeated string authorized_views = 2; + * + * @return The count of authorizedViews. + */ + int getAuthorizedViewsCount(); + /** + * + * + *
+     * List of authorized views for a dataset.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+     * 
+ * + * repeated string authorized_views = 2; + * + * @param index The index of the element to return. + * @return The authorizedViews at the given index. + */ + java.lang.String getAuthorizedViews(int index); + /** + * + * + *
+     * List of authorized views for a dataset.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+     * 
+ * + * repeated string authorized_views = 2; + * + * @param index The index of the value to return. + * @return The bytes of the authorizedViews at the given index. + */ + com.google.protobuf.ByteString getAuthorizedViewsBytes(int index); + } + /** + * + * + *
+   * An access control list.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl} + */ + public static final class BigQueryAcl extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) + BigQueryAclOrBuilder { + private static final long serialVersionUID = 0L; + // Use BigQueryAcl.newBuilder() to construct. + private BigQueryAcl(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private BigQueryAcl() { + authorizedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new BigQueryAcl(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private BigQueryAcl( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + 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; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + authorizedViews_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + authorizedViews_.add(s); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + authorizedViews_ = authorizedViews_.getUnmodifiableView(); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.class, + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder.class); + } + + public static final int POLICY_FIELD_NUMBER = 1; + private com.google.iam.v1.Policy policy_; + /** + * + * + *
+     * IAM policy for the resource.
+     * 
+ * + * .google.iam.v1.Policy policy = 1; + * + * @return Whether the policy field is set. + */ + @java.lang.Override + public boolean hasPolicy() { + return policy_ != null; + } + /** + * + * + *
+     * IAM policy for the resource.
+     * 
+ * + * .google.iam.v1.Policy policy = 1; + * + * @return The policy. + */ + @java.lang.Override + public com.google.iam.v1.Policy getPolicy() { + return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_; + } + /** + * + * + *
+     * IAM policy for the resource.
+     * 
+ * + * .google.iam.v1.Policy policy = 1; + */ + @java.lang.Override + public com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder() { + return getPolicy(); + } + + public static final int AUTHORIZED_VIEWS_FIELD_NUMBER = 2; + private com.google.protobuf.LazyStringList authorizedViews_; + /** + * + * + *
+     * List of authorized views for a dataset.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+     * 
+ * + * repeated string authorized_views = 2; + * + * @return A list containing the authorizedViews. + */ + public com.google.protobuf.ProtocolStringList getAuthorizedViewsList() { + return authorizedViews_; + } + /** + * + * + *
+     * List of authorized views for a dataset.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+     * 
+ * + * repeated string authorized_views = 2; + * + * @return The count of authorizedViews. + */ + public int getAuthorizedViewsCount() { + return authorizedViews_.size(); + } + /** + * + * + *
+     * List of authorized views for a dataset.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+     * 
+ * + * repeated string authorized_views = 2; + * + * @param index The index of the element to return. + * @return The authorizedViews at the given index. + */ + public java.lang.String getAuthorizedViews(int index) { + return authorizedViews_.get(index); + } + /** + * + * + *
+     * List of authorized views for a dataset.
+     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+     * 
+ * + * repeated string authorized_views = 2; + * + * @param index The index of the value to return. + * @return The bytes of the authorizedViews at the given index. + */ + public com.google.protobuf.ByteString getAuthorizedViewsBytes(int index) { + return authorizedViews_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (policy_ != null) { + output.writeMessage(1, getPolicy()); + } + for (int i = 0; i < authorizedViews_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, authorizedViews_.getRaw(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (policy_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getPolicy()); + } + { + int dataSize = 0; + for (int i = 0; i < authorizedViews_.size(); i++) { + dataSize += computeStringSizeNoTag(authorizedViews_.getRaw(i)); + } + size += dataSize; + size += 1 * getAuthorizedViewsList().size(); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl other = + (com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) obj; + + if (hasPolicy() != other.hasPolicy()) return false; + if (hasPolicy()) { + if (!getPolicy().equals(other.getPolicy())) return false; + } + if (!getAuthorizedViewsList().equals(other.getAuthorizedViewsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasPolicy()) { + hash = (37 * hash) + POLICY_FIELD_NUMBER; + hash = (53 * hash) + getPolicy().hashCode(); + } + if (getAuthorizedViewsCount() > 0) { + hash = (37 * hash) + AUTHORIZED_VIEWS_FIELD_NUMBER; + hash = (53 * hash) + getAuthorizedViewsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * An access control list.
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.class, + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (policyBuilder_ == null) { + policy_ = null; + } else { + policy_ = null; + policyBuilder_ = null; + } + authorizedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl build() { + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl result = + new com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl(this); + int from_bitField0_ = bitField0_; + if (policyBuilder_ == null) { + result.policy_ = policy_; + } else { + result.policy_ = policyBuilder_.build(); + } + if (((bitField0_ & 0x00000001) != 0)) { + authorizedViews_ = authorizedViews_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.authorizedViews_ = authorizedViews_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.getDefaultInstance()) + return this; + if (other.hasPolicy()) { + mergePolicy(other.getPolicy()); + } + if (!other.authorizedViews_.isEmpty()) { + if (authorizedViews_.isEmpty()) { + authorizedViews_ = other.authorizedViews_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureAuthorizedViewsIsMutable(); + authorizedViews_.addAll(other.authorizedViews_); + } + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private com.google.iam.v1.Policy policy_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.iam.v1.Policy, + com.google.iam.v1.Policy.Builder, + com.google.iam.v1.PolicyOrBuilder> + policyBuilder_; + /** + * + * + *
+       * IAM policy for the resource.
+       * 
+ * + * .google.iam.v1.Policy policy = 1; + * + * @return Whether the policy field is set. + */ + public boolean hasPolicy() { + return policyBuilder_ != null || policy_ != null; + } + /** + * + * + *
+       * IAM policy for the resource.
+       * 
+ * + * .google.iam.v1.Policy policy = 1; + * + * @return The policy. + */ + public com.google.iam.v1.Policy getPolicy() { + if (policyBuilder_ == null) { + return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_; + } else { + return policyBuilder_.getMessage(); + } + } + /** + * + * + *
+       * IAM policy for the resource.
+       * 
+ * + * .google.iam.v1.Policy policy = 1; + */ + public Builder setPolicy(com.google.iam.v1.Policy value) { + if (policyBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + policy_ = value; + onChanged(); + } else { + policyBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * IAM policy for the resource.
+       * 
+ * + * .google.iam.v1.Policy policy = 1; + */ + public Builder setPolicy(com.google.iam.v1.Policy.Builder builderForValue) { + if (policyBuilder_ == null) { + policy_ = builderForValue.build(); + onChanged(); + } else { + policyBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * IAM policy for the resource.
+       * 
+ * + * .google.iam.v1.Policy policy = 1; + */ + public Builder mergePolicy(com.google.iam.v1.Policy value) { + if (policyBuilder_ == null) { + if (policy_ != null) { + policy_ = com.google.iam.v1.Policy.newBuilder(policy_).mergeFrom(value).buildPartial(); + } else { + policy_ = value; + } + onChanged(); + } else { + policyBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * IAM policy for the resource.
+       * 
+ * + * .google.iam.v1.Policy policy = 1; + */ + public Builder clearPolicy() { + if (policyBuilder_ == null) { + policy_ = null; + onChanged(); + } else { + policy_ = null; + policyBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * IAM policy for the resource.
+       * 
+ * + * .google.iam.v1.Policy policy = 1; + */ + public com.google.iam.v1.Policy.Builder getPolicyBuilder() { + + onChanged(); + return getPolicyFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * IAM policy for the resource.
+       * 
+ * + * .google.iam.v1.Policy policy = 1; + */ + public com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder() { + if (policyBuilder_ != null) { + return policyBuilder_.getMessageOrBuilder(); + } else { + return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_; + } + } + /** + * + * + *
+       * IAM policy for the resource.
+       * 
+ * + * .google.iam.v1.Policy policy = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + 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< + com.google.iam.v1.Policy, + com.google.iam.v1.Policy.Builder, + com.google.iam.v1.PolicyOrBuilder>( + getPolicy(), getParentForChildren(), isClean()); + policy_ = null; + } + return policyBuilder_; + } + + private com.google.protobuf.LazyStringList authorizedViews_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureAuthorizedViewsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + authorizedViews_ = new com.google.protobuf.LazyStringArrayList(authorizedViews_); + bitField0_ |= 0x00000001; + } + } + /** + * + * + *
+       * List of authorized views for a dataset.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+       * 
+ * + * repeated string authorized_views = 2; + * + * @return A list containing the authorizedViews. + */ + public com.google.protobuf.ProtocolStringList getAuthorizedViewsList() { + return authorizedViews_.getUnmodifiableView(); + } + /** + * + * + *
+       * List of authorized views for a dataset.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+       * 
+ * + * repeated string authorized_views = 2; + * + * @return The count of authorizedViews. + */ + public int getAuthorizedViewsCount() { + return authorizedViews_.size(); + } + /** + * + * + *
+       * List of authorized views for a dataset.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+       * 
+ * + * repeated string authorized_views = 2; + * + * @param index The index of the element to return. + * @return The authorizedViews at the given index. + */ + public java.lang.String getAuthorizedViews(int index) { + return authorizedViews_.get(index); + } + /** + * + * + *
+       * List of authorized views for a dataset.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+       * 
+ * + * repeated string authorized_views = 2; + * + * @param index The index of the value to return. + * @return The bytes of the authorizedViews at the given index. + */ + public com.google.protobuf.ByteString getAuthorizedViewsBytes(int index) { + return authorizedViews_.getByteString(index); + } + /** + * + * + *
+       * List of authorized views for a dataset.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+       * 
+ * + * repeated string authorized_views = 2; + * + * @param index The index to set the value at. + * @param value The authorizedViews to set. + * @return This builder for chaining. + */ + public Builder setAuthorizedViews(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureAuthorizedViewsIsMutable(); + authorizedViews_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+       * List of authorized views for a dataset.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+       * 
+ * + * repeated string authorized_views = 2; + * + * @param value The authorizedViews to add. + * @return This builder for chaining. + */ + public Builder addAuthorizedViews(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureAuthorizedViewsIsMutable(); + authorizedViews_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+       * List of authorized views for a dataset.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+       * 
+ * + * repeated string authorized_views = 2; + * + * @param values The authorizedViews to add. + * @return This builder for chaining. + */ + public Builder addAllAuthorizedViews(java.lang.Iterable values) { + ensureAuthorizedViewsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, authorizedViews_); + onChanged(); + return this; + } + /** + * + * + *
+       * List of authorized views for a dataset.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+       * 
+ * + * repeated string authorized_views = 2; + * + * @return This builder for chaining. + */ + public Builder clearAuthorizedViews() { + authorizedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+       * List of authorized views for a dataset.
+       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
+       * 
+ * + * repeated string authorized_views = 2; + * + * @param value The bytes of the authorizedViews to add. + * @return This builder for chaining. + */ + public Builder addAuthorizedViewsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureAuthorizedViewsIsMutable(); + authorizedViews_.add(value); + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) + private static final com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public BigQueryAcl parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new BigQueryAcl(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface EncryptionInfoOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Cloud kms key identifier.
+     * Format:
+     * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
+     * 
+ * + * string kms_key_name = 1; + * + * @return The kmsKeyName. + */ + java.lang.String getKmsKeyName(); + /** + * + * + *
+     * Cloud kms key identifier.
+     * Format:
+     * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
+     * 
+ * + * string kms_key_name = 1; + * + * @return The bytes for kmsKeyName. + */ + com.google.protobuf.ByteString getKmsKeyNameBytes(); + } + /** + * + * + *
+   * Encryption properties for a table or a job
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo} + */ + public static final class EncryptionInfo extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) + EncryptionInfoOrBuilder { + private static final long serialVersionUID = 0L; + // Use EncryptionInfo.newBuilder() to construct. + private EncryptionInfo(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private EncryptionInfo() { + kmsKeyName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EncryptionInfo(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private EncryptionInfo( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + kmsKeyName_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.class, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder.class); + } + + public static final int KMS_KEY_NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object kmsKeyName_; + /** + * + * + *
+     * Cloud kms key identifier.
+     * Format:
+     * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
+     * 
+ * + * string kms_key_name = 1; + * + * @return The kmsKeyName. + */ + @java.lang.Override + public java.lang.String getKmsKeyName() { + java.lang.Object ref = kmsKeyName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + kmsKeyName_ = s; + return s; + } + } + /** + * + * + *
+     * Cloud kms key identifier.
+     * Format:
+     * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
+     * 
+ * + * string kms_key_name = 1; + * + * @return The bytes for kmsKeyName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getKmsKeyNameBytes() { + java.lang.Object ref = kmsKeyName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + kmsKeyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getKmsKeyNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, kmsKeyName_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getKmsKeyNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, kmsKeyName_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo other = + (com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) obj; + + if (!getKmsKeyName().equals(other.getKmsKeyName())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + KMS_KEY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getKmsKeyName().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Encryption properties for a table or a job
+     * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.class, + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + kmsKeyName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo build() { + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo result = + new com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo(this); + result.kmsKeyName_ = kmsKeyName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo other) { + if (other + == com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance()) + return this; + if (!other.getKmsKeyName().isEmpty()) { + kmsKeyName_ = other.kmsKeyName_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object kmsKeyName_ = ""; + /** + * + * + *
+       * Cloud kms key identifier.
+       * Format:
+       * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
+       * 
+ * + * string kms_key_name = 1; + * + * @return The kmsKeyName. + */ + public java.lang.String getKmsKeyName() { + java.lang.Object ref = kmsKeyName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + kmsKeyName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * Cloud kms key identifier.
+       * Format:
+       * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
+       * 
+ * + * string kms_key_name = 1; + * + * @return The bytes for kmsKeyName. + */ + public com.google.protobuf.ByteString getKmsKeyNameBytes() { + java.lang.Object ref = kmsKeyName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + kmsKeyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * Cloud kms key identifier.
+       * Format:
+       * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
+       * 
+ * + * string kms_key_name = 1; + * + * @param value The kmsKeyName to set. + * @return This builder for chaining. + */ + public Builder setKmsKeyName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + kmsKeyName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Cloud kms key identifier.
+       * Format:
+       * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
+       * 
+ * + * string kms_key_name = 1; + * + * @return This builder for chaining. + */ + public Builder clearKmsKeyName() { + + kmsKeyName_ = getDefaultInstance().getKmsKeyName(); + onChanged(); + return this; + } + /** + * + * + *
+       * Cloud kms key identifier.
+       * Format:
+       * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
+       * 
+ * + * string kms_key_name = 1; + * + * @param value The bytes for kmsKeyName to set. + * @return This builder for chaining. + */ + public Builder setKmsKeyNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + kmsKeyName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) + private static final com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EncryptionInfo parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new EncryptionInfo(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int eventCase_ = 0; + private java.lang.Object event_; + + public enum EventCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + JOB_INSERTION(1), + JOB_CHANGE(2), + DATASET_CREATION(3), + DATASET_CHANGE(4), + DATASET_DELETION(5), + TABLE_CREATION(6), + TABLE_CHANGE(8), + TABLE_DELETION(9), + TABLE_DATA_READ(10), + TABLE_DATA_CHANGE(11), + MODEL_DELETION(12), + MODEL_CREATION(13), + MODEL_METADATA_CHANGE(14), + MODEL_DATA_CHANGE(15), + MODEL_DATA_READ(19), + ROUTINE_CREATION(16), + ROUTINE_CHANGE(17), + ROUTINE_DELETION(18), + EVENT_NOT_SET(0); + private final int value; + + private EventCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static EventCase valueOf(int value) { + return forNumber(value); + } + + public static EventCase forNumber(int value) { + switch (value) { + case 1: + return JOB_INSERTION; + case 2: + return JOB_CHANGE; + case 3: + return DATASET_CREATION; + case 4: + return DATASET_CHANGE; + case 5: + return DATASET_DELETION; + case 6: + return TABLE_CREATION; + case 8: + return TABLE_CHANGE; + case 9: + return TABLE_DELETION; + case 10: + return TABLE_DATA_READ; + case 11: + return TABLE_DATA_CHANGE; + case 12: + return MODEL_DELETION; + case 13: + return MODEL_CREATION; + case 14: + return MODEL_METADATA_CHANGE; + case 15: + return MODEL_DATA_CHANGE; + case 19: + return MODEL_DATA_READ; + case 16: + return ROUTINE_CREATION; + case 17: + return ROUTINE_CHANGE; + case 18: + return ROUTINE_DELETION; + case 0: + return EVENT_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public EventCase getEventCase() { + return EventCase.forNumber(eventCase_); + } + + public static final int JOB_INSERTION_FIELD_NUMBER = 1; + /** + * + * + *
+   * Job insertion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + * + * @return Whether the jobInsertion field is set. + */ + @java.lang.Override + public boolean hasJobInsertion() { + return eventCase_ == 1; + } + /** + * + * + *
+   * Job insertion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + * + * @return The jobInsertion. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getJobInsertion() { + if (eventCase_ == 1) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); + } + /** + * + * + *
+   * Job insertion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder + getJobInsertionOrBuilder() { + if (eventCase_ == 1) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); + } + + public static final int JOB_CHANGE_FIELD_NUMBER = 2; + /** + * + * + *
+   * Job state change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + * + * @return Whether the jobChange field is set. + */ + @java.lang.Override + public boolean hasJobChange() { + return eventCase_ == 2; + } + /** + * + * + *
+   * Job state change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + * + * @return The jobChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobChange getJobChange() { + if (eventCase_ == 2) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); + } + /** + * + * + *
+   * Job state change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder getJobChangeOrBuilder() { + if (eventCase_ == 2) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); + } + + public static final int DATASET_CREATION_FIELD_NUMBER = 3; + /** + * + * + *
+   * Dataset creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + * + * @return Whether the datasetCreation field is set. + */ + @java.lang.Override + public boolean hasDatasetCreation() { + return eventCase_ == 3; + } + /** + * + * + *
+   * Dataset creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + * + * @return The datasetCreation. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation getDatasetCreation() { + if (eventCase_ == 3) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); + } + /** + * + * + *
+   * Dataset creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder + getDatasetCreationOrBuilder() { + if (eventCase_ == 3) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); + } + + public static final int DATASET_CHANGE_FIELD_NUMBER = 4; + /** + * + * + *
+   * Dataset change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + * + * @return Whether the datasetChange field is set. + */ + @java.lang.Override + public boolean hasDatasetChange() { + return eventCase_ == 4; + } + /** + * + * + *
+   * Dataset change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + * + * @return The datasetChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange getDatasetChange() { + if (eventCase_ == 4) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); + } + /** + * + * + *
+   * Dataset change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder + getDatasetChangeOrBuilder() { + if (eventCase_ == 4) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); + } + + public static final int DATASET_DELETION_FIELD_NUMBER = 5; + /** + * + * + *
+   * Dataset deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + * + * @return Whether the datasetDeletion field is set. + */ + @java.lang.Override + public boolean hasDatasetDeletion() { + return eventCase_ == 5; + } + /** + * + * + *
+   * Dataset deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + * + * @return The datasetDeletion. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion getDatasetDeletion() { + if (eventCase_ == 5) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); + } + /** + * + * + *
+   * Dataset deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder + getDatasetDeletionOrBuilder() { + if (eventCase_ == 5) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); + } + + public static final int TABLE_CREATION_FIELD_NUMBER = 6; + /** + * + * + *
+   * Table creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + * + * @return Whether the tableCreation field is set. + */ + @java.lang.Override + public boolean hasTableCreation() { + return eventCase_ == 6; + } + /** + * + * + *
+   * Table creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + * + * @return The tableCreation. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation getTableCreation() { + if (eventCase_ == 6) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); + } + /** + * + * + *
+   * Table creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder + getTableCreationOrBuilder() { + if (eventCase_ == 6) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); + } + + public static final int TABLE_CHANGE_FIELD_NUMBER = 8; + /** + * + * + *
+   * Table metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + * + * @return Whether the tableChange field is set. + */ + @java.lang.Override + public boolean hasTableChange() { + return eventCase_ == 8; + } + /** + * + * + *
+   * Table metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + * + * @return The tableChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableChange getTableChange() { + if (eventCase_ == 8) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); + } + /** + * + * + *
+   * Table metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder + getTableChangeOrBuilder() { + if (eventCase_ == 8) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); + } + + public static final int TABLE_DELETION_FIELD_NUMBER = 9; + /** + * + * + *
+   * Table deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + * + * @return Whether the tableDeletion field is set. + */ + @java.lang.Override + public boolean hasTableDeletion() { + return eventCase_ == 9; + } + /** + * + * + *
+   * Table deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + * + * @return The tableDeletion. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion getTableDeletion() { + if (eventCase_ == 9) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); + } + /** + * + * + *
+   * Table deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder + getTableDeletionOrBuilder() { + if (eventCase_ == 9) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); + } + + public static final int TABLE_DATA_READ_FIELD_NUMBER = 10; + /** + * + * + *
+   * Table data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + * + * @return Whether the tableDataRead field is set. + */ + @java.lang.Override + public boolean hasTableDataRead() { + return eventCase_ == 10; + } + /** + * + * + *
+   * Table data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + * + * @return The tableDataRead. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead getTableDataRead() { + if (eventCase_ == 10) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); + } + /** + * + * + *
+   * Table data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder + getTableDataReadOrBuilder() { + if (eventCase_ == 10) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); + } + + public static final int TABLE_DATA_CHANGE_FIELD_NUMBER = 11; + /** + * + * + *
+   * Table data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + * @return Whether the tableDataChange field is set. + */ + @java.lang.Override + public boolean hasTableDataChange() { + return eventCase_ == 11; + } + /** + * + * + *
+   * Table data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + * @return The tableDataChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange getTableDataChange() { + if (eventCase_ == 11) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); + } + /** + * + * + *
+   * Table data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder + getTableDataChangeOrBuilder() { + if (eventCase_ == 11) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); + } + + public static final int MODEL_DELETION_FIELD_NUMBER = 12; + /** + * + * + *
+   * Model deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + * + * @return Whether the modelDeletion field is set. + */ + @java.lang.Override + public boolean hasModelDeletion() { + return eventCase_ == 12; + } + /** + * + * + *
+   * Model deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + * + * @return The modelDeletion. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion getModelDeletion() { + if (eventCase_ == 12) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); + } + /** + * + * + *
+   * Model deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder + getModelDeletionOrBuilder() { + if (eventCase_ == 12) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); + } + + public static final int MODEL_CREATION_FIELD_NUMBER = 13; + /** + * + * + *
+   * Model creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + * + * @return Whether the modelCreation field is set. + */ + @java.lang.Override + public boolean hasModelCreation() { + return eventCase_ == 13; + } + /** + * + * + *
+   * Model creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + * + * @return The modelCreation. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation getModelCreation() { + if (eventCase_ == 13) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); + } + /** + * + * + *
+   * Model creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder + getModelCreationOrBuilder() { + if (eventCase_ == 13) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); + } + + public static final int MODEL_METADATA_CHANGE_FIELD_NUMBER = 14; + /** + * + * + *
+   * Model metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + * + * @return Whether the modelMetadataChange field is set. + */ + @java.lang.Override + public boolean hasModelMetadataChange() { + return eventCase_ == 14; + } + /** + * + * + *
+   * Model metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + * + * @return The modelMetadataChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange getModelMetadataChange() { + if (eventCase_ == 14) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.getDefaultInstance(); + } + /** + * + * + *
+   * Model metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder + getModelMetadataChangeOrBuilder() { + if (eventCase_ == 14) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.getDefaultInstance(); + } + + public static final int MODEL_DATA_CHANGE_FIELD_NUMBER = 15; + /** + * + * + *
+   * Model data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + * @return Whether the modelDataChange field is set. + */ + @java.lang.Override + public boolean hasModelDataChange() { + return eventCase_ == 15; + } + /** + * + * + *
+   * Model data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + * @return The modelDataChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange getModelDataChange() { + if (eventCase_ == 15) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); + } + /** + * + * + *
+   * Model data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder + getModelDataChangeOrBuilder() { + if (eventCase_ == 15) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); + } + + public static final int MODEL_DATA_READ_FIELD_NUMBER = 19; + /** + * + * + *
+   * Model data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + * + * @return Whether the modelDataRead field is set. + */ + @java.lang.Override + public boolean hasModelDataRead() { + return eventCase_ == 19; + } + /** + * + * + *
+   * Model data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + * + * @return The modelDataRead. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead getModelDataRead() { + if (eventCase_ == 19) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); + } + /** + * + * + *
+   * Model data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder + getModelDataReadOrBuilder() { + if (eventCase_ == 19) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); + } + + public static final int ROUTINE_CREATION_FIELD_NUMBER = 16; + /** + * + * + *
+   * Routine creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + * + * @return Whether the routineCreation field is set. + */ + @java.lang.Override + public boolean hasRoutineCreation() { + return eventCase_ == 16; + } + /** + * + * + *
+   * Routine creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + * + * @return The routineCreation. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation getRoutineCreation() { + if (eventCase_ == 16) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); + } + /** + * + * + *
+   * Routine creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder + getRoutineCreationOrBuilder() { + if (eventCase_ == 16) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); + } + + public static final int ROUTINE_CHANGE_FIELD_NUMBER = 17; + /** + * + * + *
+   * Routine change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + * + * @return Whether the routineChange field is set. + */ + @java.lang.Override + public boolean hasRoutineChange() { + return eventCase_ == 17; + } + /** + * + * + *
+   * Routine change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + * + * @return The routineChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange getRoutineChange() { + if (eventCase_ == 17) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); + } + /** + * + * + *
+   * Routine change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder + getRoutineChangeOrBuilder() { + if (eventCase_ == 17) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); + } + + public static final int ROUTINE_DELETION_FIELD_NUMBER = 18; + /** + * + * + *
+   * Routine deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + * + * @return Whether the routineDeletion field is set. + */ + @java.lang.Override + public boolean hasRoutineDeletion() { + return eventCase_ == 18; + } + /** + * + * + *
+   * Routine deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + * + * @return The routineDeletion. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion getRoutineDeletion() { + if (eventCase_ == 18) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); + } + /** + * + * + *
+   * Routine deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder + getRoutineDeletionOrBuilder() { + if (eventCase_ == 18) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (eventCase_ == 1) { + output.writeMessage(1, (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_); + } + if (eventCase_ == 2) { + output.writeMessage(2, (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_); + } + if (eventCase_ == 3) { + output.writeMessage(3, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_); + } + if (eventCase_ == 4) { + output.writeMessage(4, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_); + } + if (eventCase_ == 5) { + output.writeMessage(5, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_); + } + if (eventCase_ == 6) { + output.writeMessage(6, (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_); + } + if (eventCase_ == 8) { + output.writeMessage(8, (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_); + } + if (eventCase_ == 9) { + output.writeMessage(9, (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_); + } + if (eventCase_ == 10) { + output.writeMessage(10, (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_); + } + if (eventCase_ == 11) { + output.writeMessage( + 11, (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_); + } + if (eventCase_ == 12) { + output.writeMessage(12, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_); + } + if (eventCase_ == 13) { + output.writeMessage(13, (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_); + } + if (eventCase_ == 14) { + output.writeMessage( + 14, (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_); + } + if (eventCase_ == 15) { + output.writeMessage( + 15, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_); + } + if (eventCase_ == 16) { + output.writeMessage( + 16, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_); + } + if (eventCase_ == 17) { + output.writeMessage(17, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_); + } + if (eventCase_ == 18) { + output.writeMessage( + 18, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_); + } + if (eventCase_ == 19) { + output.writeMessage(19, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (eventCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_); + } + if (eventCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_); + } + if (eventCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_); + } + if (eventCase_ == 4) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 4, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_); + } + if (eventCase_ == 5) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 5, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_); + } + if (eventCase_ == 6) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 6, (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_); + } + if (eventCase_ == 8) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 8, (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_); + } + if (eventCase_ == 9) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 9, (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_); + } + if (eventCase_ == 10) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 10, (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_); + } + if (eventCase_ == 11) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 11, (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_); + } + if (eventCase_ == 12) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 12, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_); + } + if (eventCase_ == 13) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 13, (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_); + } + if (eventCase_ == 14) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 14, (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_); + } + if (eventCase_ == 15) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 15, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_); + } + if (eventCase_ == 16) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 16, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_); + } + if (eventCase_ == 17) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 17, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_); + } + if (eventCase_ == 18) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 18, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_); + } + if (eventCase_ == 19) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 19, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata)) { + return super.equals(obj); + } + com.google.cloud.audit.BigQueryAuditMetadata other = + (com.google.cloud.audit.BigQueryAuditMetadata) obj; + + if (!getEventCase().equals(other.getEventCase())) return false; + switch (eventCase_) { + case 1: + if (!getJobInsertion().equals(other.getJobInsertion())) return false; + break; + case 2: + if (!getJobChange().equals(other.getJobChange())) return false; + break; + case 3: + if (!getDatasetCreation().equals(other.getDatasetCreation())) return false; + break; + case 4: + if (!getDatasetChange().equals(other.getDatasetChange())) return false; + break; + case 5: + if (!getDatasetDeletion().equals(other.getDatasetDeletion())) return false; + break; + case 6: + if (!getTableCreation().equals(other.getTableCreation())) return false; + break; + case 8: + if (!getTableChange().equals(other.getTableChange())) return false; + break; + case 9: + if (!getTableDeletion().equals(other.getTableDeletion())) return false; + break; + case 10: + if (!getTableDataRead().equals(other.getTableDataRead())) return false; + break; + case 11: + if (!getTableDataChange().equals(other.getTableDataChange())) return false; + break; + case 12: + if (!getModelDeletion().equals(other.getModelDeletion())) return false; + break; + case 13: + if (!getModelCreation().equals(other.getModelCreation())) return false; + break; + case 14: + if (!getModelMetadataChange().equals(other.getModelMetadataChange())) return false; + break; + case 15: + if (!getModelDataChange().equals(other.getModelDataChange())) return false; + break; + case 19: + if (!getModelDataRead().equals(other.getModelDataRead())) return false; + break; + case 16: + if (!getRoutineCreation().equals(other.getRoutineCreation())) return false; + break; + case 17: + if (!getRoutineChange().equals(other.getRoutineChange())) return false; + break; + case 18: + if (!getRoutineDeletion().equals(other.getRoutineDeletion())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (eventCase_) { + case 1: + hash = (37 * hash) + JOB_INSERTION_FIELD_NUMBER; + hash = (53 * hash) + getJobInsertion().hashCode(); + break; + case 2: + hash = (37 * hash) + JOB_CHANGE_FIELD_NUMBER; + hash = (53 * hash) + getJobChange().hashCode(); + break; + case 3: + hash = (37 * hash) + DATASET_CREATION_FIELD_NUMBER; + hash = (53 * hash) + getDatasetCreation().hashCode(); + break; + case 4: + hash = (37 * hash) + DATASET_CHANGE_FIELD_NUMBER; + hash = (53 * hash) + getDatasetChange().hashCode(); + break; + case 5: + hash = (37 * hash) + DATASET_DELETION_FIELD_NUMBER; + hash = (53 * hash) + getDatasetDeletion().hashCode(); + break; + case 6: + hash = (37 * hash) + TABLE_CREATION_FIELD_NUMBER; + hash = (53 * hash) + getTableCreation().hashCode(); + break; + case 8: + hash = (37 * hash) + TABLE_CHANGE_FIELD_NUMBER; + hash = (53 * hash) + getTableChange().hashCode(); + break; + case 9: + hash = (37 * hash) + TABLE_DELETION_FIELD_NUMBER; + hash = (53 * hash) + getTableDeletion().hashCode(); + break; + case 10: + hash = (37 * hash) + TABLE_DATA_READ_FIELD_NUMBER; + hash = (53 * hash) + getTableDataRead().hashCode(); + break; + case 11: + hash = (37 * hash) + TABLE_DATA_CHANGE_FIELD_NUMBER; + hash = (53 * hash) + getTableDataChange().hashCode(); + break; + case 12: + hash = (37 * hash) + MODEL_DELETION_FIELD_NUMBER; + hash = (53 * hash) + getModelDeletion().hashCode(); + break; + case 13: + hash = (37 * hash) + MODEL_CREATION_FIELD_NUMBER; + hash = (53 * hash) + getModelCreation().hashCode(); + break; + case 14: + hash = (37 * hash) + MODEL_METADATA_CHANGE_FIELD_NUMBER; + hash = (53 * hash) + getModelMetadataChange().hashCode(); + break; + case 15: + hash = (37 * hash) + MODEL_DATA_CHANGE_FIELD_NUMBER; + hash = (53 * hash) + getModelDataChange().hashCode(); + break; + case 19: + hash = (37 * hash) + MODEL_DATA_READ_FIELD_NUMBER; + hash = (53 * hash) + getModelDataRead().hashCode(); + break; + case 16: + hash = (37 * hash) + ROUTINE_CREATION_FIELD_NUMBER; + hash = (53 * hash) + getRoutineCreation().hashCode(); + break; + case 17: + hash = (37 * hash) + ROUTINE_CHANGE_FIELD_NUMBER; + hash = (53 * hash) + getRoutineChange().hashCode(); + break; + case 18: + hash = (37 * hash) + ROUTINE_DELETION_FIELD_NUMBER; + hash = (53 * hash) + getRoutineDeletion().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.audit.BigQueryAuditMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Audit log format for BigQuery cloud audit logs metadata.
+   * 
+ * + * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata) + com.google.cloud.audit.BigQueryAuditMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.audit.BigQueryAuditMetadata.class, + com.google.cloud.audit.BigQueryAuditMetadata.Builder.class); + } + + // Construct using com.google.cloud.audit.BigQueryAuditMetadata.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + eventCase_ = 0; + event_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.audit.BigQueryAuditMetadataProto + .internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata getDefaultInstanceForType() { + return com.google.cloud.audit.BigQueryAuditMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata build() { + com.google.cloud.audit.BigQueryAuditMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata buildPartial() { + com.google.cloud.audit.BigQueryAuditMetadata result = + new com.google.cloud.audit.BigQueryAuditMetadata(this); + if (eventCase_ == 1) { + if (jobInsertionBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = jobInsertionBuilder_.build(); + } + } + if (eventCase_ == 2) { + if (jobChangeBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = jobChangeBuilder_.build(); + } + } + if (eventCase_ == 3) { + if (datasetCreationBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = datasetCreationBuilder_.build(); + } + } + if (eventCase_ == 4) { + if (datasetChangeBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = datasetChangeBuilder_.build(); + } + } + if (eventCase_ == 5) { + if (datasetDeletionBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = datasetDeletionBuilder_.build(); + } + } + if (eventCase_ == 6) { + if (tableCreationBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = tableCreationBuilder_.build(); + } + } + if (eventCase_ == 8) { + if (tableChangeBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = tableChangeBuilder_.build(); + } + } + if (eventCase_ == 9) { + if (tableDeletionBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = tableDeletionBuilder_.build(); + } + } + if (eventCase_ == 10) { + if (tableDataReadBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = tableDataReadBuilder_.build(); + } + } + if (eventCase_ == 11) { + if (tableDataChangeBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = tableDataChangeBuilder_.build(); + } + } + if (eventCase_ == 12) { + if (modelDeletionBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = modelDeletionBuilder_.build(); + } + } + if (eventCase_ == 13) { + if (modelCreationBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = modelCreationBuilder_.build(); + } + } + if (eventCase_ == 14) { + if (modelMetadataChangeBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = modelMetadataChangeBuilder_.build(); + } + } + if (eventCase_ == 15) { + if (modelDataChangeBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = modelDataChangeBuilder_.build(); + } + } + if (eventCase_ == 19) { + if (modelDataReadBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = modelDataReadBuilder_.build(); + } + } + if (eventCase_ == 16) { + if (routineCreationBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = routineCreationBuilder_.build(); + } + } + if (eventCase_ == 17) { + if (routineChangeBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = routineChangeBuilder_.build(); + } + } + if (eventCase_ == 18) { + if (routineDeletionBuilder_ == null) { + result.event_ = event_; + } else { + result.event_ = routineDeletionBuilder_.build(); + } + } + result.eventCase_ = eventCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata) { + return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata other) { + if (other == com.google.cloud.audit.BigQueryAuditMetadata.getDefaultInstance()) return this; + switch (other.getEventCase()) { + case JOB_INSERTION: + { + mergeJobInsertion(other.getJobInsertion()); + break; + } + case JOB_CHANGE: + { + mergeJobChange(other.getJobChange()); + break; + } + case DATASET_CREATION: + { + mergeDatasetCreation(other.getDatasetCreation()); + break; + } + case DATASET_CHANGE: + { + mergeDatasetChange(other.getDatasetChange()); + break; + } + case DATASET_DELETION: + { + mergeDatasetDeletion(other.getDatasetDeletion()); + break; + } + case TABLE_CREATION: + { + mergeTableCreation(other.getTableCreation()); + break; + } + case TABLE_CHANGE: + { + mergeTableChange(other.getTableChange()); + break; + } + case TABLE_DELETION: + { + mergeTableDeletion(other.getTableDeletion()); + break; + } + case TABLE_DATA_READ: + { + mergeTableDataRead(other.getTableDataRead()); + break; + } + case TABLE_DATA_CHANGE: + { + mergeTableDataChange(other.getTableDataChange()); + break; + } + case MODEL_DELETION: + { + mergeModelDeletion(other.getModelDeletion()); + break; + } + case MODEL_CREATION: + { + mergeModelCreation(other.getModelCreation()); + break; + } + case MODEL_METADATA_CHANGE: + { + mergeModelMetadataChange(other.getModelMetadataChange()); + break; + } + case MODEL_DATA_CHANGE: + { + mergeModelDataChange(other.getModelDataChange()); + break; + } + case MODEL_DATA_READ: + { + mergeModelDataRead(other.getModelDataRead()); + break; + } + case ROUTINE_CREATION: + { + mergeRoutineCreation(other.getRoutineCreation()); + break; + } + case ROUTINE_CHANGE: + { + mergeRoutineChange(other.getRoutineChange()); + break; + } + case ROUTINE_DELETION: + { + mergeRoutineDeletion(other.getRoutineDeletion()); + break; + } + case EVENT_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.audit.BigQueryAuditMetadata parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.cloud.audit.BigQueryAuditMetadata) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int eventCase_ = 0; + private java.lang.Object event_; + + public EventCase getEventCase() { + return EventCase.forNumber(eventCase_); + } + + public Builder clearEvent() { + eventCase_ = 0; + event_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion, + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder> + jobInsertionBuilder_; + /** + * + * + *
+     * Job insertion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + * + * @return Whether the jobInsertion field is set. + */ + @java.lang.Override + public boolean hasJobInsertion() { + return eventCase_ == 1; + } + /** + * + * + *
+     * Job insertion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + * + * @return The jobInsertion. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getJobInsertion() { + if (jobInsertionBuilder_ == null) { + if (eventCase_ == 1) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); + } else { + if (eventCase_ == 1) { + return jobInsertionBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); + } + } + /** + * + * + *
+     * Job insertion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + */ + public Builder setJobInsertion( + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion value) { + if (jobInsertionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + jobInsertionBuilder_.setMessage(value); + } + eventCase_ = 1; + return this; + } + /** + * + * + *
+     * Job insertion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + */ + public Builder setJobInsertion( + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder builderForValue) { + if (jobInsertionBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + jobInsertionBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 1; + return this; + } + /** + * + * + *
+     * Job insertion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + */ + public Builder mergeJobInsertion( + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion value) { + if (jobInsertionBuilder_ == null) { + if (eventCase_ == 1 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 1) { + jobInsertionBuilder_.mergeFrom(value); + } + jobInsertionBuilder_.setMessage(value); + } + eventCase_ = 1; + return this; + } + /** + * + * + *
+     * Job insertion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + */ + public Builder clearJobInsertion() { + if (jobInsertionBuilder_ == null) { + if (eventCase_ == 1) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 1) { + eventCase_ = 0; + event_ = null; + } + jobInsertionBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Job insertion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder + getJobInsertionBuilder() { + return getJobInsertionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Job insertion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder + getJobInsertionOrBuilder() { + if ((eventCase_ == 1) && (jobInsertionBuilder_ != null)) { + return jobInsertionBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 1) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); + } + } + /** + * + * + *
+     * Job insertion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion, + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder> + getJobInsertionFieldBuilder() { + if (jobInsertionBuilder_ == null) { + if (!(eventCase_ == 1)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); + } + jobInsertionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion, + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 1; + onChanged(); + ; + return jobInsertionBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobChange, + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder> + jobChangeBuilder_; + /** + * + * + *
+     * Job state change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + * + * @return Whether the jobChange field is set. + */ + @java.lang.Override + public boolean hasJobChange() { + return eventCase_ == 2; + } + /** + * + * + *
+     * Job state change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + * + * @return The jobChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobChange getJobChange() { + if (jobChangeBuilder_ == null) { + if (eventCase_ == 2) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); + } else { + if (eventCase_ == 2) { + return jobChangeBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Job state change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + */ + public Builder setJobChange(com.google.cloud.audit.BigQueryAuditMetadata.JobChange value) { + if (jobChangeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + jobChangeBuilder_.setMessage(value); + } + eventCase_ = 2; + return this; + } + /** + * + * + *
+     * Job state change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + */ + public Builder setJobChange( + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder builderForValue) { + if (jobChangeBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + jobChangeBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 2; + return this; + } + /** + * + * + *
+     * Job state change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + */ + public Builder mergeJobChange(com.google.cloud.audit.BigQueryAuditMetadata.JobChange value) { + if (jobChangeBuilder_ == null) { + if (eventCase_ == 2 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 2) { + jobChangeBuilder_.mergeFrom(value); + } + jobChangeBuilder_.setMessage(value); + } + eventCase_ = 2; + return this; + } + /** + * + * + *
+     * Job state change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + */ + public Builder clearJobChange() { + if (jobChangeBuilder_ == null) { + if (eventCase_ == 2) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 2) { + eventCase_ = 0; + event_ = null; + } + jobChangeBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Job state change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder getJobChangeBuilder() { + return getJobChangeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Job state change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder getJobChangeOrBuilder() { + if ((eventCase_ == 2) && (jobChangeBuilder_ != null)) { + return jobChangeBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 2) { + return (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Job state change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobChange, + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder> + getJobChangeFieldBuilder() { + if (jobChangeBuilder_ == null) { + if (!(eventCase_ == 2)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); + } + jobChangeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.JobChange, + com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 2; + onChanged(); + ; + return jobChangeBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder> + datasetCreationBuilder_; + /** + * + * + *
+     * Dataset creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + * + * @return Whether the datasetCreation field is set. + */ + @java.lang.Override + public boolean hasDatasetCreation() { + return eventCase_ == 3; + } + /** + * + * + *
+     * Dataset creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + * + * @return The datasetCreation. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation getDatasetCreation() { + if (datasetCreationBuilder_ == null) { + if (eventCase_ == 3) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); + } else { + if (eventCase_ == 3) { + return datasetCreationBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); + } + } + /** + * + * + *
+     * Dataset creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + */ + public Builder setDatasetCreation( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation value) { + if (datasetCreationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + datasetCreationBuilder_.setMessage(value); + } + eventCase_ = 3; + return this; + } + /** + * + * + *
+     * Dataset creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + */ + public Builder setDatasetCreation( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder builderForValue) { + if (datasetCreationBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + datasetCreationBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 3; + return this; + } + /** + * + * + *
+     * Dataset creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + */ + public Builder mergeDatasetCreation( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation value) { + if (datasetCreationBuilder_ == null) { + if (eventCase_ == 3 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 3) { + datasetCreationBuilder_.mergeFrom(value); + } + datasetCreationBuilder_.setMessage(value); + } + eventCase_ = 3; + return this; + } + /** + * + * + *
+     * Dataset creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + */ + public Builder clearDatasetCreation() { + if (datasetCreationBuilder_ == null) { + if (eventCase_ == 3) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 3) { + eventCase_ = 0; + event_ = null; + } + datasetCreationBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Dataset creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder + getDatasetCreationBuilder() { + return getDatasetCreationFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Dataset creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder + getDatasetCreationOrBuilder() { + if ((eventCase_ == 3) && (datasetCreationBuilder_ != null)) { + return datasetCreationBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 3) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); + } + } + /** + * + * + *
+     * Dataset creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder> + getDatasetCreationFieldBuilder() { + if (datasetCreationBuilder_ == null) { + if (!(eventCase_ == 3)) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); + } + datasetCreationBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 3; + onChanged(); + ; + return datasetCreationBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder> + datasetChangeBuilder_; + /** + * + * + *
+     * Dataset change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + * + * @return Whether the datasetChange field is set. + */ + @java.lang.Override + public boolean hasDatasetChange() { + return eventCase_ == 4; + } + /** + * + * + *
+     * Dataset change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + * + * @return The datasetChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange getDatasetChange() { + if (datasetChangeBuilder_ == null) { + if (eventCase_ == 4) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); + } else { + if (eventCase_ == 4) { + return datasetChangeBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Dataset change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + */ + public Builder setDatasetChange( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange value) { + if (datasetChangeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + datasetChangeBuilder_.setMessage(value); + } + eventCase_ = 4; + return this; + } + /** + * + * + *
+     * Dataset change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + */ + public Builder setDatasetChange( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder builderForValue) { + if (datasetChangeBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + datasetChangeBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 4; + return this; + } + /** + * + * + *
+     * Dataset change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + */ + public Builder mergeDatasetChange( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange value) { + if (datasetChangeBuilder_ == null) { + if (eventCase_ == 4 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 4) { + datasetChangeBuilder_.mergeFrom(value); + } + datasetChangeBuilder_.setMessage(value); + } + eventCase_ = 4; + return this; + } + /** + * + * + *
+     * Dataset change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + */ + public Builder clearDatasetChange() { + if (datasetChangeBuilder_ == null) { + if (eventCase_ == 4) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 4) { + eventCase_ = 0; + event_ = null; + } + datasetChangeBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Dataset change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder + getDatasetChangeBuilder() { + return getDatasetChangeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Dataset change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder + getDatasetChangeOrBuilder() { + if ((eventCase_ == 4) && (datasetChangeBuilder_ != null)) { + return datasetChangeBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 4) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Dataset change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder> + getDatasetChangeFieldBuilder() { + if (datasetChangeBuilder_ == null) { + if (!(eventCase_ == 4)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); + } + datasetChangeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 4; + onChanged(); + ; + return datasetChangeBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder> + datasetDeletionBuilder_; + /** + * + * + *
+     * Dataset deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + * + * @return Whether the datasetDeletion field is set. + */ + @java.lang.Override + public boolean hasDatasetDeletion() { + return eventCase_ == 5; + } + /** + * + * + *
+     * Dataset deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + * + * @return The datasetDeletion. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion getDatasetDeletion() { + if (datasetDeletionBuilder_ == null) { + if (eventCase_ == 5) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); + } else { + if (eventCase_ == 5) { + return datasetDeletionBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); + } + } + /** + * + * + *
+     * Dataset deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + */ + public Builder setDatasetDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion value) { + if (datasetDeletionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + datasetDeletionBuilder_.setMessage(value); + } + eventCase_ = 5; + return this; + } + /** + * + * + *
+     * Dataset deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + */ + public Builder setDatasetDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder builderForValue) { + if (datasetDeletionBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + datasetDeletionBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 5; + return this; + } + /** + * + * + *
+     * Dataset deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + */ + public Builder mergeDatasetDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion value) { + if (datasetDeletionBuilder_ == null) { + if (eventCase_ == 5 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 5) { + datasetDeletionBuilder_.mergeFrom(value); + } + datasetDeletionBuilder_.setMessage(value); + } + eventCase_ = 5; + return this; + } + /** + * + * + *
+     * Dataset deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + */ + public Builder clearDatasetDeletion() { + if (datasetDeletionBuilder_ == null) { + if (eventCase_ == 5) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 5) { + eventCase_ = 0; + event_ = null; + } + datasetDeletionBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Dataset deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder + getDatasetDeletionBuilder() { + return getDatasetDeletionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Dataset deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder + getDatasetDeletionOrBuilder() { + if ((eventCase_ == 5) && (datasetDeletionBuilder_ != null)) { + return datasetDeletionBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 5) { + return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); + } + } + /** + * + * + *
+     * Dataset deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder> + getDatasetDeletionFieldBuilder() { + if (datasetDeletionBuilder_ == null) { + if (!(eventCase_ == 5)) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); + } + datasetDeletionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 5; + onChanged(); + ; + return datasetDeletionBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation, + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder> + tableCreationBuilder_; + /** + * + * + *
+     * Table creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + * + * @return Whether the tableCreation field is set. + */ + @java.lang.Override + public boolean hasTableCreation() { + return eventCase_ == 6; + } + /** + * + * + *
+     * Table creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + * + * @return The tableCreation. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation getTableCreation() { + if (tableCreationBuilder_ == null) { + if (eventCase_ == 6) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); + } else { + if (eventCase_ == 6) { + return tableCreationBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); + } + } + /** + * + * + *
+     * Table creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + */ + public Builder setTableCreation( + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation value) { + if (tableCreationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + tableCreationBuilder_.setMessage(value); + } + eventCase_ = 6; + return this; + } + /** + * + * + *
+     * Table creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + */ + public Builder setTableCreation( + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder builderForValue) { + if (tableCreationBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + tableCreationBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 6; + return this; + } + /** + * + * + *
+     * Table creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + */ + public Builder mergeTableCreation( + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation value) { + if (tableCreationBuilder_ == null) { + if (eventCase_ == 6 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableCreation + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 6) { + tableCreationBuilder_.mergeFrom(value); + } + tableCreationBuilder_.setMessage(value); + } + eventCase_ = 6; + return this; + } + /** + * + * + *
+     * Table creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + */ + public Builder clearTableCreation() { + if (tableCreationBuilder_ == null) { + if (eventCase_ == 6) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 6) { + eventCase_ = 0; + event_ = null; + } + tableCreationBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Table creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder + getTableCreationBuilder() { + return getTableCreationFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Table creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder + getTableCreationOrBuilder() { + if ((eventCase_ == 6) && (tableCreationBuilder_ != null)) { + return tableCreationBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 6) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); + } + } + /** + * + * + *
+     * Table creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation, + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder> + getTableCreationFieldBuilder() { + if (tableCreationBuilder_ == null) { + if (!(eventCase_ == 6)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); + } + tableCreationBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation, + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 6; + onChanged(); + ; + return tableCreationBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableChange, + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder> + tableChangeBuilder_; + /** + * + * + *
+     * Table metadata change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + * + * @return Whether the tableChange field is set. + */ + @java.lang.Override + public boolean hasTableChange() { + return eventCase_ == 8; + } + /** + * + * + *
+     * Table metadata change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + * + * @return The tableChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableChange getTableChange() { + if (tableChangeBuilder_ == null) { + if (eventCase_ == 8) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); + } else { + if (eventCase_ == 8) { + return tableChangeBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Table metadata change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + */ + public Builder setTableChange(com.google.cloud.audit.BigQueryAuditMetadata.TableChange value) { + if (tableChangeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + tableChangeBuilder_.setMessage(value); + } + eventCase_ = 8; + return this; + } + /** + * + * + *
+     * Table metadata change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + */ + public Builder setTableChange( + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder builderForValue) { + if (tableChangeBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + tableChangeBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 8; + return this; + } + /** + * + * + *
+     * Table metadata change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + */ + public Builder mergeTableChange( + com.google.cloud.audit.BigQueryAuditMetadata.TableChange value) { + if (tableChangeBuilder_ == null) { + if (eventCase_ == 8 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 8) { + tableChangeBuilder_.mergeFrom(value); + } + tableChangeBuilder_.setMessage(value); + } + eventCase_ = 8; + return this; + } + /** + * + * + *
+     * Table metadata change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + */ + public Builder clearTableChange() { + if (tableChangeBuilder_ == null) { + if (eventCase_ == 8) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 8) { + eventCase_ = 0; + event_ = null; + } + tableChangeBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Table metadata change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder + getTableChangeBuilder() { + return getTableChangeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Table metadata change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder + getTableChangeOrBuilder() { + if ((eventCase_ == 8) && (tableChangeBuilder_ != null)) { + return tableChangeBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 8) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Table metadata change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableChange, + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder> + getTableChangeFieldBuilder() { + if (tableChangeBuilder_ == null) { + if (!(eventCase_ == 8)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); + } + tableChangeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableChange, + com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 8; + onChanged(); + ; + return tableChangeBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder> + tableDeletionBuilder_; + /** + * + * + *
+     * Table deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + * + * @return Whether the tableDeletion field is set. + */ + @java.lang.Override + public boolean hasTableDeletion() { + return eventCase_ == 9; + } + /** + * + * + *
+     * Table deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + * + * @return The tableDeletion. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion getTableDeletion() { + if (tableDeletionBuilder_ == null) { + if (eventCase_ == 9) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); + } else { + if (eventCase_ == 9) { + return tableDeletionBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); + } + } + /** + * + * + *
+     * Table deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + */ + public Builder setTableDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion value) { + if (tableDeletionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + tableDeletionBuilder_.setMessage(value); + } + eventCase_ = 9; + return this; + } + /** + * + * + *
+     * Table deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + */ + public Builder setTableDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder builderForValue) { + if (tableDeletionBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + tableDeletionBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 9; + return this; + } + /** + * + * + *
+     * Table deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + */ + public Builder mergeTableDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion value) { + if (tableDeletionBuilder_ == null) { + if (eventCase_ == 9 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 9) { + tableDeletionBuilder_.mergeFrom(value); + } + tableDeletionBuilder_.setMessage(value); + } + eventCase_ = 9; + return this; + } + /** + * + * + *
+     * Table deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + */ + public Builder clearTableDeletion() { + if (tableDeletionBuilder_ == null) { + if (eventCase_ == 9) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 9) { + eventCase_ = 0; + event_ = null; + } + tableDeletionBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Table deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder + getTableDeletionBuilder() { + return getTableDeletionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Table deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder + getTableDeletionOrBuilder() { + if ((eventCase_ == 9) && (tableDeletionBuilder_ != null)) { + return tableDeletionBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 9) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); + } + } + /** + * + * + *
+     * Table deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder> + getTableDeletionFieldBuilder() { + if (tableDeletionBuilder_ == null) { + if (!(eventCase_ == 9)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); + } + tableDeletionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 9; + onChanged(); + ; + return tableDeletionBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder> + tableDataReadBuilder_; + /** + * + * + *
+     * Table data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + * + * @return Whether the tableDataRead field is set. + */ + @java.lang.Override + public boolean hasTableDataRead() { + return eventCase_ == 10; + } + /** + * + * + *
+     * Table data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + * + * @return The tableDataRead. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead getTableDataRead() { + if (tableDataReadBuilder_ == null) { + if (eventCase_ == 10) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); + } else { + if (eventCase_ == 10) { + return tableDataReadBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); + } + } + /** + * + * + *
+     * Table data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + */ + public Builder setTableDataRead( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead value) { + if (tableDataReadBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + tableDataReadBuilder_.setMessage(value); + } + eventCase_ = 10; + return this; + } + /** + * + * + *
+     * Table data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + */ + public Builder setTableDataRead( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder builderForValue) { + if (tableDataReadBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + tableDataReadBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 10; + return this; + } + /** + * + * + *
+     * Table data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + */ + public Builder mergeTableDataRead( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead value) { + if (tableDataReadBuilder_ == null) { + if (eventCase_ == 10 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 10) { + tableDataReadBuilder_.mergeFrom(value); + } + tableDataReadBuilder_.setMessage(value); + } + eventCase_ = 10; + return this; + } + /** + * + * + *
+     * Table data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + */ + public Builder clearTableDataRead() { + if (tableDataReadBuilder_ == null) { + if (eventCase_ == 10) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 10) { + eventCase_ = 0; + event_ = null; + } + tableDataReadBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Table data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder + getTableDataReadBuilder() { + return getTableDataReadFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Table data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder + getTableDataReadOrBuilder() { + if ((eventCase_ == 10) && (tableDataReadBuilder_ != null)) { + return tableDataReadBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 10) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); + } + } + /** + * + * + *
+     * Table data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder> + getTableDataReadFieldBuilder() { + if (tableDataReadBuilder_ == null) { + if (!(eventCase_ == 10)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); + } + tableDataReadBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 10; + onChanged(); + ; + return tableDataReadBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder> + tableDataChangeBuilder_; + /** + * + * + *
+     * Table data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + * + * @return Whether the tableDataChange field is set. + */ + @java.lang.Override + public boolean hasTableDataChange() { + return eventCase_ == 11; + } + /** + * + * + *
+     * Table data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + * + * @return The tableDataChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange getTableDataChange() { + if (tableDataChangeBuilder_ == null) { + if (eventCase_ == 11) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); + } else { + if (eventCase_ == 11) { + return tableDataChangeBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Table data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + */ + public Builder setTableDataChange( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange value) { + if (tableDataChangeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + tableDataChangeBuilder_.setMessage(value); + } + eventCase_ = 11; + return this; + } + /** + * + * + *
+     * Table data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + */ + public Builder setTableDataChange( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder builderForValue) { + if (tableDataChangeBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + tableDataChangeBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 11; + return this; + } + /** + * + * + *
+     * Table data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + */ + public Builder mergeTableDataChange( + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange value) { + if (tableDataChangeBuilder_ == null) { + if (eventCase_ == 11 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 11) { + tableDataChangeBuilder_.mergeFrom(value); + } + tableDataChangeBuilder_.setMessage(value); + } + eventCase_ = 11; + return this; + } + /** + * + * + *
+     * Table data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + */ + public Builder clearTableDataChange() { + if (tableDataChangeBuilder_ == null) { + if (eventCase_ == 11) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 11) { + eventCase_ = 0; + event_ = null; + } + tableDataChangeBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Table data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder + getTableDataChangeBuilder() { + return getTableDataChangeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Table data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder + getTableDataChangeOrBuilder() { + if ((eventCase_ == 11) && (tableDataChangeBuilder_ != null)) { + return tableDataChangeBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 11) { + return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Table data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder> + getTableDataChangeFieldBuilder() { + if (tableDataChangeBuilder_ == null) { + if (!(eventCase_ == 11)) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); + } + tableDataChangeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 11; + onChanged(); + ; + return tableDataChangeBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder> + modelDeletionBuilder_; + /** + * + * + *
+     * Model deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + * + * @return Whether the modelDeletion field is set. + */ + @java.lang.Override + public boolean hasModelDeletion() { + return eventCase_ == 12; + } + /** + * + * + *
+     * Model deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + * + * @return The modelDeletion. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion getModelDeletion() { + if (modelDeletionBuilder_ == null) { + if (eventCase_ == 12) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); + } else { + if (eventCase_ == 12) { + return modelDeletionBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); + } + } + /** + * + * + *
+     * Model deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + */ + public Builder setModelDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion value) { + if (modelDeletionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + modelDeletionBuilder_.setMessage(value); + } + eventCase_ = 12; + return this; + } + /** + * + * + *
+     * Model deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + */ + public Builder setModelDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder builderForValue) { + if (modelDeletionBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + modelDeletionBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 12; + return this; + } + /** + * + * + *
+     * Model deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + */ + public Builder mergeModelDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion value) { + if (modelDeletionBuilder_ == null) { + if (eventCase_ == 12 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 12) { + modelDeletionBuilder_.mergeFrom(value); + } + modelDeletionBuilder_.setMessage(value); + } + eventCase_ = 12; + return this; + } + /** + * + * + *
+     * Model deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + */ + public Builder clearModelDeletion() { + if (modelDeletionBuilder_ == null) { + if (eventCase_ == 12) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 12) { + eventCase_ = 0; + event_ = null; + } + modelDeletionBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Model deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder + getModelDeletionBuilder() { + return getModelDeletionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Model deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder + getModelDeletionOrBuilder() { + if ((eventCase_ == 12) && (modelDeletionBuilder_ != null)) { + return modelDeletionBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 12) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); + } + } + /** + * + * + *
+     * Model deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder> + getModelDeletionFieldBuilder() { + if (modelDeletionBuilder_ == null) { + if (!(eventCase_ == 12)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); + } + modelDeletionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 12; + onChanged(); + ; + return modelDeletionBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation, + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder> + modelCreationBuilder_; + /** + * + * + *
+     * Model creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + * + * @return Whether the modelCreation field is set. + */ + @java.lang.Override + public boolean hasModelCreation() { + return eventCase_ == 13; + } + /** + * + * + *
+     * Model creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + * + * @return The modelCreation. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation getModelCreation() { + if (modelCreationBuilder_ == null) { + if (eventCase_ == 13) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); + } else { + if (eventCase_ == 13) { + return modelCreationBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); + } + } + /** + * + * + *
+     * Model creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + */ + public Builder setModelCreation( + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation value) { + if (modelCreationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + modelCreationBuilder_.setMessage(value); + } + eventCase_ = 13; + return this; + } + /** + * + * + *
+     * Model creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + */ + public Builder setModelCreation( + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder builderForValue) { + if (modelCreationBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + modelCreationBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 13; + return this; + } + /** + * + * + *
+     * Model creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + */ + public Builder mergeModelCreation( + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation value) { + if (modelCreationBuilder_ == null) { + if (eventCase_ == 13 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 13) { + modelCreationBuilder_.mergeFrom(value); + } + modelCreationBuilder_.setMessage(value); + } + eventCase_ = 13; + return this; + } + /** + * + * + *
+     * Model creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + */ + public Builder clearModelCreation() { + if (modelCreationBuilder_ == null) { + if (eventCase_ == 13) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 13) { + eventCase_ = 0; + event_ = null; + } + modelCreationBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Model creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder + getModelCreationBuilder() { + return getModelCreationFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Model creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder + getModelCreationOrBuilder() { + if ((eventCase_ == 13) && (modelCreationBuilder_ != null)) { + return modelCreationBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 13) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); + } + } + /** + * + * + *
+     * Model creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation, + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder> + getModelCreationFieldBuilder() { + if (modelCreationBuilder_ == null) { + if (!(eventCase_ == 13)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); + } + modelCreationBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation, + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 13; + onChanged(); + ; + return modelCreationBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange, + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder> + modelMetadataChangeBuilder_; + /** + * + * + *
+     * Model metadata change event.
+     * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + * + * @return Whether the modelMetadataChange field is set. + */ + @java.lang.Override + public boolean hasModelMetadataChange() { + return eventCase_ == 14; + } + /** + * + * + *
+     * Model metadata change event.
+     * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + * + * @return The modelMetadataChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + getModelMetadataChange() { + if (modelMetadataChangeBuilder_ == null) { + if (eventCase_ == 14) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + .getDefaultInstance(); + } else { + if (eventCase_ == 14) { + return modelMetadataChangeBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + .getDefaultInstance(); + } + } + /** + * + * + *
+     * Model metadata change event.
+     * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + */ + public Builder setModelMetadataChange( + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange value) { + if (modelMetadataChangeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + modelMetadataChangeBuilder_.setMessage(value); + } + eventCase_ = 14; + return this; + } + /** + * + * + *
+     * Model metadata change event.
+     * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + */ + public Builder setModelMetadataChange( + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder builderForValue) { + if (modelMetadataChangeBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + modelMetadataChangeBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 14; + return this; + } + /** + * + * + *
+     * Model metadata change event.
+     * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + */ + public Builder mergeModelMetadataChange( + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange value) { + if (modelMetadataChangeBuilder_ == null) { + if (eventCase_ == 14 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 14) { + modelMetadataChangeBuilder_.mergeFrom(value); + } + modelMetadataChangeBuilder_.setMessage(value); + } + eventCase_ = 14; + return this; + } + /** + * + * + *
+     * Model metadata change event.
+     * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + */ + public Builder clearModelMetadataChange() { + if (modelMetadataChangeBuilder_ == null) { + if (eventCase_ == 14) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 14) { + eventCase_ = 0; + event_ = null; + } + modelMetadataChangeBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Model metadata change event.
+     * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder + getModelMetadataChangeBuilder() { + return getModelMetadataChangeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Model metadata change event.
+     * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder + getModelMetadataChangeOrBuilder() { + if ((eventCase_ == 14) && (modelMetadataChangeBuilder_ != null)) { + return modelMetadataChangeBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 14) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange + .getDefaultInstance(); + } + } + /** + * + * + *
+     * Model metadata change event.
+     * 
+ * + * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange, + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder> + getModelMetadataChangeFieldBuilder() { + if (modelMetadataChangeBuilder_ == null) { + if (!(eventCase_ == 14)) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.getDefaultInstance(); + } + modelMetadataChangeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange, + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 14; + onChanged(); + ; + return modelMetadataChangeBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder> + modelDataChangeBuilder_; + /** + * + * + *
+     * Model data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + * + * @return Whether the modelDataChange field is set. + */ + @java.lang.Override + public boolean hasModelDataChange() { + return eventCase_ == 15; + } + /** + * + * + *
+     * Model data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + * + * @return The modelDataChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange getModelDataChange() { + if (modelDataChangeBuilder_ == null) { + if (eventCase_ == 15) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); + } else { + if (eventCase_ == 15) { + return modelDataChangeBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Model data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + */ + public Builder setModelDataChange( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange value) { + if (modelDataChangeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + modelDataChangeBuilder_.setMessage(value); + } + eventCase_ = 15; + return this; + } + /** + * + * + *
+     * Model data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + */ + public Builder setModelDataChange( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder builderForValue) { + if (modelDataChangeBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + modelDataChangeBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 15; + return this; + } + /** + * + * + *
+     * Model data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + */ + public Builder mergeModelDataChange( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange value) { + if (modelDataChangeBuilder_ == null) { + if (eventCase_ == 15 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 15) { + modelDataChangeBuilder_.mergeFrom(value); + } + modelDataChangeBuilder_.setMessage(value); + } + eventCase_ = 15; + return this; + } + /** + * + * + *
+     * Model data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + */ + public Builder clearModelDataChange() { + if (modelDataChangeBuilder_ == null) { + if (eventCase_ == 15) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 15) { + eventCase_ = 0; + event_ = null; + } + modelDataChangeBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Model data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + */ + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder + getModelDataChangeBuilder() { + return getModelDataChangeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Model data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder + getModelDataChangeOrBuilder() { + if ((eventCase_ == 15) && (modelDataChangeBuilder_ != null)) { + return modelDataChangeBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 15) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Model data change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder> + getModelDataChangeFieldBuilder() { + if (modelDataChangeBuilder_ == null) { + if (!(eventCase_ == 15)) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); + } + modelDataChangeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 15; + onChanged(); + ; + return modelDataChangeBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder> + modelDataReadBuilder_; + /** + * + * + *
+     * Model data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + * + * @return Whether the modelDataRead field is set. + */ + @java.lang.Override + public boolean hasModelDataRead() { + return eventCase_ == 19; + } + /** + * + * + *
+     * Model data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + * + * @return The modelDataRead. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead getModelDataRead() { + if (modelDataReadBuilder_ == null) { + if (eventCase_ == 19) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); + } else { + if (eventCase_ == 19) { + return modelDataReadBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); + } + } + /** + * + * + *
+     * Model data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + */ + public Builder setModelDataRead( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead value) { + if (modelDataReadBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + modelDataReadBuilder_.setMessage(value); + } + eventCase_ = 19; + return this; + } + /** + * + * + *
+     * Model data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + */ + public Builder setModelDataRead( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder builderForValue) { + if (modelDataReadBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + modelDataReadBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 19; + return this; + } + /** + * + * + *
+     * Model data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + */ + public Builder mergeModelDataRead( + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead value) { + if (modelDataReadBuilder_ == null) { + if (eventCase_ == 19 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 19) { + modelDataReadBuilder_.mergeFrom(value); + } + modelDataReadBuilder_.setMessage(value); + } + eventCase_ = 19; + return this; + } + /** + * + * + *
+     * Model data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + */ + public Builder clearModelDataRead() { + if (modelDataReadBuilder_ == null) { + if (eventCase_ == 19) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 19) { + eventCase_ = 0; + event_ = null; + } + modelDataReadBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Model data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder + getModelDataReadBuilder() { + return getModelDataReadFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Model data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder + getModelDataReadOrBuilder() { + if ((eventCase_ == 19) && (modelDataReadBuilder_ != null)) { + return modelDataReadBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 19) { + return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); + } + } + /** + * + * + *
+     * Model data read event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder> + getModelDataReadFieldBuilder() { + if (modelDataReadBuilder_ == null) { + if (!(eventCase_ == 19)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); + } + modelDataReadBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 19; + onChanged(); + ; + return modelDataReadBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder> + routineCreationBuilder_; + /** + * + * + *
+     * Routine creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + * + * @return Whether the routineCreation field is set. + */ + @java.lang.Override + public boolean hasRoutineCreation() { + return eventCase_ == 16; + } + /** + * + * + *
+     * Routine creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + * + * @return The routineCreation. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation getRoutineCreation() { + if (routineCreationBuilder_ == null) { + if (eventCase_ == 16) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); + } else { + if (eventCase_ == 16) { + return routineCreationBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); + } + } + /** + * + * + *
+     * Routine creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + */ + public Builder setRoutineCreation( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation value) { + if (routineCreationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + routineCreationBuilder_.setMessage(value); + } + eventCase_ = 16; + return this; + } + /** + * + * + *
+     * Routine creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + */ + public Builder setRoutineCreation( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder builderForValue) { + if (routineCreationBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + routineCreationBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 16; + return this; + } + /** + * + * + *
+     * Routine creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + */ + public Builder mergeRoutineCreation( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation value) { + if (routineCreationBuilder_ == null) { + if (eventCase_ == 16 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 16) { + routineCreationBuilder_.mergeFrom(value); + } + routineCreationBuilder_.setMessage(value); + } + eventCase_ = 16; + return this; + } + /** + * + * + *
+     * Routine creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + */ + public Builder clearRoutineCreation() { + if (routineCreationBuilder_ == null) { + if (eventCase_ == 16) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 16) { + eventCase_ = 0; + event_ = null; + } + routineCreationBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Routine creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder + getRoutineCreationBuilder() { + return getRoutineCreationFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Routine creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder + getRoutineCreationOrBuilder() { + if ((eventCase_ == 16) && (routineCreationBuilder_ != null)) { + return routineCreationBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 16) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); + } + } + /** + * + * + *
+     * Routine creation event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder> + getRoutineCreationFieldBuilder() { + if (routineCreationBuilder_ == null) { + if (!(eventCase_ == 16)) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); + } + routineCreationBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 16; + onChanged(); + ; + return routineCreationBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder> + routineChangeBuilder_; + /** + * + * + *
+     * Routine change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + * + * @return Whether the routineChange field is set. + */ + @java.lang.Override + public boolean hasRoutineChange() { + return eventCase_ == 17; + } + /** + * + * + *
+     * Routine change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + * + * @return The routineChange. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange getRoutineChange() { + if (routineChangeBuilder_ == null) { + if (eventCase_ == 17) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); + } else { + if (eventCase_ == 17) { + return routineChangeBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Routine change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + */ + public Builder setRoutineChange( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange value) { + if (routineChangeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + routineChangeBuilder_.setMessage(value); + } + eventCase_ = 17; + return this; + } + /** + * + * + *
+     * Routine change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + */ + public Builder setRoutineChange( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder builderForValue) { + if (routineChangeBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + routineChangeBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 17; + return this; + } + /** + * + * + *
+     * Routine change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + */ + public Builder mergeRoutineChange( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange value) { + if (routineChangeBuilder_ == null) { + if (eventCase_ == 17 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 17) { + routineChangeBuilder_.mergeFrom(value); + } + routineChangeBuilder_.setMessage(value); + } + eventCase_ = 17; + return this; + } + /** + * + * + *
+     * Routine change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + */ + public Builder clearRoutineChange() { + if (routineChangeBuilder_ == null) { + if (eventCase_ == 17) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 17) { + eventCase_ = 0; + event_ = null; + } + routineChangeBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Routine change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder + getRoutineChangeBuilder() { + return getRoutineChangeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Routine change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder + getRoutineChangeOrBuilder() { + if ((eventCase_ == 17) && (routineChangeBuilder_ != null)) { + return routineChangeBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 17) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); + } + } + /** + * + * + *
+     * Routine change event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder> + getRoutineChangeFieldBuilder() { + if (routineChangeBuilder_ == null) { + if (!(eventCase_ == 17)) { + event_ = com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); + } + routineChangeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 17; + onChanged(); + ; + return routineChangeBuilder_; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder> + routineDeletionBuilder_; + /** + * + * + *
+     * Routine deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + * + * @return Whether the routineDeletion field is set. + */ + @java.lang.Override + public boolean hasRoutineDeletion() { + return eventCase_ == 18; + } + /** + * + * + *
+     * Routine deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + * + * @return The routineDeletion. + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion getRoutineDeletion() { + if (routineDeletionBuilder_ == null) { + if (eventCase_ == 18) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); + } else { + if (eventCase_ == 18) { + return routineDeletionBuilder_.getMessage(); + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); + } + } + /** + * + * + *
+     * Routine deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + */ + public Builder setRoutineDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion value) { + if (routineDeletionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + event_ = value; + onChanged(); + } else { + routineDeletionBuilder_.setMessage(value); + } + eventCase_ = 18; + return this; + } + /** + * + * + *
+     * Routine deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + */ + public Builder setRoutineDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder builderForValue) { + if (routineDeletionBuilder_ == null) { + event_ = builderForValue.build(); + onChanged(); + } else { + routineDeletionBuilder_.setMessage(builderForValue.build()); + } + eventCase_ = 18; + return this; + } + /** + * + * + *
+     * Routine deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + */ + public Builder mergeRoutineDeletion( + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion value) { + if (routineDeletionBuilder_ == null) { + if (eventCase_ == 18 + && event_ + != com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion + .getDefaultInstance()) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.newBuilder( + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_) + .mergeFrom(value) + .buildPartial(); + } else { + event_ = value; + } + onChanged(); + } else { + if (eventCase_ == 18) { + routineDeletionBuilder_.mergeFrom(value); + } + routineDeletionBuilder_.setMessage(value); + } + eventCase_ = 18; + return this; + } + /** + * + * + *
+     * Routine deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + */ + public Builder clearRoutineDeletion() { + if (routineDeletionBuilder_ == null) { + if (eventCase_ == 18) { + eventCase_ = 0; + event_ = null; + onChanged(); + } + } else { + if (eventCase_ == 18) { + eventCase_ = 0; + event_ = null; + } + routineDeletionBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Routine deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + */ + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder + getRoutineDeletionBuilder() { + return getRoutineDeletionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Routine deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + */ + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder + getRoutineDeletionOrBuilder() { + if ((eventCase_ == 18) && (routineDeletionBuilder_ != null)) { + return routineDeletionBuilder_.getMessageOrBuilder(); + } else { + if (eventCase_ == 18) { + return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_; + } + return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); + } + } + /** + * + * + *
+     * Routine deletion event.
+     * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder> + getRoutineDeletionFieldBuilder() { + if (routineDeletionBuilder_ == null) { + if (!(eventCase_ == 18)) { + event_ = + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); + } + routineDeletionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder, + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder>( + (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_, + getParentForChildren(), + isClean()); + event_ = null; + } + eventCase_ = 18; + onChanged(); + ; + return routineDeletionBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata) + private static final com.google.cloud.audit.BigQueryAuditMetadata DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata(); + } + + public static com.google.cloud.audit.BigQueryAuditMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public BigQueryAuditMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new BigQueryAuditMetadata(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.audit.BigQueryAuditMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataOrBuilder.java b/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataOrBuilder.java new file mode 100644 index 00000000..b81239a0 --- /dev/null +++ b/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataOrBuilder.java @@ -0,0 +1,667 @@ +/* + * 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/cloud/audit/bigquery_audit_metadata.proto + +package com.google.cloud.audit; + +public interface BigQueryAuditMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Job insertion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + * + * @return Whether the jobInsertion field is set. + */ + boolean hasJobInsertion(); + /** + * + * + *
+   * Job insertion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + * + * @return The jobInsertion. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getJobInsertion(); + /** + * + * + *
+   * Job insertion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder getJobInsertionOrBuilder(); + + /** + * + * + *
+   * Job state change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + * + * @return Whether the jobChange field is set. + */ + boolean hasJobChange(); + /** + * + * + *
+   * Job state change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + * + * @return The jobChange. + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobChange getJobChange(); + /** + * + * + *
+   * Job state change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; + */ + com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder getJobChangeOrBuilder(); + + /** + * + * + *
+   * Dataset creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + * + * @return Whether the datasetCreation field is set. + */ + boolean hasDatasetCreation(); + /** + * + * + *
+   * Dataset creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + * + * @return The datasetCreation. + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation getDatasetCreation(); + /** + * + * + *
+   * Dataset creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder + getDatasetCreationOrBuilder(); + + /** + * + * + *
+   * Dataset change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + * + * @return Whether the datasetChange field is set. + */ + boolean hasDatasetChange(); + /** + * + * + *
+   * Dataset change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + * + * @return The datasetChange. + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange getDatasetChange(); + /** + * + * + *
+   * Dataset change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder getDatasetChangeOrBuilder(); + + /** + * + * + *
+   * Dataset deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + * + * @return Whether the datasetDeletion field is set. + */ + boolean hasDatasetDeletion(); + /** + * + * + *
+   * Dataset deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + * + * @return The datasetDeletion. + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion getDatasetDeletion(); + /** + * + * + *
+   * Dataset deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; + */ + com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder + getDatasetDeletionOrBuilder(); + + /** + * + * + *
+   * Table creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + * + * @return Whether the tableCreation field is set. + */ + boolean hasTableCreation(); + /** + * + * + *
+   * Table creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + * + * @return The tableCreation. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableCreation getTableCreation(); + /** + * + * + *
+   * Table creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder getTableCreationOrBuilder(); + + /** + * + * + *
+   * Table metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + * + * @return Whether the tableChange field is set. + */ + boolean hasTableChange(); + /** + * + * + *
+   * Table metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + * + * @return The tableChange. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableChange getTableChange(); + /** + * + * + *
+   * Table metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder getTableChangeOrBuilder(); + + /** + * + * + *
+   * Table deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + * + * @return Whether the tableDeletion field is set. + */ + boolean hasTableDeletion(); + /** + * + * + *
+   * Table deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + * + * @return The tableDeletion. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion getTableDeletion(); + /** + * + * + *
+   * Table deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder getTableDeletionOrBuilder(); + + /** + * + * + *
+   * Table data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + * + * @return Whether the tableDataRead field is set. + */ + boolean hasTableDataRead(); + /** + * + * + *
+   * Table data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + * + * @return The tableDataRead. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead getTableDataRead(); + /** + * + * + *
+   * Table data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder getTableDataReadOrBuilder(); + + /** + * + * + *
+   * Table data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + * @return Whether the tableDataChange field is set. + */ + boolean hasTableDataChange(); + /** + * + * + *
+   * Table data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + * + * @return The tableDataChange. + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange getTableDataChange(); + /** + * + * + *
+   * Table data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; + */ + com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder + getTableDataChangeOrBuilder(); + + /** + * + * + *
+   * Model deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + * + * @return Whether the modelDeletion field is set. + */ + boolean hasModelDeletion(); + /** + * + * + *
+   * Model deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + * + * @return The modelDeletion. + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion getModelDeletion(); + /** + * + * + *
+   * Model deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder getModelDeletionOrBuilder(); + + /** + * + * + *
+   * Model creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + * + * @return Whether the modelCreation field is set. + */ + boolean hasModelCreation(); + /** + * + * + *
+   * Model creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + * + * @return The modelCreation. + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation getModelCreation(); + /** + * + * + *
+   * Model creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder getModelCreationOrBuilder(); + + /** + * + * + *
+   * Model metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + * + * @return Whether the modelMetadataChange field is set. + */ + boolean hasModelMetadataChange(); + /** + * + * + *
+   * Model metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + * + * @return The modelMetadataChange. + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange getModelMetadataChange(); + /** + * + * + *
+   * Model metadata change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; + * + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder + getModelMetadataChangeOrBuilder(); + + /** + * + * + *
+   * Model data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + * @return Whether the modelDataChange field is set. + */ + boolean hasModelDataChange(); + /** + * + * + *
+   * Model data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + * + * @return The modelDataChange. + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange getModelDataChange(); + /** + * + * + *
+   * Model data change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder + getModelDataChangeOrBuilder(); + + /** + * + * + *
+   * Model data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + * + * @return Whether the modelDataRead field is set. + */ + boolean hasModelDataRead(); + /** + * + * + *
+   * Model data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + * + * @return The modelDataRead. + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead getModelDataRead(); + /** + * + * + *
+   * Model data read event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; + */ + com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder getModelDataReadOrBuilder(); + + /** + * + * + *
+   * Routine creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + * + * @return Whether the routineCreation field is set. + */ + boolean hasRoutineCreation(); + /** + * + * + *
+   * Routine creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + * + * @return The routineCreation. + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation getRoutineCreation(); + /** + * + * + *
+   * Routine creation event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder + getRoutineCreationOrBuilder(); + + /** + * + * + *
+   * Routine change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + * + * @return Whether the routineChange field is set. + */ + boolean hasRoutineChange(); + /** + * + * + *
+   * Routine change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + * + * @return The routineChange. + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange getRoutineChange(); + /** + * + * + *
+   * Routine change event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder getRoutineChangeOrBuilder(); + + /** + * + * + *
+   * Routine deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + * + * @return Whether the routineDeletion field is set. + */ + boolean hasRoutineDeletion(); + /** + * + * + *
+   * Routine deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + * + * @return The routineDeletion. + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion getRoutineDeletion(); + /** + * + * + *
+   * Routine deletion event.
+   * 
+ * + * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; + */ + com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder + getRoutineDeletionOrBuilder(); + + public com.google.cloud.audit.BigQueryAuditMetadata.EventCase getEventCase(); +} diff --git a/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataProto.java b/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataProto.java new file mode 100644 index 00000000..0b7c50e9 --- /dev/null +++ b/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataProto.java @@ -0,0 +1,1033 @@ +/* + * 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/cloud/audit/bigquery_audit_metadata.proto + +package com.google.cloud.audit; + +public final class BigQueryAuditMetadataProto { + private BigQueryAuditMetadataProto() {} + + 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_cloud_audit_BigQueryAuditMetadata_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n0google/cloud/audit/bigquery_audit_meta" + + "data.proto\022\022google.cloud.audit\032\032google/i" + + "am/v1/policy.proto\032\036google/protobuf/dura" + + "tion.proto\032\037google/protobuf/timestamp.pr" + + "oto\032\027google/rpc/status.proto\"\301a\n\025BigQuer" + + "yAuditMetadata\022O\n\rjob_insertion\030\001 \001(\01326." + + "google.cloud.audit.BigQueryAuditMetadata" + + ".JobInsertionH\000\022I\n\njob_change\030\002 \001(\01323.go" + + "ogle.cloud.audit.BigQueryAuditMetadata.J" + + "obChangeH\000\022U\n\020dataset_creation\030\003 \001(\01329.g" + + "oogle.cloud.audit.BigQueryAuditMetadata." + + "DatasetCreationH\000\022Q\n\016dataset_change\030\004 \001(" + + "\01327.google.cloud.audit.BigQueryAuditMeta" + + "data.DatasetChangeH\000\022U\n\020dataset_deletion" + + "\030\005 \001(\01329.google.cloud.audit.BigQueryAudi" + + "tMetadata.DatasetDeletionH\000\022Q\n\016table_cre" + + "ation\030\006 \001(\01327.google.cloud.audit.BigQuer" + + "yAuditMetadata.TableCreationH\000\022M\n\014table_" + + "change\030\010 \001(\01325.google.cloud.audit.BigQue" + + "ryAuditMetadata.TableChangeH\000\022Q\n\016table_d" + + "eletion\030\t \001(\01327.google.cloud.audit.BigQu" + + "eryAuditMetadata.TableDeletionH\000\022R\n\017tabl" + + "e_data_read\030\n \001(\01327.google.cloud.audit.B" + + "igQueryAuditMetadata.TableDataReadH\000\022V\n\021" + + "table_data_change\030\013 \001(\01329.google.cloud.a" + + "udit.BigQueryAuditMetadata.TableDataChan" + + "geH\000\022Q\n\016model_deletion\030\014 \001(\01327.google.cl" + + "oud.audit.BigQueryAuditMetadata.ModelDel" + + "etionH\000\022Q\n\016model_creation\030\r \001(\01327.google" + + ".cloud.audit.BigQueryAuditMetadata.Model" + + "CreationH\000\022^\n\025model_metadata_change\030\016 \001(" + + "\0132=.google.cloud.audit.BigQueryAuditMeta" + + "data.ModelMetadataChangeH\000\022V\n\021model_data" + + "_change\030\017 \001(\01329.google.cloud.audit.BigQu" + + "eryAuditMetadata.ModelDataChangeH\000\022R\n\017mo" + + "del_data_read\030\023 \001(\01327.google.cloud.audit" + + ".BigQueryAuditMetadata.ModelDataReadH\000\022U" + + "\n\020routine_creation\030\020 \001(\01329.google.cloud." + + "audit.BigQueryAuditMetadata.RoutineCreat" + + "ionH\000\022Q\n\016routine_change\030\021 \001(\01327.google.c" + + "loud.audit.BigQueryAuditMetadata.Routine" + + "ChangeH\000\022U\n\020routine_deletion\030\022 \001(\01329.goo" + + "gle.cloud.audit.BigQueryAuditMetadata.Ro" + + "utineDeletionH\000\032\346\001\n\014JobInsertion\022:\n\003job\030" + + "\001 \001(\0132-.google.cloud.audit.BigQueryAudit" + + "Metadata.Job\022M\n\006reason\030\002 \001(\0162=.google.cl" + + "oud.audit.BigQueryAuditMetadata.JobInser" + + "tion.Reason\"K\n\006Reason\022\026\n\022REASON_UNSPECIF" + + "IED\020\000\022\026\n\022JOB_INSERT_REQUEST\020\001\022\021\n\rQUERY_R" + + "EQUEST\020\002\032\316\001\n\tJobChange\022B\n\006before\030\001 \001(\01622" + + ".google.cloud.audit.BigQueryAuditMetadat" + + "a.JobState\022A\n\005after\030\002 \001(\01622.google.cloud" + + ".audit.BigQueryAuditMetadata.JobState\022:\n" + + "\003job\030\003 \001(\0132-.google.cloud.audit.BigQuery" + + "AuditMetadata.Job\032\362\001\n\017DatasetCreation\022B\n" + + "\007dataset\030\001 \001(\01321.google.cloud.audit.BigQ" + + "ueryAuditMetadata.Dataset\022P\n\006reason\030\002 \001(" + + "\0162@.google.cloud.audit.BigQueryAuditMeta" + + "data.DatasetCreation.Reason\022\020\n\010job_name\030" + + "\003 \001(\t\"7\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022" + + "\n\n\006CREATE\020\001\022\t\n\005QUERY\020\002\032\202\002\n\rDatasetChange" + + "\022B\n\007dataset\030\001 \001(\01321.google.cloud.audit.B" + + "igQueryAuditMetadata.Dataset\022N\n\006reason\030\002" + + " \001(\0162>.google.cloud.audit.BigQueryAuditM" + + "etadata.DatasetChange.Reason\022\020\n\010job_name" + + "\030\003 \001(\t\"K\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000" + + "\022\n\n\006UPDATE\020\001\022\022\n\016SET_IAM_POLICY\020\002\022\t\n\005QUER" + + "Y\020\003\032\256\001\n\017DatasetDeletion\022P\n\006reason\030\001 \001(\0162" + + "@.google.cloud.audit.BigQueryAuditMetada" + + "ta.DatasetDeletion.Reason\022\020\n\010job_name\030\002 " + + "\001(\t\"7\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022\n\n" + + "\006DELETE\020\001\022\t\n\005QUERY\020\002\032\201\002\n\rTableCreation\022>" + + "\n\005table\030\001 \001(\0132/.google.cloud.audit.BigQu" + + "eryAuditMetadata.Table\022N\n\006reason\030\003 \001(\0162>" + + ".google.cloud.audit.BigQueryAuditMetadat" + + "a.TableCreation.Reason\022\020\n\010job_name\030\004 \001(\t" + + "\"N\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022\007\n\003JO" + + "B\020\001\022\t\n\005QUERY\020\002\022\030\n\024TABLE_INSERT_REQUEST\020\003" + + "\032\336\001\n\rModelCreation\022>\n\005model\030\001 \001(\0132/.goog" + + "le.cloud.audit.BigQueryAuditMetadata.Mod" + + "el\022N\n\006reason\030\003 \001(\0162>.google.cloud.audit." + + "BigQueryAuditMetadata.ModelCreation.Reas" + + "on\022\020\n\010job_name\030\004 \001(\t\"+\n\006Reason\022\026\n\022REASON" + + "_UNSPECIFIED\020\000\022\t\n\005QUERY\020\002\032\202\002\n\017RoutineCre" + + "ation\022B\n\007routine\030\001 \001(\01321.google.cloud.au" + + "dit.BigQueryAuditMetadata.Routine\022P\n\006rea" + + "son\030\003 \001(\0162@.google.cloud.audit.BigQueryA" + + "uditMetadata.RoutineCreation.Reason\022\020\n\010j" + + "ob_name\030\004 \001(\t\"G\n\006Reason\022\026\n\022REASON_UNSPEC" + + "IFIED\020\000\022\t\n\005QUERY\020\001\022\032\n\026ROUTINE_INSERT_REQ" + + "UEST\020\002\032\227\003\n\rTableDataRead\022\016\n\006fields\030\002 \003(\t" + + "\022\030\n\020fields_truncated\030\010 \001(\010\022\023\n\013policy_tag" + + "s\030\t \003(\t\022\035\n\025policy_tags_truncated\030\n \001(\010\022N" + + "\n\006reason\030\003 \001(\0162>.google.cloud.audit.BigQ" + + "ueryAuditMetadata.TableDataRead.Reason\022\020" + + "\n\010job_name\030\004 \001(\t\022\024\n\014session_name\030\005 \001(\t\"\257" + + "\001\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022\007\n\003JOB" + + "\020\001\022\032\n\026TABLEDATA_LIST_REQUEST\020\002\022\035\n\031GET_QU" + + "ERY_RESULTS_REQUEST\020\003\022\021\n\rQUERY_REQUEST\020\004" + + "\022\027\n\023CREATE_READ_SESSION\020\005\022\035\n\031MATERIALIZE" + + "D_VIEW_REFRESH\020\006\032\220\002\n\013TableChange\022>\n\005tabl" + + "e\030\001 \001(\0132/.google.cloud.audit.BigQueryAud" + + "itMetadata.Table\022\021\n\ttruncated\030\004 \001(\010\022L\n\006r" + + "eason\030\005 \001(\0162<.google.cloud.audit.BigQuer" + + "yAuditMetadata.TableChange.Reason\022\020\n\010job" + + "_name\030\006 \001(\t\"N\n\006Reason\022\026\n\022REASON_UNSPECIF" + + "IED\020\000\022\030\n\024TABLE_UPDATE_REQUEST\020\001\022\007\n\003JOB\020\002" + + "\022\t\n\005QUERY\020\003\032\203\002\n\023ModelMetadataChange\022>\n\005m" + + "odel\030\001 \001(\0132/.google.cloud.audit.BigQuery" + + "AuditMetadata.Model\022T\n\006reason\030\002 \001(\0162D.go" + + "ogle.cloud.audit.BigQueryAuditMetadata.M" + + "odelMetadataChange.Reason\022\020\n\010job_name\030\003 " + + "\001(\t\"D\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022\027\n" + + "\023MODEL_PATCH_REQUEST\020\001\022\t\n\005QUERY\020\002\032\376\001\n\rRo" + + "utineChange\022B\n\007routine\030\001 \001(\01321.google.cl" + + "oud.audit.BigQueryAuditMetadata.Routine\022" + + "N\n\006reason\030\003 \001(\0162>.google.cloud.audit.Big" + + "QueryAuditMetadata.RoutineChange.Reason\022" + + "\020\n\010job_name\030\004 \001(\t\"G\n\006Reason\022\026\n\022REASON_UN" + + "SPECIFIED\020\000\022\t\n\005QUERY\020\001\022\032\n\026ROUTINE_UPDATE" + + "_REQUEST\020\002\032\272\002\n\017TableDataChange\022\032\n\022delete" + + "d_rows_count\030\001 \001(\003\022\033\n\023inserted_rows_coun" + + "t\030\002 \001(\003\022\021\n\ttruncated\030\003 \001(\010\022P\n\006reason\030\004 \001" + + "(\0162@.google.cloud.audit.BigQueryAuditMet" + + "adata.TableDataChange.Reason\022\020\n\010job_name" + + "\030\005 \001(\t\022\023\n\013stream_name\030\006 \001(\t\"b\n\006Reason\022\026\n" + + "\022REASON_UNSPECIFIED\020\000\022\007\n\003JOB\020\001\022\t\n\005QUERY\020" + + "\002\022\035\n\031MATERIALIZED_VIEW_REFRESH\020\003\022\r\n\tWRIT" + + "E_API\020\004\032\242\001\n\017ModelDataChange\022P\n\006reason\030\001 " + + "\001(\0162@.google.cloud.audit.BigQueryAuditMe" + + "tadata.ModelDataChange.Reason\022\020\n\010job_nam" + + "e\030\002 \001(\t\"+\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020" + + "\000\022\t\n\005QUERY\020\001\032\234\001\n\rModelDataRead\022N\n\006reason" + + "\030\001 \001(\0162>.google.cloud.audit.BigQueryAudi" + + "tMetadata.ModelDataRead.Reason\022\020\n\010job_na" + + "me\030\002 \001(\t\")\n\006Reason\022\026\n\022REASON_UNSPECIFIED" + + "\020\000\022\007\n\003JOB\020\001\032\251\003\n\007Dataset\022\024\n\014dataset_name\030" + + "\001 \001(\t\022/\n\013create_time\030\003 \001(\0132\032.google.prot" + + "obuf.Timestamp\022/\n\013update_time\030\004 \001(\0132\032.go" + + "ogle.protobuf.Timestamp\022B\n\003acl\030\005 \001(\01325.g" + + "oogle.cloud.audit.BigQueryAuditMetadata." + + "BigQueryAcl\022@\n\035default_table_expire_dura" + + "tion\030\006 \001(\0132\031.google.protobuf.Duration\022J\n" + + "\014dataset_info\030\007 \001(\01324.google.cloud.audit" + + ".BigQueryAuditMetadata.EntityInfo\022T\n\022def" + + "ault_encryption\030\010 \001(\01328.google.cloud.aud" + + "it.BigQueryAuditMetadata.EncryptionInfo\032" + + "\305\001\n\rTableDeletion\022N\n\006reason\030\001 \001(\0162>.goog" + + "le.cloud.audit.BigQueryAuditMetadata.Tab" + + "leDeletion.Reason\022\020\n\010job_name\030\002 \001(\t\"R\n\006R" + + "eason\022\026\n\022REASON_UNSPECIFIED\020\000\022\030\n\024TABLE_D" + + "ELETE_REQUEST\020\002\022\013\n\007EXPIRED\020\003\022\t\n\005QUERY\020\004\032" + + "\305\001\n\rModelDeletion\022N\n\006reason\030\001 \001(\0162>.goog" + + "le.cloud.audit.BigQueryAuditMetadata.Mod" + + "elDeletion.Reason\022\020\n\010job_name\030\002 \001(\t\"R\n\006R" + + "eason\022\026\n\022REASON_UNSPECIFIED\020\000\022\030\n\024MODEL_D" + + "ELETE_REQUEST\020\001\022\013\n\007EXPIRED\020\002\022\t\n\005QUERY\020\003\032" + + "\306\002\n\005Model\022\022\n\nmodel_name\030\001 \001(\t\022H\n\nmodel_i" + + "nfo\030\002 \001(\01324.google.cloud.audit.BigQueryA" + + "uditMetadata.EntityInfo\022/\n\013expire_time\030\005" + + " \001(\0132\032.google.protobuf.Timestamp\022/\n\013crea" + + "te_time\030\006 \001(\0132\032.google.protobuf.Timestam" + + "p\022/\n\013update_time\030\007 \001(\0132\032.google.protobuf" + + ".Timestamp\022L\n\nencryption\030\010 \001(\01328.google." + + "cloud.audit.BigQueryAuditMetadata.Encryp" + + "tionInfo\032\202\002\n\017RoutineDeletion\022B\n\007routine\030" + + "\001 \001(\01321.google.cloud.audit.BigQueryAudit" + + "Metadata.Routine\022P\n\006reason\030\003 \001(\0162@.googl" + + "e.cloud.audit.BigQueryAuditMetadata.Rout" + + "ineDeletion.Reason\022\020\n\010job_name\030\004 \001(\t\"G\n\006" + + "Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022\t\n\005QUERY\020" + + "\001\022\032\n\026ROUTINE_DELETE_REQUEST\020\002\032\360\001\n\003Job\022\020\n" + + "\010job_name\030\001 \001(\t\022G\n\njob_config\030\002 \001(\01323.go" + + "ogle.cloud.audit.BigQueryAuditMetadata.J" + + "obConfig\022G\n\njob_status\030\003 \001(\01323.google.cl" + + "oud.audit.BigQueryAuditMetadata.JobStatu" + + "s\022E\n\tjob_stats\030\004 \001(\01322.google.cloud.audi" + + "t.BigQueryAuditMetadata.JobStats\032\350\022\n\tJob" + + "Config\022F\n\004type\030\001 \001(\01628.google.cloud.audi" + + "t.BigQueryAuditMetadata.JobConfig.Type\022Q" + + "\n\014query_config\030\002 \001(\01329.google.cloud.audi" + + "t.BigQueryAuditMetadata.JobConfig.QueryH" + + "\000\022O\n\013load_config\030\003 \001(\01328.google.cloud.au" + + "dit.BigQueryAuditMetadata.JobConfig.Load" + + "H\000\022U\n\016extract_config\030\004 \001(\0132;.google.clou" + + "d.audit.BigQueryAuditMetadata.JobConfig." + + "ExtractH\000\022Z\n\021table_copy_config\030\005 \001(\0132=.g" + + "oogle.cloud.audit.BigQueryAuditMetadata." + + "JobConfig.TableCopyH\000\022O\n\006labels\030\006 \003(\0132?." + + "google.cloud.audit.BigQueryAuditMetadata" + + ".JobConfig.LabelsEntry\032\303\005\n\005Query\022\r\n\005quer" + + "y\030\001 \001(\t\022\027\n\017query_truncated\030\n \001(\010\022\031\n\021dest" + + "ination_table\030\002 \001(\t\022W\n\022create_dispositio" + + "n\030\003 \001(\0162;.google.cloud.audit.BigQueryAud" + + "itMetadata.CreateDisposition\022U\n\021write_di" + + "sposition\030\004 \001(\0162:.google.cloud.audit.Big" + + "QueryAuditMetadata.WriteDisposition\022\027\n\017d" + + "efault_dataset\030\005 \001(\t\022T\n\021table_definition" + + "s\030\006 \003(\01329.google.cloud.audit.BigQueryAud" + + "itMetadata.TableDefinition\022T\n\010priority\030\007" + + " \001(\0162B.google.cloud.audit.BigQueryAuditM" + + "etadata.JobConfig.Query.Priority\022^\n\034dest" + + "ination_table_encryption\030\010 \001(\01328.google." + + "cloud.audit.BigQueryAuditMetadata.Encryp" + + "tionInfo\022T\n\016statement_type\030\t \001(\0162<.googl" + + "e.cloud.audit.BigQueryAuditMetadata.Quer" + + "yStatementType\"L\n\010Priority\022\030\n\024PRIORITY_U" + + "NSPECIFIED\020\000\022\025\n\021QUERY_INTERACTIVE\020\001\022\017\n\013Q" + + "UERY_BATCH\020\002\032\231\003\n\004Load\022\023\n\013source_uris\030\001 \003" + + "(\t\022\035\n\025source_uris_truncated\030\007 \001(\010\022\023\n\013sch" + + "ema_json\030\002 \001(\t\022\035\n\025schema_json_truncated\030" + + "\010 \001(\010\022\031\n\021destination_table\030\003 \001(\t\022W\n\022crea" + + "te_disposition\030\004 \001(\0162;.google.cloud.audi" + + "t.BigQueryAuditMetadata.CreateDispositio" + + "n\022U\n\021write_disposition\030\005 \001(\0162:.google.cl" + + "oud.audit.BigQueryAuditMetadata.WriteDis" + + "position\022^\n\034destination_table_encryption" + + "\030\006 \001(\01328.google.cloud.audit.BigQueryAudi" + + "tMetadata.EncryptionInfo\032\201\001\n\007Extract\022\030\n\020" + + "destination_uris\030\001 \003(\t\022\"\n\032destination_ur" + + "is_truncated\030\003 \001(\010\022\026\n\014source_table\030\002 \001(\t" + + "H\000\022\026\n\014source_model\030\004 \001(\tH\000B\010\n\006source\032\200\004\n" + + "\tTableCopy\022\025\n\rsource_tables\030\001 \003(\t\022\037\n\027sou" + + "rce_tables_truncated\030\006 \001(\010\022\031\n\021destinatio" + + "n_table\030\002 \001(\t\022W\n\022create_disposition\030\003 \001(" + + "\0162;.google.cloud.audit.BigQueryAuditMeta" + + "data.CreateDisposition\022U\n\021write_disposit" + + "ion\030\004 \001(\0162:.google.cloud.audit.BigQueryA" + + "uditMetadata.WriteDisposition\022^\n\034destina" + + "tion_table_encryption\030\005 \001(\01328.google.clo" + + "ud.audit.BigQueryAuditMetadata.Encryptio" + + "nInfo\022O\n\016operation_type\030\007 \001(\01627.google.c" + + "loud.audit.BigQueryAuditMetadata.Operati" + + "onType\022?\n\033destination_expiration_time\030\010 " + + "\001(\0132\032.google.protobuf.Timestamp\032-\n\013Label" + + "sEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"I" + + "\n\004Type\022\024\n\020TYPE_UNSPECIFIED\020\000\022\t\n\005QUERY\020\001\022" + + "\010\n\004COPY\020\002\022\n\n\006EXPORT\020\003\022\n\n\006IMPORT\020\004B\010\n\006con" + + "fig\0324\n\017TableDefinition\022\014\n\004name\030\001 \001(\t\022\023\n\013" + + "source_uris\030\002 \003(\t\032\240\001\n\tJobStatus\022E\n\tjob_s" + + "tate\030\001 \001(\01622.google.cloud.audit.BigQuery" + + "AuditMetadata.JobState\022(\n\014error_result\030\002" + + " \001(\0132\022.google.rpc.Status\022\"\n\006errors\030\003 \003(\013" + + "2\022.google.rpc.Status\032\221\007\n\010JobStats\022/\n\013cre" + + "ate_time\030\001 \001(\0132\032.google.protobuf.Timesta" + + "mp\022.\n\nstart_time\030\002 \001(\0132\032.google.protobuf" + + ".Timestamp\022,\n\010end_time\030\003 \001(\0132\032.google.pr" + + "otobuf.Timestamp\022O\n\013query_stats\030\010 \001(\01328." + + "google.cloud.audit.BigQueryAuditMetadata" + + ".JobStats.QueryH\000\022M\n\nload_stats\030\t \001(\01327." + + "google.cloud.audit.BigQueryAuditMetadata" + + ".JobStats.LoadH\000\022S\n\rextract_stats\030\r \001(\0132" + + ":.google.cloud.audit.BigQueryAuditMetada" + + "ta.JobStats.ExtractH\000\022\025\n\rtotal_slot_ms\030\n" + + " \001(\003\022f\n\021reservation_usage\030\013 \003(\0132K.google" + + ".cloud.audit.BigQueryAuditMetadata.JobSt" + + "ats.ReservationResourceUsage\022\027\n\017parent_j" + + "ob_name\030\014 \001(\t\032\327\001\n\005Query\022\035\n\025total_process" + + "ed_bytes\030\001 \001(\003\022\032\n\022total_billed_bytes\030\002 \001" + + "(\003\022\024\n\014billing_tier\030\003 \001(\005\022\031\n\021referenced_t" + + "ables\030\006 \003(\t\022\030\n\020referenced_views\030\007 \003(\t\022\033\n" + + "\023referenced_routines\030\n \003(\t\022\030\n\020output_row" + + "_count\030\010 \001(\003\022\021\n\tcache_hit\030\t \001(\010\032\"\n\004Load\022" + + "\032\n\022total_output_bytes\030\001 \001(\003\032$\n\007Extract\022\031" + + "\n\021total_input_bytes\030\001 \001(\003\0329\n\030Reservation" + + "ResourceUsage\022\014\n\004name\030\001 \001(\t\022\017\n\007slot_ms\030\002" + + " \001(\003B\n\n\010extended\032\372\003\n\005Table\022\022\n\ntable_name" + + "\030\001 \001(\t\022\023\n\013schema_json\030\003 \001(\t\022\035\n\025schema_js" + + "on_truncated\030\013 \001(\010\022K\n\004view\030\004 \001(\0132=.googl" + + "e.cloud.audit.BigQueryAuditMetadata.Tabl" + + "eViewDefinition\022/\n\013expire_time\030\005 \001(\0132\032.g" + + "oogle.protobuf.Timestamp\022/\n\013create_time\030" + + "\006 \001(\0132\032.google.protobuf.Timestamp\022/\n\013upd" + + "ate_time\030\007 \001(\0132\032.google.protobuf.Timesta" + + "mp\0221\n\rtruncate_time\030\010 \001(\0132\032.google.proto" + + "buf.Timestamp\022L\n\nencryption\030\t \001(\01328.goog" + + "le.cloud.audit.BigQueryAuditMetadata.Enc" + + "ryptionInfo\022H\n\ntable_info\030\n \001(\01324.google" + + ".cloud.audit.BigQueryAuditMetadata.Entit" + + "yInfo\032\201\001\n\007Routine\022\024\n\014routine_name\030\001 \001(\t\022" + + "/\n\013create_time\030\005 \001(\0132\032.google.protobuf.T" + + "imestamp\022/\n\013update_time\030\006 \001(\0132\032.google.p" + + "rotobuf.Timestamp\032\271\001\n\nEntityInfo\022\025\n\rfrie" + + "ndly_name\030\001 \001(\t\022\023\n\013description\030\002 \001(\t\022P\n\006" + + "labels\030\003 \003(\0132@.google.cloud.audit.BigQue" + + "ryAuditMetadata.EntityInfo.LabelsEntry\032-" + + "\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(" + + "\t:\0028\001\032=\n\023TableViewDefinition\022\r\n\005query\030\001 " + + "\001(\t\022\027\n\017query_truncated\030\002 \001(\010\032N\n\013BigQuery" + + "Acl\022%\n\006policy\030\001 \001(\0132\025.google.iam.v1.Poli" + + "cy\022\030\n\020authorized_views\030\002 \003(\t\032&\n\016Encrypti" + + "onInfo\022\024\n\014kms_key_name\030\001 \001(\t\"l\n\020WriteDis" + + "position\022!\n\035WRITE_DISPOSITION_UNSPECIFIE" + + "D\020\000\022\017\n\013WRITE_EMPTY\020\001\022\022\n\016WRITE_TRUNCATE\020\002" + + "\022\020\n\014WRITE_APPEND\020\003\"T\n\rOperationType\022\036\n\032O" + + "PERATION_TYPE_UNSPECIFIED\020\000\022\010\n\004COPY\020\001\022\014\n" + + "\010SNAPSHOT\020\002\022\013\n\007RESTORE\020\003\"_\n\021CreateDispos" + + "ition\022\"\n\036CREATE_DISPOSITION_UNSPECIFIED\020" + + "\000\022\020\n\014CREATE_NEVER\020\001\022\024\n\020CREATE_IF_NEEDED\020" + + "\002\"I\n\010JobState\022\031\n\025JOB_STATE_UNSPECIFIED\020\000" + + "\022\013\n\007PENDING\020\001\022\013\n\007RUNNING\020\002\022\010\n\004DONE\020\003\"\360\004\n" + + "\022QueryStatementType\022$\n QUERY_STATEMENT_T" + + "YPE_UNSPECIFIED\020\000\022\n\n\006SELECT\020\001\022\n\n\006ASSERT\020" + + "\027\022\n\n\006INSERT\020\002\022\n\n\006UPDATE\020\003\022\n\n\006DELETE\020\004\022\t\n" + + "\005MERGE\020\005\022\020\n\014CREATE_TABLE\020\006\022\032\n\026CREATE_TAB" + + "LE_AS_SELECT\020\007\022\017\n\013CREATE_VIEW\020\010\022\020\n\014CREAT" + + "E_MODEL\020\t\022\034\n\030CREATE_MATERIALIZED_VIEW\020\r\022" + + "\023\n\017CREATE_FUNCTION\020\016\022\024\n\020CREATE_PROCEDURE" + + "\020\024\022\021\n\rCREATE_SCHEMA\0205\022\016\n\nDROP_TABLE\020\n\022\027\n" + + "\023DROP_EXTERNAL_TABLE\020!\022\r\n\tDROP_VIEW\020\013\022\016\n" + + "\nDROP_MODEL\020\014\022\032\n\026DROP_MATERIALIZED_VIEW\020" + + "\017\022\021\n\rDROP_FUNCTION\020\020\022\022\n\016DROP_PROCEDURE\020\025" + + "\022\017\n\013DROP_SCHEMA\0206\022\017\n\013ALTER_TABLE\020\021\022\016\n\nAL" + + "TER_VIEW\020\022\022\033\n\027ALTER_MATERIALIZED_VIEW\020\026\022" + + "\020\n\014ALTER_SCHEMA\0207\022\n\n\006SCRIPT\020\023\022\022\n\016TRUNCAT" + + "E_TABLE\020\032\022\031\n\025CREATE_EXTERNAL_TABLE\020\033\022\017\n\013" + + "EXPORT_DATA\020\034\022\010\n\004CALL\020\035B\007\n\005eventB\237\001\n\026com" + + ".google.cloud.auditB\032BigQueryAuditMetada" + + "taProtoP\001Z7google.golang.org/genproto/go" + + "ogleapis/cloud/audit;audit\242\002\003GCA\252\002\022Googl" + + "e.Cloud.Audit\312\002\022Google\\Cloud\\Auditb\006prot" + + "o3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.iam.v1.PolicyProto.getDescriptor(), + com.google.protobuf.DurationProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + com.google.rpc.StatusProto.getDescriptor(), + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_audit_BigQueryAuditMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor, + new java.lang.String[] { + "JobInsertion", + "JobChange", + "DatasetCreation", + "DatasetChange", + "DatasetDeletion", + "TableCreation", + "TableChange", + "TableDeletion", + "TableDataRead", + "TableDataChange", + "ModelDeletion", + "ModelCreation", + "ModelMetadataChange", + "ModelDataChange", + "ModelDataRead", + "RoutineCreation", + "RoutineChange", + "RoutineDeletion", + "Event", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(0); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor, + new java.lang.String[] { + "Job", "Reason", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(1); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor, + new java.lang.String[] { + "Before", "After", "Job", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(2); + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor, + new java.lang.String[] { + "Dataset", "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(3); + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor, + new java.lang.String[] { + "Dataset", "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(4); + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor, + new java.lang.String[] { + "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(5); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor, + new java.lang.String[] { + "Table", "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(6); + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor, + new java.lang.String[] { + "Model", "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(7); + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor, + new java.lang.String[] { + "Routine", "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(8); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor, + new java.lang.String[] { + "Fields", + "FieldsTruncated", + "PolicyTags", + "PolicyTagsTruncated", + "Reason", + "JobName", + "SessionName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(9); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor, + new java.lang.String[] { + "Table", "Truncated", "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(10); + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor, + new java.lang.String[] { + "Model", "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(11); + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor, + new java.lang.String[] { + "Routine", "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(12); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor, + new java.lang.String[] { + "DeletedRowsCount", + "InsertedRowsCount", + "Truncated", + "Reason", + "JobName", + "StreamName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(13); + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor, + new java.lang.String[] { + "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(14); + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor, + new java.lang.String[] { + "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(15); + internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor, + new java.lang.String[] { + "DatasetName", + "CreateTime", + "UpdateTime", + "Acl", + "DefaultTableExpireDuration", + "DatasetInfo", + "DefaultEncryption", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(16); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor, + new java.lang.String[] { + "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(17); + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor, + new java.lang.String[] { + "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(18); + internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor, + new java.lang.String[] { + "ModelName", "ModelInfo", "ExpireTime", "CreateTime", "UpdateTime", "Encryption", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(19); + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor, + new java.lang.String[] { + "Routine", "Reason", "JobName", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(20); + internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor, + new java.lang.String[] { + "JobName", "JobConfig", "JobStatus", "JobStats", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(21); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor, + new java.lang.String[] { + "Type", + "QueryConfig", + "LoadConfig", + "ExtractConfig", + "TableCopyConfig", + "Labels", + "Config", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor, + new java.lang.String[] { + "Query", + "QueryTruncated", + "DestinationTable", + "CreateDisposition", + "WriteDisposition", + "DefaultDataset", + "TableDefinitions", + "Priority", + "DestinationTableEncryption", + "StatementType", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor + .getNestedTypes() + .get(1); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor, + new java.lang.String[] { + "SourceUris", + "SourceUrisTruncated", + "SchemaJson", + "SchemaJsonTruncated", + "DestinationTable", + "CreateDisposition", + "WriteDisposition", + "DestinationTableEncryption", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor + .getNestedTypes() + .get(2); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor, + new java.lang.String[] { + "DestinationUris", "DestinationUrisTruncated", "SourceTable", "SourceModel", "Source", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor + .getNestedTypes() + .get(3); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor, + new java.lang.String[] { + "SourceTables", + "SourceTablesTruncated", + "DestinationTable", + "CreateDisposition", + "WriteDisposition", + "DestinationTableEncryption", + "OperationType", + "DestinationExpirationTime", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor + .getNestedTypes() + .get(4); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(22); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor, + new java.lang.String[] { + "Name", "SourceUris", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(23); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor, + new java.lang.String[] { + "JobState", "ErrorResult", "Errors", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(24); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor, + new java.lang.String[] { + "CreateTime", + "StartTime", + "EndTime", + "QueryStats", + "LoadStats", + "ExtractStats", + "TotalSlotMs", + "ReservationUsage", + "ParentJobName", + "Extended", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor, + new java.lang.String[] { + "TotalProcessedBytes", + "TotalBilledBytes", + "BillingTier", + "ReferencedTables", + "ReferencedViews", + "ReferencedRoutines", + "OutputRowCount", + "CacheHit", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor + .getNestedTypes() + .get(1); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor, + new java.lang.String[] { + "TotalOutputBytes", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor + .getNestedTypes() + .get(2); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor, + new java.lang.String[] { + "TotalInputBytes", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor + .getNestedTypes() + .get(3); + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor, + new java.lang.String[] { + "Name", "SlotMs", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(25); + internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor, + new java.lang.String[] { + "TableName", + "SchemaJson", + "SchemaJsonTruncated", + "View", + "ExpireTime", + "CreateTime", + "UpdateTime", + "TruncateTime", + "Encryption", + "TableInfo", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(26); + internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor, + new java.lang.String[] { + "RoutineName", "CreateTime", "UpdateTime", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(27); + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor, + new java.lang.String[] { + "FriendlyName", "Description", "Labels", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(28); + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor, + new java.lang.String[] { + "Query", "QueryTruncated", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(29); + internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor, + new java.lang.String[] { + "Policy", "AuthorizedViews", + }); + internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor = + internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor + .getNestedTypes() + .get(30); + internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor, + new java.lang.String[] { + "KmsKeyName", + }); + com.google.iam.v1.PolicyProto.getDescriptor(); + com.google.protobuf.DurationProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + com.google.rpc.StatusProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/proto-google-common-protos/src/main/java/com/google/type/LocalizedText.java b/proto-google-common-protos/src/main/java/com/google/type/LocalizedText.java new file mode 100644 index 00000000..87998f0f --- /dev/null +++ b/proto-google-common-protos/src/main/java/com/google/type/LocalizedText.java @@ -0,0 +1,821 @@ +/* + * 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/type/localized_text.proto + +package com.google.type; + +/** + * + * + *
+ * Localized variant of a text in a particular language.
+ * 
+ * + * Protobuf type {@code google.type.LocalizedText} + */ +public final class LocalizedText extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.type.LocalizedText) + LocalizedTextOrBuilder { + private static final long serialVersionUID = 0L; + // Use LocalizedText.newBuilder() to construct. + private LocalizedText(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private LocalizedText() { + text_ = ""; + languageCode_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new LocalizedText(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private LocalizedText( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + text_ = s; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + languageCode_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + 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); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.type.LocalizedTextProto.internal_static_google_type_LocalizedText_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.type.LocalizedTextProto + .internal_static_google_type_LocalizedText_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.type.LocalizedText.class, com.google.type.LocalizedText.Builder.class); + } + + public static final int TEXT_FIELD_NUMBER = 1; + private volatile java.lang.Object text_; + /** + * + * + *
+   * Localized string in the language corresponding to `language_code' below.
+   * 
+ * + * string text = 1; + * + * @return The text. + */ + @java.lang.Override + public java.lang.String getText() { + java.lang.Object ref = text_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + text_ = s; + return s; + } + } + /** + * + * + *
+   * Localized string in the language corresponding to `language_code' below.
+   * 
+ * + * string text = 1; + * + * @return The bytes for text. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTextBytes() { + java.lang.Object ref = text_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + text_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int LANGUAGE_CODE_FIELD_NUMBER = 2; + private volatile java.lang.Object languageCode_; + /** + * + * + *
+   * The text's BCP-47 language code, such as "en-US" or "sr-Latn".
+   * For more information, see
+   * http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
+   * 
+ * + * string language_code = 2; + * + * @return The languageCode. + */ + @java.lang.Override + public java.lang.String getLanguageCode() { + java.lang.Object ref = languageCode_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + languageCode_ = s; + return s; + } + } + /** + * + * + *
+   * The text's BCP-47 language code, such as "en-US" or "sr-Latn".
+   * For more information, see
+   * http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
+   * 
+ * + * string language_code = 2; + * + * @return The bytes for languageCode. + */ + @java.lang.Override + public com.google.protobuf.ByteString getLanguageCodeBytes() { + java.lang.Object ref = languageCode_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + languageCode_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getTextBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, text_); + } + if (!getLanguageCodeBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, languageCode_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getTextBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, text_); + } + if (!getLanguageCodeBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, languageCode_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.type.LocalizedText)) { + return super.equals(obj); + } + com.google.type.LocalizedText other = (com.google.type.LocalizedText) obj; + + if (!getText().equals(other.getText())) return false; + if (!getLanguageCode().equals(other.getLanguageCode())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TEXT_FIELD_NUMBER; + hash = (53 * hash) + getText().hashCode(); + hash = (37 * hash) + LANGUAGE_CODE_FIELD_NUMBER; + hash = (53 * hash) + getLanguageCode().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.type.LocalizedText parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.type.LocalizedText parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.type.LocalizedText parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.type.LocalizedText parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.type.LocalizedText parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.type.LocalizedText parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.type.LocalizedText parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.type.LocalizedText parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.type.LocalizedText parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.type.LocalizedText parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.type.LocalizedText parseFrom(com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.type.LocalizedText parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.type.LocalizedText prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Localized variant of a text in a particular language.
+   * 
+ * + * Protobuf type {@code google.type.LocalizedText} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.type.LocalizedText) + com.google.type.LocalizedTextOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.type.LocalizedTextProto + .internal_static_google_type_LocalizedText_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.type.LocalizedTextProto + .internal_static_google_type_LocalizedText_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.type.LocalizedText.class, com.google.type.LocalizedText.Builder.class); + } + + // Construct using com.google.type.LocalizedText.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + text_ = ""; + + languageCode_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.type.LocalizedTextProto + .internal_static_google_type_LocalizedText_descriptor; + } + + @java.lang.Override + public com.google.type.LocalizedText getDefaultInstanceForType() { + return com.google.type.LocalizedText.getDefaultInstance(); + } + + @java.lang.Override + public com.google.type.LocalizedText build() { + com.google.type.LocalizedText result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.type.LocalizedText buildPartial() { + com.google.type.LocalizedText result = new com.google.type.LocalizedText(this); + result.text_ = text_; + result.languageCode_ = languageCode_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.type.LocalizedText) { + return mergeFrom((com.google.type.LocalizedText) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.type.LocalizedText other) { + if (other == com.google.type.LocalizedText.getDefaultInstance()) return this; + if (!other.getText().isEmpty()) { + text_ = other.text_; + onChanged(); + } + if (!other.getLanguageCode().isEmpty()) { + languageCode_ = other.languageCode_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.type.LocalizedText parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.type.LocalizedText) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object text_ = ""; + /** + * + * + *
+     * Localized string in the language corresponding to `language_code' below.
+     * 
+ * + * string text = 1; + * + * @return The text. + */ + public java.lang.String getText() { + java.lang.Object ref = text_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + text_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Localized string in the language corresponding to `language_code' below.
+     * 
+ * + * string text = 1; + * + * @return The bytes for text. + */ + public com.google.protobuf.ByteString getTextBytes() { + java.lang.Object ref = text_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + text_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Localized string in the language corresponding to `language_code' below.
+     * 
+ * + * string text = 1; + * + * @param value The text to set. + * @return This builder for chaining. + */ + public Builder setText(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + text_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Localized string in the language corresponding to `language_code' below.
+     * 
+ * + * string text = 1; + * + * @return This builder for chaining. + */ + public Builder clearText() { + + text_ = getDefaultInstance().getText(); + onChanged(); + return this; + } + /** + * + * + *
+     * Localized string in the language corresponding to `language_code' below.
+     * 
+ * + * string text = 1; + * + * @param value The bytes for text to set. + * @return This builder for chaining. + */ + public Builder setTextBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + text_ = value; + onChanged(); + return this; + } + + private java.lang.Object languageCode_ = ""; + /** + * + * + *
+     * The text's BCP-47 language code, such as "en-US" or "sr-Latn".
+     * For more information, see
+     * http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
+     * 
+ * + * string language_code = 2; + * + * @return The languageCode. + */ + public java.lang.String getLanguageCode() { + java.lang.Object ref = languageCode_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + languageCode_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The text's BCP-47 language code, such as "en-US" or "sr-Latn".
+     * For more information, see
+     * http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
+     * 
+ * + * string language_code = 2; + * + * @return The bytes for languageCode. + */ + public com.google.protobuf.ByteString getLanguageCodeBytes() { + java.lang.Object ref = languageCode_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + languageCode_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The text's BCP-47 language code, such as "en-US" or "sr-Latn".
+     * For more information, see
+     * http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
+     * 
+ * + * string language_code = 2; + * + * @param value The languageCode to set. + * @return This builder for chaining. + */ + public Builder setLanguageCode(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + languageCode_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The text's BCP-47 language code, such as "en-US" or "sr-Latn".
+     * For more information, see
+     * http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
+     * 
+ * + * string language_code = 2; + * + * @return This builder for chaining. + */ + public Builder clearLanguageCode() { + + languageCode_ = getDefaultInstance().getLanguageCode(); + onChanged(); + return this; + } + /** + * + * + *
+     * The text's BCP-47 language code, such as "en-US" or "sr-Latn".
+     * For more information, see
+     * http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
+     * 
+ * + * string language_code = 2; + * + * @param value The bytes for languageCode to set. + * @return This builder for chaining. + */ + public Builder setLanguageCodeBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + languageCode_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.type.LocalizedText) + } + + // @@protoc_insertion_point(class_scope:google.type.LocalizedText) + private static final com.google.type.LocalizedText DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.type.LocalizedText(); + } + + public static com.google.type.LocalizedText getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public LocalizedText parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new LocalizedText(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.type.LocalizedText getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-common-protos/src/main/java/com/google/type/LocalizedTextOrBuilder.java b/proto-google-common-protos/src/main/java/com/google/type/LocalizedTextOrBuilder.java new file mode 100644 index 00000000..c1038869 --- /dev/null +++ b/proto-google-common-protos/src/main/java/com/google/type/LocalizedTextOrBuilder.java @@ -0,0 +1,79 @@ +/* + * 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/type/localized_text.proto + +package com.google.type; + +public interface LocalizedTextOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.type.LocalizedText) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Localized string in the language corresponding to `language_code' below.
+   * 
+ * + * string text = 1; + * + * @return The text. + */ + java.lang.String getText(); + /** + * + * + *
+   * Localized string in the language corresponding to `language_code' below.
+   * 
+ * + * string text = 1; + * + * @return The bytes for text. + */ + com.google.protobuf.ByteString getTextBytes(); + + /** + * + * + *
+   * The text's BCP-47 language code, such as "en-US" or "sr-Latn".
+   * For more information, see
+   * http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
+   * 
+ * + * string language_code = 2; + * + * @return The languageCode. + */ + java.lang.String getLanguageCode(); + /** + * + * + *
+   * The text's BCP-47 language code, such as "en-US" or "sr-Latn".
+   * For more information, see
+   * http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
+   * 
+ * + * string language_code = 2; + * + * @return The bytes for languageCode. + */ + com.google.protobuf.ByteString getLanguageCodeBytes(); +} diff --git a/proto-google-common-protos/src/main/java/com/google/type/LocalizedTextProto.java b/proto-google-common-protos/src/main/java/com/google/type/LocalizedTextProto.java new file mode 100644 index 00000000..4d1559b6 --- /dev/null +++ b/proto-google-common-protos/src/main/java/com/google/type/LocalizedTextProto.java @@ -0,0 +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/type/localized_text.proto + +package com.google.type; + +public final class LocalizedTextProto { + private LocalizedTextProto() {} + + 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_type_LocalizedText_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_type_LocalizedText_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n google/type/localized_text.proto\022\013goog" + + "le.type\"4\n\rLocalizedText\022\014\n\004text\030\001 \001(\t\022\025" + + "\n\rlanguage_code\030\002 \001(\tBz\n\017com.google.type" + + "B\022LocalizedTextProtoP\001ZHgoogle.golang.or" + + "g/genproto/googleapis/type/localized_tex" + + "t;localized_text\370\001\001\242\002\003GTPb\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, new com.google.protobuf.Descriptors.FileDescriptor[] {}); + internal_static_google_type_LocalizedText_descriptor = getDescriptor().getMessageTypes().get(0); + internal_static_google_type_LocalizedText_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_type_LocalizedText_descriptor, + new java.lang.String[] { + "Text", "LanguageCode", + }); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/proto-google-common-protos/src/main/proto/google/cloud/audit/bigquery_audit_metadata.proto b/proto-google-common-protos/src/main/proto/google/cloud/audit/bigquery_audit_metadata.proto new file mode 100644 index 00000000..f3a87ac5 --- /dev/null +++ b/proto-google-common-protos/src/main/proto/google/cloud/audit/bigquery_audit_metadata.proto @@ -0,0 +1,1184 @@ +// Copyright 2021 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +syntax = "proto3"; + +package google.cloud.audit; + +import "google/iam/v1/policy.proto"; +import "google/protobuf/duration.proto"; +import "google/protobuf/timestamp.proto"; +import "google/rpc/status.proto"; + +option csharp_namespace = "Google.Cloud.Audit"; +option go_package = "google.golang.org/genproto/googleapis/cloud/audit;audit"; +option java_multiple_files = true; +option java_outer_classname = "BigQueryAuditMetadataProto"; +option java_package = "com.google.cloud.audit"; +option objc_class_prefix = "GCA"; +option php_namespace = "Google\\Cloud\\Audit"; + +// Audit log format for BigQuery cloud audit logs metadata. +// +message BigQueryAuditMetadata { + // Job insertion event. + message JobInsertion { + // Describes how the job was inserted. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Job was inserted using the jobs.insert API. + JOB_INSERT_REQUEST = 1; + + // Job was inserted using the jobs.query RPC. + QUERY_REQUEST = 2; + } + + // Job metadata. + Job job = 1; + + // Describes how the job was inserted. + Reason reason = 2; + } + + // Job state change event. + message JobChange { + // Job state before the job state change. + JobState before = 1; + + // Job state after the job state change. + JobState after = 2; + + // Job metadata. + Job job = 3; + } + + // Dataset creation event. + message DatasetCreation { + // Describes how the dataset was created. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Dataset was created using the datasets.create API. + CREATE = 1; + + // Dataset was created using a query job, e.g., CREATE SCHEMA statement. + QUERY = 2; + } + + // Dataset metadata. + Dataset dataset = 1; + + // Describes how the dataset was created. + Reason reason = 2; + + // The URI of the job that created the dataset. + // Present if the reason is QUERY. + // + // Format: `projects//jobs/`. + string job_name = 3; + } + + // Dataset change event. + message DatasetChange { + // Describes how the dataset was changed. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Dataset was changed using the datasets.update or datasets.patch API. + UPDATE = 1; + + // Dataset was changed using the SetIamPolicy API. + SET_IAM_POLICY = 2; + + // Dataset was changed using a query job, e.g., ALTER SCHEMA statement. + QUERY = 3; + } + + // Dataset metadata after the change. + Dataset dataset = 1; + + // Describes how the dataset was changed. + Reason reason = 2; + + // The URI of the job that updated the dataset. + // Present if the reason is QUERY. + // + // Format: `projects//jobs/`. + string job_name = 3; + } + + // Dataset deletion event. + message DatasetDeletion { + // Describes how the dataset was deleted. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Dataset was deleted using the datasets.delete API. + DELETE = 1; + + // Dataset was deleted using a query job, e.g., DROP SCHEMA statement. + QUERY = 2; + } + + // Describes how the dataset was deleted. + Reason reason = 1; + + // The URI of the job that deleted the dataset. + // Present if the reason is QUERY. + // + // Format: `projects//jobs/`. + string job_name = 2; + } + + // Table creation event. + message TableCreation { + // Describes how the table was created. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Table was created as a destination table during a query, load or copy + // job. + JOB = 1; + + // Table was created using a DDL query. + QUERY = 2; + + // Table was created using the tables.create API. + TABLE_INSERT_REQUEST = 3; + } + + // Table metadata. + Table table = 1; + + // Describes how the table was created. + Reason reason = 3; + + // The URI of the job that created a table. + // Present if the reason is JOB or QUERY. + // + // Format: `projects//jobs/`. + string job_name = 4; + } + + // Model creation event. + message ModelCreation { + // Describes how the model was created. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Model was created using a DDL query. + QUERY = 2; + } + + // Model metadata. + Model model = 1; + + // Describes how the model was created. + Reason reason = 3; + + // The URI of the job that created the model. + // + // Format: `projects//jobs/`. + string job_name = 4; + } + + // Routine creation event. + message RoutineCreation { + // Describes how the routine was created. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Routine was created using a DDL query. + QUERY = 1; + + // Routine was created using the routines.create API. + ROUTINE_INSERT_REQUEST = 2; + } + + // Created routine. + Routine routine = 1; + + // Describes how the routine was created. + Reason reason = 3; + + // The URI of the job that created the routine. + // + // Format: `projects//jobs/`. + string job_name = 4; + } + + // Table data read event. + message TableDataRead { + // Describes how the table data was read. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Table was used as a source table during a BigQuery job. + JOB = 1; + + // Table data was accessed using the tabledata.list API. + TABLEDATA_LIST_REQUEST = 2; + + // Table data was accessed using the jobs.getQueryResults API. + GET_QUERY_RESULTS_REQUEST = 3; + + // Table data was accessed using the jobs.query RPC. + QUERY_REQUEST = 4; + + // Table data was accessed using storage.CreateReadSession API. + CREATE_READ_SESSION = 5; + + // Table data was accessed during a materialized view refresh. + MATERIALIZED_VIEW_REFRESH = 6; + } + + // List of the accessed fields. Entire list is truncated if the record size + // exceeds 100K. + repeated string fields = 2; + + // True if the fields list was truncated. + bool fields_truncated = 8; + + // List of the referenced policy tags. That is, policy tags attached to the + // accessed fields or their ancestors. + // Policy tag resource name is a string of the format: + // `projects//locations//taxonomies//policyTags/` + repeated string policy_tags = 9; + + // True if the policy tag list was truncated. At most 100 policy tags can be + // saved. + bool policy_tags_truncated = 10; + + // Describes how the table data was read. + Reason reason = 3; + + // The URI of the job that read a table. + // Present if the reason is JOB but can be redacted for privacy reasons. + // + // Format: `projects//jobs/`. + string job_name = 4; + + // The URI of the read session that read a table. + // Present if the reason is CREATE_READ_SESSION. + // + // Format: + // `projects//locations//sessions/`. + string session_name = 5; + } + + // Table metadata change event. + message TableChange { + // Describes how the table metadata was changed. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Table metadata was updated using the tables.update or tables.patch API. + TABLE_UPDATE_REQUEST = 1; + + // Table was used as a job destination table. + JOB = 2; + + // Table metadata was updated using a DML or DDL query. + QUERY = 3; + } + + // Updated table metadata. + Table table = 1; + + // True if the table was truncated. + bool truncated = 4; + + // Describes how the table metadata was changed. + Reason reason = 5; + + // The URI of the job that changed a table. + // Present if the reason is JOB or QUERY. + // + // Format: `projects//jobs/`. + string job_name = 6; + } + + // Model metadata change event. + message ModelMetadataChange { + // Describes how the model metadata was changed. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Model metadata was updated using the models.patch API. + MODEL_PATCH_REQUEST = 1; + + // Model metadata was updated using a DDL query. + QUERY = 2; + } + + // Updated model. + Model model = 1; + + // Describes how the model metadata was changed. + Reason reason = 2; + + // The URI of the job that changed the model metadata. + // Present if and only if the reason is QUERY. + // + // Format: `projects//jobs/`. + string job_name = 3; + } + + // Routine change event. + message RoutineChange { + // Describes how the routine was updated. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Routine was updated using a DDL query. + QUERY = 1; + + // Routine was updated using the routines.update or routines.patch API. + ROUTINE_UPDATE_REQUEST = 2; + } + + // Updated routine. + Routine routine = 1; + + // Describes how the routine was updated. + Reason reason = 3; + + // The URI of the job that updated the routine. + // + // Format: `projects//jobs/`. + string job_name = 4; + } + + // Table data change event. + message TableDataChange { + // Describes how the table data was changed. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Table was used as a job destination table. + JOB = 1; + + // Table data was updated using a DML or DDL query. + QUERY = 2; + + // Table data was updated during a materialized view refresh. + MATERIALIZED_VIEW_REFRESH = 3; + + // Table data was added using the Write API. + WRITE_API = 4; + } + + // Number of deleted rows. + int64 deleted_rows_count = 1; + + // Number of inserted rows. + int64 inserted_rows_count = 2; + + // True if the table was truncated. + bool truncated = 3; + + // Describes how the table data was changed. + Reason reason = 4; + + // The URI of the job that changed a table. + // + // Format: `projects//jobs/`. + string job_name = 5; + + // If written from WRITE_API, the name of the stream. + // + // Format: + // `projects//datasets//tables//streams/` + string stream_name = 6; + } + + // Model data change event. + message ModelDataChange { + // Describes how the model data was changed. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Model data was changed using a DDL query. + QUERY = 1; + } + + // Describes how the model data was changed. + Reason reason = 1; + + // The URI of the job that changed the model data. + // + // Format: `projects//jobs/`. + string job_name = 2; + } + + // Model data read event. + message ModelDataRead { + // Describes how the model data was read. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Model was used as a source model during a BigQuery job. + JOB = 1; + } + + // Describes how the model data was read. + Reason reason = 1; + + // The URI of the job that read the model data. + // + // Format: `projects//jobs/`. + string job_name = 2; + } + + // BigQuery dataset. + message Dataset { + // Dataset URI. + // + // Format: `projects//datasets/`. + string dataset_name = 1; + + // Dataset creation time. + google.protobuf.Timestamp create_time = 3; + + // Dataset metadata last update time. + google.protobuf.Timestamp update_time = 4; + + // The access control list for the dataset. + BigQueryAcl acl = 5; + + // Default expiration time for tables in the dataset. + google.protobuf.Duration default_table_expire_duration = 6; + + // User-provided metadata for the dataset. + EntityInfo dataset_info = 7; + + // Default encryption for tables in the dataset. + EncryptionInfo default_encryption = 8; + } + + // Table deletion event. + message TableDeletion { + // Describes how the table was deleted. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Table was deleted using the tables.delete API. + TABLE_DELETE_REQUEST = 2; + + // Table expired. + EXPIRED = 3; + + // Table deleted using a DDL query. + QUERY = 4; + } + + // Describes how the table was deleted. + Reason reason = 1; + + // The URI of the job that deleted a table. + // Present if the reason is QUERY. + // + // Format: `projects//jobs/`. + string job_name = 2; + } + + // Model deletion event. + message ModelDeletion { + // Describes how the model was deleted. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Model was deleted using the models.delete API. + MODEL_DELETE_REQUEST = 1; + + // Model expired. + EXPIRED = 2; + + // Model was deleted using DDL query. + QUERY = 3; + } + + // Describes how the model was deleted. + Reason reason = 1; + + // The URI of the job that deleted a model. + // Present if the reason is QUERY. + // + // Format: `projects//jobs/`. + string job_name = 2; + } + + // Trained BigQuery ML model. + message Model { + // Model URI. + // + // Format: `projects//datasets//models/`. + string model_name = 1; + + // User-provided metadata for the model. + EntityInfo model_info = 2; + + // Model expiration time. + google.protobuf.Timestamp expire_time = 5; + + // Model creation time. + google.protobuf.Timestamp create_time = 6; + + // Model last update time. + google.protobuf.Timestamp update_time = 7; + + // Model encryption information. Set when non-default encryption is used. + EncryptionInfo encryption = 8; + } + + // Routine deletion event. + message RoutineDeletion { + // Describes how the routine was deleted. + enum Reason { + // Unknown. + REASON_UNSPECIFIED = 0; + + // Routine was deleted using DDL query. + QUERY = 1; + + // Routine was deleted using the API. + ROUTINE_DELETE_REQUEST = 2; + } + + // Deleted routine. + Routine routine = 1; + + // Describes how the routine was deleted. + Reason reason = 3; + + // The URI of the job that deleted the routine. + // Present if the reason is QUERY. + // + // Format: `projects//jobs/`. + string job_name = 4; + } + + // BigQuery job. + message Job { + // Job URI. + // + // Format: `projects//jobs/`. + string job_name = 1; + + // Job configuration. + JobConfig job_config = 2; + + // Job status. + JobStatus job_status = 3; + + // Job statistics. + JobStats job_stats = 4; + } + + // Job configuration. + // See the [Jobs](https://cloud.google.com/bigquery/docs/reference/v2/jobs) + // API resource for more details on individual fields. + message JobConfig { + // Query job configuration. + message Query { + // Priority given to the query. + enum Priority { + // Unknown. + PRIORITY_UNSPECIFIED = 0; + + // Interactive query. + QUERY_INTERACTIVE = 1; + + // Batch query. + QUERY_BATCH = 2; + } + + // The SQL query to run. Truncated if exceeds 50K. + string query = 1; + + // True if the query field was truncated. + bool query_truncated = 10; + + // The destination table for the query results. + string destination_table = 2; + + // Destination table create disposition. + CreateDisposition create_disposition = 3; + + // Destination table write disposition. + WriteDisposition write_disposition = 4; + + // Default dataset for the query. + string default_dataset = 5; + + // External data sources used in the query. + repeated TableDefinition table_definitions = 6; + + // Priority given to the query. + Priority priority = 7; + + // Result table encryption information. Set when non-default encryption is + // used. + EncryptionInfo destination_table_encryption = 8; + + // Type of the query. + QueryStatementType statement_type = 9; + } + + // Load job configuration. + message Load { + // URIs for the data to be imported. Entire list is truncated if exceeds + // 40K. + repeated string source_uris = 1; + + // True if the source_URIs field was truncated. + bool source_uris_truncated = 7; + + // The table schema in JSON format. Entire field is truncated if exceeds + // 40K. + string schema_json = 2; + + // True if the schema_json field was truncated. + bool schema_json_truncated = 8; + + // The destination table for the import. + string destination_table = 3; + + // Destination table create disposition. + CreateDisposition create_disposition = 4; + + // Destination table write disposition. + WriteDisposition write_disposition = 5; + + // Result table encryption information. Set when non-default encryption is + // used. + EncryptionInfo destination_table_encryption = 6; + } + + // Extract job configuration. + message Extract { + // URIs where extracted data should be written. Entire list is truncated + // if exceeds 50K. + repeated string destination_uris = 1; + + // True if the destination_URIs field was truncated. + bool destination_uris_truncated = 3; + + oneof source { + // The source table. + string source_table = 2; + + // The source model. + string source_model = 4; + } + } + + // Table copy job configuration. + message TableCopy { + // Source tables. Entire list is truncated if exceeds 50K. + repeated string source_tables = 1; + + // True if the source_tables field was truncated. + bool source_tables_truncated = 6; + + // Destination table. + string destination_table = 2; + + // Destination table create disposition. + CreateDisposition create_disposition = 3; + + // Destination table write disposition. + WriteDisposition write_disposition = 4; + + // Result table encryption information. Set when non-default encryption is + // used. + EncryptionInfo destination_table_encryption = 5; + + // Supported operation types in the table copy job. + OperationType operation_type = 7; + + // Expiration time set on the destination table. Expired tables will be + // deleted and their storage reclaimed. + google.protobuf.Timestamp destination_expiration_time = 8; + } + + // Job type. + enum Type { + // Unknown. + TYPE_UNSPECIFIED = 0; + + // Query job. + QUERY = 1; + + // Table copy job. + COPY = 2; + + // Export (extract) job. + EXPORT = 3; + + // Import (load) job. + IMPORT = 4; + } + + // Job type. + Type type = 1; + + // Job configuration information. + oneof config { + // Query job information. + Query query_config = 2; + + // Load job information. + Load load_config = 3; + + // Extract job information. + Extract extract_config = 4; + + // TableCopy job information. + TableCopy table_copy_config = 5; + } + + // Labels provided for the job. + map labels = 6; + } + + // Definition of an external data source used in a query. + message TableDefinition { + // Name of the table, used in queries. + string name = 1; + + // URIs for the data. + repeated string source_uris = 2; + } + + // Status of a job. + message JobStatus { + // State of the job. + JobState job_state = 1; + + // Job error, if the job failed. + google.rpc.Status error_result = 2; + + // Errors encountered during the running of the job. Does not necessarily + // mean that the job has completed or was unsuccessful. + repeated google.rpc.Status errors = 3; + } + + // Job statistics. + message JobStats { + // Query job statistics. + message Query { + // Total bytes processed by the query job. + int64 total_processed_bytes = 1; + + // Total bytes billed by the query job. + int64 total_billed_bytes = 2; + + // The tier assigned by the CPU-based billing. + int32 billing_tier = 3; + + // Tables accessed by the query job. + repeated string referenced_tables = 6; + + // Views accessed by the query job. + repeated string referenced_views = 7; + + // Routines accessed by the query job. + repeated string referenced_routines = 10; + + // Number of output rows produced by the query job. + int64 output_row_count = 8; + + // True if the query job results were read from the query cache. + bool cache_hit = 9; + } + + // Load job statistics. + message Load { + // Total bytes loaded by the import job. + int64 total_output_bytes = 1; + } + + // Extract job statistics. + message Extract { + // Total bytes exported by the extract job. + int64 total_input_bytes = 1; + } + + // Job resource usage breakdown by reservation. + message ReservationResourceUsage { + // Reservation name or "unreserved" for on-demand resources usage. + string name = 1; + + // Total slot milliseconds used by the reservation for a particular job. + int64 slot_ms = 2; + } + + // Job creation time. + google.protobuf.Timestamp create_time = 1; + + // Job execution start time. + google.protobuf.Timestamp start_time = 2; + + // Job completion time. + google.protobuf.Timestamp end_time = 3; + + // Statistics specific to the job type. + oneof extended { + // Query job statistics. + Query query_stats = 8; + + // Load job statistics. + Load load_stats = 9; + + // Extract job statistics. + Extract extract_stats = 13; + } + + // The total number of slot-ms consumed by the query job. + int64 total_slot_ms = 10; + + // Reservation usage attributed from each tier of a reservation hierarchy. + repeated ReservationResourceUsage reservation_usage = 11; + + // Parent job name. Only present for child jobs. + string parent_job_name = 12; + } + + // Describes whether a job should overwrite or append the existing destination + // table if it already exists. + enum WriteDisposition { + // Unknown. + WRITE_DISPOSITION_UNSPECIFIED = 0; + + // This job should only be writing to empty tables. + WRITE_EMPTY = 1; + + // This job will truncate the existing table data. + WRITE_TRUNCATE = 2; + + // This job will append to the table. + WRITE_APPEND = 3; + } + + // BigQuery table. + message Table { + // Table URI. + // + // Format: `projects//datasets//tables/`. + string table_name = 1; + + // A JSON representation of the table's schema. Entire field is truncated + // if exceeds 40K. + string schema_json = 3; + + // True if the schema_json field was truncated. + bool schema_json_truncated = 11; + + // View metadata. Only present for views. + TableViewDefinition view = 4; + + // Table expiration time. + google.protobuf.Timestamp expire_time = 5; + + // The table creation time. + google.protobuf.Timestamp create_time = 6; + + // The last time metadata update time. + google.protobuf.Timestamp update_time = 7; + + // The last table truncation time. + google.protobuf.Timestamp truncate_time = 8; + + // Table encryption information. Set when non-default encryption is used. + EncryptionInfo encryption = 9; + + // User-provided metadata for the table. + EntityInfo table_info = 10; + } + + // User Defined Function (UDF) or Stored Procedure. + message Routine { + // Routine URI. + // + // Format: + // `projects//datasets//routines/`. + string routine_name = 1; + + // Routine creation time. + google.protobuf.Timestamp create_time = 5; + + // Routine last update time. + google.protobuf.Timestamp update_time = 6; + } + + // Table copy job operation type. + enum OperationType { + // Unspecified operation type. + OPERATION_TYPE_UNSPECIFIED = 0; + + // The source and the destination table have the same table type. + COPY = 1; + + // The source table type is TABLE and + // the destination table type is SNAPSHOT. + SNAPSHOT = 2; + + // The source table type is SNAPSHOT and + // the destination table type is TABLE. + RESTORE = 3; + } + + // User-provided metadata for an entity, for e.g. dataset, table or model. + message EntityInfo { + // A short name for the entity. + string friendly_name = 1; + + // A long description for the entity. + string description = 2; + + // Labels provided for the entity. + map labels = 3; + } + + // View definition. + message TableViewDefinition { + // SQL query defining the view. Truncated if exceeds 40K. + string query = 1; + + // True if the schema_json field was truncated. + bool query_truncated = 2; + } + + // An access control list. + message BigQueryAcl { + // IAM policy for the resource. + google.iam.v1.Policy policy = 1; + + // List of authorized views for a dataset. + // + // Format: `projects//datasets//tables/`. + repeated string authorized_views = 2; + } + + // Encryption properties for a table or a job + message EncryptionInfo { + // Cloud kms key identifier. + // + // Format: + // `projects//locations//keyRings//cryptoKeys/` + string kms_key_name = 1; + } + + // Describes whether a job should create a destination table if it doesn't + // exist. + enum CreateDisposition { + // Unknown. + CREATE_DISPOSITION_UNSPECIFIED = 0; + + // This job should never create tables. + CREATE_NEVER = 1; + + // This job should create a table if it doesn't already exist. + CREATE_IF_NEEDED = 2; + } + + // State of a job. + enum JobState { + // State unknown. + JOB_STATE_UNSPECIFIED = 0; + + // Job is waiting for the resources. + PENDING = 1; + + // Job is running. + RUNNING = 2; + + // Job is done. + DONE = 3; + } + + // Type of the statement (e.g. SELECT, INSERT, CREATE_TABLE, CREATE_MODEL..) + enum QueryStatementType { + // Unknown. + QUERY_STATEMENT_TYPE_UNSPECIFIED = 0; + + // SELECT ... FROM <Table list> ... + SELECT = 1; + + // ASSERT <condition> AS 'description' + ASSERT = 23; + + // INSERT INTO <Table> .... + INSERT = 2; + + // UPDATE <Table> SET ... + UPDATE = 3; + + // DELETE <Table> ... + DELETE = 4; + + // MERGE INTO <Table> .... + MERGE = 5; + + // CREATE TABLE <Table> <column list> + CREATE_TABLE = 6; + + // CREATE TABLE <Table> AS SELECT + CREATE_TABLE_AS_SELECT = 7; + + // CREATE VIEW <View> + CREATE_VIEW = 8; + + // CREATE MODEL <Model> AS <Query> + CREATE_MODEL = 9; + + // CREATE MATERIALIZED VIEW <View> AS ... + CREATE_MATERIALIZED_VIEW = 13; + + // CREATE FUNCTION <Function>(<Signature>) AS ... + CREATE_FUNCTION = 14; + + // CREATE PROCEDURE <Procedure> + CREATE_PROCEDURE = 20; + + // CREATE SCHEMA <Schema> + CREATE_SCHEMA = 53; + + // DROP TABLE <Table> + DROP_TABLE = 10; + + // DROP EXTERNAL TABLE <Table> + DROP_EXTERNAL_TABLE = 33; + + // DROP VIEW <View> + DROP_VIEW = 11; + + // DROP MODEL <Model> + DROP_MODEL = 12; + + // DROP MATERIALIZED VIEW <View> + DROP_MATERIALIZED_VIEW = 15; + + // DROP FUNCTION <Function> + DROP_FUNCTION = 16; + + // DROP PROCEDURE <Procedure> + DROP_PROCEDURE = 21; + + // DROP SCHEMA <Schema> + DROP_SCHEMA = 54; + + // ALTER TABLE <Table> + ALTER_TABLE = 17; + + // ALTER VIEW <View> + ALTER_VIEW = 18; + + // ALTER MATERIALIZED_VIEW <view> + ALTER_MATERIALIZED_VIEW = 22; + + // ALTER SCHEMA <Schema> + ALTER_SCHEMA = 55; + + // Script + SCRIPT = 19; + + // TRUNCATE TABLE <Table> + TRUNCATE_TABLE = 26; + + // CREATE EXTERNAL TABLE <TABLE> + CREATE_EXTERNAL_TABLE = 27; + + // EXPORT DATA; + EXPORT_DATA = 28; + + // CALL <stored procedure> + CALL = 29; + } + + // BigQuery event information. + oneof event { + // Job insertion event. + JobInsertion job_insertion = 1; + + // Job state change event. + JobChange job_change = 2; + + // Dataset creation event. + DatasetCreation dataset_creation = 3; + + // Dataset change event. + DatasetChange dataset_change = 4; + + // Dataset deletion event. + DatasetDeletion dataset_deletion = 5; + + // Table creation event. + TableCreation table_creation = 6; + + // Table metadata change event. + TableChange table_change = 8; + + // Table deletion event. + TableDeletion table_deletion = 9; + + // Table data read event. + TableDataRead table_data_read = 10; + + // Table data change event. + TableDataChange table_data_change = 11; + + // Model deletion event. + ModelDeletion model_deletion = 12; + + // Model creation event. + ModelCreation model_creation = 13; + + // Model metadata change event. + ModelMetadataChange model_metadata_change = 14; + + // Model data change event. + ModelDataChange model_data_change = 15; + + // Model data read event. + ModelDataRead model_data_read = 19; + + // Routine creation event. + RoutineCreation routine_creation = 16; + + // Routine change event. + RoutineChange routine_change = 17; + + // Routine deletion event. + RoutineDeletion routine_deletion = 18; + } +} diff --git a/synth.metadata b/synth.metadata index 32d0ffaf..14a309d5 100644 --- a/synth.metadata +++ b/synth.metadata @@ -3,395 +3,23 @@ { "git": { "name": ".", - "remote": "https://github.com/googleapis/java-common-protos.git", - "sha": "4942688dbe02580ea0be48e9a9366d489bb3c9d6" + "remote": "git@github.com:googleapis/java-common-protos.git", + "sha": "66db02e9b97c724179a2110671a51bc2ce92b3df" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "aa136fa6649f7d999bf3873d0e5fca75cb2354a5", - "internalRef": "382337225" + "sha": "ccb73479aebb76f13698907884269bb7a38b4207" } }, { "git": { "name": "synthtool", "remote": "https://github.com/googleapis/synthtool.git", - "sha": "5d3c52f5db664eee9026db76b5bcb466f3a09ca9" + "sha": "31728d872f50e439ded2f67fa8d67955b26a4e35" } } - ], - "generatedFiles": [ - ".github/CODEOWNERS", - ".github/ISSUE_TEMPLATE/bug_report.md", - ".github/ISSUE_TEMPLATE/feature_request.md", - ".github/ISSUE_TEMPLATE/support_request.md", - ".github/PULL_REQUEST_TEMPLATE.md", - ".github/blunderbuss.yml", - ".github/generated-files-bot.yml", - ".github/readme/synth.py", - ".github/release-please.yml", - ".github/snippet-bot.yml", - ".github/sync-repo-settings.yaml", - ".github/trusted-contribution.yml", - ".github/workflows/approve-readme.yaml", - ".github/workflows/auto-release.yaml", - ".github/workflows/ci.yaml", - ".kokoro/build.bat", - ".kokoro/build.sh", - ".kokoro/coerce_logs.sh", - ".kokoro/common.cfg", - ".kokoro/common.sh", - ".kokoro/continuous/common.cfg", - ".kokoro/continuous/java8.cfg", - ".kokoro/continuous/readme.cfg", - ".kokoro/dependencies.sh", - ".kokoro/nightly/common.cfg", - ".kokoro/nightly/integration.cfg", - ".kokoro/nightly/java11.cfg", - ".kokoro/nightly/java7.cfg", - ".kokoro/nightly/java8-osx.cfg", - ".kokoro/nightly/java8-win.cfg", - ".kokoro/nightly/java8.cfg", - ".kokoro/nightly/samples.cfg", - ".kokoro/populate-secrets.sh", - ".kokoro/presubmit/clirr.cfg", - ".kokoro/presubmit/common.cfg", - ".kokoro/presubmit/dependencies.cfg", - ".kokoro/presubmit/integration.cfg", - ".kokoro/presubmit/java11.cfg", - ".kokoro/presubmit/java7.cfg", - ".kokoro/presubmit/java8-osx.cfg", - ".kokoro/presubmit/java8-win.cfg", - ".kokoro/presubmit/java8.cfg", - ".kokoro/presubmit/linkage-monitor.cfg", - ".kokoro/presubmit/lint.cfg", - ".kokoro/presubmit/samples.cfg", - ".kokoro/readme.sh", - ".kokoro/release/bump_snapshot.cfg", - ".kokoro/release/common.cfg", - ".kokoro/release/common.sh", - ".kokoro/release/drop.cfg", - ".kokoro/release/drop.sh", - ".kokoro/release/promote.cfg", - ".kokoro/release/promote.sh", - ".kokoro/release/publish_javadoc.cfg", - ".kokoro/release/publish_javadoc.sh", - ".kokoro/release/publish_javadoc11.cfg", - ".kokoro/release/publish_javadoc11.sh", - ".kokoro/release/snapshot.cfg", - ".kokoro/release/snapshot.sh", - ".kokoro/release/stage.cfg", - ".kokoro/release/stage.sh", - ".kokoro/trampoline.sh", - "CODE_OF_CONDUCT.md", - "CONTRIBUTING.md", - "LICENSE", - "SECURITY.md", - "codecov.yaml", - "grpc-google-common-protos/src/main/java/com/google/longrunning/OperationsGrpc.java", - "java.header", - "license-checks.xml", - "proto-google-common-protos/src/main/java/com/google/api/Advice.java", - "proto-google-common-protos/src/main/java/com/google/api/AdviceOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/AnnotationsProto.java", - "proto-google-common-protos/src/main/java/com/google/api/AuthProto.java", - "proto-google-common-protos/src/main/java/com/google/api/AuthProvider.java", - "proto-google-common-protos/src/main/java/com/google/api/AuthProviderOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/AuthRequirement.java", - "proto-google-common-protos/src/main/java/com/google/api/AuthRequirementOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Authentication.java", - "proto-google-common-protos/src/main/java/com/google/api/AuthenticationOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/AuthenticationRule.java", - "proto-google-common-protos/src/main/java/com/google/api/AuthenticationRuleOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Backend.java", - "proto-google-common-protos/src/main/java/com/google/api/BackendOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/BackendProto.java", - "proto-google-common-protos/src/main/java/com/google/api/BackendRule.java", - "proto-google-common-protos/src/main/java/com/google/api/BackendRuleOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Billing.java", - "proto-google-common-protos/src/main/java/com/google/api/BillingOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/BillingProto.java", - "proto-google-common-protos/src/main/java/com/google/api/ChangeType.java", - "proto-google-common-protos/src/main/java/com/google/api/ClientProto.java", - "proto-google-common-protos/src/main/java/com/google/api/ConfigChange.java", - "proto-google-common-protos/src/main/java/com/google/api/ConfigChangeOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/ConfigChangeProto.java", - "proto-google-common-protos/src/main/java/com/google/api/ConsumerProto.java", - "proto-google-common-protos/src/main/java/com/google/api/Context.java", - "proto-google-common-protos/src/main/java/com/google/api/ContextOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/ContextProto.java", - "proto-google-common-protos/src/main/java/com/google/api/ContextRule.java", - "proto-google-common-protos/src/main/java/com/google/api/ContextRuleOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Control.java", - "proto-google-common-protos/src/main/java/com/google/api/ControlOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/ControlProto.java", - "proto-google-common-protos/src/main/java/com/google/api/CustomHttpPattern.java", - "proto-google-common-protos/src/main/java/com/google/api/CustomHttpPatternOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Distribution.java", - "proto-google-common-protos/src/main/java/com/google/api/DistributionOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/DistributionProto.java", - "proto-google-common-protos/src/main/java/com/google/api/Documentation.java", - "proto-google-common-protos/src/main/java/com/google/api/DocumentationOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/DocumentationProto.java", - "proto-google-common-protos/src/main/java/com/google/api/DocumentationRule.java", - "proto-google-common-protos/src/main/java/com/google/api/DocumentationRuleOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Endpoint.java", - "proto-google-common-protos/src/main/java/com/google/api/EndpointOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/EndpointProto.java", - "proto-google-common-protos/src/main/java/com/google/api/FieldBehavior.java", - "proto-google-common-protos/src/main/java/com/google/api/FieldBehaviorProto.java", - "proto-google-common-protos/src/main/java/com/google/api/Http.java", - "proto-google-common-protos/src/main/java/com/google/api/HttpBody.java", - "proto-google-common-protos/src/main/java/com/google/api/HttpBodyOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/HttpBodyProto.java", - "proto-google-common-protos/src/main/java/com/google/api/HttpOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/HttpProto.java", - "proto-google-common-protos/src/main/java/com/google/api/HttpRule.java", - "proto-google-common-protos/src/main/java/com/google/api/HttpRuleOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/JwtLocation.java", - "proto-google-common-protos/src/main/java/com/google/api/JwtLocationOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/LabelDescriptor.java", - "proto-google-common-protos/src/main/java/com/google/api/LabelDescriptorOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/LabelProto.java", - "proto-google-common-protos/src/main/java/com/google/api/LaunchStage.java", - "proto-google-common-protos/src/main/java/com/google/api/LaunchStageProto.java", - "proto-google-common-protos/src/main/java/com/google/api/LogDescriptor.java", - "proto-google-common-protos/src/main/java/com/google/api/LogDescriptorOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/LogProto.java", - "proto-google-common-protos/src/main/java/com/google/api/Logging.java", - "proto-google-common-protos/src/main/java/com/google/api/LoggingOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/LoggingProto.java", - "proto-google-common-protos/src/main/java/com/google/api/Metric.java", - "proto-google-common-protos/src/main/java/com/google/api/MetricDescriptor.java", - "proto-google-common-protos/src/main/java/com/google/api/MetricDescriptorOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/MetricOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/MetricProto.java", - "proto-google-common-protos/src/main/java/com/google/api/MetricRule.java", - "proto-google-common-protos/src/main/java/com/google/api/MetricRuleOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/MonitoredResource.java", - "proto-google-common-protos/src/main/java/com/google/api/MonitoredResourceDescriptor.java", - "proto-google-common-protos/src/main/java/com/google/api/MonitoredResourceDescriptorOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/MonitoredResourceMetadata.java", - "proto-google-common-protos/src/main/java/com/google/api/MonitoredResourceMetadataOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/MonitoredResourceOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/MonitoredResourceProto.java", - "proto-google-common-protos/src/main/java/com/google/api/Monitoring.java", - "proto-google-common-protos/src/main/java/com/google/api/MonitoringOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/MonitoringProto.java", - "proto-google-common-protos/src/main/java/com/google/api/OAuthRequirements.java", - "proto-google-common-protos/src/main/java/com/google/api/OAuthRequirementsOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Page.java", - "proto-google-common-protos/src/main/java/com/google/api/PageOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/ProjectProperties.java", - "proto-google-common-protos/src/main/java/com/google/api/ProjectPropertiesOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Property.java", - "proto-google-common-protos/src/main/java/com/google/api/PropertyOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Quota.java", - "proto-google-common-protos/src/main/java/com/google/api/QuotaLimit.java", - "proto-google-common-protos/src/main/java/com/google/api/QuotaLimitOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/QuotaOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/QuotaProto.java", - "proto-google-common-protos/src/main/java/com/google/api/ResourceDescriptor.java", - "proto-google-common-protos/src/main/java/com/google/api/ResourceDescriptorOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/ResourceProto.java", - "proto-google-common-protos/src/main/java/com/google/api/ResourceReference.java", - "proto-google-common-protos/src/main/java/com/google/api/ResourceReferenceOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Service.java", - "proto-google-common-protos/src/main/java/com/google/api/ServiceOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/ServiceProto.java", - "proto-google-common-protos/src/main/java/com/google/api/SourceInfo.java", - "proto-google-common-protos/src/main/java/com/google/api/SourceInfoOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/SourceInfoProto.java", - "proto-google-common-protos/src/main/java/com/google/api/SystemParameter.java", - "proto-google-common-protos/src/main/java/com/google/api/SystemParameterOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/SystemParameterProto.java", - "proto-google-common-protos/src/main/java/com/google/api/SystemParameterRule.java", - "proto-google-common-protos/src/main/java/com/google/api/SystemParameterRuleOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/SystemParameters.java", - "proto-google-common-protos/src/main/java/com/google/api/SystemParametersOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Usage.java", - "proto-google-common-protos/src/main/java/com/google/api/UsageOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/UsageProto.java", - "proto-google-common-protos/src/main/java/com/google/api/UsageRule.java", - "proto-google-common-protos/src/main/java/com/google/api/UsageRuleOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/Visibility.java", - "proto-google-common-protos/src/main/java/com/google/api/VisibilityOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/api/VisibilityProto.java", - "proto-google-common-protos/src/main/java/com/google/api/VisibilityRule.java", - "proto-google-common-protos/src/main/java/com/google/api/VisibilityRuleOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/AuditLog.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/AuditLogOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/AuditLogProto.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/AuthenticationInfo.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/AuthenticationInfoOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/AuthorizationInfo.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/AuthorizationInfoOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/RequestMetadata.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/RequestMetadataOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/ResourceLocation.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/ResourceLocationOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/ServiceAccountDelegationInfo.java", - "proto-google-common-protos/src/main/java/com/google/cloud/audit/ServiceAccountDelegationInfoOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/geo/type/Viewport.java", - "proto-google-common-protos/src/main/java/com/google/geo/type/ViewportOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/geo/type/ViewportProto.java", - "proto-google-common-protos/src/main/java/com/google/logging/type/HttpRequest.java", - "proto-google-common-protos/src/main/java/com/google/logging/type/HttpRequestOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/logging/type/HttpRequestProto.java", - "proto-google-common-protos/src/main/java/com/google/logging/type/LogSeverity.java", - "proto-google-common-protos/src/main/java/com/google/logging/type/LogSeverityProto.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/CancelOperationRequest.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/CancelOperationRequestOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/DeleteOperationRequest.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/DeleteOperationRequestOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/GetOperationRequest.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/GetOperationRequestOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/ListOperationsRequest.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/ListOperationsRequestOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/ListOperationsResponse.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/ListOperationsResponseOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/Operation.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/OperationInfo.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/OperationInfoOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/OperationOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/OperationsProto.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/WaitOperationRequest.java", - "proto-google-common-protos/src/main/java/com/google/longrunning/WaitOperationRequestOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/BadRequest.java", - "proto-google-common-protos/src/main/java/com/google/rpc/BadRequestOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/Code.java", - "proto-google-common-protos/src/main/java/com/google/rpc/CodeProto.java", - "proto-google-common-protos/src/main/java/com/google/rpc/DebugInfo.java", - "proto-google-common-protos/src/main/java/com/google/rpc/DebugInfoOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/ErrorDetailsProto.java", - "proto-google-common-protos/src/main/java/com/google/rpc/ErrorInfo.java", - "proto-google-common-protos/src/main/java/com/google/rpc/ErrorInfoOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/Help.java", - "proto-google-common-protos/src/main/java/com/google/rpc/HelpOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/LocalizedMessage.java", - "proto-google-common-protos/src/main/java/com/google/rpc/LocalizedMessageOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/PreconditionFailure.java", - "proto-google-common-protos/src/main/java/com/google/rpc/PreconditionFailureOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/QuotaFailure.java", - "proto-google-common-protos/src/main/java/com/google/rpc/QuotaFailureOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/RequestInfo.java", - "proto-google-common-protos/src/main/java/com/google/rpc/RequestInfoOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/ResourceInfo.java", - "proto-google-common-protos/src/main/java/com/google/rpc/ResourceInfoOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/RetryInfo.java", - "proto-google-common-protos/src/main/java/com/google/rpc/RetryInfoOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/Status.java", - "proto-google-common-protos/src/main/java/com/google/rpc/StatusOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/StatusProto.java", - "proto-google-common-protos/src/main/java/com/google/rpc/context/AttributeContext.java", - "proto-google-common-protos/src/main/java/com/google/rpc/context/AttributeContextOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/rpc/context/AttributeContextProto.java", - "proto-google-common-protos/src/main/java/com/google/type/CalendarPeriod.java", - "proto-google-common-protos/src/main/java/com/google/type/CalendarPeriodProto.java", - "proto-google-common-protos/src/main/java/com/google/type/Color.java", - "proto-google-common-protos/src/main/java/com/google/type/ColorOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/ColorProto.java", - "proto-google-common-protos/src/main/java/com/google/type/Date.java", - "proto-google-common-protos/src/main/java/com/google/type/DateOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/DateProto.java", - "proto-google-common-protos/src/main/java/com/google/type/DateTime.java", - "proto-google-common-protos/src/main/java/com/google/type/DateTimeOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/DateTimeProto.java", - "proto-google-common-protos/src/main/java/com/google/type/DayOfWeek.java", - "proto-google-common-protos/src/main/java/com/google/type/DayOfWeekProto.java", - "proto-google-common-protos/src/main/java/com/google/type/Decimal.java", - "proto-google-common-protos/src/main/java/com/google/type/DecimalOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/DecimalProto.java", - "proto-google-common-protos/src/main/java/com/google/type/Expr.java", - "proto-google-common-protos/src/main/java/com/google/type/ExprOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/ExprProto.java", - "proto-google-common-protos/src/main/java/com/google/type/Fraction.java", - "proto-google-common-protos/src/main/java/com/google/type/FractionOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/FractionProto.java", - "proto-google-common-protos/src/main/java/com/google/type/Interval.java", - "proto-google-common-protos/src/main/java/com/google/type/IntervalOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/IntervalProto.java", - "proto-google-common-protos/src/main/java/com/google/type/LatLng.java", - "proto-google-common-protos/src/main/java/com/google/type/LatLngOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/LatLngProto.java", - "proto-google-common-protos/src/main/java/com/google/type/Money.java", - "proto-google-common-protos/src/main/java/com/google/type/MoneyOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/MoneyProto.java", - "proto-google-common-protos/src/main/java/com/google/type/Month.java", - "proto-google-common-protos/src/main/java/com/google/type/MonthProto.java", - "proto-google-common-protos/src/main/java/com/google/type/PhoneNumber.java", - "proto-google-common-protos/src/main/java/com/google/type/PhoneNumberOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/PhoneNumberProto.java", - "proto-google-common-protos/src/main/java/com/google/type/PostalAddress.java", - "proto-google-common-protos/src/main/java/com/google/type/PostalAddressOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/PostalAddressProto.java", - "proto-google-common-protos/src/main/java/com/google/type/Quaternion.java", - "proto-google-common-protos/src/main/java/com/google/type/QuaternionOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/QuaternionProto.java", - "proto-google-common-protos/src/main/java/com/google/type/TimeOfDay.java", - "proto-google-common-protos/src/main/java/com/google/type/TimeOfDayOrBuilder.java", - "proto-google-common-protos/src/main/java/com/google/type/TimeOfDayProto.java", - "proto-google-common-protos/src/main/java/com/google/type/TimeZone.java", - "proto-google-common-protos/src/main/java/com/google/type/TimeZoneOrBuilder.java", - "proto-google-common-protos/src/main/proto/google/api/annotations.proto", - "proto-google-common-protos/src/main/proto/google/api/auth.proto", - "proto-google-common-protos/src/main/proto/google/api/backend.proto", - "proto-google-common-protos/src/main/proto/google/api/billing.proto", - "proto-google-common-protos/src/main/proto/google/api/client.proto", - "proto-google-common-protos/src/main/proto/google/api/config_change.proto", - "proto-google-common-protos/src/main/proto/google/api/consumer.proto", - "proto-google-common-protos/src/main/proto/google/api/context.proto", - "proto-google-common-protos/src/main/proto/google/api/control.proto", - "proto-google-common-protos/src/main/proto/google/api/distribution.proto", - "proto-google-common-protos/src/main/proto/google/api/documentation.proto", - "proto-google-common-protos/src/main/proto/google/api/endpoint.proto", - "proto-google-common-protos/src/main/proto/google/api/error_reason.proto", - "proto-google-common-protos/src/main/proto/google/api/field_behavior.proto", - "proto-google-common-protos/src/main/proto/google/api/http.proto", - "proto-google-common-protos/src/main/proto/google/api/httpbody.proto", - "proto-google-common-protos/src/main/proto/google/api/label.proto", - "proto-google-common-protos/src/main/proto/google/api/launch_stage.proto", - "proto-google-common-protos/src/main/proto/google/api/log.proto", - "proto-google-common-protos/src/main/proto/google/api/logging.proto", - "proto-google-common-protos/src/main/proto/google/api/metric.proto", - "proto-google-common-protos/src/main/proto/google/api/monitored_resource.proto", - "proto-google-common-protos/src/main/proto/google/api/monitoring.proto", - "proto-google-common-protos/src/main/proto/google/api/quota.proto", - "proto-google-common-protos/src/main/proto/google/api/resource.proto", - "proto-google-common-protos/src/main/proto/google/api/service.proto", - "proto-google-common-protos/src/main/proto/google/api/source_info.proto", - "proto-google-common-protos/src/main/proto/google/api/system_parameter.proto", - "proto-google-common-protos/src/main/proto/google/api/usage.proto", - "proto-google-common-protos/src/main/proto/google/api/visibility.proto", - "proto-google-common-protos/src/main/proto/google/cloud/audit/audit_log.proto", - "proto-google-common-protos/src/main/proto/google/geo/type/viewport.proto", - "proto-google-common-protos/src/main/proto/google/logging/type/http_request.proto", - "proto-google-common-protos/src/main/proto/google/logging/type/log_severity.proto", - "proto-google-common-protos/src/main/proto/google/longrunning/operations.proto", - "proto-google-common-protos/src/main/proto/google/rpc/code.proto", - "proto-google-common-protos/src/main/proto/google/rpc/context/attribute_context.proto", - "proto-google-common-protos/src/main/proto/google/rpc/error_details.proto", - "proto-google-common-protos/src/main/proto/google/rpc/status.proto", - "proto-google-common-protos/src/main/proto/google/type/calendar_period.proto", - "proto-google-common-protos/src/main/proto/google/type/color.proto", - "proto-google-common-protos/src/main/proto/google/type/date.proto", - "proto-google-common-protos/src/main/proto/google/type/datetime.proto", - "proto-google-common-protos/src/main/proto/google/type/dayofweek.proto", - "proto-google-common-protos/src/main/proto/google/type/decimal.proto", - "proto-google-common-protos/src/main/proto/google/type/expr.proto", - "proto-google-common-protos/src/main/proto/google/type/fraction.proto", - "proto-google-common-protos/src/main/proto/google/type/interval.proto", - "proto-google-common-protos/src/main/proto/google/type/latlng.proto", - "proto-google-common-protos/src/main/proto/google/type/localized_text.proto", - "proto-google-common-protos/src/main/proto/google/type/money.proto", - "proto-google-common-protos/src/main/proto/google/type/month.proto", - "proto-google-common-protos/src/main/proto/google/type/phone_number.proto", - "proto-google-common-protos/src/main/proto/google/type/postal_address.proto", - "proto-google-common-protos/src/main/proto/google/type/quaternion.proto", - "proto-google-common-protos/src/main/proto/google/type/timeofday.proto", - "renovate.json" ] } \ No newline at end of file From 92eb2634d6a174f5d2011269b9051afb85d089b4 Mon Sep 17 00:00:00 2001 From: Neenu1995 Date: Thu, 26 Aug 2021 17:45:42 -0400 Subject: [PATCH 2/3] feat: generate java files for extended_operations.proto --- .../google/cloud/ExtendedOperationsProto.java | 181 +++++++++++++ .../cloud/OperationResponseMapping.java | 242 ++++++++++++++++++ .../proto/google/cloud/common_resources.proto | 52 ++++ .../google/cloud/extended_operations.proto | 150 +++++++++++ synth.metadata | 2 +- synth.py | 1 + 6 files changed, 627 insertions(+), 1 deletion(-) create mode 100644 proto-google-common-protos/src/main/java/com/google/cloud/ExtendedOperationsProto.java create mode 100644 proto-google-common-protos/src/main/java/com/google/cloud/OperationResponseMapping.java create mode 100644 proto-google-common-protos/src/main/proto/google/cloud/common_resources.proto create mode 100644 proto-google-common-protos/src/main/proto/google/cloud/extended_operations.proto diff --git a/proto-google-common-protos/src/main/java/com/google/cloud/ExtendedOperationsProto.java b/proto-google-common-protos/src/main/java/com/google/cloud/ExtendedOperationsProto.java new file mode 100644 index 00000000..e5215cdc --- /dev/null +++ b/proto-google-common-protos/src/main/java/com/google/cloud/ExtendedOperationsProto.java @@ -0,0 +1,181 @@ +/* + * 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/cloud/extended_operations.proto + +package com.google.cloud; + +public final class ExtendedOperationsProto { + private ExtendedOperationsProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) { + registry.add(com.google.cloud.ExtendedOperationsProto.operationField); + registry.add(com.google.cloud.ExtendedOperationsProto.operationRequestField); + registry.add(com.google.cloud.ExtendedOperationsProto.operationResponseField); + registry.add(com.google.cloud.ExtendedOperationsProto.operationService); + registry.add(com.google.cloud.ExtendedOperationsProto.operationPollingMethod); + } + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + public static final int OPERATION_FIELD_FIELD_NUMBER = 1149; + /** + * + * + *
+   * A field annotation that maps fields in an API-specific Operation object to
+   * their standard counterparts in google.longrunning.Operation. See
+   * OperationResponseMapping enum definition.
+   * 
+ * + * extend .google.protobuf.FieldOptions { ... } + */ + public static final com.google.protobuf.GeneratedMessage.GeneratedExtension< + com.google.protobuf.DescriptorProtos.FieldOptions, + com.google.cloud.OperationResponseMapping> + operationField = + com.google.protobuf.GeneratedMessage.newFileScopedGeneratedExtension( + com.google.cloud.OperationResponseMapping.class, null); + + public static final int OPERATION_REQUEST_FIELD_FIELD_NUMBER = 1150; + /** + * + * + *
+   * A field annotation that maps fields in the initial request message
+   * (the one which started the LRO) to their counterparts in the polling
+   * request message. For non-standard LRO, the polling response may be missing
+   * some of the information needed to make a subsequent polling request. The
+   * missing information (for example, project or region ID) is contained in the
+   * fields of the initial request message that this annotation must be applied
+   * to. The string value of the annotation corresponds to the name of the
+   * counterpart field in the polling request message that the annotated field's
+   * value will be copied to.
+   * 
+ * + * extend .google.protobuf.FieldOptions { ... } + */ + public static final com.google.protobuf.GeneratedMessage.GeneratedExtension< + com.google.protobuf.DescriptorProtos.FieldOptions, java.lang.String> + operationRequestField = + com.google.protobuf.GeneratedMessage.newFileScopedGeneratedExtension( + java.lang.String.class, null); + + public static final int OPERATION_RESPONSE_FIELD_FIELD_NUMBER = 1151; + /** + * + * + *
+   * A field annotation that maps fields in the polling request message to their
+   * counterparts in the initial and/or polling response message. The initial
+   * and the polling methods return an API-specific Operation object. Some of
+   * the fields from that response object must be reused in the subsequent
+   * request (like operation name/ID) to fully identify the polled operation.
+   * This annotation must be applied to the fields in the polling request
+   * message, the string value of the annotation must correspond to the name of
+   * the counterpart field in the Operation response object whose value will be
+   * copied to the annotated field.
+   * 
+ * + * extend .google.protobuf.FieldOptions { ... } + */ + public static final com.google.protobuf.GeneratedMessage.GeneratedExtension< + com.google.protobuf.DescriptorProtos.FieldOptions, java.lang.String> + operationResponseField = + com.google.protobuf.GeneratedMessage.newFileScopedGeneratedExtension( + java.lang.String.class, null); + + public static final int OPERATION_SERVICE_FIELD_NUMBER = 1249; + /** + * + * + *
+   * A method annotation that maps an LRO method (the one which starts an LRO)
+   * to the service, which will be used to poll for the operation status. The
+   * annotation must be applied to the method which starts an LRO, the string
+   * value of the annotation must correspond to the name of the service used to
+   * poll for the operation status.
+   * 
+ * + * extend .google.protobuf.MethodOptions { ... } + */ + public static final com.google.protobuf.GeneratedMessage.GeneratedExtension< + com.google.protobuf.DescriptorProtos.MethodOptions, java.lang.String> + operationService = + com.google.protobuf.GeneratedMessage.newFileScopedGeneratedExtension( + java.lang.String.class, null); + + public static final int OPERATION_POLLING_METHOD_FIELD_NUMBER = 1250; + /** + * + * + *
+   * A method annotation that marks methods that can be used for polling
+   * operation status (e.g. the MyPollingService.Get(MyPollingRequest) method).
+   * 
+ * + * extend .google.protobuf.MethodOptions { ... } + */ + public static final com.google.protobuf.GeneratedMessage.GeneratedExtension< + com.google.protobuf.DescriptorProtos.MethodOptions, java.lang.Boolean> + operationPollingMethod = + com.google.protobuf.GeneratedMessage.newFileScopedGeneratedExtension( + java.lang.Boolean.class, null); + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n&google/cloud/extended_operations.proto" + + "\022\014google.cloud\032 google/protobuf/descript" + + "or.proto*b\n\030OperationResponseMapping\022\r\n\t" + + "UNDEFINED\020\000\022\010\n\004NAME\020\001\022\n\n\006STATUS\020\002\022\016\n\nERR" + + "OR_CODE\020\003\022\021\n\rERROR_MESSAGE\020\004:_\n\017operatio" + + "n_field\022\035.google.protobuf.FieldOptions\030\375" + + "\010 \001(\0162&.google.cloud.OperationResponseMa" + + "pping:?\n\027operation_request_field\022\035.googl" + + "e.protobuf.FieldOptions\030\376\010 \001(\t:@\n\030operat" + + "ion_response_field\022\035.google.protobuf.Fie" + + "ldOptions\030\377\010 \001(\t::\n\021operation_service\022\036." + + "google.protobuf.MethodOptions\030\341\t \001(\t:A\n\030" + + "operation_polling_method\022\036.google.protob" + + "uf.MethodOptions\030\342\t \001(\010By\n\020com.google.cl" + + "oudB\027ExtendedOperationsProtoP\001ZCgoogle.g" + + "olang.org/genproto/googleapis/cloud/exte" + + "ndedops;extendedops\242\002\004GAPIb\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.protobuf.DescriptorProtos.getDescriptor(), + }); + operationField.internalInit(descriptor.getExtensions().get(0)); + operationRequestField.internalInit(descriptor.getExtensions().get(1)); + operationResponseField.internalInit(descriptor.getExtensions().get(2)); + operationService.internalInit(descriptor.getExtensions().get(3)); + operationPollingMethod.internalInit(descriptor.getExtensions().get(4)); + com.google.protobuf.DescriptorProtos.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/proto-google-common-protos/src/main/java/com/google/cloud/OperationResponseMapping.java b/proto-google-common-protos/src/main/java/com/google/cloud/OperationResponseMapping.java new file mode 100644 index 00000000..212af822 --- /dev/null +++ b/proto-google-common-protos/src/main/java/com/google/cloud/OperationResponseMapping.java @@ -0,0 +1,242 @@ +/* + * 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/cloud/extended_operations.proto + +package com.google.cloud; + +/** + * + * + *
+ * An enum to be used to mark the essential (for polling) fields in an
+ * API-specific Operation object. A custom Operation object may contain many
+ * different fields, but only few of them are essential to conduct a successful
+ * polling process.
+ * 
+ * + * Protobuf enum {@code google.cloud.OperationResponseMapping} + */ +public enum OperationResponseMapping implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+   * Do not use.
+   * 
+ * + * UNDEFINED = 0; + */ + UNDEFINED(0), + /** + * + * + *
+   * A field in an API-specific (custom) Operation object which carries the same
+   * meaning as google.longrunning.Operation.name.
+   * 
+ * + * NAME = 1; + */ + NAME(1), + /** + * + * + *
+   * A field in an API-specific (custom) Operation object which carries the same
+   * meaning as google.longrunning.Operation.done. If the annotated field is of
+   * an enum type, `annotated_field_name == EnumType.DONE` semantics should be
+   * equivalent to `Operation.done == true`. If the annotated field is of type
+   * boolean, then it should follow the same semantics as Operation.done.
+   * Otherwise, a non-empty value should be treated as `Operation.done == true`.
+   * 
+ * + * STATUS = 2; + */ + STATUS(2), + /** + * + * + *
+   * A field in an API-specific (custom) Operation object which carries the same
+   * meaning as google.longrunning.Operation.error.code.
+   * 
+ * + * ERROR_CODE = 3; + */ + ERROR_CODE(3), + /** + * + * + *
+   * A field in an API-specific (custom) Operation object which carries the same
+   * meaning as google.longrunning.Operation.error.message.
+   * 
+ * + * ERROR_MESSAGE = 4; + */ + ERROR_MESSAGE(4), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+   * Do not use.
+   * 
+ * + * UNDEFINED = 0; + */ + public static final int UNDEFINED_VALUE = 0; + /** + * + * + *
+   * A field in an API-specific (custom) Operation object which carries the same
+   * meaning as google.longrunning.Operation.name.
+   * 
+ * + * NAME = 1; + */ + public static final int NAME_VALUE = 1; + /** + * + * + *
+   * A field in an API-specific (custom) Operation object which carries the same
+   * meaning as google.longrunning.Operation.done. If the annotated field is of
+   * an enum type, `annotated_field_name == EnumType.DONE` semantics should be
+   * equivalent to `Operation.done == true`. If the annotated field is of type
+   * boolean, then it should follow the same semantics as Operation.done.
+   * Otherwise, a non-empty value should be treated as `Operation.done == true`.
+   * 
+ * + * STATUS = 2; + */ + public static final int STATUS_VALUE = 2; + /** + * + * + *
+   * A field in an API-specific (custom) Operation object which carries the same
+   * meaning as google.longrunning.Operation.error.code.
+   * 
+ * + * ERROR_CODE = 3; + */ + public static final int ERROR_CODE_VALUE = 3; + /** + * + * + *
+   * A field in an API-specific (custom) Operation object which carries the same
+   * meaning as google.longrunning.Operation.error.message.
+   * 
+ * + * ERROR_MESSAGE = 4; + */ + public static final int ERROR_MESSAGE_VALUE = 4; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static OperationResponseMapping 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 OperationResponseMapping forNumber(int value) { + switch (value) { + case 0: + return UNDEFINED; + case 1: + return NAME; + case 2: + return STATUS; + case 3: + return ERROR_CODE; + case 4: + return ERROR_MESSAGE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public OperationResponseMapping findValueByNumber(int number) { + return OperationResponseMapping.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.ExtendedOperationsProto.getDescriptor().getEnumTypes().get(0); + } + + private static final OperationResponseMapping[] VALUES = values(); + + public static OperationResponseMapping valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private OperationResponseMapping(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.OperationResponseMapping) +} diff --git a/proto-google-common-protos/src/main/proto/google/cloud/common_resources.proto b/proto-google-common-protos/src/main/proto/google/cloud/common_resources.proto new file mode 100644 index 00000000..56c9f800 --- /dev/null +++ b/proto-google-common-protos/src/main/proto/google/cloud/common_resources.proto @@ -0,0 +1,52 @@ +// 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 file contains stub messages for common resources in GCP. +// It is not intended to be directly generated, and is instead used by +// other tooling to be able to match common resource patterns. +syntax = "proto3"; + +package google.cloud; + +import "google/api/resource.proto"; + + +option (google.api.resource_definition) = { + type: "cloudresourcemanager.googleapis.com/Project" + pattern: "projects/{project}" +}; + + +option (google.api.resource_definition) = { + type: "cloudresourcemanager.googleapis.com/Organization" + pattern: "organizations/{organization}" +}; + + +option (google.api.resource_definition) = { + type: "cloudresourcemanager.googleapis.com/Folder" + pattern: "folders/{folder}" +}; + + +option (google.api.resource_definition) = { + type: "cloudbilling.googleapis.com/BillingAccount" + pattern: "billingAccounts/{billing_account}" +}; + +option (google.api.resource_definition) = { + type: "locations.googleapis.com/Location" + pattern: "projects/{project}/locations/{location}" +}; + diff --git a/proto-google-common-protos/src/main/proto/google/cloud/extended_operations.proto b/proto-google-common-protos/src/main/proto/google/cloud/extended_operations.proto new file mode 100644 index 00000000..1477d2d6 --- /dev/null +++ b/proto-google-common-protos/src/main/proto/google/cloud/extended_operations.proto @@ -0,0 +1,150 @@ +// Copyright 2021 Google LLC. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// This file contains custom annotations that are used by GAPIC generators to +// handle Long Running Operation methods (LRO) that are NOT compliant with +// https://google.aip.dev/151. These annotations are public for technical +// reasons only. Please DO NOT USE them in your protos. +syntax = "proto3"; + +package google.cloud; + +import "google/protobuf/descriptor.proto"; + +option go_package = "google.golang.org/genproto/googleapis/cloud/extendedops;extendedops"; +option java_multiple_files = true; +option java_outer_classname = "ExtendedOperationsProto"; +option java_package = "com.google.cloud"; +option objc_class_prefix = "GAPI"; + +// FieldOptions to match corresponding fields in the initial request, +// polling request and operation response messages. +// +// Example: +// +// In an API-specific operation message: +// +// message MyOperation { +// string http_error_message = 1 [(operation_field) = ERROR_MESSAGE]; +// int32 http_error_status_code = 2 [(operation_field) = ERROR_CODE]; +// string id = 3 [(operation_field) = NAME]; +// Status status = 4 [(operation_field) = STATUS]; +// } +// +// In a polling request message (the one which is used to poll for an LRO +// status): +// +// message MyPollingRequest { +// string operation = 1 [(operation_response_field) = "id"]; +// string project = 2; +// string region = 3; +// } +// +// In an initial request message (the one which starts an LRO): +// +// message MyInitialRequest { +// string my_project = 2 [(operation_request_field) = "project"]; +// string my_region = 3 [(operation_request_field) = "region"]; +// } +// +extend google.protobuf.FieldOptions { + // A field annotation that maps fields in an API-specific Operation object to + // their standard counterparts in google.longrunning.Operation. See + // OperationResponseMapping enum definition. + OperationResponseMapping operation_field = 1149; + + // A field annotation that maps fields in the initial request message + // (the one which started the LRO) to their counterparts in the polling + // request message. For non-standard LRO, the polling response may be missing + // some of the information needed to make a subsequent polling request. The + // missing information (for example, project or region ID) is contained in the + // fields of the initial request message that this annotation must be applied + // to. The string value of the annotation corresponds to the name of the + // counterpart field in the polling request message that the annotated field's + // value will be copied to. + string operation_request_field = 1150; + + // A field annotation that maps fields in the polling request message to their + // counterparts in the initial and/or polling response message. The initial + // and the polling methods return an API-specific Operation object. Some of + // the fields from that response object must be reused in the subsequent + // request (like operation name/ID) to fully identify the polled operation. + // This annotation must be applied to the fields in the polling request + // message, the string value of the annotation must correspond to the name of + // the counterpart field in the Operation response object whose value will be + // copied to the annotated field. + string operation_response_field = 1151; +} + +// MethodOptions to identify the actual service and method used for operation +// status polling. +// +// Example: +// +// In a method, which starts an LRO: +// +// service MyService { +// rpc Foo(MyInitialRequest) returns (MyOperation) { +// option (operation_service) = "MyPollingService"; +// } +// } +// +// In a polling method: +// +// service MyPollingService { +// rpc Get(MyPollingRequest) returns (MyOperation) { +// option (operation_polling_method) = true; +// } +// } +extend google.protobuf.MethodOptions { + // A method annotation that maps an LRO method (the one which starts an LRO) + // to the service, which will be used to poll for the operation status. The + // annotation must be applied to the method which starts an LRO, the string + // value of the annotation must correspond to the name of the service used to + // poll for the operation status. + string operation_service = 1249; + + // A method annotation that marks methods that can be used for polling + // operation status (e.g. the MyPollingService.Get(MyPollingRequest) method). + bool operation_polling_method = 1250; +} + +// An enum to be used to mark the essential (for polling) fields in an +// API-specific Operation object. A custom Operation object may contain many +// different fields, but only few of them are essential to conduct a successful +// polling process. +enum OperationResponseMapping { + // Do not use. + UNDEFINED = 0; + + // A field in an API-specific (custom) Operation object which carries the same + // meaning as google.longrunning.Operation.name. + NAME = 1; + + // A field in an API-specific (custom) Operation object which carries the same + // meaning as google.longrunning.Operation.done. If the annotated field is of + // an enum type, `annotated_field_name == EnumType.DONE` semantics should be + // equivalent to `Operation.done == true`. If the annotated field is of type + // boolean, then it should follow the same semantics as Operation.done. + // Otherwise, a non-empty value should be treated as `Operation.done == true`. + STATUS = 2; + + // A field in an API-specific (custom) Operation object which carries the same + // meaning as google.longrunning.Operation.error.code. + ERROR_CODE = 3; + + // A field in an API-specific (custom) Operation object which carries the same + // meaning as google.longrunning.Operation.error.message. + ERROR_MESSAGE = 4; +} \ No newline at end of file diff --git a/synth.metadata b/synth.metadata index 14a309d5..5c1a84c6 100644 --- a/synth.metadata +++ b/synth.metadata @@ -4,7 +4,7 @@ "git": { "name": ".", "remote": "git@github.com:googleapis/java-common-protos.git", - "sha": "66db02e9b97c724179a2110671a51bc2ce92b3df" + "sha": "95909d1b02a29bbe12e4abe5e12178d273425ebc" } }, { diff --git a/synth.py b/synth.py index c5c64dd6..8ac4ef49 100644 --- a/synth.py +++ b/synth.py @@ -89,6 +89,7 @@ def build_grpc(target): build_proto("//google/rpc:rpc_java_proto") build_proto("//google/rpc/context:attribute_context_java_proto") build_proto("//google/type:type_java_proto") +build_proto("//google/cloud:extended_operations_java_proto") build_grpc("//google/longrunning:longrunning_java_grpc") From f9f1854d121870c2496704659f4a137ddf6e93dc Mon Sep 17 00:00:00 2001 From: Neenu1995 Date: Thu, 26 Aug 2021 18:57:35 -0400 Subject: [PATCH 3/3] chore: remove BigqueryAuditMetadata --- .../cloud/audit/BigQueryAuditMetadata.java | 67540 ---------------- .../audit/BigQueryAuditMetadataOrBuilder.java | 667 - .../audit/BigQueryAuditMetadataProto.java | 1033 - .../cloud/audit/bigquery_audit_metadata.proto | 1184 - synth.py | 5 + 5 files changed, 5 insertions(+), 70424 deletions(-) delete mode 100644 proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadata.java delete mode 100644 proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataOrBuilder.java delete mode 100644 proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataProto.java delete mode 100644 proto-google-common-protos/src/main/proto/google/cloud/audit/bigquery_audit_metadata.proto diff --git a/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadata.java b/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadata.java deleted file mode 100644 index 2a70955f..00000000 --- a/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadata.java +++ /dev/null @@ -1,67540 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/audit/bigquery_audit_metadata.proto - -package com.google.cloud.audit; - -/** - * - * - *
- * Audit log format for BigQuery cloud audit logs metadata.
- * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata} - */ -public final class BigQueryAuditMetadata extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata) - BigQueryAuditMetadataOrBuilder { - private static final long serialVersionUID = 0L; - // Use BigQueryAuditMetadata.newBuilder() to construct. - private BigQueryAuditMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BigQueryAuditMetadata() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new BigQueryAuditMetadata(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private BigQueryAuditMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder subBuilder = null; - if (eventCase_ == 1) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 1; - break; - } - case 18: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder subBuilder = null; - if (eventCase_ == 2) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_).toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 2; - break; - } - case 26: - { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder subBuilder = - null; - if (eventCase_ == 3) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 3; - break; - } - case 34: - { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder subBuilder = null; - if (eventCase_ == 4) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 4; - break; - } - case 42: - { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder subBuilder = - null; - if (eventCase_ == 5) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 5; - break; - } - case 50: - { - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder subBuilder = null; - if (eventCase_ == 6) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 6; - break; - } - case 66: - { - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder subBuilder = null; - if (eventCase_ == 8) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_).toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 8; - break; - } - case 74: - { - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder subBuilder = null; - if (eventCase_ == 9) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 9; - break; - } - case 82: - { - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder subBuilder = null; - if (eventCase_ == 10) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 10; - break; - } - case 90: - { - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder subBuilder = - null; - if (eventCase_ == 11) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 11; - break; - } - case 98: - { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder subBuilder = null; - if (eventCase_ == 12) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 12; - break; - } - case 106: - { - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder subBuilder = null; - if (eventCase_ == 13) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 13; - break; - } - case 114: - { - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder subBuilder = - null; - if (eventCase_ == 14) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 14; - break; - } - case 122: - { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder subBuilder = - null; - if (eventCase_ == 15) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 15; - break; - } - case 130: - { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder subBuilder = - null; - if (eventCase_ == 16) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 16; - break; - } - case 138: - { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder subBuilder = null; - if (eventCase_ == 17) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 17; - break; - } - case 146: - { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder subBuilder = - null; - if (eventCase_ == 18) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 18; - break; - } - case 154: - { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder subBuilder = null; - if (eventCase_ == 19) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_) - .toBuilder(); - } - event_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 19; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.class, - com.google.cloud.audit.BigQueryAuditMetadata.Builder.class); - } - - /** - * - * - *
-   * Describes whether a job should overwrite or append the existing destination
-   * table if it already exists.
-   * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.WriteDisposition} - */ - public enum WriteDisposition implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Unknown.
-     * 
- * - * WRITE_DISPOSITION_UNSPECIFIED = 0; - */ - WRITE_DISPOSITION_UNSPECIFIED(0), - /** - * - * - *
-     * This job should only be writing to empty tables.
-     * 
- * - * WRITE_EMPTY = 1; - */ - WRITE_EMPTY(1), - /** - * - * - *
-     * This job will truncate the existing table data.
-     * 
- * - * WRITE_TRUNCATE = 2; - */ - WRITE_TRUNCATE(2), - /** - * - * - *
-     * This job will append to the table.
-     * 
- * - * WRITE_APPEND = 3; - */ - WRITE_APPEND(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Unknown.
-     * 
- * - * WRITE_DISPOSITION_UNSPECIFIED = 0; - */ - public static final int WRITE_DISPOSITION_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * This job should only be writing to empty tables.
-     * 
- * - * WRITE_EMPTY = 1; - */ - public static final int WRITE_EMPTY_VALUE = 1; - /** - * - * - *
-     * This job will truncate the existing table data.
-     * 
- * - * WRITE_TRUNCATE = 2; - */ - public static final int WRITE_TRUNCATE_VALUE = 2; - /** - * - * - *
-     * This job will append to the table.
-     * 
- * - * WRITE_APPEND = 3; - */ - public static final int WRITE_APPEND_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static WriteDisposition 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 WriteDisposition forNumber(int value) { - switch (value) { - case 0: - return WRITE_DISPOSITION_UNSPECIFIED; - case 1: - return WRITE_EMPTY; - case 2: - return WRITE_TRUNCATE; - case 3: - return WRITE_APPEND; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public WriteDisposition findValueByNumber(int number) { - return WriteDisposition.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.getDescriptor().getEnumTypes().get(0); - } - - private static final WriteDisposition[] VALUES = values(); - - public static WriteDisposition valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private WriteDisposition(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.WriteDisposition) - } - - /** - * - * - *
-   * Table copy job operation type.
-   * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.OperationType} - */ - public enum OperationType implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Unspecified operation type.
-     * 
- * - * OPERATION_TYPE_UNSPECIFIED = 0; - */ - OPERATION_TYPE_UNSPECIFIED(0), - /** - * - * - *
-     * The source and the destination table have the same table type.
-     * 
- * - * COPY = 1; - */ - COPY(1), - /** - * - * - *
-     * The source table type is TABLE and
-     * the destination table type is SNAPSHOT.
-     * 
- * - * SNAPSHOT = 2; - */ - SNAPSHOT(2), - /** - * - * - *
-     * The source table type is SNAPSHOT and
-     * the destination table type is TABLE.
-     * 
- * - * RESTORE = 3; - */ - RESTORE(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Unspecified operation type.
-     * 
- * - * OPERATION_TYPE_UNSPECIFIED = 0; - */ - public static final int OPERATION_TYPE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * The source and the destination table have the same table type.
-     * 
- * - * COPY = 1; - */ - public static final int COPY_VALUE = 1; - /** - * - * - *
-     * The source table type is TABLE and
-     * the destination table type is SNAPSHOT.
-     * 
- * - * SNAPSHOT = 2; - */ - public static final int SNAPSHOT_VALUE = 2; - /** - * - * - *
-     * The source table type is SNAPSHOT and
-     * the destination table type is TABLE.
-     * 
- * - * RESTORE = 3; - */ - public static final int RESTORE_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static OperationType 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 OperationType forNumber(int value) { - switch (value) { - case 0: - return OPERATION_TYPE_UNSPECIFIED; - case 1: - return COPY; - case 2: - return SNAPSHOT; - case 3: - return RESTORE; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public OperationType findValueByNumber(int number) { - return OperationType.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.getDescriptor().getEnumTypes().get(1); - } - - private static final OperationType[] VALUES = values(); - - public static OperationType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private OperationType(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.OperationType) - } - - /** - * - * - *
-   * Describes whether a job should create a destination table if it doesn't
-   * exist.
-   * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.CreateDisposition} - */ - public enum CreateDisposition implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Unknown.
-     * 
- * - * CREATE_DISPOSITION_UNSPECIFIED = 0; - */ - CREATE_DISPOSITION_UNSPECIFIED(0), - /** - * - * - *
-     * This job should never create tables.
-     * 
- * - * CREATE_NEVER = 1; - */ - CREATE_NEVER(1), - /** - * - * - *
-     * This job should create a table if it doesn't already exist.
-     * 
- * - * CREATE_IF_NEEDED = 2; - */ - CREATE_IF_NEEDED(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Unknown.
-     * 
- * - * CREATE_DISPOSITION_UNSPECIFIED = 0; - */ - public static final int CREATE_DISPOSITION_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * This job should never create tables.
-     * 
- * - * CREATE_NEVER = 1; - */ - public static final int CREATE_NEVER_VALUE = 1; - /** - * - * - *
-     * This job should create a table if it doesn't already exist.
-     * 
- * - * CREATE_IF_NEEDED = 2; - */ - public static final int CREATE_IF_NEEDED_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static CreateDisposition 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 CreateDisposition forNumber(int value) { - switch (value) { - case 0: - return CREATE_DISPOSITION_UNSPECIFIED; - case 1: - return CREATE_NEVER; - case 2: - return CREATE_IF_NEEDED; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public CreateDisposition findValueByNumber(int number) { - return CreateDisposition.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.getDescriptor().getEnumTypes().get(2); - } - - private static final CreateDisposition[] VALUES = values(); - - public static CreateDisposition valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private CreateDisposition(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.CreateDisposition) - } - - /** - * - * - *
-   * State of a job.
-   * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.JobState} - */ - public enum JobState implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * State unknown.
-     * 
- * - * JOB_STATE_UNSPECIFIED = 0; - */ - JOB_STATE_UNSPECIFIED(0), - /** - * - * - *
-     * Job is waiting for the resources.
-     * 
- * - * PENDING = 1; - */ - PENDING(1), - /** - * - * - *
-     * Job is running.
-     * 
- * - * RUNNING = 2; - */ - RUNNING(2), - /** - * - * - *
-     * Job is done.
-     * 
- * - * DONE = 3; - */ - DONE(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * State unknown.
-     * 
- * - * JOB_STATE_UNSPECIFIED = 0; - */ - public static final int JOB_STATE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * Job is waiting for the resources.
-     * 
- * - * PENDING = 1; - */ - public static final int PENDING_VALUE = 1; - /** - * - * - *
-     * Job is running.
-     * 
- * - * RUNNING = 2; - */ - public static final int RUNNING_VALUE = 2; - /** - * - * - *
-     * Job is done.
-     * 
- * - * DONE = 3; - */ - public static final int DONE_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static JobState 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 JobState forNumber(int value) { - switch (value) { - case 0: - return JOB_STATE_UNSPECIFIED; - case 1: - return PENDING; - case 2: - return RUNNING; - case 3: - return DONE; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public JobState findValueByNumber(int number) { - return JobState.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.getDescriptor().getEnumTypes().get(3); - } - - private static final JobState[] VALUES = values(); - - public static JobState valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private JobState(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.JobState) - } - - /** - * - * - *
-   * Type of the statement (e.g. SELECT, INSERT, CREATE_TABLE, CREATE_MODEL..)
-   * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.QueryStatementType} - */ - public enum QueryStatementType implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Unknown.
-     * 
- * - * QUERY_STATEMENT_TYPE_UNSPECIFIED = 0; - */ - QUERY_STATEMENT_TYPE_UNSPECIFIED(0), - /** - * - * - *
-     * SELECT ... FROM &lt;Table list&gt; ...
-     * 
- * - * SELECT = 1; - */ - SELECT(1), - /** - * - * - *
-     * ASSERT &lt;condition&gt; AS 'description'
-     * 
- * - * ASSERT = 23; - */ - ASSERT(23), - /** - * - * - *
-     * INSERT INTO &lt;Table&gt; ....
-     * 
- * - * INSERT = 2; - */ - INSERT(2), - /** - * - * - *
-     * UPDATE &lt;Table&gt; SET ...
-     * 
- * - * UPDATE = 3; - */ - UPDATE(3), - /** - * - * - *
-     * DELETE &lt;Table&gt; ...
-     * 
- * - * DELETE = 4; - */ - DELETE(4), - /** - * - * - *
-     * MERGE INTO &lt;Table&gt; ....
-     * 
- * - * MERGE = 5; - */ - MERGE(5), - /** - * - * - *
-     * CREATE TABLE &lt;Table&gt; &lt;column list&gt;
-     * 
- * - * CREATE_TABLE = 6; - */ - CREATE_TABLE(6), - /** - * - * - *
-     * CREATE TABLE &lt;Table&gt; AS SELECT
-     * 
- * - * CREATE_TABLE_AS_SELECT = 7; - */ - CREATE_TABLE_AS_SELECT(7), - /** - * - * - *
-     * CREATE VIEW &lt;View&gt;
-     * 
- * - * CREATE_VIEW = 8; - */ - CREATE_VIEW(8), - /** - * - * - *
-     * CREATE MODEL &lt;Model&gt; AS &lt;Query&gt;
-     * 
- * - * CREATE_MODEL = 9; - */ - CREATE_MODEL(9), - /** - * - * - *
-     * CREATE MATERIALIZED VIEW &lt;View&gt; AS ...
-     * 
- * - * CREATE_MATERIALIZED_VIEW = 13; - */ - CREATE_MATERIALIZED_VIEW(13), - /** - * - * - *
-     * CREATE FUNCTION &lt;Function&gt;(&lt;Signature&gt;) AS ...
-     * 
- * - * CREATE_FUNCTION = 14; - */ - CREATE_FUNCTION(14), - /** - * - * - *
-     * CREATE PROCEDURE &lt;Procedure&gt;
-     * 
- * - * CREATE_PROCEDURE = 20; - */ - CREATE_PROCEDURE(20), - /** - * - * - *
-     * CREATE SCHEMA &lt;Schema&gt;
-     * 
- * - * CREATE_SCHEMA = 53; - */ - CREATE_SCHEMA(53), - /** - * - * - *
-     * DROP TABLE &lt;Table&gt;
-     * 
- * - * DROP_TABLE = 10; - */ - DROP_TABLE(10), - /** - * - * - *
-     * DROP EXTERNAL TABLE &lt;Table&gt;
-     * 
- * - * DROP_EXTERNAL_TABLE = 33; - */ - DROP_EXTERNAL_TABLE(33), - /** - * - * - *
-     * DROP VIEW &lt;View&gt;
-     * 
- * - * DROP_VIEW = 11; - */ - DROP_VIEW(11), - /** - * - * - *
-     * DROP MODEL &lt;Model&gt;
-     * 
- * - * DROP_MODEL = 12; - */ - DROP_MODEL(12), - /** - * - * - *
-     * DROP MATERIALIZED VIEW &lt;View&gt;
-     * 
- * - * DROP_MATERIALIZED_VIEW = 15; - */ - DROP_MATERIALIZED_VIEW(15), - /** - * - * - *
-     * DROP FUNCTION &lt;Function&gt;
-     * 
- * - * DROP_FUNCTION = 16; - */ - DROP_FUNCTION(16), - /** - * - * - *
-     * DROP PROCEDURE &lt;Procedure&gt;
-     * 
- * - * DROP_PROCEDURE = 21; - */ - DROP_PROCEDURE(21), - /** - * - * - *
-     * DROP SCHEMA &lt;Schema&gt;
-     * 
- * - * DROP_SCHEMA = 54; - */ - DROP_SCHEMA(54), - /** - * - * - *
-     * ALTER TABLE &lt;Table&gt;
-     * 
- * - * ALTER_TABLE = 17; - */ - ALTER_TABLE(17), - /** - * - * - *
-     * ALTER VIEW &lt;View&gt;
-     * 
- * - * ALTER_VIEW = 18; - */ - ALTER_VIEW(18), - /** - * - * - *
-     * ALTER MATERIALIZED_VIEW &lt;view&gt;
-     * 
- * - * ALTER_MATERIALIZED_VIEW = 22; - */ - ALTER_MATERIALIZED_VIEW(22), - /** - * - * - *
-     * ALTER SCHEMA &lt;Schema&gt;
-     * 
- * - * ALTER_SCHEMA = 55; - */ - ALTER_SCHEMA(55), - /** - * - * - *
-     * Script
-     * 
- * - * SCRIPT = 19; - */ - SCRIPT(19), - /** - * - * - *
-     * TRUNCATE TABLE &lt;Table&gt
-     * 
- * - * TRUNCATE_TABLE = 26; - */ - TRUNCATE_TABLE(26), - /** - * - * - *
-     * CREATE EXTERNAL TABLE &lt;TABLE&gt;
-     * 
- * - * CREATE_EXTERNAL_TABLE = 27; - */ - CREATE_EXTERNAL_TABLE(27), - /** - * - * - *
-     * EXPORT DATA;
-     * 
- * - * EXPORT_DATA = 28; - */ - EXPORT_DATA(28), - /** - * - * - *
-     * CALL &lt;stored procedure&gt;
-     * 
- * - * CALL = 29; - */ - CALL(29), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Unknown.
-     * 
- * - * QUERY_STATEMENT_TYPE_UNSPECIFIED = 0; - */ - public static final int QUERY_STATEMENT_TYPE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * SELECT ... FROM &lt;Table list&gt; ...
-     * 
- * - * SELECT = 1; - */ - public static final int SELECT_VALUE = 1; - /** - * - * - *
-     * ASSERT &lt;condition&gt; AS 'description'
-     * 
- * - * ASSERT = 23; - */ - public static final int ASSERT_VALUE = 23; - /** - * - * - *
-     * INSERT INTO &lt;Table&gt; ....
-     * 
- * - * INSERT = 2; - */ - public static final int INSERT_VALUE = 2; - /** - * - * - *
-     * UPDATE &lt;Table&gt; SET ...
-     * 
- * - * UPDATE = 3; - */ - public static final int UPDATE_VALUE = 3; - /** - * - * - *
-     * DELETE &lt;Table&gt; ...
-     * 
- * - * DELETE = 4; - */ - public static final int DELETE_VALUE = 4; - /** - * - * - *
-     * MERGE INTO &lt;Table&gt; ....
-     * 
- * - * MERGE = 5; - */ - public static final int MERGE_VALUE = 5; - /** - * - * - *
-     * CREATE TABLE &lt;Table&gt; &lt;column list&gt;
-     * 
- * - * CREATE_TABLE = 6; - */ - public static final int CREATE_TABLE_VALUE = 6; - /** - * - * - *
-     * CREATE TABLE &lt;Table&gt; AS SELECT
-     * 
- * - * CREATE_TABLE_AS_SELECT = 7; - */ - public static final int CREATE_TABLE_AS_SELECT_VALUE = 7; - /** - * - * - *
-     * CREATE VIEW &lt;View&gt;
-     * 
- * - * CREATE_VIEW = 8; - */ - public static final int CREATE_VIEW_VALUE = 8; - /** - * - * - *
-     * CREATE MODEL &lt;Model&gt; AS &lt;Query&gt;
-     * 
- * - * CREATE_MODEL = 9; - */ - public static final int CREATE_MODEL_VALUE = 9; - /** - * - * - *
-     * CREATE MATERIALIZED VIEW &lt;View&gt; AS ...
-     * 
- * - * CREATE_MATERIALIZED_VIEW = 13; - */ - public static final int CREATE_MATERIALIZED_VIEW_VALUE = 13; - /** - * - * - *
-     * CREATE FUNCTION &lt;Function&gt;(&lt;Signature&gt;) AS ...
-     * 
- * - * CREATE_FUNCTION = 14; - */ - public static final int CREATE_FUNCTION_VALUE = 14; - /** - * - * - *
-     * CREATE PROCEDURE &lt;Procedure&gt;
-     * 
- * - * CREATE_PROCEDURE = 20; - */ - public static final int CREATE_PROCEDURE_VALUE = 20; - /** - * - * - *
-     * CREATE SCHEMA &lt;Schema&gt;
-     * 
- * - * CREATE_SCHEMA = 53; - */ - public static final int CREATE_SCHEMA_VALUE = 53; - /** - * - * - *
-     * DROP TABLE &lt;Table&gt;
-     * 
- * - * DROP_TABLE = 10; - */ - public static final int DROP_TABLE_VALUE = 10; - /** - * - * - *
-     * DROP EXTERNAL TABLE &lt;Table&gt;
-     * 
- * - * DROP_EXTERNAL_TABLE = 33; - */ - public static final int DROP_EXTERNAL_TABLE_VALUE = 33; - /** - * - * - *
-     * DROP VIEW &lt;View&gt;
-     * 
- * - * DROP_VIEW = 11; - */ - public static final int DROP_VIEW_VALUE = 11; - /** - * - * - *
-     * DROP MODEL &lt;Model&gt;
-     * 
- * - * DROP_MODEL = 12; - */ - public static final int DROP_MODEL_VALUE = 12; - /** - * - * - *
-     * DROP MATERIALIZED VIEW &lt;View&gt;
-     * 
- * - * DROP_MATERIALIZED_VIEW = 15; - */ - public static final int DROP_MATERIALIZED_VIEW_VALUE = 15; - /** - * - * - *
-     * DROP FUNCTION &lt;Function&gt;
-     * 
- * - * DROP_FUNCTION = 16; - */ - public static final int DROP_FUNCTION_VALUE = 16; - /** - * - * - *
-     * DROP PROCEDURE &lt;Procedure&gt;
-     * 
- * - * DROP_PROCEDURE = 21; - */ - public static final int DROP_PROCEDURE_VALUE = 21; - /** - * - * - *
-     * DROP SCHEMA &lt;Schema&gt;
-     * 
- * - * DROP_SCHEMA = 54; - */ - public static final int DROP_SCHEMA_VALUE = 54; - /** - * - * - *
-     * ALTER TABLE &lt;Table&gt;
-     * 
- * - * ALTER_TABLE = 17; - */ - public static final int ALTER_TABLE_VALUE = 17; - /** - * - * - *
-     * ALTER VIEW &lt;View&gt;
-     * 
- * - * ALTER_VIEW = 18; - */ - public static final int ALTER_VIEW_VALUE = 18; - /** - * - * - *
-     * ALTER MATERIALIZED_VIEW &lt;view&gt;
-     * 
- * - * ALTER_MATERIALIZED_VIEW = 22; - */ - public static final int ALTER_MATERIALIZED_VIEW_VALUE = 22; - /** - * - * - *
-     * ALTER SCHEMA &lt;Schema&gt;
-     * 
- * - * ALTER_SCHEMA = 55; - */ - public static final int ALTER_SCHEMA_VALUE = 55; - /** - * - * - *
-     * Script
-     * 
- * - * SCRIPT = 19; - */ - public static final int SCRIPT_VALUE = 19; - /** - * - * - *
-     * TRUNCATE TABLE &lt;Table&gt
-     * 
- * - * TRUNCATE_TABLE = 26; - */ - public static final int TRUNCATE_TABLE_VALUE = 26; - /** - * - * - *
-     * CREATE EXTERNAL TABLE &lt;TABLE&gt;
-     * 
- * - * CREATE_EXTERNAL_TABLE = 27; - */ - public static final int CREATE_EXTERNAL_TABLE_VALUE = 27; - /** - * - * - *
-     * EXPORT DATA;
-     * 
- * - * EXPORT_DATA = 28; - */ - public static final int EXPORT_DATA_VALUE = 28; - /** - * - * - *
-     * CALL &lt;stored procedure&gt;
-     * 
- * - * CALL = 29; - */ - public static final int CALL_VALUE = 29; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static QueryStatementType 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 QueryStatementType forNumber(int value) { - switch (value) { - case 0: - return QUERY_STATEMENT_TYPE_UNSPECIFIED; - case 1: - return SELECT; - case 23: - return ASSERT; - case 2: - return INSERT; - case 3: - return UPDATE; - case 4: - return DELETE; - case 5: - return MERGE; - case 6: - return CREATE_TABLE; - case 7: - return CREATE_TABLE_AS_SELECT; - case 8: - return CREATE_VIEW; - case 9: - return CREATE_MODEL; - case 13: - return CREATE_MATERIALIZED_VIEW; - case 14: - return CREATE_FUNCTION; - case 20: - return CREATE_PROCEDURE; - case 53: - return CREATE_SCHEMA; - case 10: - return DROP_TABLE; - case 33: - return DROP_EXTERNAL_TABLE; - case 11: - return DROP_VIEW; - case 12: - return DROP_MODEL; - case 15: - return DROP_MATERIALIZED_VIEW; - case 16: - return DROP_FUNCTION; - case 21: - return DROP_PROCEDURE; - case 54: - return DROP_SCHEMA; - case 17: - return ALTER_TABLE; - case 18: - return ALTER_VIEW; - case 22: - return ALTER_MATERIALIZED_VIEW; - case 55: - return ALTER_SCHEMA; - case 19: - return SCRIPT; - case 26: - return TRUNCATE_TABLE; - case 27: - return CREATE_EXTERNAL_TABLE; - case 28: - return EXPORT_DATA; - case 29: - return CALL; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public QueryStatementType findValueByNumber(int number) { - return QueryStatementType.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.getDescriptor().getEnumTypes().get(4); - } - - private static final QueryStatementType[] VALUES = values(); - - public static QueryStatementType valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private QueryStatementType(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.QueryStatementType) - } - - public interface JobInsertionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobInsertion) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - * - * @return Whether the job field is set. - */ - boolean hasJob(); - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - * - * @return The job. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Job getJob(); - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder(); - - /** - * - * - *
-     * Describes how the job was inserted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the job was inserted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason getReason(); - } - /** - * - * - *
-   * Job insertion event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobInsertion} - */ - public static final class JobInsertion extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobInsertion) - JobInsertionOrBuilder { - private static final long serialVersionUID = 0L; - // Use JobInsertion.newBuilder() to construct. - private JobInsertion(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private JobInsertion() { - reason_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new JobInsertion(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private JobInsertion( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder subBuilder = null; - if (job_ != null) { - subBuilder = job_.toBuilder(); - } - job_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Job.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(job_); - job_ = subBuilder.buildPartial(); - } - - break; - } - case 16: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder.class); - } - - /** - * - * - *
-     * Describes how the job was inserted.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Job was inserted using the jobs.insert API.
-       * 
- * - * JOB_INSERT_REQUEST = 1; - */ - JOB_INSERT_REQUEST(1), - /** - * - * - *
-       * Job was inserted using the jobs.query RPC.
-       * 
- * - * QUERY_REQUEST = 2; - */ - QUERY_REQUEST(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Job was inserted using the jobs.insert API.
-       * 
- * - * JOB_INSERT_REQUEST = 1; - */ - public static final int JOB_INSERT_REQUEST_VALUE = 1; - /** - * - * - *
-       * Job was inserted using the jobs.query RPC.
-       * 
- * - * QUERY_REQUEST = 2; - */ - public static final int QUERY_REQUEST_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return JOB_INSERT_REQUEST; - case 2: - return QUERY_REQUEST; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason) - } - - public static final int JOB_FIELD_NUMBER = 1; - private com.google.cloud.audit.BigQueryAuditMetadata.Job job_; - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - * - * @return Whether the job field is set. - */ - @java.lang.Override - public boolean hasJob() { - return job_ != null; - } - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - * - * @return The job. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Job getJob() { - return job_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() - : job_; - } - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder() { - return getJob(); - } - - public static final int REASON_FIELD_NUMBER = 2; - private int reason_; - /** - * - * - *
-     * Describes how the job was inserted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the job was inserted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.UNRECOGNIZED - : result; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (job_ != null) { - output.writeMessage(1, getJob()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(2, reason_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (job_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getJob()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, reason_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) obj; - - if (hasJob() != other.hasJob()) return false; - if (hasJob()) { - if (!getJob().equals(other.getJob())) return false; - } - if (reason_ != other.reason_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasJob()) { - hash = (37 * hash) + JOB_FIELD_NUMBER; - hash = (53 * hash) + getJob().hashCode(); - } - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Job insertion event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobInsertion} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobInsertion) - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (jobBuilder_ == null) { - job_ = null; - } else { - job_ = null; - jobBuilder_ = null; - } - reason_ = 0; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion(this); - if (jobBuilder_ == null) { - result.job_ = job_; - } else { - result.job_ = jobBuilder_.build(); - } - result.reason_ = reason_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance()) - return this; - if (other.hasJob()) { - mergeJob(other.getJob()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Job job_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Job, - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder> - jobBuilder_; - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - * - * @return Whether the job field is set. - */ - public boolean hasJob() { - return jobBuilder_ != null || job_ != null; - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - * - * @return The job. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Job getJob() { - if (jobBuilder_ == null) { - return job_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() - : job_; - } else { - return jobBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - */ - public Builder setJob(com.google.cloud.audit.BigQueryAuditMetadata.Job value) { - if (jobBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - job_ = value; - onChanged(); - } else { - jobBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - */ - public Builder setJob( - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder builderForValue) { - if (jobBuilder_ == null) { - job_ = builderForValue.build(); - onChanged(); - } else { - jobBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - */ - public Builder mergeJob(com.google.cloud.audit.BigQueryAuditMetadata.Job value) { - if (jobBuilder_ == null) { - if (job_ != null) { - job_ = - com.google.cloud.audit.BigQueryAuditMetadata.Job.newBuilder(job_) - .mergeFrom(value) - .buildPartial(); - } else { - job_ = value; - } - onChanged(); - } else { - jobBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - */ - public Builder clearJob() { - if (jobBuilder_ == null) { - job_ = null; - onChanged(); - } else { - job_ = null; - jobBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder getJobBuilder() { - - onChanged(); - return getJobFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder() { - if (jobBuilder_ != null) { - return jobBuilder_.getMessageOrBuilder(); - } else { - return job_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() - : job_; - } - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Job, - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder> - getJobFieldBuilder() { - if (jobBuilder_ == null) { - jobBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Job, - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder>( - getJob(), getParentForChildren(), isClean()); - job_ = null; - } - return jobBuilder_; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the job was inserted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the job was inserted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the job was inserted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the job was inserted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the job was inserted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Reason reason = 2; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobInsertion) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobInsertion) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public JobInsertion parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new JobInsertion(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface JobChangeOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobChange) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Job state before the job state change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; - * - * @return The enum numeric value on the wire for before. - */ - int getBeforeValue(); - /** - * - * - *
-     * Job state before the job state change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; - * - * @return The before. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobState getBefore(); - - /** - * - * - *
-     * Job state after the job state change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; - * - * @return The enum numeric value on the wire for after. - */ - int getAfterValue(); - /** - * - * - *
-     * Job state after the job state change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; - * - * @return The after. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobState getAfter(); - - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - * - * @return Whether the job field is set. - */ - boolean hasJob(); - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - * - * @return The job. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Job getJob(); - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder(); - } - /** - * - * - *
-   * Job state change event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobChange} - */ - public static final class JobChange extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobChange) - JobChangeOrBuilder { - private static final long serialVersionUID = 0L; - // Use JobChange.newBuilder() to construct. - private JobChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private JobChange() { - before_ = 0; - after_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new JobChange(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private JobChange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - before_ = rawValue; - break; - } - case 16: - { - int rawValue = input.readEnum(); - - after_ = rawValue; - break; - } - case 26: - { - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder subBuilder = null; - if (job_ != null) { - subBuilder = job_.toBuilder(); - } - job_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Job.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(job_); - job_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder.class); - } - - public static final int BEFORE_FIELD_NUMBER = 1; - private int before_; - /** - * - * - *
-     * Job state before the job state change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; - * - * @return The enum numeric value on the wire for before. - */ - @java.lang.Override - public int getBeforeValue() { - return before_; - } - /** - * - * - *
-     * Job state before the job state change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; - * - * @return The before. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobState getBefore() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobState result = - com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(before_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED - : result; - } - - public static final int AFTER_FIELD_NUMBER = 2; - private int after_; - /** - * - * - *
-     * Job state after the job state change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; - * - * @return The enum numeric value on the wire for after. - */ - @java.lang.Override - public int getAfterValue() { - return after_; - } - /** - * - * - *
-     * Job state after the job state change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; - * - * @return The after. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobState getAfter() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobState result = - com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(after_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED - : result; - } - - public static final int JOB_FIELD_NUMBER = 3; - private com.google.cloud.audit.BigQueryAuditMetadata.Job job_; - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - * - * @return Whether the job field is set. - */ - @java.lang.Override - public boolean hasJob() { - return job_ != null; - } - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - * - * @return The job. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Job getJob() { - return job_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() - : job_; - } - /** - * - * - *
-     * Job metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder() { - return getJob(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (before_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, before_); - } - if (after_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED - .getNumber()) { - output.writeEnum(2, after_); - } - if (job_ != null) { - output.writeMessage(3, getJob()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (before_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, before_); - } - if (after_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, after_); - } - if (job_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getJob()); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobChange)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobChange other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) obj; - - if (before_ != other.before_) return false; - if (after_ != other.after_) return false; - if (hasJob() != other.hasJob()) return false; - if (hasJob()) { - if (!getJob().equals(other.getJob())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + BEFORE_FIELD_NUMBER; - hash = (53 * hash) + before_; - hash = (37 * hash) + AFTER_FIELD_NUMBER; - hash = (53 * hash) + after_; - if (hasJob()) { - hash = (37 * hash) + JOB_FIELD_NUMBER; - hash = (53 * hash) + getJob().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobChange prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Job state change event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobChange} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobChange) - com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobChange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - before_ = 0; - - after_ = 0; - - if (jobBuilder_ == null) { - job_ = null; - } else { - job_ = null; - jobBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobChange getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobChange build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobChange result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobChange buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobChange result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobChange(this); - result.before_ = before_; - result.after_ = after_; - if (jobBuilder_ == null) { - result.job_ = job_; - } else { - result.job_ = jobBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobChange) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobChange) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobChange other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance()) - return this; - if (other.before_ != 0) { - setBeforeValue(other.getBeforeValue()); - } - if (other.after_ != 0) { - setAfterValue(other.getAfterValue()); - } - if (other.hasJob()) { - mergeJob(other.getJob()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobChange parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int before_ = 0; - /** - * - * - *
-       * Job state before the job state change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; - * - * @return The enum numeric value on the wire for before. - */ - @java.lang.Override - public int getBeforeValue() { - return before_; - } - /** - * - * - *
-       * Job state before the job state change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; - * - * @param value The enum numeric value on the wire for before to set. - * @return This builder for chaining. - */ - public Builder setBeforeValue(int value) { - - before_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Job state before the job state change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; - * - * @return The before. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobState getBefore() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobState result = - com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(before_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Job state before the job state change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; - * - * @param value The before to set. - * @return This builder for chaining. - */ - public Builder setBefore(com.google.cloud.audit.BigQueryAuditMetadata.JobState value) { - if (value == null) { - throw new NullPointerException(); - } - - before_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Job state before the job state change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState before = 1; - * - * @return This builder for chaining. - */ - public Builder clearBefore() { - - before_ = 0; - onChanged(); - return this; - } - - private int after_ = 0; - /** - * - * - *
-       * Job state after the job state change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; - * - * @return The enum numeric value on the wire for after. - */ - @java.lang.Override - public int getAfterValue() { - return after_; - } - /** - * - * - *
-       * Job state after the job state change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; - * - * @param value The enum numeric value on the wire for after to set. - * @return This builder for chaining. - */ - public Builder setAfterValue(int value) { - - after_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Job state after the job state change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; - * - * @return The after. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobState getAfter() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobState result = - com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(after_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Job state after the job state change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; - * - * @param value The after to set. - * @return This builder for chaining. - */ - public Builder setAfter(com.google.cloud.audit.BigQueryAuditMetadata.JobState value) { - if (value == null) { - throw new NullPointerException(); - } - - after_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Job state after the job state change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState after = 2; - * - * @return This builder for chaining. - */ - public Builder clearAfter() { - - after_ = 0; - onChanged(); - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Job job_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Job, - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder> - jobBuilder_; - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - * - * @return Whether the job field is set. - */ - public boolean hasJob() { - return jobBuilder_ != null || job_ != null; - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - * - * @return The job. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Job getJob() { - if (jobBuilder_ == null) { - return job_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() - : job_; - } else { - return jobBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - */ - public Builder setJob(com.google.cloud.audit.BigQueryAuditMetadata.Job value) { - if (jobBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - job_ = value; - onChanged(); - } else { - jobBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - */ - public Builder setJob( - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder builderForValue) { - if (jobBuilder_ == null) { - job_ = builderForValue.build(); - onChanged(); - } else { - jobBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - */ - public Builder mergeJob(com.google.cloud.audit.BigQueryAuditMetadata.Job value) { - if (jobBuilder_ == null) { - if (job_ != null) { - job_ = - com.google.cloud.audit.BigQueryAuditMetadata.Job.newBuilder(job_) - .mergeFrom(value) - .buildPartial(); - } else { - job_ = value; - } - onChanged(); - } else { - jobBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - */ - public Builder clearJob() { - if (jobBuilder_ == null) { - job_ = null; - onChanged(); - } else { - job_ = null; - jobBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder getJobBuilder() { - - onChanged(); - return getJobFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder getJobOrBuilder() { - if (jobBuilder_ != null) { - return jobBuilder_.getMessageOrBuilder(); - } else { - return job_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance() - : job_; - } - } - /** - * - * - *
-       * Job metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Job job = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Job, - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder> - getJobFieldBuilder() { - if (jobBuilder_ == null) { - jobBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Job, - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder>( - getJob(), getParentForChildren(), isClean()); - job_ = null; - } - return jobBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobChange) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobChange) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobChange DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobChange(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobChange getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public JobChange parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new JobChange(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobChange getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface DatasetCreationOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Dataset metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return Whether the dataset field is set. - */ - boolean hasDataset(); - /** - * - * - *
-     * Dataset metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return The dataset. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset(); - /** - * - * - *
-     * Dataset metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder(); - - /** - * - * - *
-     * Describes how the dataset was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the dataset was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that created the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that created the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Dataset creation event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetCreation} - */ - public static final class DatasetCreation extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) - DatasetCreationOrBuilder { - private static final long serialVersionUID = 0L; - // Use DatasetCreation.newBuilder() to construct. - private DatasetCreation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private DatasetCreation() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new DatasetCreation(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private DatasetCreation( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder subBuilder = null; - if (dataset_ != null) { - subBuilder = dataset_.toBuilder(); - } - dataset_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(dataset_); - dataset_ = subBuilder.buildPartial(); - } - - break; - } - case 16: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.class, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder.class); - } - - /** - * - * - *
-     * Describes how the dataset was created.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Dataset was created using the datasets.create API.
-       * 
- * - * CREATE = 1; - */ - CREATE(1), - /** - * - * - *
-       * Dataset was created using a query job, e.g., CREATE SCHEMA statement.
-       * 
- * - * QUERY = 2; - */ - QUERY(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Dataset was created using the datasets.create API.
-       * 
- * - * CREATE = 1; - */ - public static final int CREATE_VALUE = 1; - /** - * - * - *
-       * Dataset was created using a query job, e.g., CREATE SCHEMA statement.
-       * 
- * - * QUERY = 2; - */ - public static final int QUERY_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return CREATE; - case 2: - return QUERY; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason) - } - - public static final int DATASET_FIELD_NUMBER = 1; - private com.google.cloud.audit.BigQueryAuditMetadata.Dataset dataset_; - /** - * - * - *
-     * Dataset metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return Whether the dataset field is set. - */ - @java.lang.Override - public boolean hasDataset() { - return dataset_ != null; - } - /** - * - * - *
-     * Dataset metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return The dataset. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset() { - return dataset_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() - : dataset_; - } - /** - * - * - *
-     * Dataset metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder() { - return getDataset(); - } - - public static final int REASON_FIELD_NUMBER = 2; - private int reason_; - /** - * - * - *
-     * Describes how the dataset was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the dataset was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 3; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that created the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that created the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (dataset_ != null) { - output.writeMessage(1, getDataset()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(2, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (dataset_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getDataset()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation other = - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) obj; - - if (hasDataset() != other.hasDataset()) return false; - if (hasDataset()) { - if (!getDataset().equals(other.getDataset())) return false; - } - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasDataset()) { - hash = (37 * hash) + DATASET_FIELD_NUMBER; - hash = (53 * hash) + getDataset().hashCode(); - } - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Dataset creation event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetCreation} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.class, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (datasetBuilder_ == null) { - dataset_ = null; - } else { - dataset_ = null; - datasetBuilder_ = null; - } - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation build() { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation result = - new com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation(this); - if (datasetBuilder_ == null) { - result.dataset_ = dataset_; - } else { - result.dataset_ = datasetBuilder_.build(); - } - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance()) - return this; - if (other.hasDataset()) { - mergeDataset(other.getDataset()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Dataset dataset_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Dataset, - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder> - datasetBuilder_; - /** - * - * - *
-       * Dataset metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return Whether the dataset field is set. - */ - public boolean hasDataset() { - return datasetBuilder_ != null || dataset_ != null; - } - /** - * - * - *
-       * Dataset metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return The dataset. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset() { - if (datasetBuilder_ == null) { - return dataset_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() - : dataset_; - } else { - return datasetBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Dataset metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public Builder setDataset(com.google.cloud.audit.BigQueryAuditMetadata.Dataset value) { - if (datasetBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - dataset_ = value; - onChanged(); - } else { - datasetBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Dataset metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public Builder setDataset( - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder builderForValue) { - if (datasetBuilder_ == null) { - dataset_ = builderForValue.build(); - onChanged(); - } else { - datasetBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Dataset metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public Builder mergeDataset(com.google.cloud.audit.BigQueryAuditMetadata.Dataset value) { - if (datasetBuilder_ == null) { - if (dataset_ != null) { - dataset_ = - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.newBuilder(dataset_) - .mergeFrom(value) - .buildPartial(); - } else { - dataset_ = value; - } - onChanged(); - } else { - datasetBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Dataset metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public Builder clearDataset() { - if (datasetBuilder_ == null) { - dataset_ = null; - onChanged(); - } else { - dataset_ = null; - datasetBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Dataset metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder getDatasetBuilder() { - - onChanged(); - return getDatasetFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Dataset metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder() { - if (datasetBuilder_ != null) { - return datasetBuilder_.getMessageOrBuilder(); - } else { - return dataset_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() - : dataset_; - } - } - /** - * - * - *
-       * Dataset metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Dataset, - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder> - getDatasetFieldBuilder() { - if (datasetBuilder_ == null) { - datasetBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Dataset, - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder>( - getDataset(), getParentForChildren(), isClean()); - dataset_ = null; - } - return datasetBuilder_; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the dataset was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the dataset was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the dataset was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the dataset was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the dataset was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Reason reason = 2; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that created the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that created the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that created the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that created the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that created the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) - private static final com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DatasetCreation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DatasetCreation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface DatasetChangeOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.DatasetChange) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Dataset metadata after the change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return Whether the dataset field is set. - */ - boolean hasDataset(); - /** - * - * - *
-     * Dataset metadata after the change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return The dataset. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset(); - /** - * - * - *
-     * Dataset metadata after the change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder(); - - /** - * - * - *
-     * Describes how the dataset was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the dataset was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that updated the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that updated the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Dataset change event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetChange} - */ - public static final class DatasetChange extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetChange) - DatasetChangeOrBuilder { - private static final long serialVersionUID = 0L; - // Use DatasetChange.newBuilder() to construct. - private DatasetChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private DatasetChange() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new DatasetChange(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private DatasetChange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder subBuilder = null; - if (dataset_ != null) { - subBuilder = dataset_.toBuilder(); - } - dataset_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(dataset_); - dataset_ = subBuilder.buildPartial(); - } - - break; - } - case 16: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder.class); - } - - /** - * - * - *
-     * Describes how the dataset was changed.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Dataset was changed using the datasets.update or datasets.patch API.
-       * 
- * - * UPDATE = 1; - */ - UPDATE(1), - /** - * - * - *
-       * Dataset was changed using the SetIamPolicy API.
-       * 
- * - * SET_IAM_POLICY = 2; - */ - SET_IAM_POLICY(2), - /** - * - * - *
-       * Dataset was changed using a query job, e.g., ALTER SCHEMA statement.
-       * 
- * - * QUERY = 3; - */ - QUERY(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Dataset was changed using the datasets.update or datasets.patch API.
-       * 
- * - * UPDATE = 1; - */ - public static final int UPDATE_VALUE = 1; - /** - * - * - *
-       * Dataset was changed using the SetIamPolicy API.
-       * 
- * - * SET_IAM_POLICY = 2; - */ - public static final int SET_IAM_POLICY_VALUE = 2; - /** - * - * - *
-       * Dataset was changed using a query job, e.g., ALTER SCHEMA statement.
-       * 
- * - * QUERY = 3; - */ - public static final int QUERY_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return UPDATE; - case 2: - return SET_IAM_POLICY; - case 3: - return QUERY; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason) - } - - public static final int DATASET_FIELD_NUMBER = 1; - private com.google.cloud.audit.BigQueryAuditMetadata.Dataset dataset_; - /** - * - * - *
-     * Dataset metadata after the change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return Whether the dataset field is set. - */ - @java.lang.Override - public boolean hasDataset() { - return dataset_ != null; - } - /** - * - * - *
-     * Dataset metadata after the change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return The dataset. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset() { - return dataset_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() - : dataset_; - } - /** - * - * - *
-     * Dataset metadata after the change.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder() { - return getDataset(); - } - - public static final int REASON_FIELD_NUMBER = 2; - private int reason_; - /** - * - * - *
-     * Describes how the dataset was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the dataset was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 3; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that updated the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that updated the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (dataset_ != null) { - output.writeMessage(1, getDataset()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(2, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (dataset_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getDataset()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange other = - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) obj; - - if (hasDataset() != other.hasDataset()) return false; - if (hasDataset()) { - if (!getDataset().equals(other.getDataset())) return false; - } - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasDataset()) { - hash = (37 * hash) + DATASET_FIELD_NUMBER; - hash = (53 * hash) + getDataset().hashCode(); - } - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Dataset change event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetChange} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetChange) - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (datasetBuilder_ == null) { - dataset_ = null; - } else { - dataset_ = null; - datasetBuilder_ = null; - } - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange build() { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange result = - new com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange(this); - if (datasetBuilder_ == null) { - result.dataset_ = dataset_; - } else { - result.dataset_ = datasetBuilder_.build(); - } - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance()) - return this; - if (other.hasDataset()) { - mergeDataset(other.getDataset()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Dataset dataset_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Dataset, - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder> - datasetBuilder_; - /** - * - * - *
-       * Dataset metadata after the change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return Whether the dataset field is set. - */ - public boolean hasDataset() { - return datasetBuilder_ != null || dataset_ != null; - } - /** - * - * - *
-       * Dataset metadata after the change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - * - * @return The dataset. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDataset() { - if (datasetBuilder_ == null) { - return dataset_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() - : dataset_; - } else { - return datasetBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Dataset metadata after the change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public Builder setDataset(com.google.cloud.audit.BigQueryAuditMetadata.Dataset value) { - if (datasetBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - dataset_ = value; - onChanged(); - } else { - datasetBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Dataset metadata after the change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public Builder setDataset( - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder builderForValue) { - if (datasetBuilder_ == null) { - dataset_ = builderForValue.build(); - onChanged(); - } else { - datasetBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Dataset metadata after the change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public Builder mergeDataset(com.google.cloud.audit.BigQueryAuditMetadata.Dataset value) { - if (datasetBuilder_ == null) { - if (dataset_ != null) { - dataset_ = - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.newBuilder(dataset_) - .mergeFrom(value) - .buildPartial(); - } else { - dataset_ = value; - } - onChanged(); - } else { - datasetBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Dataset metadata after the change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public Builder clearDataset() { - if (datasetBuilder_ == null) { - dataset_ = null; - onChanged(); - } else { - dataset_ = null; - datasetBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Dataset metadata after the change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder getDatasetBuilder() { - - onChanged(); - return getDatasetFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Dataset metadata after the change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder getDatasetOrBuilder() { - if (datasetBuilder_ != null) { - return datasetBuilder_.getMessageOrBuilder(); - } else { - return dataset_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance() - : dataset_; - } - } - /** - * - * - *
-       * Dataset metadata after the change.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Dataset dataset = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Dataset, - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder> - getDatasetFieldBuilder() { - if (datasetBuilder_ == null) { - datasetBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Dataset, - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder>( - getDataset(), getParentForChildren(), isClean()); - dataset_ = null; - } - return datasetBuilder_; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the dataset was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the dataset was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the dataset was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the dataset was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the dataset was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Reason reason = 2; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that updated the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that updated the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that updated the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that updated the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that updated the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetChange) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetChange) - private static final com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DatasetChange parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DatasetChange(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface DatasetDeletionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Describes how the dataset was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the dataset was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that deleted the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that deleted the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Dataset deletion event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion} - */ - public static final class DatasetDeletion extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) - DatasetDeletionOrBuilder { - private static final long serialVersionUID = 0L; - // Use DatasetDeletion.newBuilder() to construct. - private DatasetDeletion(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private DatasetDeletion() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new DatasetDeletion(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private DatasetDeletion( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.class, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder.class); - } - - /** - * - * - *
-     * Describes how the dataset was deleted.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Dataset was deleted using the datasets.delete API.
-       * 
- * - * DELETE = 1; - */ - DELETE(1), - /** - * - * - *
-       * Dataset was deleted using a query job, e.g., DROP SCHEMA statement.
-       * 
- * - * QUERY = 2; - */ - QUERY(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Dataset was deleted using the datasets.delete API.
-       * 
- * - * DELETE = 1; - */ - public static final int DELETE_VALUE = 1; - /** - * - * - *
-       * Dataset was deleted using a query job, e.g., DROP SCHEMA statement.
-       * 
- * - * QUERY = 2; - */ - public static final int QUERY_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return DELETE; - case 2: - return QUERY; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason) - } - - public static final int REASON_FIELD_NUMBER = 1; - private int reason_; - /** - * - * - *
-     * Describes how the dataset was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the dataset was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that deleted the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that deleted the dataset.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion other = - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) obj; - - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Dataset deletion event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.class, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion build() { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion result = - new com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion(this); - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance()) - return this; - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the dataset was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the dataset was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the dataset was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the dataset was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the dataset was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Reason reason = 1; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that deleted the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that deleted the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that deleted the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that deleted the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that deleted the dataset.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) - private static final com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DatasetDeletion parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DatasetDeletion(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface TableCreationOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableCreation) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return Whether the table field is set. - */ - boolean hasTable(); - /** - * - * - *
-     * Table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return The table. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Table getTable(); - /** - * - * - *
-     * Table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder(); - - /** - * - * - *
-     * Describes how the table was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the table was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that created a table.
-     * Present if the reason is JOB or QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that created a table.
-     * Present if the reason is JOB or QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Table creation event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableCreation} - */ - public static final class TableCreation extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableCreation) - TableCreationOrBuilder { - private static final long serialVersionUID = 0L; - // Use TableCreation.newBuilder() to construct. - private TableCreation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private TableCreation() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TableCreation(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private TableCreation( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder subBuilder = null; - if (table_ != null) { - subBuilder = table_.toBuilder(); - } - table_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Table.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(table_); - table_ = subBuilder.buildPartial(); - } - - break; - } - case 24: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder.class); - } - - /** - * - * - *
-     * Describes how the table was created.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Table was created as a destination table during a query, load or copy
-       * job.
-       * 
- * - * JOB = 1; - */ - JOB(1), - /** - * - * - *
-       * Table was created using a DDL query.
-       * 
- * - * QUERY = 2; - */ - QUERY(2), - /** - * - * - *
-       * Table was created using the tables.create API.
-       * 
- * - * TABLE_INSERT_REQUEST = 3; - */ - TABLE_INSERT_REQUEST(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Table was created as a destination table during a query, load or copy
-       * job.
-       * 
- * - * JOB = 1; - */ - public static final int JOB_VALUE = 1; - /** - * - * - *
-       * Table was created using a DDL query.
-       * 
- * - * QUERY = 2; - */ - public static final int QUERY_VALUE = 2; - /** - * - * - *
-       * Table was created using the tables.create API.
-       * 
- * - * TABLE_INSERT_REQUEST = 3; - */ - public static final int TABLE_INSERT_REQUEST_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return JOB; - case 2: - return QUERY; - case 3: - return TABLE_INSERT_REQUEST; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason) - } - - public static final int TABLE_FIELD_NUMBER = 1; - private com.google.cloud.audit.BigQueryAuditMetadata.Table table_; - /** - * - * - *
-     * Table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return Whether the table field is set. - */ - @java.lang.Override - public boolean hasTable() { - return table_ != null; - } - /** - * - * - *
-     * Table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return The table. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Table getTable() { - return table_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() - : table_; - } - /** - * - * - *
-     * Table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder() { - return getTable(); - } - - public static final int REASON_FIELD_NUMBER = 3; - private int reason_; - /** - * - * - *
-     * Describes how the table was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the table was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 4; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that created a table.
-     * Present if the reason is JOB or QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that created a table.
-     * Present if the reason is JOB or QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (table_ != null) { - output.writeMessage(1, getTable()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (table_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getTable()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableCreation)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation other = - (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) obj; - - if (hasTable() != other.hasTable()) return false; - if (hasTable()) { - if (!getTable().equals(other.getTable())) return false; - } - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasTable()) { - hash = (37 * hash) + TABLE_FIELD_NUMBER; - hash = (53 * hash) + getTable().hashCode(); - } - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Table creation event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableCreation} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableCreation) - com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (tableBuilder_ == null) { - table_ = null; - } else { - table_ = null; - tableBuilder_ = null; - } - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation build() { - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation result = - new com.google.cloud.audit.BigQueryAuditMetadata.TableCreation(this); - if (tableBuilder_ == null) { - result.table_ = table_; - } else { - result.table_ = tableBuilder_.build(); - } - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableCreation other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance()) - return this; - if (other.hasTable()) { - mergeTable(other.getTable()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Table table_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Table, - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder> - tableBuilder_; - /** - * - * - *
-       * Table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return Whether the table field is set. - */ - public boolean hasTable() { - return tableBuilder_ != null || table_ != null; - } - /** - * - * - *
-       * Table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return The table. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Table getTable() { - if (tableBuilder_ == null) { - return table_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() - : table_; - } else { - return tableBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public Builder setTable(com.google.cloud.audit.BigQueryAuditMetadata.Table value) { - if (tableBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - table_ = value; - onChanged(); - } else { - tableBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public Builder setTable( - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder builderForValue) { - if (tableBuilder_ == null) { - table_ = builderForValue.build(); - onChanged(); - } else { - tableBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public Builder mergeTable(com.google.cloud.audit.BigQueryAuditMetadata.Table value) { - if (tableBuilder_ == null) { - if (table_ != null) { - table_ = - com.google.cloud.audit.BigQueryAuditMetadata.Table.newBuilder(table_) - .mergeFrom(value) - .buildPartial(); - } else { - table_ = value; - } - onChanged(); - } else { - tableBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public Builder clearTable() { - if (tableBuilder_ == null) { - table_ = null; - onChanged(); - } else { - table_ = null; - tableBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder getTableBuilder() { - - onChanged(); - return getTableFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder() { - if (tableBuilder_ != null) { - return tableBuilder_.getMessageOrBuilder(); - } else { - return table_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() - : table_; - } - } - /** - * - * - *
-       * Table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Table, - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder> - getTableFieldBuilder() { - if (tableBuilder_ == null) { - tableBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Table, - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder>( - getTable(), getParentForChildren(), isClean()); - table_ = null; - } - return tableBuilder_; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the table was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the table was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the table was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the table was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the table was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation.Reason reason = 3; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that created a table.
-       * Present if the reason is JOB or QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that created a table.
-       * Present if the reason is JOB or QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that created a table.
-       * Present if the reason is JOB or QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that created a table.
-       * Present if the reason is JOB or QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that created a table.
-       * Present if the reason is JOB or QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableCreation) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableCreation) - private static final com.google.cloud.audit.BigQueryAuditMetadata.TableCreation - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableCreation(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableCreation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public TableCreation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TableCreation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface ModelCreationOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.ModelCreation) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Model metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return Whether the model field is set. - */ - boolean hasModel(); - /** - * - * - *
-     * Model metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return The model. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Model getModel(); - /** - * - * - *
-     * Model metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder(); - - /** - * - * - *
-     * Describes how the model was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the model was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that created the model.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that created the model.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Model creation event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelCreation} - */ - public static final class ModelCreation extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.ModelCreation) - ModelCreationOrBuilder { - private static final long serialVersionUID = 0L; - // Use ModelCreation.newBuilder() to construct. - private ModelCreation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ModelCreation() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ModelCreation(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ModelCreation( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder subBuilder = null; - if (model_ != null) { - subBuilder = model_.toBuilder(); - } - model_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Model.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(model_); - model_ = subBuilder.buildPartial(); - } - - break; - } - case 24: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.class, - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder.class); - } - - /** - * - * - *
-     * Describes how the model was created.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Model was created using a DDL query.
-       * 
- * - * QUERY = 2; - */ - QUERY(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Model was created using a DDL query.
-       * 
- * - * QUERY = 2; - */ - public static final int QUERY_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 2: - return QUERY; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason) - } - - public static final int MODEL_FIELD_NUMBER = 1; - private com.google.cloud.audit.BigQueryAuditMetadata.Model model_; - /** - * - * - *
-     * Model metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return Whether the model field is set. - */ - @java.lang.Override - public boolean hasModel() { - return model_ != null; - } - /** - * - * - *
-     * Model metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return The model. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Model getModel() { - return model_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() - : model_; - } - /** - * - * - *
-     * Model metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder() { - return getModel(); - } - - public static final int REASON_FIELD_NUMBER = 3; - private int reason_; - /** - * - * - *
-     * Describes how the model was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the model was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 4; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that created the model.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that created the model.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (model_ != null) { - output.writeMessage(1, getModel()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (model_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getModel()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation other = - (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) obj; - - if (hasModel() != other.hasModel()) return false; - if (hasModel()) { - if (!getModel().equals(other.getModel())) return false; - } - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasModel()) { - hash = (37 * hash) + MODEL_FIELD_NUMBER; - hash = (53 * hash) + getModel().hashCode(); - } - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Model creation event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelCreation} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.ModelCreation) - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.class, - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (modelBuilder_ == null) { - model_ = null; - } else { - model_ = null; - modelBuilder_ = null; - } - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation build() { - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation result = - new com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation(this); - if (modelBuilder_ == null) { - result.model_ = model_; - } else { - result.model_ = modelBuilder_.build(); - } - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance()) - return this; - if (other.hasModel()) { - mergeModel(other.getModel()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Model model_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Model, - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder> - modelBuilder_; - /** - * - * - *
-       * Model metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return Whether the model field is set. - */ - public boolean hasModel() { - return modelBuilder_ != null || model_ != null; - } - /** - * - * - *
-       * Model metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return The model. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Model getModel() { - if (modelBuilder_ == null) { - return model_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() - : model_; - } else { - return modelBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Model metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public Builder setModel(com.google.cloud.audit.BigQueryAuditMetadata.Model value) { - if (modelBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - model_ = value; - onChanged(); - } else { - modelBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Model metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public Builder setModel( - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder builderForValue) { - if (modelBuilder_ == null) { - model_ = builderForValue.build(); - onChanged(); - } else { - modelBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Model metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public Builder mergeModel(com.google.cloud.audit.BigQueryAuditMetadata.Model value) { - if (modelBuilder_ == null) { - if (model_ != null) { - model_ = - com.google.cloud.audit.BigQueryAuditMetadata.Model.newBuilder(model_) - .mergeFrom(value) - .buildPartial(); - } else { - model_ = value; - } - onChanged(); - } else { - modelBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Model metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public Builder clearModel() { - if (modelBuilder_ == null) { - model_ = null; - onChanged(); - } else { - model_ = null; - modelBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Model metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder getModelBuilder() { - - onChanged(); - return getModelFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Model metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder() { - if (modelBuilder_ != null) { - return modelBuilder_.getMessageOrBuilder(); - } else { - return model_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() - : model_; - } - } - /** - * - * - *
-       * Model metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Model, - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder> - getModelFieldBuilder() { - if (modelBuilder_ == null) { - modelBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Model, - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder>( - getModel(), getParentForChildren(), isClean()); - model_ = null; - } - return modelBuilder_; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the model was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the model was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the model was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the model was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the model was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Reason reason = 3; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that created the model.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that created the model.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that created the model.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that created the model.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that created the model.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.ModelCreation) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.ModelCreation) - private static final com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ModelCreation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ModelCreation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface RoutineCreationOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Created routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return Whether the routine field is set. - */ - boolean hasRoutine(); - /** - * - * - *
-     * Created routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return The routine. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine(); - /** - * - * - *
-     * Created routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder(); - - /** - * - * - *
-     * Describes how the routine was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the routine was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that created the routine.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that created the routine.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Routine creation event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineCreation} - */ - public static final class RoutineCreation extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) - RoutineCreationOrBuilder { - private static final long serialVersionUID = 0L; - // Use RoutineCreation.newBuilder() to construct. - private RoutineCreation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private RoutineCreation() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new RoutineCreation(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private RoutineCreation( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder subBuilder = null; - if (routine_ != null) { - subBuilder = routine_.toBuilder(); - } - routine_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Routine.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(routine_); - routine_ = subBuilder.buildPartial(); - } - - break; - } - case 24: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.class, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder.class); - } - - /** - * - * - *
-     * Describes how the routine was created.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Routine was created using a DDL query.
-       * 
- * - * QUERY = 1; - */ - QUERY(1), - /** - * - * - *
-       * Routine was created using the routines.create API.
-       * 
- * - * ROUTINE_INSERT_REQUEST = 2; - */ - ROUTINE_INSERT_REQUEST(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Routine was created using a DDL query.
-       * 
- * - * QUERY = 1; - */ - public static final int QUERY_VALUE = 1; - /** - * - * - *
-       * Routine was created using the routines.create API.
-       * 
- * - * ROUTINE_INSERT_REQUEST = 2; - */ - public static final int ROUTINE_INSERT_REQUEST_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return QUERY; - case 2: - return ROUTINE_INSERT_REQUEST; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason) - } - - public static final int ROUTINE_FIELD_NUMBER = 1; - private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; - /** - * - * - *
-     * Created routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return Whether the routine field is set. - */ - @java.lang.Override - public boolean hasRoutine() { - return routine_ != null; - } - /** - * - * - *
-     * Created routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return The routine. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { - return routine_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() - : routine_; - } - /** - * - * - *
-     * Created routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { - return getRoutine(); - } - - public static final int REASON_FIELD_NUMBER = 3; - private int reason_; - /** - * - * - *
-     * Describes how the routine was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the routine was created.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 4; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that created the routine.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that created the routine.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (routine_ != null) { - output.writeMessage(1, getRoutine()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (routine_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getRoutine()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation other = - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) obj; - - if (hasRoutine() != other.hasRoutine()) return false; - if (hasRoutine()) { - if (!getRoutine().equals(other.getRoutine())) return false; - } - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasRoutine()) { - hash = (37 * hash) + ROUTINE_FIELD_NUMBER; - hash = (53 * hash) + getRoutine().hashCode(); - } - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Routine creation event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineCreation} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.class, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (routineBuilder_ == null) { - routine_ = null; - } else { - routine_ = null; - routineBuilder_ = null; - } - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation build() { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation result = - new com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation(this); - if (routineBuilder_ == null) { - result.routine_ = routine_; - } else { - result.routine_ = routineBuilder_.build(); - } - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance()) - return this; - if (other.hasRoutine()) { - mergeRoutine(other.getRoutine()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Routine, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> - routineBuilder_; - /** - * - * - *
-       * Created routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return Whether the routine field is set. - */ - public boolean hasRoutine() { - return routineBuilder_ != null || routine_ != null; - } - /** - * - * - *
-       * Created routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return The routine. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { - if (routineBuilder_ == null) { - return routine_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() - : routine_; - } else { - return routineBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Created routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder setRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { - if (routineBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - routine_ = value; - onChanged(); - } else { - routineBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Created routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder setRoutine( - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder builderForValue) { - if (routineBuilder_ == null) { - routine_ = builderForValue.build(); - onChanged(); - } else { - routineBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Created routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder mergeRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { - if (routineBuilder_ == null) { - if (routine_ != null) { - routine_ = - com.google.cloud.audit.BigQueryAuditMetadata.Routine.newBuilder(routine_) - .mergeFrom(value) - .buildPartial(); - } else { - routine_ = value; - } - onChanged(); - } else { - routineBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Created routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder clearRoutine() { - if (routineBuilder_ == null) { - routine_ = null; - onChanged(); - } else { - routine_ = null; - routineBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Created routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder getRoutineBuilder() { - - onChanged(); - return getRoutineFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Created routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { - if (routineBuilder_ != null) { - return routineBuilder_.getMessageOrBuilder(); - } else { - return routine_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() - : routine_; - } - } - /** - * - * - *
-       * Created routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Routine, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> - getRoutineFieldBuilder() { - if (routineBuilder_ == null) { - routineBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Routine, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder>( - getRoutine(), getParentForChildren(), isClean()); - routine_ = null; - } - return routineBuilder_; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the routine was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the routine was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the routine was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the routine was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the routine was created.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Reason reason = 3; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that created the routine.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that created the routine.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that created the routine.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that created the routine.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that created the routine.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) - private static final com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public RoutineCreation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RoutineCreation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface TableDataReadOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableDataRead) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * List of the accessed fields. Entire list is truncated if the record size
-     * exceeds 100K.
-     * 
- * - * repeated string fields = 2; - * - * @return A list containing the fields. - */ - java.util.List getFieldsList(); - /** - * - * - *
-     * List of the accessed fields. Entire list is truncated if the record size
-     * exceeds 100K.
-     * 
- * - * repeated string fields = 2; - * - * @return The count of fields. - */ - int getFieldsCount(); - /** - * - * - *
-     * List of the accessed fields. Entire list is truncated if the record size
-     * exceeds 100K.
-     * 
- * - * repeated string fields = 2; - * - * @param index The index of the element to return. - * @return The fields at the given index. - */ - java.lang.String getFields(int index); - /** - * - * - *
-     * List of the accessed fields. Entire list is truncated if the record size
-     * exceeds 100K.
-     * 
- * - * repeated string fields = 2; - * - * @param index The index of the value to return. - * @return The bytes of the fields at the given index. - */ - com.google.protobuf.ByteString getFieldsBytes(int index); - - /** - * - * - *
-     * True if the fields list was truncated.
-     * 
- * - * bool fields_truncated = 8; - * - * @return The fieldsTruncated. - */ - boolean getFieldsTruncated(); - - /** - * - * - *
-     * List of the referenced policy tags. That is, policy tags attached to the
-     * accessed fields or their ancestors.
-     * Policy tag resource name is a string of the format:
-     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-     * 
- * - * repeated string policy_tags = 9; - * - * @return A list containing the policyTags. - */ - java.util.List getPolicyTagsList(); - /** - * - * - *
-     * List of the referenced policy tags. That is, policy tags attached to the
-     * accessed fields or their ancestors.
-     * Policy tag resource name is a string of the format:
-     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-     * 
- * - * repeated string policy_tags = 9; - * - * @return The count of policyTags. - */ - int getPolicyTagsCount(); - /** - * - * - *
-     * List of the referenced policy tags. That is, policy tags attached to the
-     * accessed fields or their ancestors.
-     * Policy tag resource name is a string of the format:
-     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-     * 
- * - * repeated string policy_tags = 9; - * - * @param index The index of the element to return. - * @return The policyTags at the given index. - */ - java.lang.String getPolicyTags(int index); - /** - * - * - *
-     * List of the referenced policy tags. That is, policy tags attached to the
-     * accessed fields or their ancestors.
-     * Policy tag resource name is a string of the format:
-     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-     * 
- * - * repeated string policy_tags = 9; - * - * @param index The index of the value to return. - * @return The bytes of the policyTags at the given index. - */ - com.google.protobuf.ByteString getPolicyTagsBytes(int index); - - /** - * - * - *
-     * True if the policy tag list was truncated. At most 100 policy tags can be
-     * saved.
-     * 
- * - * bool policy_tags_truncated = 10; - * - * @return The policyTagsTruncated. - */ - boolean getPolicyTagsTruncated(); - - /** - * - * - *
-     * Describes how the table data was read.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the table data was read.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that read a table.
-     * Present if the reason is JOB but can be redacted for privacy reasons.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that read a table.
-     * Present if the reason is JOB but can be redacted for privacy reasons.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - - /** - * - * - *
-     * The URI of the read session that read a table.
-     * Present if the reason is CREATE_READ_SESSION.
-     * Format:
-     * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
-     * 
- * - * string session_name = 5; - * - * @return The sessionName. - */ - java.lang.String getSessionName(); - /** - * - * - *
-     * The URI of the read session that read a table.
-     * Present if the reason is CREATE_READ_SESSION.
-     * Format:
-     * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
-     * 
- * - * string session_name = 5; - * - * @return The bytes for sessionName. - */ - com.google.protobuf.ByteString getSessionNameBytes(); - } - /** - * - * - *
-   * Table data read event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDataRead} - */ - public static final class TableDataRead extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableDataRead) - TableDataReadOrBuilder { - private static final long serialVersionUID = 0L; - // Use TableDataRead.newBuilder() to construct. - private TableDataRead(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private TableDataRead() { - fields_ = com.google.protobuf.LazyStringArrayList.EMPTY; - policyTags_ = com.google.protobuf.LazyStringArrayList.EMPTY; - reason_ = 0; - jobName_ = ""; - sessionName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TableDataRead(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private TableDataRead( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - fields_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - fields_.add(s); - break; - } - case 24: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - sessionName_ = s; - break; - } - case 64: - { - fieldsTruncated_ = input.readBool(); - break; - } - case 74: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - policyTags_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - policyTags_.add(s); - break; - } - case 80: - { - policyTagsTruncated_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - fields_ = fields_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - policyTags_ = policyTags_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder.class); - } - - /** - * - * - *
-     * Describes how the table data was read.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Table was used as a source table during a BigQuery job.
-       * 
- * - * JOB = 1; - */ - JOB(1), - /** - * - * - *
-       * Table data was accessed using the tabledata.list API.
-       * 
- * - * TABLEDATA_LIST_REQUEST = 2; - */ - TABLEDATA_LIST_REQUEST(2), - /** - * - * - *
-       * Table data was accessed using the jobs.getQueryResults API.
-       * 
- * - * GET_QUERY_RESULTS_REQUEST = 3; - */ - GET_QUERY_RESULTS_REQUEST(3), - /** - * - * - *
-       * Table data was accessed using the jobs.query RPC.
-       * 
- * - * QUERY_REQUEST = 4; - */ - QUERY_REQUEST(4), - /** - * - * - *
-       * Table data was accessed using storage.CreateReadSession API.
-       * 
- * - * CREATE_READ_SESSION = 5; - */ - CREATE_READ_SESSION(5), - /** - * - * - *
-       * Table data was accessed during a materialized view refresh.
-       * 
- * - * MATERIALIZED_VIEW_REFRESH = 6; - */ - MATERIALIZED_VIEW_REFRESH(6), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Table was used as a source table during a BigQuery job.
-       * 
- * - * JOB = 1; - */ - public static final int JOB_VALUE = 1; - /** - * - * - *
-       * Table data was accessed using the tabledata.list API.
-       * 
- * - * TABLEDATA_LIST_REQUEST = 2; - */ - public static final int TABLEDATA_LIST_REQUEST_VALUE = 2; - /** - * - * - *
-       * Table data was accessed using the jobs.getQueryResults API.
-       * 
- * - * GET_QUERY_RESULTS_REQUEST = 3; - */ - public static final int GET_QUERY_RESULTS_REQUEST_VALUE = 3; - /** - * - * - *
-       * Table data was accessed using the jobs.query RPC.
-       * 
- * - * QUERY_REQUEST = 4; - */ - public static final int QUERY_REQUEST_VALUE = 4; - /** - * - * - *
-       * Table data was accessed using storage.CreateReadSession API.
-       * 
- * - * CREATE_READ_SESSION = 5; - */ - public static final int CREATE_READ_SESSION_VALUE = 5; - /** - * - * - *
-       * Table data was accessed during a materialized view refresh.
-       * 
- * - * MATERIALIZED_VIEW_REFRESH = 6; - */ - public static final int MATERIALIZED_VIEW_REFRESH_VALUE = 6; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return JOB; - case 2: - return TABLEDATA_LIST_REQUEST; - case 3: - return GET_QUERY_RESULTS_REQUEST; - case 4: - return QUERY_REQUEST; - case 5: - return CREATE_READ_SESSION; - case 6: - return MATERIALIZED_VIEW_REFRESH; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason) - } - - public static final int FIELDS_FIELD_NUMBER = 2; - private com.google.protobuf.LazyStringList fields_; - /** - * - * - *
-     * List of the accessed fields. Entire list is truncated if the record size
-     * exceeds 100K.
-     * 
- * - * repeated string fields = 2; - * - * @return A list containing the fields. - */ - public com.google.protobuf.ProtocolStringList getFieldsList() { - return fields_; - } - /** - * - * - *
-     * List of the accessed fields. Entire list is truncated if the record size
-     * exceeds 100K.
-     * 
- * - * repeated string fields = 2; - * - * @return The count of fields. - */ - public int getFieldsCount() { - return fields_.size(); - } - /** - * - * - *
-     * List of the accessed fields. Entire list is truncated if the record size
-     * exceeds 100K.
-     * 
- * - * repeated string fields = 2; - * - * @param index The index of the element to return. - * @return The fields at the given index. - */ - public java.lang.String getFields(int index) { - return fields_.get(index); - } - /** - * - * - *
-     * List of the accessed fields. Entire list is truncated if the record size
-     * exceeds 100K.
-     * 
- * - * repeated string fields = 2; - * - * @param index The index of the value to return. - * @return The bytes of the fields at the given index. - */ - public com.google.protobuf.ByteString getFieldsBytes(int index) { - return fields_.getByteString(index); - } - - public static final int FIELDS_TRUNCATED_FIELD_NUMBER = 8; - private boolean fieldsTruncated_; - /** - * - * - *
-     * True if the fields list was truncated.
-     * 
- * - * bool fields_truncated = 8; - * - * @return The fieldsTruncated. - */ - @java.lang.Override - public boolean getFieldsTruncated() { - return fieldsTruncated_; - } - - public static final int POLICY_TAGS_FIELD_NUMBER = 9; - private com.google.protobuf.LazyStringList policyTags_; - /** - * - * - *
-     * List of the referenced policy tags. That is, policy tags attached to the
-     * accessed fields or their ancestors.
-     * Policy tag resource name is a string of the format:
-     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-     * 
- * - * repeated string policy_tags = 9; - * - * @return A list containing the policyTags. - */ - public com.google.protobuf.ProtocolStringList getPolicyTagsList() { - return policyTags_; - } - /** - * - * - *
-     * List of the referenced policy tags. That is, policy tags attached to the
-     * accessed fields or their ancestors.
-     * Policy tag resource name is a string of the format:
-     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-     * 
- * - * repeated string policy_tags = 9; - * - * @return The count of policyTags. - */ - public int getPolicyTagsCount() { - return policyTags_.size(); - } - /** - * - * - *
-     * List of the referenced policy tags. That is, policy tags attached to the
-     * accessed fields or their ancestors.
-     * Policy tag resource name is a string of the format:
-     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-     * 
- * - * repeated string policy_tags = 9; - * - * @param index The index of the element to return. - * @return The policyTags at the given index. - */ - public java.lang.String getPolicyTags(int index) { - return policyTags_.get(index); - } - /** - * - * - *
-     * List of the referenced policy tags. That is, policy tags attached to the
-     * accessed fields or their ancestors.
-     * Policy tag resource name is a string of the format:
-     * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-     * 
- * - * repeated string policy_tags = 9; - * - * @param index The index of the value to return. - * @return The bytes of the policyTags at the given index. - */ - public com.google.protobuf.ByteString getPolicyTagsBytes(int index) { - return policyTags_.getByteString(index); - } - - public static final int POLICY_TAGS_TRUNCATED_FIELD_NUMBER = 10; - private boolean policyTagsTruncated_; - /** - * - * - *
-     * True if the policy tag list was truncated. At most 100 policy tags can be
-     * saved.
-     * 
- * - * bool policy_tags_truncated = 10; - * - * @return The policyTagsTruncated. - */ - @java.lang.Override - public boolean getPolicyTagsTruncated() { - return policyTagsTruncated_; - } - - public static final int REASON_FIELD_NUMBER = 3; - private int reason_; - /** - * - * - *
-     * Describes how the table data was read.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the table data was read.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 4; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that read a table.
-     * Present if the reason is JOB but can be redacted for privacy reasons.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that read a table.
-     * Present if the reason is JOB but can be redacted for privacy reasons.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SESSION_NAME_FIELD_NUMBER = 5; - private volatile java.lang.Object sessionName_; - /** - * - * - *
-     * The URI of the read session that read a table.
-     * Present if the reason is CREATE_READ_SESSION.
-     * Format:
-     * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
-     * 
- * - * string session_name = 5; - * - * @return The sessionName. - */ - @java.lang.Override - public java.lang.String getSessionName() { - java.lang.Object ref = sessionName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - sessionName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the read session that read a table.
-     * Present if the reason is CREATE_READ_SESSION.
-     * Format:
-     * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
-     * 
- * - * string session_name = 5; - * - * @return The bytes for sessionName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getSessionNameBytes() { - java.lang.Object ref = sessionName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - sessionName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < fields_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, fields_.getRaw(i)); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); - } - if (!getSessionNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, sessionName_); - } - if (fieldsTruncated_ != false) { - output.writeBool(8, fieldsTruncated_); - } - for (int i = 0; i < policyTags_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 9, policyTags_.getRaw(i)); - } - if (policyTagsTruncated_ != false) { - output.writeBool(10, policyTagsTruncated_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - for (int i = 0; i < fields_.size(); i++) { - dataSize += computeStringSizeNoTag(fields_.getRaw(i)); - } - size += dataSize; - size += 1 * getFieldsList().size(); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); - } - if (!getSessionNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, sessionName_); - } - if (fieldsTruncated_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, fieldsTruncated_); - } - { - int dataSize = 0; - for (int i = 0; i < policyTags_.size(); i++) { - dataSize += computeStringSizeNoTag(policyTags_.getRaw(i)); - } - size += dataSize; - size += 1 * getPolicyTagsList().size(); - } - if (policyTagsTruncated_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(10, policyTagsTruncated_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead other = - (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) obj; - - if (!getFieldsList().equals(other.getFieldsList())) return false; - if (getFieldsTruncated() != other.getFieldsTruncated()) return false; - if (!getPolicyTagsList().equals(other.getPolicyTagsList())) return false; - if (getPolicyTagsTruncated() != other.getPolicyTagsTruncated()) return false; - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!getSessionName().equals(other.getSessionName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getFieldsCount() > 0) { - hash = (37 * hash) + FIELDS_FIELD_NUMBER; - hash = (53 * hash) + getFieldsList().hashCode(); - } - hash = (37 * hash) + FIELDS_TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getFieldsTruncated()); - if (getPolicyTagsCount() > 0) { - hash = (37 * hash) + POLICY_TAGS_FIELD_NUMBER; - hash = (53 * hash) + getPolicyTagsList().hashCode(); - } - hash = (37 * hash) + POLICY_TAGS_TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPolicyTagsTruncated()); - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (37 * hash) + SESSION_NAME_FIELD_NUMBER; - hash = (53 * hash) + getSessionName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Table data read event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDataRead} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableDataRead) - com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - fields_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - fieldsTruncated_ = false; - - policyTags_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - policyTagsTruncated_ = false; - - reason_ = 0; - - jobName_ = ""; - - sessionName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead build() { - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead result = - new com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead(this); - int from_bitField0_ = bitField0_; - if (((bitField0_ & 0x00000001) != 0)) { - fields_ = fields_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.fields_ = fields_; - result.fieldsTruncated_ = fieldsTruncated_; - if (((bitField0_ & 0x00000002) != 0)) { - policyTags_ = policyTags_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.policyTags_ = policyTags_; - result.policyTagsTruncated_ = policyTagsTruncated_; - result.reason_ = reason_; - result.jobName_ = jobName_; - result.sessionName_ = sessionName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance()) - return this; - if (!other.fields_.isEmpty()) { - if (fields_.isEmpty()) { - fields_ = other.fields_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureFieldsIsMutable(); - fields_.addAll(other.fields_); - } - onChanged(); - } - if (other.getFieldsTruncated() != false) { - setFieldsTruncated(other.getFieldsTruncated()); - } - if (!other.policyTags_.isEmpty()) { - if (policyTags_.isEmpty()) { - policyTags_ = other.policyTags_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensurePolicyTagsIsMutable(); - policyTags_.addAll(other.policyTags_); - } - onChanged(); - } - if (other.getPolicyTagsTruncated() != false) { - setPolicyTagsTruncated(other.getPolicyTagsTruncated()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - if (!other.getSessionName().isEmpty()) { - sessionName_ = other.sessionName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private com.google.protobuf.LazyStringList fields_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureFieldsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - fields_ = new com.google.protobuf.LazyStringArrayList(fields_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-       * List of the accessed fields. Entire list is truncated if the record size
-       * exceeds 100K.
-       * 
- * - * repeated string fields = 2; - * - * @return A list containing the fields. - */ - public com.google.protobuf.ProtocolStringList getFieldsList() { - return fields_.getUnmodifiableView(); - } - /** - * - * - *
-       * List of the accessed fields. Entire list is truncated if the record size
-       * exceeds 100K.
-       * 
- * - * repeated string fields = 2; - * - * @return The count of fields. - */ - public int getFieldsCount() { - return fields_.size(); - } - /** - * - * - *
-       * List of the accessed fields. Entire list is truncated if the record size
-       * exceeds 100K.
-       * 
- * - * repeated string fields = 2; - * - * @param index The index of the element to return. - * @return The fields at the given index. - */ - public java.lang.String getFields(int index) { - return fields_.get(index); - } - /** - * - * - *
-       * List of the accessed fields. Entire list is truncated if the record size
-       * exceeds 100K.
-       * 
- * - * repeated string fields = 2; - * - * @param index The index of the value to return. - * @return The bytes of the fields at the given index. - */ - public com.google.protobuf.ByteString getFieldsBytes(int index) { - return fields_.getByteString(index); - } - /** - * - * - *
-       * List of the accessed fields. Entire list is truncated if the record size
-       * exceeds 100K.
-       * 
- * - * repeated string fields = 2; - * - * @param index The index to set the value at. - * @param value The fields to set. - * @return This builder for chaining. - */ - public Builder setFields(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldsIsMutable(); - fields_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-       * List of the accessed fields. Entire list is truncated if the record size
-       * exceeds 100K.
-       * 
- * - * repeated string fields = 2; - * - * @param value The fields to add. - * @return This builder for chaining. - */ - public Builder addFields(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldsIsMutable(); - fields_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-       * List of the accessed fields. Entire list is truncated if the record size
-       * exceeds 100K.
-       * 
- * - * repeated string fields = 2; - * - * @param values The fields to add. - * @return This builder for chaining. - */ - public Builder addAllFields(java.lang.Iterable values) { - ensureFieldsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, fields_); - onChanged(); - return this; - } - /** - * - * - *
-       * List of the accessed fields. Entire list is truncated if the record size
-       * exceeds 100K.
-       * 
- * - * repeated string fields = 2; - * - * @return This builder for chaining. - */ - public Builder clearFields() { - fields_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-       * List of the accessed fields. Entire list is truncated if the record size
-       * exceeds 100K.
-       * 
- * - * repeated string fields = 2; - * - * @param value The bytes of the fields to add. - * @return This builder for chaining. - */ - public Builder addFieldsBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureFieldsIsMutable(); - fields_.add(value); - onChanged(); - return this; - } - - private boolean fieldsTruncated_; - /** - * - * - *
-       * True if the fields list was truncated.
-       * 
- * - * bool fields_truncated = 8; - * - * @return The fieldsTruncated. - */ - @java.lang.Override - public boolean getFieldsTruncated() { - return fieldsTruncated_; - } - /** - * - * - *
-       * True if the fields list was truncated.
-       * 
- * - * bool fields_truncated = 8; - * - * @param value The fieldsTruncated to set. - * @return This builder for chaining. - */ - public Builder setFieldsTruncated(boolean value) { - - fieldsTruncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * True if the fields list was truncated.
-       * 
- * - * bool fields_truncated = 8; - * - * @return This builder for chaining. - */ - public Builder clearFieldsTruncated() { - - fieldsTruncated_ = false; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList policyTags_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensurePolicyTagsIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - policyTags_ = new com.google.protobuf.LazyStringArrayList(policyTags_); - bitField0_ |= 0x00000002; - } - } - /** - * - * - *
-       * List of the referenced policy tags. That is, policy tags attached to the
-       * accessed fields or their ancestors.
-       * Policy tag resource name is a string of the format:
-       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-       * 
- * - * repeated string policy_tags = 9; - * - * @return A list containing the policyTags. - */ - public com.google.protobuf.ProtocolStringList getPolicyTagsList() { - return policyTags_.getUnmodifiableView(); - } - /** - * - * - *
-       * List of the referenced policy tags. That is, policy tags attached to the
-       * accessed fields or their ancestors.
-       * Policy tag resource name is a string of the format:
-       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-       * 
- * - * repeated string policy_tags = 9; - * - * @return The count of policyTags. - */ - public int getPolicyTagsCount() { - return policyTags_.size(); - } - /** - * - * - *
-       * List of the referenced policy tags. That is, policy tags attached to the
-       * accessed fields or their ancestors.
-       * Policy tag resource name is a string of the format:
-       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-       * 
- * - * repeated string policy_tags = 9; - * - * @param index The index of the element to return. - * @return The policyTags at the given index. - */ - public java.lang.String getPolicyTags(int index) { - return policyTags_.get(index); - } - /** - * - * - *
-       * List of the referenced policy tags. That is, policy tags attached to the
-       * accessed fields or their ancestors.
-       * Policy tag resource name is a string of the format:
-       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-       * 
- * - * repeated string policy_tags = 9; - * - * @param index The index of the value to return. - * @return The bytes of the policyTags at the given index. - */ - public com.google.protobuf.ByteString getPolicyTagsBytes(int index) { - return policyTags_.getByteString(index); - } - /** - * - * - *
-       * List of the referenced policy tags. That is, policy tags attached to the
-       * accessed fields or their ancestors.
-       * Policy tag resource name is a string of the format:
-       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-       * 
- * - * repeated string policy_tags = 9; - * - * @param index The index to set the value at. - * @param value The policyTags to set. - * @return This builder for chaining. - */ - public Builder setPolicyTags(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensurePolicyTagsIsMutable(); - policyTags_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-       * List of the referenced policy tags. That is, policy tags attached to the
-       * accessed fields or their ancestors.
-       * Policy tag resource name is a string of the format:
-       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-       * 
- * - * repeated string policy_tags = 9; - * - * @param value The policyTags to add. - * @return This builder for chaining. - */ - public Builder addPolicyTags(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensurePolicyTagsIsMutable(); - policyTags_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-       * List of the referenced policy tags. That is, policy tags attached to the
-       * accessed fields or their ancestors.
-       * Policy tag resource name is a string of the format:
-       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-       * 
- * - * repeated string policy_tags = 9; - * - * @param values The policyTags to add. - * @return This builder for chaining. - */ - public Builder addAllPolicyTags(java.lang.Iterable values) { - ensurePolicyTagsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, policyTags_); - onChanged(); - return this; - } - /** - * - * - *
-       * List of the referenced policy tags. That is, policy tags attached to the
-       * accessed fields or their ancestors.
-       * Policy tag resource name is a string of the format:
-       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-       * 
- * - * repeated string policy_tags = 9; - * - * @return This builder for chaining. - */ - public Builder clearPolicyTags() { - policyTags_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - return this; - } - /** - * - * - *
-       * List of the referenced policy tags. That is, policy tags attached to the
-       * accessed fields or their ancestors.
-       * Policy tag resource name is a string of the format:
-       * `projects/<project_id>/locations/<location_id>/taxonomies/<taxonomy_id>/policyTags/<policy_tag_id>`
-       * 
- * - * repeated string policy_tags = 9; - * - * @param value The bytes of the policyTags to add. - * @return This builder for chaining. - */ - public Builder addPolicyTagsBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensurePolicyTagsIsMutable(); - policyTags_.add(value); - onChanged(); - return this; - } - - private boolean policyTagsTruncated_; - /** - * - * - *
-       * True if the policy tag list was truncated. At most 100 policy tags can be
-       * saved.
-       * 
- * - * bool policy_tags_truncated = 10; - * - * @return The policyTagsTruncated. - */ - @java.lang.Override - public boolean getPolicyTagsTruncated() { - return policyTagsTruncated_; - } - /** - * - * - *
-       * True if the policy tag list was truncated. At most 100 policy tags can be
-       * saved.
-       * 
- * - * bool policy_tags_truncated = 10; - * - * @param value The policyTagsTruncated to set. - * @return This builder for chaining. - */ - public Builder setPolicyTagsTruncated(boolean value) { - - policyTagsTruncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * True if the policy tag list was truncated. At most 100 policy tags can be
-       * saved.
-       * 
- * - * bool policy_tags_truncated = 10; - * - * @return This builder for chaining. - */ - public Builder clearPolicyTagsTruncated() { - - policyTagsTruncated_ = false; - onChanged(); - return this; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the table data was read.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the table data was read.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the table data was read.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the table data was read.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the table data was read.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Reason reason = 3; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that read a table.
-       * Present if the reason is JOB but can be redacted for privacy reasons.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that read a table.
-       * Present if the reason is JOB but can be redacted for privacy reasons.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that read a table.
-       * Present if the reason is JOB but can be redacted for privacy reasons.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that read a table.
-       * Present if the reason is JOB but can be redacted for privacy reasons.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that read a table.
-       * Present if the reason is JOB but can be redacted for privacy reasons.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - private java.lang.Object sessionName_ = ""; - /** - * - * - *
-       * The URI of the read session that read a table.
-       * Present if the reason is CREATE_READ_SESSION.
-       * Format:
-       * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
-       * 
- * - * string session_name = 5; - * - * @return The sessionName. - */ - public java.lang.String getSessionName() { - java.lang.Object ref = sessionName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - sessionName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the read session that read a table.
-       * Present if the reason is CREATE_READ_SESSION.
-       * Format:
-       * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
-       * 
- * - * string session_name = 5; - * - * @return The bytes for sessionName. - */ - public com.google.protobuf.ByteString getSessionNameBytes() { - java.lang.Object ref = sessionName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - sessionName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the read session that read a table.
-       * Present if the reason is CREATE_READ_SESSION.
-       * Format:
-       * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
-       * 
- * - * string session_name = 5; - * - * @param value The sessionName to set. - * @return This builder for chaining. - */ - public Builder setSessionName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - sessionName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the read session that read a table.
-       * Present if the reason is CREATE_READ_SESSION.
-       * Format:
-       * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
-       * 
- * - * string session_name = 5; - * - * @return This builder for chaining. - */ - public Builder clearSessionName() { - - sessionName_ = getDefaultInstance().getSessionName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the read session that read a table.
-       * Present if the reason is CREATE_READ_SESSION.
-       * Format:
-       * `projects/<project_id>/locations/<location>/sessions/<session_id>`.
-       * 
- * - * string session_name = 5; - * - * @param value The bytes for sessionName to set. - * @return This builder for chaining. - */ - public Builder setSessionNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - sessionName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataRead) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataRead) - private static final com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public TableDataRead parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TableDataRead(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface TableChangeOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableChange) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Updated table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return Whether the table field is set. - */ - boolean hasTable(); - /** - * - * - *
-     * Updated table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return The table. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Table getTable(); - /** - * - * - *
-     * Updated table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder(); - - /** - * - * - *
-     * True if the table was truncated.
-     * 
- * - * bool truncated = 4; - * - * @return The truncated. - */ - boolean getTruncated(); - - /** - * - * - *
-     * Describes how the table metadata was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the table metadata was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that changed a table.
-     * Present if the reason is JOB or QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 6; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that changed a table.
-     * Present if the reason is JOB or QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 6; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Table metadata change event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableChange} - */ - public static final class TableChange extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableChange) - TableChangeOrBuilder { - private static final long serialVersionUID = 0L; - // Use TableChange.newBuilder() to construct. - private TableChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private TableChange() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TableChange(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private TableChange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder subBuilder = null; - if (table_ != null) { - subBuilder = table_.toBuilder(); - } - table_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Table.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(table_); - table_ = subBuilder.buildPartial(); - } - - break; - } - case 32: - { - truncated_ = input.readBool(); - break; - } - case 40: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder.class); - } - - /** - * - * - *
-     * Describes how the table metadata was changed.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Table metadata was updated using the tables.update or tables.patch API.
-       * 
- * - * TABLE_UPDATE_REQUEST = 1; - */ - TABLE_UPDATE_REQUEST(1), - /** - * - * - *
-       * Table was used as a job destination table.
-       * 
- * - * JOB = 2; - */ - JOB(2), - /** - * - * - *
-       * Table metadata was updated using a DML or DDL query.
-       * 
- * - * QUERY = 3; - */ - QUERY(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Table metadata was updated using the tables.update or tables.patch API.
-       * 
- * - * TABLE_UPDATE_REQUEST = 1; - */ - public static final int TABLE_UPDATE_REQUEST_VALUE = 1; - /** - * - * - *
-       * Table was used as a job destination table.
-       * 
- * - * JOB = 2; - */ - public static final int JOB_VALUE = 2; - /** - * - * - *
-       * Table metadata was updated using a DML or DDL query.
-       * 
- * - * QUERY = 3; - */ - public static final int QUERY_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return TABLE_UPDATE_REQUEST; - case 2: - return JOB; - case 3: - return QUERY; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason) - } - - public static final int TABLE_FIELD_NUMBER = 1; - private com.google.cloud.audit.BigQueryAuditMetadata.Table table_; - /** - * - * - *
-     * Updated table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return Whether the table field is set. - */ - @java.lang.Override - public boolean hasTable() { - return table_ != null; - } - /** - * - * - *
-     * Updated table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return The table. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Table getTable() { - return table_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() - : table_; - } - /** - * - * - *
-     * Updated table metadata.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder() { - return getTable(); - } - - public static final int TRUNCATED_FIELD_NUMBER = 4; - private boolean truncated_; - /** - * - * - *
-     * True if the table was truncated.
-     * 
- * - * bool truncated = 4; - * - * @return The truncated. - */ - @java.lang.Override - public boolean getTruncated() { - return truncated_; - } - - public static final int REASON_FIELD_NUMBER = 5; - private int reason_; - /** - * - * - *
-     * Describes how the table metadata was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the table metadata was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 6; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that changed a table.
-     * Present if the reason is JOB or QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 6; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that changed a table.
-     * Present if the reason is JOB or QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 6; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (table_ != null) { - output.writeMessage(1, getTable()); - } - if (truncated_ != false) { - output.writeBool(4, truncated_); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(5, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 6, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (table_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getTable()); - } - if (truncated_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, truncated_); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableChange)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.TableChange other = - (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) obj; - - if (hasTable() != other.hasTable()) return false; - if (hasTable()) { - if (!getTable().equals(other.getTable())) return false; - } - if (getTruncated() != other.getTruncated()) return false; - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasTable()) { - hash = (37 * hash) + TABLE_FIELD_NUMBER; - hash = (53 * hash) + getTable().hashCode(); - } - hash = (37 * hash) + TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getTruncated()); - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.TableChange prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Table metadata change event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableChange} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableChange) - com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableChange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (tableBuilder_ == null) { - table_ = null; - } else { - table_ = null; - tableBuilder_ = null; - } - truncated_ = false; - - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableChange getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableChange build() { - com.google.cloud.audit.BigQueryAuditMetadata.TableChange result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableChange buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.TableChange result = - new com.google.cloud.audit.BigQueryAuditMetadata.TableChange(this); - if (tableBuilder_ == null) { - result.table_ = table_; - } else { - result.table_ = tableBuilder_.build(); - } - result.truncated_ = truncated_; - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableChange) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableChange) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableChange other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance()) - return this; - if (other.hasTable()) { - mergeTable(other.getTable()); - } - if (other.getTruncated() != false) { - setTruncated(other.getTruncated()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.TableChange parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Table table_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Table, - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder> - tableBuilder_; - /** - * - * - *
-       * Updated table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return Whether the table field is set. - */ - public boolean hasTable() { - return tableBuilder_ != null || table_ != null; - } - /** - * - * - *
-       * Updated table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - * - * @return The table. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Table getTable() { - if (tableBuilder_ == null) { - return table_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() - : table_; - } else { - return tableBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Updated table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public Builder setTable(com.google.cloud.audit.BigQueryAuditMetadata.Table value) { - if (tableBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - table_ = value; - onChanged(); - } else { - tableBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Updated table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public Builder setTable( - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder builderForValue) { - if (tableBuilder_ == null) { - table_ = builderForValue.build(); - onChanged(); - } else { - tableBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Updated table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public Builder mergeTable(com.google.cloud.audit.BigQueryAuditMetadata.Table value) { - if (tableBuilder_ == null) { - if (table_ != null) { - table_ = - com.google.cloud.audit.BigQueryAuditMetadata.Table.newBuilder(table_) - .mergeFrom(value) - .buildPartial(); - } else { - table_ = value; - } - onChanged(); - } else { - tableBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Updated table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public Builder clearTable() { - if (tableBuilder_ == null) { - table_ = null; - onChanged(); - } else { - table_ = null; - tableBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Updated table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder getTableBuilder() { - - onChanged(); - return getTableFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Updated table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder getTableOrBuilder() { - if (tableBuilder_ != null) { - return tableBuilder_.getMessageOrBuilder(); - } else { - return table_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance() - : table_; - } - } - /** - * - * - *
-       * Updated table metadata.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Table table = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Table, - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder> - getTableFieldBuilder() { - if (tableBuilder_ == null) { - tableBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Table, - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder>( - getTable(), getParentForChildren(), isClean()); - table_ = null; - } - return tableBuilder_; - } - - private boolean truncated_; - /** - * - * - *
-       * True if the table was truncated.
-       * 
- * - * bool truncated = 4; - * - * @return The truncated. - */ - @java.lang.Override - public boolean getTruncated() { - return truncated_; - } - /** - * - * - *
-       * True if the table was truncated.
-       * 
- * - * bool truncated = 4; - * - * @param value The truncated to set. - * @return This builder for chaining. - */ - public Builder setTruncated(boolean value) { - - truncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * True if the table was truncated.
-       * 
- * - * bool truncated = 4; - * - * @return This builder for chaining. - */ - public Builder clearTruncated() { - - truncated_ = false; - onChanged(); - return this; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the table metadata was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the table metadata was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the table metadata was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the table metadata was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the table metadata was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange.Reason reason = 5; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that changed a table.
-       * Present if the reason is JOB or QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 6; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that changed a table.
-       * Present if the reason is JOB or QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 6; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that changed a table.
-       * Present if the reason is JOB or QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 6; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that changed a table.
-       * Present if the reason is JOB or QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 6; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that changed a table.
-       * Present if the reason is JOB or QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 6; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableChange) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableChange) - private static final com.google.cloud.audit.BigQueryAuditMetadata.TableChange DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableChange(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableChange getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public TableChange parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TableChange(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableChange getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface ModelMetadataChangeOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Updated model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return Whether the model field is set. - */ - boolean hasModel(); - /** - * - * - *
-     * Updated model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return The model. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Model getModel(); - /** - * - * - *
-     * Updated model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder(); - - /** - * - * - *
-     * Describes how the model metadata was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the model metadata was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that changed the model metadata.
-     * Present if and only if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that changed the model metadata.
-     * Present if and only if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Model metadata change event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange} - */ - public static final class ModelMetadataChange extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) - ModelMetadataChangeOrBuilder { - private static final long serialVersionUID = 0L; - // Use ModelMetadataChange.newBuilder() to construct. - private ModelMetadataChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ModelMetadataChange() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ModelMetadataChange(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ModelMetadataChange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder subBuilder = null; - if (model_ != null) { - subBuilder = model_.toBuilder(); - } - model_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Model.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(model_); - model_ = subBuilder.buildPartial(); - } - - break; - } - case 16: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder.class); - } - - /** - * - * - *
-     * Describes how the model metadata was changed.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Model metadata was updated using the models.patch API.
-       * 
- * - * MODEL_PATCH_REQUEST = 1; - */ - MODEL_PATCH_REQUEST(1), - /** - * - * - *
-       * Model metadata was updated using a DDL query.
-       * 
- * - * QUERY = 2; - */ - QUERY(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Model metadata was updated using the models.patch API.
-       * 
- * - * MODEL_PATCH_REQUEST = 1; - */ - public static final int MODEL_PATCH_REQUEST_VALUE = 1; - /** - * - * - *
-       * Model metadata was updated using a DDL query.
-       * 
- * - * QUERY = 2; - */ - public static final int QUERY_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return MODEL_PATCH_REQUEST; - case 2: - return QUERY; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason) - } - - public static final int MODEL_FIELD_NUMBER = 1; - private com.google.cloud.audit.BigQueryAuditMetadata.Model model_; - /** - * - * - *
-     * Updated model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return Whether the model field is set. - */ - @java.lang.Override - public boolean hasModel() { - return model_ != null; - } - /** - * - * - *
-     * Updated model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return The model. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Model getModel() { - return model_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() - : model_; - } - /** - * - * - *
-     * Updated model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder() { - return getModel(); - } - - public static final int REASON_FIELD_NUMBER = 2; - private int reason_; - /** - * - * - *
-     * Describes how the model metadata was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the model metadata was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 3; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that changed the model metadata.
-     * Present if and only if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that changed the model metadata.
-     * Present if and only if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 3; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (model_ != null) { - output.writeMessage(1, getModel()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason - .REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(2, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (model_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getModel()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason - .REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange other = - (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) obj; - - if (hasModel() != other.hasModel()) return false; - if (hasModel()) { - if (!getModel().equals(other.getModel())) return false; - } - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasModel()) { - hash = (37 * hash) + MODEL_FIELD_NUMBER; - hash = (53 * hash) + getModel().hashCode(); - } - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Model metadata change event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder.class); - } - - // Construct using - // com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (modelBuilder_ == null) { - model_ = null; - } else { - model_ = null; - modelBuilder_ = null; - } - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - .getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange build() { - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange result = - new com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange(this); - if (modelBuilder_ == null) { - result.model_ = model_; - } else { - result.model_ = modelBuilder_.build(); - } - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) { - return mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - .getDefaultInstance()) return this; - if (other.hasModel()) { - mergeModel(other.getModel()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Model model_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Model, - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder> - modelBuilder_; - /** - * - * - *
-       * Updated model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return Whether the model field is set. - */ - public boolean hasModel() { - return modelBuilder_ != null || model_ != null; - } - /** - * - * - *
-       * Updated model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - * - * @return The model. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Model getModel() { - if (modelBuilder_ == null) { - return model_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() - : model_; - } else { - return modelBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Updated model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public Builder setModel(com.google.cloud.audit.BigQueryAuditMetadata.Model value) { - if (modelBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - model_ = value; - onChanged(); - } else { - modelBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Updated model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public Builder setModel( - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder builderForValue) { - if (modelBuilder_ == null) { - model_ = builderForValue.build(); - onChanged(); - } else { - modelBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Updated model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public Builder mergeModel(com.google.cloud.audit.BigQueryAuditMetadata.Model value) { - if (modelBuilder_ == null) { - if (model_ != null) { - model_ = - com.google.cloud.audit.BigQueryAuditMetadata.Model.newBuilder(model_) - .mergeFrom(value) - .buildPartial(); - } else { - model_ = value; - } - onChanged(); - } else { - modelBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Updated model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public Builder clearModel() { - if (modelBuilder_ == null) { - model_ = null; - onChanged(); - } else { - model_ = null; - modelBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Updated model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder getModelBuilder() { - - onChanged(); - return getModelFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Updated model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder getModelOrBuilder() { - if (modelBuilder_ != null) { - return modelBuilder_.getMessageOrBuilder(); - } else { - return model_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance() - : model_; - } - } - /** - * - * - *
-       * Updated model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Model model = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Model, - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder> - getModelFieldBuilder() { - if (modelBuilder_ == null) { - modelBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Model, - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder>( - getModel(), getParentForChildren(), isClean()); - model_ = null; - } - return modelBuilder_; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the model metadata was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; - * - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the model metadata was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; - * - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the model metadata was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; - * - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason.valueOf( - reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the model metadata was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; - * - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the model metadata was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Reason reason = 2; - * - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that changed the model metadata.
-       * Present if and only if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that changed the model metadata.
-       * Present if and only if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that changed the model metadata.
-       * Present if and only if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that changed the model metadata.
-       * Present if and only if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that changed the model metadata.
-       * Present if and only if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 3; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) - private static final com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ModelMetadataChange parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ModelMetadataChange(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface RoutineChangeOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.RoutineChange) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Updated routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return Whether the routine field is set. - */ - boolean hasRoutine(); - /** - * - * - *
-     * Updated routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return The routine. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine(); - /** - * - * - *
-     * Updated routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder(); - - /** - * - * - *
-     * Describes how the routine was updated.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the routine was updated.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that updated the routine.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that updated the routine.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Routine change event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineChange} - */ - public static final class RoutineChange extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineChange) - RoutineChangeOrBuilder { - private static final long serialVersionUID = 0L; - // Use RoutineChange.newBuilder() to construct. - private RoutineChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private RoutineChange() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new RoutineChange(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private RoutineChange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder subBuilder = null; - if (routine_ != null) { - subBuilder = routine_.toBuilder(); - } - routine_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Routine.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(routine_); - routine_ = subBuilder.buildPartial(); - } - - break; - } - case 24: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder.class); - } - - /** - * - * - *
-     * Describes how the routine was updated.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Routine was updated using a DDL query.
-       * 
- * - * QUERY = 1; - */ - QUERY(1), - /** - * - * - *
-       * Routine was updated using the routines.update or routines.patch API.
-       * 
- * - * ROUTINE_UPDATE_REQUEST = 2; - */ - ROUTINE_UPDATE_REQUEST(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Routine was updated using a DDL query.
-       * 
- * - * QUERY = 1; - */ - public static final int QUERY_VALUE = 1; - /** - * - * - *
-       * Routine was updated using the routines.update or routines.patch API.
-       * 
- * - * ROUTINE_UPDATE_REQUEST = 2; - */ - public static final int ROUTINE_UPDATE_REQUEST_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return QUERY; - case 2: - return ROUTINE_UPDATE_REQUEST; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason) - } - - public static final int ROUTINE_FIELD_NUMBER = 1; - private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; - /** - * - * - *
-     * Updated routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return Whether the routine field is set. - */ - @java.lang.Override - public boolean hasRoutine() { - return routine_ != null; - } - /** - * - * - *
-     * Updated routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return The routine. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { - return routine_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() - : routine_; - } - /** - * - * - *
-     * Updated routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { - return getRoutine(); - } - - public static final int REASON_FIELD_NUMBER = 3; - private int reason_; - /** - * - * - *
-     * Describes how the routine was updated.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the routine was updated.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 4; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that updated the routine.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that updated the routine.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (routine_ != null) { - output.writeMessage(1, getRoutine()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (routine_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getRoutine()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange other = - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) obj; - - if (hasRoutine() != other.hasRoutine()) return false; - if (hasRoutine()) { - if (!getRoutine().equals(other.getRoutine())) return false; - } - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasRoutine()) { - hash = (37 * hash) + ROUTINE_FIELD_NUMBER; - hash = (53 * hash) + getRoutine().hashCode(); - } - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Routine change event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineChange} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineChange) - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (routineBuilder_ == null) { - routine_ = null; - } else { - routine_ = null; - routineBuilder_ = null; - } - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange build() { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange result = - new com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange(this); - if (routineBuilder_ == null) { - result.routine_ = routine_; - } else { - result.routine_ = routineBuilder_.build(); - } - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance()) - return this; - if (other.hasRoutine()) { - mergeRoutine(other.getRoutine()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Routine, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> - routineBuilder_; - /** - * - * - *
-       * Updated routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return Whether the routine field is set. - */ - public boolean hasRoutine() { - return routineBuilder_ != null || routine_ != null; - } - /** - * - * - *
-       * Updated routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return The routine. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { - if (routineBuilder_ == null) { - return routine_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() - : routine_; - } else { - return routineBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Updated routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder setRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { - if (routineBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - routine_ = value; - onChanged(); - } else { - routineBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Updated routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder setRoutine( - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder builderForValue) { - if (routineBuilder_ == null) { - routine_ = builderForValue.build(); - onChanged(); - } else { - routineBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Updated routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder mergeRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { - if (routineBuilder_ == null) { - if (routine_ != null) { - routine_ = - com.google.cloud.audit.BigQueryAuditMetadata.Routine.newBuilder(routine_) - .mergeFrom(value) - .buildPartial(); - } else { - routine_ = value; - } - onChanged(); - } else { - routineBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Updated routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder clearRoutine() { - if (routineBuilder_ == null) { - routine_ = null; - onChanged(); - } else { - routine_ = null; - routineBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Updated routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder getRoutineBuilder() { - - onChanged(); - return getRoutineFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Updated routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { - if (routineBuilder_ != null) { - return routineBuilder_.getMessageOrBuilder(); - } else { - return routine_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() - : routine_; - } - } - /** - * - * - *
-       * Updated routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Routine, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> - getRoutineFieldBuilder() { - if (routineBuilder_ == null) { - routineBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Routine, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder>( - getRoutine(), getParentForChildren(), isClean()); - routine_ = null; - } - return routineBuilder_; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the routine was updated.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the routine was updated.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the routine was updated.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the routine was updated.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the routine was updated.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Reason reason = 3; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that updated the routine.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that updated the routine.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that updated the routine.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that updated the routine.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that updated the routine.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineChange) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineChange) - private static final com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public RoutineChange parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RoutineChange(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface TableDataChangeOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableDataChange) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Number of deleted rows.
-     * 
- * - * int64 deleted_rows_count = 1; - * - * @return The deletedRowsCount. - */ - long getDeletedRowsCount(); - - /** - * - * - *
-     * Number of inserted rows.
-     * 
- * - * int64 inserted_rows_count = 2; - * - * @return The insertedRowsCount. - */ - long getInsertedRowsCount(); - - /** - * - * - *
-     * True if the table was truncated.
-     * 
- * - * bool truncated = 3; - * - * @return The truncated. - */ - boolean getTruncated(); - - /** - * - * - *
-     * Describes how the table data was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the table data was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that changed a table.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 5; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that changed a table.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 5; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - - /** - * - * - *
-     * If written from WRITE_API, the name of the stream.
-     * Format:
-     * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
-     * 
- * - * string stream_name = 6; - * - * @return The streamName. - */ - java.lang.String getStreamName(); - /** - * - * - *
-     * If written from WRITE_API, the name of the stream.
-     * Format:
-     * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
-     * 
- * - * string stream_name = 6; - * - * @return The bytes for streamName. - */ - com.google.protobuf.ByteString getStreamNameBytes(); - } - /** - * - * - *
-   * Table data change event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDataChange} - */ - public static final class TableDataChange extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableDataChange) - TableDataChangeOrBuilder { - private static final long serialVersionUID = 0L; - // Use TableDataChange.newBuilder() to construct. - private TableDataChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private TableDataChange() { - reason_ = 0; - jobName_ = ""; - streamName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TableDataChange(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private TableDataChange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - deletedRowsCount_ = input.readInt64(); - break; - } - case 16: - { - insertedRowsCount_ = input.readInt64(); - break; - } - case 24: - { - truncated_ = input.readBool(); - break; - } - case 32: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - - streamName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder.class); - } - - /** - * - * - *
-     * Describes how the table data was changed.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Table was used as a job destination table.
-       * 
- * - * JOB = 1; - */ - JOB(1), - /** - * - * - *
-       * Table data was updated using a DML or DDL query.
-       * 
- * - * QUERY = 2; - */ - QUERY(2), - /** - * - * - *
-       * Table data was updated during a materialized view refresh.
-       * 
- * - * MATERIALIZED_VIEW_REFRESH = 3; - */ - MATERIALIZED_VIEW_REFRESH(3), - /** - * - * - *
-       * Table data was added using the Write API.
-       * 
- * - * WRITE_API = 4; - */ - WRITE_API(4), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Table was used as a job destination table.
-       * 
- * - * JOB = 1; - */ - public static final int JOB_VALUE = 1; - /** - * - * - *
-       * Table data was updated using a DML or DDL query.
-       * 
- * - * QUERY = 2; - */ - public static final int QUERY_VALUE = 2; - /** - * - * - *
-       * Table data was updated during a materialized view refresh.
-       * 
- * - * MATERIALIZED_VIEW_REFRESH = 3; - */ - public static final int MATERIALIZED_VIEW_REFRESH_VALUE = 3; - /** - * - * - *
-       * Table data was added using the Write API.
-       * 
- * - * WRITE_API = 4; - */ - public static final int WRITE_API_VALUE = 4; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return JOB; - case 2: - return QUERY; - case 3: - return MATERIALIZED_VIEW_REFRESH; - case 4: - return WRITE_API; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason) - } - - public static final int DELETED_ROWS_COUNT_FIELD_NUMBER = 1; - private long deletedRowsCount_; - /** - * - * - *
-     * Number of deleted rows.
-     * 
- * - * int64 deleted_rows_count = 1; - * - * @return The deletedRowsCount. - */ - @java.lang.Override - public long getDeletedRowsCount() { - return deletedRowsCount_; - } - - public static final int INSERTED_ROWS_COUNT_FIELD_NUMBER = 2; - private long insertedRowsCount_; - /** - * - * - *
-     * Number of inserted rows.
-     * 
- * - * int64 inserted_rows_count = 2; - * - * @return The insertedRowsCount. - */ - @java.lang.Override - public long getInsertedRowsCount() { - return insertedRowsCount_; - } - - public static final int TRUNCATED_FIELD_NUMBER = 3; - private boolean truncated_; - /** - * - * - *
-     * True if the table was truncated.
-     * 
- * - * bool truncated = 3; - * - * @return The truncated. - */ - @java.lang.Override - public boolean getTruncated() { - return truncated_; - } - - public static final int REASON_FIELD_NUMBER = 4; - private int reason_; - /** - * - * - *
-     * Describes how the table data was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the table data was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 5; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that changed a table.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 5; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that changed a table.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 5; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int STREAM_NAME_FIELD_NUMBER = 6; - private volatile java.lang.Object streamName_; - /** - * - * - *
-     * If written from WRITE_API, the name of the stream.
-     * Format:
-     * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
-     * 
- * - * string stream_name = 6; - * - * @return The streamName. - */ - @java.lang.Override - public java.lang.String getStreamName() { - java.lang.Object ref = streamName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - streamName_ = s; - return s; - } - } - /** - * - * - *
-     * If written from WRITE_API, the name of the stream.
-     * Format:
-     * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
-     * 
- * - * string stream_name = 6; - * - * @return The bytes for streamName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getStreamNameBytes() { - java.lang.Object ref = streamName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - streamName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (deletedRowsCount_ != 0L) { - output.writeInt64(1, deletedRowsCount_); - } - if (insertedRowsCount_ != 0L) { - output.writeInt64(2, insertedRowsCount_); - } - if (truncated_ != false) { - output.writeBool(3, truncated_); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(4, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, jobName_); - } - if (!getStreamNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 6, streamName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (deletedRowsCount_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, deletedRowsCount_); - } - if (insertedRowsCount_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, insertedRowsCount_); - } - if (truncated_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, truncated_); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, jobName_); - } - if (!getStreamNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, streamName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange other = - (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) obj; - - if (getDeletedRowsCount() != other.getDeletedRowsCount()) return false; - if (getInsertedRowsCount() != other.getInsertedRowsCount()) return false; - if (getTruncated() != other.getTruncated()) return false; - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!getStreamName().equals(other.getStreamName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + DELETED_ROWS_COUNT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getDeletedRowsCount()); - hash = (37 * hash) + INSERTED_ROWS_COUNT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getInsertedRowsCount()); - hash = (37 * hash) + TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getTruncated()); - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (37 * hash) + STREAM_NAME_FIELD_NUMBER; - hash = (53 * hash) + getStreamName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Table data change event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDataChange} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableDataChange) - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - deletedRowsCount_ = 0L; - - insertedRowsCount_ = 0L; - - truncated_ = false; - - reason_ = 0; - - jobName_ = ""; - - streamName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange build() { - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange result = - new com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange(this); - result.deletedRowsCount_ = deletedRowsCount_; - result.insertedRowsCount_ = insertedRowsCount_; - result.truncated_ = truncated_; - result.reason_ = reason_; - result.jobName_ = jobName_; - result.streamName_ = streamName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance()) - return this; - if (other.getDeletedRowsCount() != 0L) { - setDeletedRowsCount(other.getDeletedRowsCount()); - } - if (other.getInsertedRowsCount() != 0L) { - setInsertedRowsCount(other.getInsertedRowsCount()); - } - if (other.getTruncated() != false) { - setTruncated(other.getTruncated()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - if (!other.getStreamName().isEmpty()) { - streamName_ = other.streamName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private long deletedRowsCount_; - /** - * - * - *
-       * Number of deleted rows.
-       * 
- * - * int64 deleted_rows_count = 1; - * - * @return The deletedRowsCount. - */ - @java.lang.Override - public long getDeletedRowsCount() { - return deletedRowsCount_; - } - /** - * - * - *
-       * Number of deleted rows.
-       * 
- * - * int64 deleted_rows_count = 1; - * - * @param value The deletedRowsCount to set. - * @return This builder for chaining. - */ - public Builder setDeletedRowsCount(long value) { - - deletedRowsCount_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Number of deleted rows.
-       * 
- * - * int64 deleted_rows_count = 1; - * - * @return This builder for chaining. - */ - public Builder clearDeletedRowsCount() { - - deletedRowsCount_ = 0L; - onChanged(); - return this; - } - - private long insertedRowsCount_; - /** - * - * - *
-       * Number of inserted rows.
-       * 
- * - * int64 inserted_rows_count = 2; - * - * @return The insertedRowsCount. - */ - @java.lang.Override - public long getInsertedRowsCount() { - return insertedRowsCount_; - } - /** - * - * - *
-       * Number of inserted rows.
-       * 
- * - * int64 inserted_rows_count = 2; - * - * @param value The insertedRowsCount to set. - * @return This builder for chaining. - */ - public Builder setInsertedRowsCount(long value) { - - insertedRowsCount_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Number of inserted rows.
-       * 
- * - * int64 inserted_rows_count = 2; - * - * @return This builder for chaining. - */ - public Builder clearInsertedRowsCount() { - - insertedRowsCount_ = 0L; - onChanged(); - return this; - } - - private boolean truncated_; - /** - * - * - *
-       * True if the table was truncated.
-       * 
- * - * bool truncated = 3; - * - * @return The truncated. - */ - @java.lang.Override - public boolean getTruncated() { - return truncated_; - } - /** - * - * - *
-       * True if the table was truncated.
-       * 
- * - * bool truncated = 3; - * - * @param value The truncated to set. - * @return This builder for chaining. - */ - public Builder setTruncated(boolean value) { - - truncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * True if the table was truncated.
-       * 
- * - * bool truncated = 3; - * - * @return This builder for chaining. - */ - public Builder clearTruncated() { - - truncated_ = false; - onChanged(); - return this; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the table data was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the table data was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the table data was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the table data was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the table data was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Reason reason = 4; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that changed a table.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 5; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that changed a table.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 5; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that changed a table.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 5; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that changed a table.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 5; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that changed a table.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 5; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - private java.lang.Object streamName_ = ""; - /** - * - * - *
-       * If written from WRITE_API, the name of the stream.
-       * Format:
-       * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
-       * 
- * - * string stream_name = 6; - * - * @return The streamName. - */ - public java.lang.String getStreamName() { - java.lang.Object ref = streamName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - streamName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * If written from WRITE_API, the name of the stream.
-       * Format:
-       * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
-       * 
- * - * string stream_name = 6; - * - * @return The bytes for streamName. - */ - public com.google.protobuf.ByteString getStreamNameBytes() { - java.lang.Object ref = streamName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - streamName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * If written from WRITE_API, the name of the stream.
-       * Format:
-       * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
-       * 
- * - * string stream_name = 6; - * - * @param value The streamName to set. - * @return This builder for chaining. - */ - public Builder setStreamName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - streamName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * If written from WRITE_API, the name of the stream.
-       * Format:
-       * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
-       * 
- * - * string stream_name = 6; - * - * @return This builder for chaining. - */ - public Builder clearStreamName() { - - streamName_ = getDefaultInstance().getStreamName(); - onChanged(); - return this; - } - /** - * - * - *
-       * If written from WRITE_API, the name of the stream.
-       * Format:
-       * `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>/streams/<stream_id>`
-       * 
- * - * string stream_name = 6; - * - * @param value The bytes for streamName to set. - * @return This builder for chaining. - */ - public Builder setStreamNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - streamName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataChange) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableDataChange) - private static final com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public TableDataChange parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TableDataChange(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface ModelDataChangeOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Describes how the model data was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the model data was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that changed the model data.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that changed the model data.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Model data change event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataChange} - */ - public static final class ModelDataChange extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) - ModelDataChangeOrBuilder { - private static final long serialVersionUID = 0L; - // Use ModelDataChange.newBuilder() to construct. - private ModelDataChange(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ModelDataChange() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ModelDataChange(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ModelDataChange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder.class); - } - - /** - * - * - *
-     * Describes how the model data was changed.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Model data was changed using a DDL query.
-       * 
- * - * QUERY = 1; - */ - QUERY(1), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Model data was changed using a DDL query.
-       * 
- * - * QUERY = 1; - */ - public static final int QUERY_VALUE = 1; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return QUERY; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason) - } - - public static final int REASON_FIELD_NUMBER = 1; - private int reason_; - /** - * - * - *
-     * Describes how the model data was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the model data was changed.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that changed the model data.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that changed the model data.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange other = - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) obj; - - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Model data change event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataChange} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.class, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange build() { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange result = - new com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange(this); - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance()) - return this; - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the model data was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the model data was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the model data was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the model data was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the model data was changed.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Reason reason = 1; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that changed the model data.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that changed the model data.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that changed the model data.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that changed the model data.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that changed the model data.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) - private static final com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ModelDataChange parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ModelDataChange(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface ModelDataReadOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Describes how the model data was read.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the model data was read.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that read the model data.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that read the model data.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Model data read event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataRead} - */ - public static final class ModelDataRead extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) - ModelDataReadOrBuilder { - private static final long serialVersionUID = 0L; - // Use ModelDataRead.newBuilder() to construct. - private ModelDataRead(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ModelDataRead() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ModelDataRead(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ModelDataRead( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.class, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder.class); - } - - /** - * - * - *
-     * Describes how the model data was read.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Model was used as a source model during a BigQuery job.
-       * 
- * - * JOB = 1; - */ - JOB(1), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Model was used as a source model during a BigQuery job.
-       * 
- * - * JOB = 1; - */ - public static final int JOB_VALUE = 1; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return JOB; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason) - } - - public static final int REASON_FIELD_NUMBER = 1; - private int reason_; - /** - * - * - *
-     * Describes how the model data was read.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the model data was read.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that read the model data.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that read the model data.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead other = - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) obj; - - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Model data read event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDataRead} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.class, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead build() { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead result = - new com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead(this); - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance()) - return this; - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the model data was read.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the model data was read.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the model data was read.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the model data was read.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the model data was read.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Reason reason = 1; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that read the model data.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that read the model data.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that read the model data.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that read the model data.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that read the model data.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) - private static final com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ModelDataRead parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ModelDataRead(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface DatasetOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.Dataset) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Dataset URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>`.
-     * 
- * - * string dataset_name = 1; - * - * @return The datasetName. - */ - java.lang.String getDatasetName(); - /** - * - * - *
-     * Dataset URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>`.
-     * 
- * - * string dataset_name = 1; - * - * @return The bytes for datasetName. - */ - com.google.protobuf.ByteString getDatasetNameBytes(); - - /** - * - * - *
-     * Dataset creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 3; - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-     * Dataset creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 3; - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-     * Dataset creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-     * Dataset metadata last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 4; - * - * @return Whether the updateTime field is set. - */ - boolean hasUpdateTime(); - /** - * - * - *
-     * Dataset metadata last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 4; - * - * @return The updateTime. - */ - com.google.protobuf.Timestamp getUpdateTime(); - /** - * - * - *
-     * Dataset metadata last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 4; - */ - com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); - - /** - * - * - *
-     * The access control list for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - * - * @return Whether the acl field is set. - */ - boolean hasAcl(); - /** - * - * - *
-     * The access control list for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - * - * @return The acl. - */ - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getAcl(); - /** - * - * - *
-     * The access control list for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - */ - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder getAclOrBuilder(); - - /** - * - * - *
-     * Default expiration time for tables in the dataset.
-     * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - * - * @return Whether the defaultTableExpireDuration field is set. - */ - boolean hasDefaultTableExpireDuration(); - /** - * - * - *
-     * Default expiration time for tables in the dataset.
-     * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - * - * @return The defaultTableExpireDuration. - */ - com.google.protobuf.Duration getDefaultTableExpireDuration(); - /** - * - * - *
-     * Default expiration time for tables in the dataset.
-     * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - */ - com.google.protobuf.DurationOrBuilder getDefaultTableExpireDurationOrBuilder(); - - /** - * - * - *
-     * User-provided metadata for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - * - * @return Whether the datasetInfo field is set. - */ - boolean hasDatasetInfo(); - /** - * - * - *
-     * User-provided metadata for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - * - * @return The datasetInfo. - */ - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDatasetInfo(); - /** - * - * - *
-     * User-provided metadata for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - */ - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder getDatasetInfoOrBuilder(); - - /** - * - * - *
-     * Default encryption for tables in the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - * @return Whether the defaultEncryption field is set. - */ - boolean hasDefaultEncryption(); - /** - * - * - *
-     * Default encryption for tables in the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - * @return The defaultEncryption. - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDefaultEncryption(); - /** - * - * - *
-     * Default encryption for tables in the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDefaultEncryptionOrBuilder(); - } - /** - * - * - *
-   * BigQuery dataset.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Dataset} - */ - public static final class Dataset extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.Dataset) - DatasetOrBuilder { - private static final long serialVersionUID = 0L; - // Use Dataset.newBuilder() to construct. - private Dataset(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Dataset() { - datasetName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Dataset(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Dataset( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - datasetName_ = s; - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (updateTime_ != null) { - subBuilder = updateTime_.toBuilder(); - } - updateTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateTime_); - updateTime_ = subBuilder.buildPartial(); - } - - break; - } - case 42: - { - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder subBuilder = null; - if (acl_ != null) { - subBuilder = acl_.toBuilder(); - } - acl_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(acl_); - acl_ = subBuilder.buildPartial(); - } - - break; - } - case 50: - { - com.google.protobuf.Duration.Builder subBuilder = null; - if (defaultTableExpireDuration_ != null) { - subBuilder = defaultTableExpireDuration_.toBuilder(); - } - defaultTableExpireDuration_ = - input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(defaultTableExpireDuration_); - defaultTableExpireDuration_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder subBuilder = null; - if (datasetInfo_ != null) { - subBuilder = datasetInfo_.toBuilder(); - } - datasetInfo_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(datasetInfo_); - datasetInfo_ = subBuilder.buildPartial(); - } - - break; - } - case 66: - { - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = - null; - if (defaultEncryption_ != null) { - subBuilder = defaultEncryption_.toBuilder(); - } - defaultEncryption_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(defaultEncryption_); - defaultEncryption_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.class, - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder.class); - } - - public static final int DATASET_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object datasetName_; - /** - * - * - *
-     * Dataset URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>`.
-     * 
- * - * string dataset_name = 1; - * - * @return The datasetName. - */ - @java.lang.Override - public java.lang.String getDatasetName() { - java.lang.Object ref = datasetName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - datasetName_ = s; - return s; - } - } - /** - * - * - *
-     * Dataset URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>`.
-     * 
- * - * string dataset_name = 1; - * - * @return The bytes for datasetName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDatasetNameBytes() { - java.lang.Object ref = datasetName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - datasetName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATE_TIME_FIELD_NUMBER = 3; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-     * Dataset creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 3; - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-     * Dataset creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 3; - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-     * Dataset creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int UPDATE_TIME_FIELD_NUMBER = 4; - private com.google.protobuf.Timestamp updateTime_; - /** - * - * - *
-     * Dataset metadata last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 4; - * - * @return Whether the updateTime field is set. - */ - @java.lang.Override - public boolean hasUpdateTime() { - return updateTime_ != null; - } - /** - * - * - *
-     * Dataset metadata last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 4; - * - * @return The updateTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getUpdateTime() { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; - } - /** - * - * - *
-     * Dataset metadata last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 4; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - return getUpdateTime(); - } - - public static final int ACL_FIELD_NUMBER = 5; - private com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl_; - /** - * - * - *
-     * The access control list for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - * - * @return Whether the acl field is set. - */ - @java.lang.Override - public boolean hasAcl() { - return acl_ != null; - } - /** - * - * - *
-     * The access control list for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - * - * @return The acl. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getAcl() { - return acl_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.getDefaultInstance() - : acl_; - } - /** - * - * - *
-     * The access control list for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder getAclOrBuilder() { - return getAcl(); - } - - public static final int DEFAULT_TABLE_EXPIRE_DURATION_FIELD_NUMBER = 6; - private com.google.protobuf.Duration defaultTableExpireDuration_; - /** - * - * - *
-     * Default expiration time for tables in the dataset.
-     * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - * - * @return Whether the defaultTableExpireDuration field is set. - */ - @java.lang.Override - public boolean hasDefaultTableExpireDuration() { - return defaultTableExpireDuration_ != null; - } - /** - * - * - *
-     * Default expiration time for tables in the dataset.
-     * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - * - * @return The defaultTableExpireDuration. - */ - @java.lang.Override - public com.google.protobuf.Duration getDefaultTableExpireDuration() { - return defaultTableExpireDuration_ == null - ? com.google.protobuf.Duration.getDefaultInstance() - : defaultTableExpireDuration_; - } - /** - * - * - *
-     * Default expiration time for tables in the dataset.
-     * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - */ - @java.lang.Override - public com.google.protobuf.DurationOrBuilder getDefaultTableExpireDurationOrBuilder() { - return getDefaultTableExpireDuration(); - } - - public static final int DATASET_INFO_FIELD_NUMBER = 7; - private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo datasetInfo_; - /** - * - * - *
-     * User-provided metadata for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - * - * @return Whether the datasetInfo field is set. - */ - @java.lang.Override - public boolean hasDatasetInfo() { - return datasetInfo_ != null; - } - /** - * - * - *
-     * User-provided metadata for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - * - * @return The datasetInfo. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDatasetInfo() { - return datasetInfo_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() - : datasetInfo_; - } - /** - * - * - *
-     * User-provided metadata for the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder - getDatasetInfoOrBuilder() { - return getDatasetInfo(); - } - - public static final int DEFAULT_ENCRYPTION_FIELD_NUMBER = 8; - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo defaultEncryption_; - /** - * - * - *
-     * Default encryption for tables in the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - * @return Whether the defaultEncryption field is set. - */ - @java.lang.Override - public boolean hasDefaultEncryption() { - return defaultEncryption_ != null; - } - /** - * - * - *
-     * Default encryption for tables in the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - * @return The defaultEncryption. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDefaultEncryption() { - return defaultEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : defaultEncryption_; - } - /** - * - * - *
-     * Default encryption for tables in the dataset.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDefaultEncryptionOrBuilder() { - return getDefaultEncryption(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getDatasetNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, datasetName_); - } - if (createTime_ != null) { - output.writeMessage(3, getCreateTime()); - } - if (updateTime_ != null) { - output.writeMessage(4, getUpdateTime()); - } - if (acl_ != null) { - output.writeMessage(5, getAcl()); - } - if (defaultTableExpireDuration_ != null) { - output.writeMessage(6, getDefaultTableExpireDuration()); - } - if (datasetInfo_ != null) { - output.writeMessage(7, getDatasetInfo()); - } - if (defaultEncryption_ != null) { - output.writeMessage(8, getDefaultEncryption()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getDatasetNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, datasetName_); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCreateTime()); - } - if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getUpdateTime()); - } - if (acl_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getAcl()); - } - if (defaultTableExpireDuration_ != null) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 6, getDefaultTableExpireDuration()); - } - if (datasetInfo_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getDatasetInfo()); - } - if (defaultEncryption_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getDefaultEncryption()); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.Dataset)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.Dataset other = - (com.google.cloud.audit.BigQueryAuditMetadata.Dataset) obj; - - if (!getDatasetName().equals(other.getDatasetName())) return false; - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasUpdateTime() != other.hasUpdateTime()) return false; - if (hasUpdateTime()) { - if (!getUpdateTime().equals(other.getUpdateTime())) return false; - } - if (hasAcl() != other.hasAcl()) return false; - if (hasAcl()) { - if (!getAcl().equals(other.getAcl())) return false; - } - if (hasDefaultTableExpireDuration() != other.hasDefaultTableExpireDuration()) return false; - if (hasDefaultTableExpireDuration()) { - if (!getDefaultTableExpireDuration().equals(other.getDefaultTableExpireDuration())) - return false; - } - if (hasDatasetInfo() != other.hasDatasetInfo()) return false; - if (hasDatasetInfo()) { - if (!getDatasetInfo().equals(other.getDatasetInfo())) return false; - } - if (hasDefaultEncryption() != other.hasDefaultEncryption()) return false; - if (hasDefaultEncryption()) { - if (!getDefaultEncryption().equals(other.getDefaultEncryption())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + DATASET_NAME_FIELD_NUMBER; - hash = (53 * hash) + getDatasetName().hashCode(); - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasUpdateTime()) { - hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getUpdateTime().hashCode(); - } - if (hasAcl()) { - hash = (37 * hash) + ACL_FIELD_NUMBER; - hash = (53 * hash) + getAcl().hashCode(); - } - if (hasDefaultTableExpireDuration()) { - hash = (37 * hash) + DEFAULT_TABLE_EXPIRE_DURATION_FIELD_NUMBER; - hash = (53 * hash) + getDefaultTableExpireDuration().hashCode(); - } - if (hasDatasetInfo()) { - hash = (37 * hash) + DATASET_INFO_FIELD_NUMBER; - hash = (53 * hash) + getDatasetInfo().hashCode(); - } - if (hasDefaultEncryption()) { - hash = (37 * hash) + DEFAULT_ENCRYPTION_FIELD_NUMBER; - hash = (53 * hash) + getDefaultEncryption().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.Dataset prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * BigQuery dataset.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Dataset} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.Dataset) - com.google.cloud.audit.BigQueryAuditMetadata.DatasetOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.class, - com.google.cloud.audit.BigQueryAuditMetadata.Dataset.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.Dataset.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - datasetName_ = ""; - - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (updateTimeBuilder_ == null) { - updateTime_ = null; - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - if (aclBuilder_ == null) { - acl_ = null; - } else { - acl_ = null; - aclBuilder_ = null; - } - if (defaultTableExpireDurationBuilder_ == null) { - defaultTableExpireDuration_ = null; - } else { - defaultTableExpireDuration_ = null; - defaultTableExpireDurationBuilder_ = null; - } - if (datasetInfoBuilder_ == null) { - datasetInfo_ = null; - } else { - datasetInfo_ = null; - datasetInfoBuilder_ = null; - } - if (defaultEncryptionBuilder_ == null) { - defaultEncryption_ = null; - } else { - defaultEncryption_ = null; - defaultEncryptionBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Dataset build() { - com.google.cloud.audit.BigQueryAuditMetadata.Dataset result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Dataset buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.Dataset result = - new com.google.cloud.audit.BigQueryAuditMetadata.Dataset(this); - result.datasetName_ = datasetName_; - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (updateTimeBuilder_ == null) { - result.updateTime_ = updateTime_; - } else { - result.updateTime_ = updateTimeBuilder_.build(); - } - if (aclBuilder_ == null) { - result.acl_ = acl_; - } else { - result.acl_ = aclBuilder_.build(); - } - if (defaultTableExpireDurationBuilder_ == null) { - result.defaultTableExpireDuration_ = defaultTableExpireDuration_; - } else { - result.defaultTableExpireDuration_ = defaultTableExpireDurationBuilder_.build(); - } - if (datasetInfoBuilder_ == null) { - result.datasetInfo_ = datasetInfo_; - } else { - result.datasetInfo_ = datasetInfoBuilder_.build(); - } - if (defaultEncryptionBuilder_ == null) { - result.defaultEncryption_ = defaultEncryption_; - } else { - result.defaultEncryption_ = defaultEncryptionBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.Dataset) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.Dataset) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.Dataset other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.Dataset.getDefaultInstance()) - return this; - if (!other.getDatasetName().isEmpty()) { - datasetName_ = other.datasetName_; - onChanged(); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasUpdateTime()) { - mergeUpdateTime(other.getUpdateTime()); - } - if (other.hasAcl()) { - mergeAcl(other.getAcl()); - } - if (other.hasDefaultTableExpireDuration()) { - mergeDefaultTableExpireDuration(other.getDefaultTableExpireDuration()); - } - if (other.hasDatasetInfo()) { - mergeDatasetInfo(other.getDatasetInfo()); - } - if (other.hasDefaultEncryption()) { - mergeDefaultEncryption(other.getDefaultEncryption()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.Dataset parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.Dataset) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object datasetName_ = ""; - /** - * - * - *
-       * Dataset URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>`.
-       * 
- * - * string dataset_name = 1; - * - * @return The datasetName. - */ - public java.lang.String getDatasetName() { - java.lang.Object ref = datasetName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - datasetName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Dataset URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>`.
-       * 
- * - * string dataset_name = 1; - * - * @return The bytes for datasetName. - */ - public com.google.protobuf.ByteString getDatasetNameBytes() { - java.lang.Object ref = datasetName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - datasetName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Dataset URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>`.
-       * 
- * - * string dataset_name = 1; - * - * @param value The datasetName to set. - * @return This builder for chaining. - */ - public Builder setDatasetName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - datasetName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Dataset URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>`.
-       * 
- * - * string dataset_name = 1; - * - * @return This builder for chaining. - */ - public Builder clearDatasetName() { - - datasetName_ = getDefaultInstance().getDatasetName(); - onChanged(); - return this; - } - /** - * - * - *
-       * Dataset URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>`.
-       * 
- * - * string dataset_name = 1; - * - * @param value The bytes for datasetName to set. - * @return This builder for chaining. - */ - public Builder setDatasetNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - datasetName_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-       * Dataset creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 3; - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-       * Dataset creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 3; - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Dataset creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Dataset creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Dataset creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_) - .mergeFrom(value) - .buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Dataset creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Dataset creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Dataset creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-       * Dataset creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private com.google.protobuf.Timestamp updateTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - updateTimeBuilder_; - /** - * - * - *
-       * Dataset metadata last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 4; - * - * @return Whether the updateTime field is set. - */ - public boolean hasUpdateTime() { - return updateTimeBuilder_ != null || updateTime_ != null; - } - /** - * - * - *
-       * Dataset metadata last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 4; - * - * @return The updateTime. - */ - public com.google.protobuf.Timestamp getUpdateTime() { - if (updateTimeBuilder_ == null) { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } else { - return updateTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Dataset metadata last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 4; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp value) { - if (updateTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - updateTime_ = value; - onChanged(); - } else { - updateTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Dataset metadata last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 4; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (updateTimeBuilder_ == null) { - updateTime_ = builderForValue.build(); - onChanged(); - } else { - updateTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Dataset metadata last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 4; - */ - public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { - if (updateTimeBuilder_ == null) { - if (updateTime_ != null) { - updateTime_ = - com.google.protobuf.Timestamp.newBuilder(updateTime_) - .mergeFrom(value) - .buildPartial(); - } else { - updateTime_ = value; - } - onChanged(); - } else { - updateTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Dataset metadata last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 4; - */ - public Builder clearUpdateTime() { - if (updateTimeBuilder_ == null) { - updateTime_ = null; - onChanged(); - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Dataset metadata last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 4; - */ - public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - - onChanged(); - return getUpdateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Dataset metadata last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 4; - */ - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - if (updateTimeBuilder_ != null) { - return updateTimeBuilder_.getMessageOrBuilder(); - } else { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } - } - /** - * - * - *
-       * Dataset metadata last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getUpdateTimeFieldBuilder() { - if (updateTimeBuilder_ == null) { - updateTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getUpdateTime(), getParentForChildren(), isClean()); - updateTime_ = null; - } - return updateTimeBuilder_; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl, - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder> - aclBuilder_; - /** - * - * - *
-       * The access control list for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - * - * @return Whether the acl field is set. - */ - public boolean hasAcl() { - return aclBuilder_ != null || acl_ != null; - } - /** - * - * - *
-       * The access control list for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - * - * @return The acl. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getAcl() { - if (aclBuilder_ == null) { - return acl_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.getDefaultInstance() - : acl_; - } else { - return aclBuilder_.getMessage(); - } - } - /** - * - * - *
-       * The access control list for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - */ - public Builder setAcl(com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl value) { - if (aclBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - acl_ = value; - onChanged(); - } else { - aclBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * The access control list for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - */ - public Builder setAcl( - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder builderForValue) { - if (aclBuilder_ == null) { - acl_ = builderForValue.build(); - onChanged(); - } else { - aclBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * The access control list for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - */ - public Builder mergeAcl(com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl value) { - if (aclBuilder_ == null) { - if (acl_ != null) { - acl_ = - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.newBuilder(acl_) - .mergeFrom(value) - .buildPartial(); - } else { - acl_ = value; - } - onChanged(); - } else { - aclBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * The access control list for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - */ - public Builder clearAcl() { - if (aclBuilder_ == null) { - acl_ = null; - onChanged(); - } else { - acl_ = null; - aclBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * The access control list for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder getAclBuilder() { - - onChanged(); - return getAclFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * The access control list for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder getAclOrBuilder() { - if (aclBuilder_ != null) { - return aclBuilder_.getMessageOrBuilder(); - } else { - return acl_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.getDefaultInstance() - : acl_; - } - } - /** - * - * - *
-       * The access control list for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl acl = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl, - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder> - getAclFieldBuilder() { - if (aclBuilder_ == null) { - aclBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl, - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder>( - getAcl(), getParentForChildren(), isClean()); - acl_ = null; - } - return aclBuilder_; - } - - private com.google.protobuf.Duration defaultTableExpireDuration_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder> - defaultTableExpireDurationBuilder_; - /** - * - * - *
-       * Default expiration time for tables in the dataset.
-       * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - * - * @return Whether the defaultTableExpireDuration field is set. - */ - public boolean hasDefaultTableExpireDuration() { - return defaultTableExpireDurationBuilder_ != null || defaultTableExpireDuration_ != null; - } - /** - * - * - *
-       * Default expiration time for tables in the dataset.
-       * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - * - * @return The defaultTableExpireDuration. - */ - public com.google.protobuf.Duration getDefaultTableExpireDuration() { - if (defaultTableExpireDurationBuilder_ == null) { - return defaultTableExpireDuration_ == null - ? com.google.protobuf.Duration.getDefaultInstance() - : defaultTableExpireDuration_; - } else { - return defaultTableExpireDurationBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Default expiration time for tables in the dataset.
-       * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - */ - public Builder setDefaultTableExpireDuration(com.google.protobuf.Duration value) { - if (defaultTableExpireDurationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - defaultTableExpireDuration_ = value; - onChanged(); - } else { - defaultTableExpireDurationBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Default expiration time for tables in the dataset.
-       * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - */ - public Builder setDefaultTableExpireDuration( - com.google.protobuf.Duration.Builder builderForValue) { - if (defaultTableExpireDurationBuilder_ == null) { - defaultTableExpireDuration_ = builderForValue.build(); - onChanged(); - } else { - defaultTableExpireDurationBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Default expiration time for tables in the dataset.
-       * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - */ - public Builder mergeDefaultTableExpireDuration(com.google.protobuf.Duration value) { - if (defaultTableExpireDurationBuilder_ == null) { - if (defaultTableExpireDuration_ != null) { - defaultTableExpireDuration_ = - com.google.protobuf.Duration.newBuilder(defaultTableExpireDuration_) - .mergeFrom(value) - .buildPartial(); - } else { - defaultTableExpireDuration_ = value; - } - onChanged(); - } else { - defaultTableExpireDurationBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Default expiration time for tables in the dataset.
-       * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - */ - public Builder clearDefaultTableExpireDuration() { - if (defaultTableExpireDurationBuilder_ == null) { - defaultTableExpireDuration_ = null; - onChanged(); - } else { - defaultTableExpireDuration_ = null; - defaultTableExpireDurationBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Default expiration time for tables in the dataset.
-       * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - */ - public com.google.protobuf.Duration.Builder getDefaultTableExpireDurationBuilder() { - - onChanged(); - return getDefaultTableExpireDurationFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Default expiration time for tables in the dataset.
-       * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - */ - public com.google.protobuf.DurationOrBuilder getDefaultTableExpireDurationOrBuilder() { - if (defaultTableExpireDurationBuilder_ != null) { - return defaultTableExpireDurationBuilder_.getMessageOrBuilder(); - } else { - return defaultTableExpireDuration_ == null - ? com.google.protobuf.Duration.getDefaultInstance() - : defaultTableExpireDuration_; - } - } - /** - * - * - *
-       * Default expiration time for tables in the dataset.
-       * 
- * - * .google.protobuf.Duration default_table_expire_duration = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder> - getDefaultTableExpireDurationFieldBuilder() { - if (defaultTableExpireDurationBuilder_ == null) { - defaultTableExpireDurationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder>( - getDefaultTableExpireDuration(), getParentForChildren(), isClean()); - defaultTableExpireDuration_ = null; - } - return defaultTableExpireDurationBuilder_; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo datasetInfo_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> - datasetInfoBuilder_; - /** - * - * - *
-       * User-provided metadata for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - * - * @return Whether the datasetInfo field is set. - */ - public boolean hasDatasetInfo() { - return datasetInfoBuilder_ != null || datasetInfo_ != null; - } - /** - * - * - *
-       * User-provided metadata for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - * - * @return The datasetInfo. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDatasetInfo() { - if (datasetInfoBuilder_ == null) { - return datasetInfo_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() - : datasetInfo_; - } else { - return datasetInfoBuilder_.getMessage(); - } - } - /** - * - * - *
-       * User-provided metadata for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - */ - public Builder setDatasetInfo(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { - if (datasetInfoBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - datasetInfo_ = value; - onChanged(); - } else { - datasetInfoBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - */ - public Builder setDatasetInfo( - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder builderForValue) { - if (datasetInfoBuilder_ == null) { - datasetInfo_ = builderForValue.build(); - onChanged(); - } else { - datasetInfoBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - */ - public Builder mergeDatasetInfo( - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { - if (datasetInfoBuilder_ == null) { - if (datasetInfo_ != null) { - datasetInfo_ = - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.newBuilder(datasetInfo_) - .mergeFrom(value) - .buildPartial(); - } else { - datasetInfo_ = value; - } - onChanged(); - } else { - datasetInfoBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - */ - public Builder clearDatasetInfo() { - if (datasetInfoBuilder_ == null) { - datasetInfo_ = null; - onChanged(); - } else { - datasetInfo_ = null; - datasetInfoBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder - getDatasetInfoBuilder() { - - onChanged(); - return getDatasetInfoFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * User-provided metadata for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder - getDatasetInfoOrBuilder() { - if (datasetInfoBuilder_ != null) { - return datasetInfoBuilder_.getMessageOrBuilder(); - } else { - return datasetInfo_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() - : datasetInfo_; - } - } - /** - * - * - *
-       * User-provided metadata for the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo dataset_info = 7; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> - getDatasetInfoFieldBuilder() { - if (datasetInfoBuilder_ == null) { - datasetInfoBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder>( - getDatasetInfo(), getParentForChildren(), isClean()); - datasetInfo_ = null; - } - return datasetInfoBuilder_; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo defaultEncryption_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - defaultEncryptionBuilder_; - /** - * - * - *
-       * Default encryption for tables in the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - * - * @return Whether the defaultEncryption field is set. - */ - public boolean hasDefaultEncryption() { - return defaultEncryptionBuilder_ != null || defaultEncryption_ != null; - } - /** - * - * - *
-       * Default encryption for tables in the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - * - * @return The defaultEncryption. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDefaultEncryption() { - if (defaultEncryptionBuilder_ == null) { - return defaultEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : defaultEncryption_; - } else { - return defaultEncryptionBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Default encryption for tables in the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - */ - public Builder setDefaultEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (defaultEncryptionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - defaultEncryption_ = value; - onChanged(); - } else { - defaultEncryptionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Default encryption for tables in the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - */ - public Builder setDefaultEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { - if (defaultEncryptionBuilder_ == null) { - defaultEncryption_ = builderForValue.build(); - onChanged(); - } else { - defaultEncryptionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Default encryption for tables in the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - */ - public Builder mergeDefaultEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (defaultEncryptionBuilder_ == null) { - if (defaultEncryption_ != null) { - defaultEncryption_ = - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder( - defaultEncryption_) - .mergeFrom(value) - .buildPartial(); - } else { - defaultEncryption_ = value; - } - onChanged(); - } else { - defaultEncryptionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Default encryption for tables in the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - */ - public Builder clearDefaultEncryption() { - if (defaultEncryptionBuilder_ == null) { - defaultEncryption_ = null; - onChanged(); - } else { - defaultEncryption_ = null; - defaultEncryptionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Default encryption for tables in the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder - getDefaultEncryptionBuilder() { - - onChanged(); - return getDefaultEncryptionFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Default encryption for tables in the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDefaultEncryptionOrBuilder() { - if (defaultEncryptionBuilder_ != null) { - return defaultEncryptionBuilder_.getMessageOrBuilder(); - } else { - return defaultEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : defaultEncryption_; - } - } - /** - * - * - *
-       * Default encryption for tables in the dataset.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo default_encryption = 8; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - getDefaultEncryptionFieldBuilder() { - if (defaultEncryptionBuilder_ == null) { - defaultEncryptionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( - getDefaultEncryption(), getParentForChildren(), isClean()); - defaultEncryption_ = null; - } - return defaultEncryptionBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.Dataset) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.Dataset) - private static final com.google.cloud.audit.BigQueryAuditMetadata.Dataset DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.Dataset(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Dataset parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Dataset(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Dataset getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface TableDeletionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableDeletion) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Describes how the table was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the table was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that deleted a table.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that deleted a table.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Table deletion event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDeletion} - */ - public static final class TableDeletion extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableDeletion) - TableDeletionOrBuilder { - private static final long serialVersionUID = 0L; - // Use TableDeletion.newBuilder() to construct. - private TableDeletion(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private TableDeletion() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TableDeletion(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private TableDeletion( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder.class); - } - - /** - * - * - *
-     * Describes how the table was deleted.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Table was deleted using the tables.delete API.
-       * 
- * - * TABLE_DELETE_REQUEST = 2; - */ - TABLE_DELETE_REQUEST(2), - /** - * - * - *
-       * Table expired.
-       * 
- * - * EXPIRED = 3; - */ - EXPIRED(3), - /** - * - * - *
-       * Table deleted using a DDL query.
-       * 
- * - * QUERY = 4; - */ - QUERY(4), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Table was deleted using the tables.delete API.
-       * 
- * - * TABLE_DELETE_REQUEST = 2; - */ - public static final int TABLE_DELETE_REQUEST_VALUE = 2; - /** - * - * - *
-       * Table expired.
-       * 
- * - * EXPIRED = 3; - */ - public static final int EXPIRED_VALUE = 3; - /** - * - * - *
-       * Table deleted using a DDL query.
-       * 
- * - * QUERY = 4; - */ - public static final int QUERY_VALUE = 4; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 2: - return TABLE_DELETE_REQUEST; - case 3: - return EXPIRED; - case 4: - return QUERY; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason) - } - - public static final int REASON_FIELD_NUMBER = 1; - private int reason_; - /** - * - * - *
-     * Describes how the table was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the table was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that deleted a table.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that deleted a table.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion other = - (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) obj; - - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Table deletion event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDeletion} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableDeletion) - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion build() { - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion result = - new com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion(this); - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance()) - return this; - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the table was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the table was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the table was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the table was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the table was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Reason reason = 1; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that deleted a table.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that deleted a table.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that deleted a table.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that deleted a table.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that deleted a table.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableDeletion) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableDeletion) - private static final com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public TableDeletion parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TableDeletion(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface ModelDeletionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Describes how the model was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the model was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that deleted a model.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that deleted a model.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Model deletion event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDeletion} - */ - public static final class ModelDeletion extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) - ModelDeletionOrBuilder { - private static final long serialVersionUID = 0L; - // Use ModelDeletion.newBuilder() to construct. - private ModelDeletion(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ModelDeletion() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ModelDeletion(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ModelDeletion( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.class, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder.class); - } - - /** - * - * - *
-     * Describes how the model was deleted.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Model was deleted using the models.delete API.
-       * 
- * - * MODEL_DELETE_REQUEST = 1; - */ - MODEL_DELETE_REQUEST(1), - /** - * - * - *
-       * Model expired.
-       * 
- * - * EXPIRED = 2; - */ - EXPIRED(2), - /** - * - * - *
-       * Model was deleted using DDL query.
-       * 
- * - * QUERY = 3; - */ - QUERY(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Model was deleted using the models.delete API.
-       * 
- * - * MODEL_DELETE_REQUEST = 1; - */ - public static final int MODEL_DELETE_REQUEST_VALUE = 1; - /** - * - * - *
-       * Model expired.
-       * 
- * - * EXPIRED = 2; - */ - public static final int EXPIRED_VALUE = 2; - /** - * - * - *
-       * Model was deleted using DDL query.
-       * 
- * - * QUERY = 3; - */ - public static final int QUERY_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return MODEL_DELETE_REQUEST; - case 2: - return EXPIRED; - case 3: - return QUERY; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason) - } - - public static final int REASON_FIELD_NUMBER = 1; - private int reason_; - /** - * - * - *
-     * Describes how the model was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the model was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that deleted a model.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that deleted a model.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion other = - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) obj; - - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Model deletion event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.ModelDeletion} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.class, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion build() { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion result = - new com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion(this); - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance()) - return this; - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the model was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the model was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the model was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the model was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the model was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Reason reason = 1; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that deleted a model.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that deleted a model.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that deleted a model.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that deleted a model.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that deleted a model.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 2; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) - private static final com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ModelDeletion parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ModelDeletion(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface ModelOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.Model) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Model URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
-     * 
- * - * string model_name = 1; - * - * @return The modelName. - */ - java.lang.String getModelName(); - /** - * - * - *
-     * Model URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
-     * 
- * - * string model_name = 1; - * - * @return The bytes for modelName. - */ - com.google.protobuf.ByteString getModelNameBytes(); - - /** - * - * - *
-     * User-provided metadata for the model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - * - * @return Whether the modelInfo field is set. - */ - boolean hasModelInfo(); - /** - * - * - *
-     * User-provided metadata for the model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - * - * @return The modelInfo. - */ - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getModelInfo(); - /** - * - * - *
-     * User-provided metadata for the model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - */ - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder getModelInfoOrBuilder(); - - /** - * - * - *
-     * Model expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return Whether the expireTime field is set. - */ - boolean hasExpireTime(); - /** - * - * - *
-     * Model expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return The expireTime. - */ - com.google.protobuf.Timestamp getExpireTime(); - /** - * - * - *
-     * Model expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder(); - - /** - * - * - *
-     * Model creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-     * Model creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-     * Model creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-     * Model last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return Whether the updateTime field is set. - */ - boolean hasUpdateTime(); - /** - * - * - *
-     * Model last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return The updateTime. - */ - com.google.protobuf.Timestamp getUpdateTime(); - /** - * - * - *
-     * Model last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); - - /** - * - * - *
-     * Model encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - * - * @return Whether the encryption field is set. - */ - boolean hasEncryption(); - /** - * - * - *
-     * Model encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - * - * @return The encryption. - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption(); - /** - * - * - *
-     * Model encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder getEncryptionOrBuilder(); - } - /** - * - * - *
-   * Trained BigQuery ML model.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Model} - */ - public static final class Model extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.Model) - ModelOrBuilder { - private static final long serialVersionUID = 0L; - // Use Model.newBuilder() to construct. - private Model(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Model() { - modelName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Model(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Model( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - modelName_ = s; - break; - } - case 18: - { - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder subBuilder = null; - if (modelInfo_ != null) { - subBuilder = modelInfo_.toBuilder(); - } - modelInfo_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(modelInfo_); - modelInfo_ = subBuilder.buildPartial(); - } - - break; - } - case 42: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (expireTime_ != null) { - subBuilder = expireTime_.toBuilder(); - } - expireTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(expireTime_); - expireTime_ = subBuilder.buildPartial(); - } - - break; - } - case 50: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (updateTime_ != null) { - subBuilder = updateTime_.toBuilder(); - } - updateTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateTime_); - updateTime_ = subBuilder.buildPartial(); - } - - break; - } - case 66: - { - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = - null; - if (encryption_ != null) { - subBuilder = encryption_.toBuilder(); - } - encryption_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(encryption_); - encryption_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.Model.class, - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder.class); - } - - public static final int MODEL_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object modelName_; - /** - * - * - *
-     * Model URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
-     * 
- * - * string model_name = 1; - * - * @return The modelName. - */ - @java.lang.Override - public java.lang.String getModelName() { - java.lang.Object ref = modelName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - modelName_ = s; - return s; - } - } - /** - * - * - *
-     * Model URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
-     * 
- * - * string model_name = 1; - * - * @return The bytes for modelName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getModelNameBytes() { - java.lang.Object ref = modelName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - modelName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int MODEL_INFO_FIELD_NUMBER = 2; - private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo modelInfo_; - /** - * - * - *
-     * User-provided metadata for the model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - * - * @return Whether the modelInfo field is set. - */ - @java.lang.Override - public boolean hasModelInfo() { - return modelInfo_ != null; - } - /** - * - * - *
-     * User-provided metadata for the model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - * - * @return The modelInfo. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getModelInfo() { - return modelInfo_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() - : modelInfo_; - } - /** - * - * - *
-     * User-provided metadata for the model.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder - getModelInfoOrBuilder() { - return getModelInfo(); - } - - public static final int EXPIRE_TIME_FIELD_NUMBER = 5; - private com.google.protobuf.Timestamp expireTime_; - /** - * - * - *
-     * Model expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return Whether the expireTime field is set. - */ - @java.lang.Override - public boolean hasExpireTime() { - return expireTime_ != null; - } - /** - * - * - *
-     * Model expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return The expireTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getExpireTime() { - return expireTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : expireTime_; - } - /** - * - * - *
-     * Model expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder() { - return getExpireTime(); - } - - public static final int CREATE_TIME_FIELD_NUMBER = 6; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-     * Model creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-     * Model creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-     * Model creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int UPDATE_TIME_FIELD_NUMBER = 7; - private com.google.protobuf.Timestamp updateTime_; - /** - * - * - *
-     * Model last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return Whether the updateTime field is set. - */ - @java.lang.Override - public boolean hasUpdateTime() { - return updateTime_ != null; - } - /** - * - * - *
-     * Model last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return The updateTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getUpdateTime() { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; - } - /** - * - * - *
-     * Model last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - return getUpdateTime(); - } - - public static final int ENCRYPTION_FIELD_NUMBER = 8; - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption_; - /** - * - * - *
-     * Model encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - * - * @return Whether the encryption field is set. - */ - @java.lang.Override - public boolean hasEncryption() { - return encryption_ != null; - } - /** - * - * - *
-     * Model encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - * - * @return The encryption. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption() { - return encryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : encryption_; - } - /** - * - * - *
-     * Model encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getEncryptionOrBuilder() { - return getEncryption(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getModelNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, modelName_); - } - if (modelInfo_ != null) { - output.writeMessage(2, getModelInfo()); - } - if (expireTime_ != null) { - output.writeMessage(5, getExpireTime()); - } - if (createTime_ != null) { - output.writeMessage(6, getCreateTime()); - } - if (updateTime_ != null) { - output.writeMessage(7, getUpdateTime()); - } - if (encryption_ != null) { - output.writeMessage(8, getEncryption()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getModelNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, modelName_); - } - if (modelInfo_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getModelInfo()); - } - if (expireTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getExpireTime()); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getCreateTime()); - } - if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getUpdateTime()); - } - if (encryption_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getEncryption()); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.Model)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.Model other = - (com.google.cloud.audit.BigQueryAuditMetadata.Model) obj; - - if (!getModelName().equals(other.getModelName())) return false; - if (hasModelInfo() != other.hasModelInfo()) return false; - if (hasModelInfo()) { - if (!getModelInfo().equals(other.getModelInfo())) return false; - } - if (hasExpireTime() != other.hasExpireTime()) return false; - if (hasExpireTime()) { - if (!getExpireTime().equals(other.getExpireTime())) return false; - } - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasUpdateTime() != other.hasUpdateTime()) return false; - if (hasUpdateTime()) { - if (!getUpdateTime().equals(other.getUpdateTime())) return false; - } - if (hasEncryption() != other.hasEncryption()) return false; - if (hasEncryption()) { - if (!getEncryption().equals(other.getEncryption())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + MODEL_NAME_FIELD_NUMBER; - hash = (53 * hash) + getModelName().hashCode(); - if (hasModelInfo()) { - hash = (37 * hash) + MODEL_INFO_FIELD_NUMBER; - hash = (53 * hash) + getModelInfo().hashCode(); - } - if (hasExpireTime()) { - hash = (37 * hash) + EXPIRE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getExpireTime().hashCode(); - } - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasUpdateTime()) { - hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getUpdateTime().hashCode(); - } - if (hasEncryption()) { - hash = (37 * hash) + ENCRYPTION_FIELD_NUMBER; - hash = (53 * hash) + getEncryption().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloud.audit.BigQueryAuditMetadata.Model prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Trained BigQuery ML model.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Model} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.Model) - com.google.cloud.audit.BigQueryAuditMetadata.ModelOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.Model.class, - com.google.cloud.audit.BigQueryAuditMetadata.Model.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.Model.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - modelName_ = ""; - - if (modelInfoBuilder_ == null) { - modelInfo_ = null; - } else { - modelInfo_ = null; - modelInfoBuilder_ = null; - } - if (expireTimeBuilder_ == null) { - expireTime_ = null; - } else { - expireTime_ = null; - expireTimeBuilder_ = null; - } - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (updateTimeBuilder_ == null) { - updateTime_ = null; - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - if (encryptionBuilder_ == null) { - encryption_ = null; - } else { - encryption_ = null; - encryptionBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Model getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Model build() { - com.google.cloud.audit.BigQueryAuditMetadata.Model result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Model buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.Model result = - new com.google.cloud.audit.BigQueryAuditMetadata.Model(this); - result.modelName_ = modelName_; - if (modelInfoBuilder_ == null) { - result.modelInfo_ = modelInfo_; - } else { - result.modelInfo_ = modelInfoBuilder_.build(); - } - if (expireTimeBuilder_ == null) { - result.expireTime_ = expireTime_; - } else { - result.expireTime_ = expireTimeBuilder_.build(); - } - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (updateTimeBuilder_ == null) { - result.updateTime_ = updateTime_; - } else { - result.updateTime_ = updateTimeBuilder_.build(); - } - if (encryptionBuilder_ == null) { - result.encryption_ = encryption_; - } else { - result.encryption_ = encryptionBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.Model) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.Model) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.Model other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.Model.getDefaultInstance()) - return this; - if (!other.getModelName().isEmpty()) { - modelName_ = other.modelName_; - onChanged(); - } - if (other.hasModelInfo()) { - mergeModelInfo(other.getModelInfo()); - } - if (other.hasExpireTime()) { - mergeExpireTime(other.getExpireTime()); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasUpdateTime()) { - mergeUpdateTime(other.getUpdateTime()); - } - if (other.hasEncryption()) { - mergeEncryption(other.getEncryption()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.Model parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.Model) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object modelName_ = ""; - /** - * - * - *
-       * Model URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
-       * 
- * - * string model_name = 1; - * - * @return The modelName. - */ - public java.lang.String getModelName() { - java.lang.Object ref = modelName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - modelName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Model URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
-       * 
- * - * string model_name = 1; - * - * @return The bytes for modelName. - */ - public com.google.protobuf.ByteString getModelNameBytes() { - java.lang.Object ref = modelName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - modelName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Model URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
-       * 
- * - * string model_name = 1; - * - * @param value The modelName to set. - * @return This builder for chaining. - */ - public Builder setModelName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - modelName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Model URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
-       * 
- * - * string model_name = 1; - * - * @return This builder for chaining. - */ - public Builder clearModelName() { - - modelName_ = getDefaultInstance().getModelName(); - onChanged(); - return this; - } - /** - * - * - *
-       * Model URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/models/<model_id>`.
-       * 
- * - * string model_name = 1; - * - * @param value The bytes for modelName to set. - * @return This builder for chaining. - */ - public Builder setModelNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - modelName_ = value; - onChanged(); - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo modelInfo_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> - modelInfoBuilder_; - /** - * - * - *
-       * User-provided metadata for the model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - * - * @return Whether the modelInfo field is set. - */ - public boolean hasModelInfo() { - return modelInfoBuilder_ != null || modelInfo_ != null; - } - /** - * - * - *
-       * User-provided metadata for the model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - * - * @return The modelInfo. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getModelInfo() { - if (modelInfoBuilder_ == null) { - return modelInfo_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() - : modelInfo_; - } else { - return modelInfoBuilder_.getMessage(); - } - } - /** - * - * - *
-       * User-provided metadata for the model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - */ - public Builder setModelInfo(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { - if (modelInfoBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - modelInfo_ = value; - onChanged(); - } else { - modelInfoBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - */ - public Builder setModelInfo( - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder builderForValue) { - if (modelInfoBuilder_ == null) { - modelInfo_ = builderForValue.build(); - onChanged(); - } else { - modelInfoBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - */ - public Builder mergeModelInfo(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { - if (modelInfoBuilder_ == null) { - if (modelInfo_ != null) { - modelInfo_ = - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.newBuilder(modelInfo_) - .mergeFrom(value) - .buildPartial(); - } else { - modelInfo_ = value; - } - onChanged(); - } else { - modelInfoBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - */ - public Builder clearModelInfo() { - if (modelInfoBuilder_ == null) { - modelInfo_ = null; - onChanged(); - } else { - modelInfo_ = null; - modelInfoBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder getModelInfoBuilder() { - - onChanged(); - return getModelInfoFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * User-provided metadata for the model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder - getModelInfoOrBuilder() { - if (modelInfoBuilder_ != null) { - return modelInfoBuilder_.getMessageOrBuilder(); - } else { - return modelInfo_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() - : modelInfo_; - } - } - /** - * - * - *
-       * User-provided metadata for the model.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo model_info = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> - getModelInfoFieldBuilder() { - if (modelInfoBuilder_ == null) { - modelInfoBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder>( - getModelInfo(), getParentForChildren(), isClean()); - modelInfo_ = null; - } - return modelInfoBuilder_; - } - - private com.google.protobuf.Timestamp expireTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - expireTimeBuilder_; - /** - * - * - *
-       * Model expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return Whether the expireTime field is set. - */ - public boolean hasExpireTime() { - return expireTimeBuilder_ != null || expireTime_ != null; - } - /** - * - * - *
-       * Model expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return The expireTime. - */ - public com.google.protobuf.Timestamp getExpireTime() { - if (expireTimeBuilder_ == null) { - return expireTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : expireTime_; - } else { - return expireTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Model expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public Builder setExpireTime(com.google.protobuf.Timestamp value) { - if (expireTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - expireTime_ = value; - onChanged(); - } else { - expireTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Model expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public Builder setExpireTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (expireTimeBuilder_ == null) { - expireTime_ = builderForValue.build(); - onChanged(); - } else { - expireTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Model expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public Builder mergeExpireTime(com.google.protobuf.Timestamp value) { - if (expireTimeBuilder_ == null) { - if (expireTime_ != null) { - expireTime_ = - com.google.protobuf.Timestamp.newBuilder(expireTime_) - .mergeFrom(value) - .buildPartial(); - } else { - expireTime_ = value; - } - onChanged(); - } else { - expireTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Model expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public Builder clearExpireTime() { - if (expireTimeBuilder_ == null) { - expireTime_ = null; - onChanged(); - } else { - expireTime_ = null; - expireTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Model expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public com.google.protobuf.Timestamp.Builder getExpireTimeBuilder() { - - onChanged(); - return getExpireTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Model expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder() { - if (expireTimeBuilder_ != null) { - return expireTimeBuilder_.getMessageOrBuilder(); - } else { - return expireTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : expireTime_; - } - } - /** - * - * - *
-       * Model expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getExpireTimeFieldBuilder() { - if (expireTimeBuilder_ == null) { - expireTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getExpireTime(), getParentForChildren(), isClean()); - expireTime_ = null; - } - return expireTimeBuilder_; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-       * Model creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-       * Model creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Model creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Model creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Model creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_) - .mergeFrom(value) - .buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Model creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Model creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Model creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-       * Model creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private com.google.protobuf.Timestamp updateTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - updateTimeBuilder_; - /** - * - * - *
-       * Model last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return Whether the updateTime field is set. - */ - public boolean hasUpdateTime() { - return updateTimeBuilder_ != null || updateTime_ != null; - } - /** - * - * - *
-       * Model last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return The updateTime. - */ - public com.google.protobuf.Timestamp getUpdateTime() { - if (updateTimeBuilder_ == null) { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } else { - return updateTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Model last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp value) { - if (updateTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - updateTime_ = value; - onChanged(); - } else { - updateTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Model last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (updateTimeBuilder_ == null) { - updateTime_ = builderForValue.build(); - onChanged(); - } else { - updateTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Model last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { - if (updateTimeBuilder_ == null) { - if (updateTime_ != null) { - updateTime_ = - com.google.protobuf.Timestamp.newBuilder(updateTime_) - .mergeFrom(value) - .buildPartial(); - } else { - updateTime_ = value; - } - onChanged(); - } else { - updateTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Model last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public Builder clearUpdateTime() { - if (updateTimeBuilder_ == null) { - updateTime_ = null; - onChanged(); - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Model last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - - onChanged(); - return getUpdateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Model last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - if (updateTimeBuilder_ != null) { - return updateTimeBuilder_.getMessageOrBuilder(); - } else { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } - } - /** - * - * - *
-       * Model last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getUpdateTimeFieldBuilder() { - if (updateTimeBuilder_ == null) { - updateTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getUpdateTime(), getParentForChildren(), isClean()); - updateTime_ = null; - } - return updateTimeBuilder_; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - encryptionBuilder_; - /** - * - * - *
-       * Model encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - * - * @return Whether the encryption field is set. - */ - public boolean hasEncryption() { - return encryptionBuilder_ != null || encryption_ != null; - } - /** - * - * - *
-       * Model encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - * - * @return The encryption. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption() { - if (encryptionBuilder_ == null) { - return encryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : encryption_; - } else { - return encryptionBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Model encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - */ - public Builder setEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (encryptionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - encryption_ = value; - onChanged(); - } else { - encryptionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Model encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - */ - public Builder setEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { - if (encryptionBuilder_ == null) { - encryption_ = builderForValue.build(); - onChanged(); - } else { - encryptionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Model encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - */ - public Builder mergeEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (encryptionBuilder_ == null) { - if (encryption_ != null) { - encryption_ = - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder(encryption_) - .mergeFrom(value) - .buildPartial(); - } else { - encryption_ = value; - } - onChanged(); - } else { - encryptionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Model encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - */ - public Builder clearEncryption() { - if (encryptionBuilder_ == null) { - encryption_ = null; - onChanged(); - } else { - encryption_ = null; - encryptionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Model encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder - getEncryptionBuilder() { - - onChanged(); - return getEncryptionFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Model encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getEncryptionOrBuilder() { - if (encryptionBuilder_ != null) { - return encryptionBuilder_.getMessageOrBuilder(); - } else { - return encryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : encryption_; - } - } - /** - * - * - *
-       * Model encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 8; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - getEncryptionFieldBuilder() { - if (encryptionBuilder_ == null) { - encryptionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( - getEncryption(), getParentForChildren(), isClean()); - encryption_ = null; - } - return encryptionBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.Model) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.Model) - private static final com.google.cloud.audit.BigQueryAuditMetadata.Model DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.Model(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Model getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Model parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Model(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Model getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface RoutineDeletionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Deleted routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return Whether the routine field is set. - */ - boolean hasRoutine(); - /** - * - * - *
-     * Deleted routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return The routine. - */ - com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine(); - /** - * - * - *
-     * Deleted routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder(); - - /** - * - * - *
-     * Describes how the routine was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - int getReasonValue(); - /** - * - * - *
-     * Describes how the routine was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; - * - * @return The reason. - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason getReason(); - - /** - * - * - *
-     * The URI of the job that deleted the routine.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * The URI of the job that deleted the routine.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - } - /** - * - * - *
-   * Routine deletion event.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion} - */ - public static final class RoutineDeletion extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) - RoutineDeletionOrBuilder { - private static final long serialVersionUID = 0L; - // Use RoutineDeletion.newBuilder() to construct. - private RoutineDeletion(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private RoutineDeletion() { - reason_ = 0; - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new RoutineDeletion(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private RoutineDeletion( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder subBuilder = null; - if (routine_ != null) { - subBuilder = routine_.toBuilder(); - } - routine_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.Routine.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(routine_); - routine_ = subBuilder.buildPartial(); - } - - break; - } - case 24: - { - int rawValue = input.readEnum(); - - reason_ = rawValue; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.class, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder.class); - } - - /** - * - * - *
-     * Describes how the routine was deleted.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason} - */ - public enum Reason implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - REASON_UNSPECIFIED(0), - /** - * - * - *
-       * Routine was deleted using DDL query.
-       * 
- * - * QUERY = 1; - */ - QUERY(1), - /** - * - * - *
-       * Routine was deleted using the API.
-       * 
- * - * ROUTINE_DELETE_REQUEST = 2; - */ - ROUTINE_DELETE_REQUEST(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * REASON_UNSPECIFIED = 0; - */ - public static final int REASON_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Routine was deleted using DDL query.
-       * 
- * - * QUERY = 1; - */ - public static final int QUERY_VALUE = 1; - /** - * - * - *
-       * Routine was deleted using the API.
-       * 
- * - * ROUTINE_DELETE_REQUEST = 2; - */ - public static final int ROUTINE_DELETE_REQUEST_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Reason 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 Reason forNumber(int value) { - switch (value) { - case 0: - return REASON_UNSPECIFIED; - case 1: - return QUERY; - case 2: - return ROUTINE_DELETE_REQUEST; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Reason findValueByNumber(int number) { - return Reason.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Reason[] VALUES = values(); - - public static Reason valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Reason(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason) - } - - public static final int ROUTINE_FIELD_NUMBER = 1; - private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; - /** - * - * - *
-     * Deleted routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return Whether the routine field is set. - */ - @java.lang.Override - public boolean hasRoutine() { - return routine_ != null; - } - /** - * - * - *
-     * Deleted routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return The routine. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { - return routine_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() - : routine_; - } - /** - * - * - *
-     * Deleted routine.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { - return getRoutine(); - } - - public static final int REASON_FIELD_NUMBER = 3; - private int reason_; - /** - * - * - *
-     * Describes how the routine was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-     * Describes how the routine was deleted.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.UNRECOGNIZED - : result; - } - - public static final int JOB_NAME_FIELD_NUMBER = 4; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * The URI of the job that deleted the routine.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * The URI of the job that deleted the routine.
-     * Present if the reason is QUERY.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (routine_ != null) { - output.writeMessage(1, getRoutine()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.REASON_UNSPECIFIED - .getNumber()) { - output.writeEnum(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, jobName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (routine_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getRoutine()); - } - if (reason_ - != com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.REASON_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, reason_); - } - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, jobName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion other = - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) obj; - - if (hasRoutine() != other.hasRoutine()) return false; - if (hasRoutine()) { - if (!getRoutine().equals(other.getRoutine())) return false; - } - if (reason_ != other.reason_) return false; - if (!getJobName().equals(other.getJobName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasRoutine()) { - hash = (37 * hash) + ROUTINE_FIELD_NUMBER; - hash = (53 * hash) + getRoutine().hashCode(); - } - hash = (37 * hash) + REASON_FIELD_NUMBER; - hash = (53 * hash) + reason_; - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Routine deletion event.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.class, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (routineBuilder_ == null) { - routine_ = null; - } else { - routine_ = null; - routineBuilder_ = null; - } - reason_ = 0; - - jobName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion build() { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion result = - new com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion(this); - if (routineBuilder_ == null) { - result.routine_ = routine_; - } else { - result.routine_ = routineBuilder_.build(); - } - result.reason_ = reason_; - result.jobName_ = jobName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance()) - return this; - if (other.hasRoutine()) { - mergeRoutine(other.getRoutine()); - } - if (other.reason_ != 0) { - setReasonValue(other.getReasonValue()); - } - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.Routine routine_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Routine, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> - routineBuilder_; - /** - * - * - *
-       * Deleted routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return Whether the routine field is set. - */ - public boolean hasRoutine() { - return routineBuilder_ != null || routine_ != null; - } - /** - * - * - *
-       * Deleted routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - * - * @return The routine. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Routine getRoutine() { - if (routineBuilder_ == null) { - return routine_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() - : routine_; - } else { - return routineBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Deleted routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder setRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { - if (routineBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - routine_ = value; - onChanged(); - } else { - routineBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Deleted routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder setRoutine( - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder builderForValue) { - if (routineBuilder_ == null) { - routine_ = builderForValue.build(); - onChanged(); - } else { - routineBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Deleted routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder mergeRoutine(com.google.cloud.audit.BigQueryAuditMetadata.Routine value) { - if (routineBuilder_ == null) { - if (routine_ != null) { - routine_ = - com.google.cloud.audit.BigQueryAuditMetadata.Routine.newBuilder(routine_) - .mergeFrom(value) - .buildPartial(); - } else { - routine_ = value; - } - onChanged(); - } else { - routineBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Deleted routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public Builder clearRoutine() { - if (routineBuilder_ == null) { - routine_ = null; - onChanged(); - } else { - routine_ = null; - routineBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Deleted routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder getRoutineBuilder() { - - onChanged(); - return getRoutineFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Deleted routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder getRoutineOrBuilder() { - if (routineBuilder_ != null) { - return routineBuilder_.getMessageOrBuilder(); - } else { - return routine_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance() - : routine_; - } - } - /** - * - * - *
-       * Deleted routine.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.Routine routine = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Routine, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder> - getRoutineFieldBuilder() { - if (routineBuilder_ == null) { - routineBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.Routine, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder>( - getRoutine(), getParentForChildren(), isClean()); - routine_ = null; - } - return routineBuilder_; - } - - private int reason_ = 0; - /** - * - * - *
-       * Describes how the routine was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; - * - * @return The enum numeric value on the wire for reason. - */ - @java.lang.Override - public int getReasonValue() { - return reason_; - } - /** - * - * - *
-       * Describes how the routine was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; - * - * @param value The enum numeric value on the wire for reason to set. - * @return This builder for chaining. - */ - public Builder setReasonValue(int value) { - - reason_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the routine was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; - * - * @return The reason. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason getReason() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason result = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.valueOf(reason_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Describes how the routine was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; - * - * @param value The reason to set. - * @return This builder for chaining. - */ - public Builder setReason( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason value) { - if (value == null) { - throw new NullPointerException(); - } - - reason_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Describes how the routine was deleted.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Reason reason = 3; - * - * @return This builder for chaining. - */ - public Builder clearReason() { - - reason_ = 0; - onChanged(); - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * The URI of the job that deleted the routine.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The URI of the job that deleted the routine.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The URI of the job that deleted the routine.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that deleted the routine.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The URI of the job that deleted the routine.
-       * Present if the reason is QUERY.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 4; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) - private static final com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public RoutineDeletion parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RoutineDeletion(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface JobOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.Job) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Job URI.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 1; - * - * @return The jobName. - */ - java.lang.String getJobName(); - /** - * - * - *
-     * Job URI.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 1; - * - * @return The bytes for jobName. - */ - com.google.protobuf.ByteString getJobNameBytes(); - - /** - * - * - *
-     * Job configuration.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - * - * @return Whether the jobConfig field is set. - */ - boolean hasJobConfig(); - /** - * - * - *
-     * Job configuration.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - * - * @return The jobConfig. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getJobConfig(); - /** - * - * - *
-     * Job configuration.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder getJobConfigOrBuilder(); - - /** - * - * - *
-     * Job status.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - * - * @return Whether the jobStatus field is set. - */ - boolean hasJobStatus(); - /** - * - * - *
-     * Job status.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - * - * @return The jobStatus. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getJobStatus(); - /** - * - * - *
-     * Job status.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder getJobStatusOrBuilder(); - - /** - * - * - *
-     * Job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - * - * @return Whether the jobStats field is set. - */ - boolean hasJobStats(); - /** - * - * - *
-     * Job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - * - * @return The jobStats. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStats getJobStats(); - /** - * - * - *
-     * Job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder getJobStatsOrBuilder(); - } - /** - * - * - *
-   * BigQuery job.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Job} - */ - public static final class Job extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.Job) - JobOrBuilder { - private static final long serialVersionUID = 0L; - // Use Job.newBuilder() to construct. - private Job(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Job() { - jobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Job(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Job( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - jobName_ = s; - break; - } - case 18: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder subBuilder = null; - if (jobConfig_ != null) { - subBuilder = jobConfig_.toBuilder(); - } - jobConfig_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(jobConfig_); - jobConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder subBuilder = null; - if (jobStatus_ != null) { - subBuilder = jobStatus_.toBuilder(); - } - jobStatus_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(jobStatus_); - jobStatus_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder subBuilder = null; - if (jobStats_ != null) { - subBuilder = jobStats_.toBuilder(); - } - jobStats_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(jobStats_); - jobStats_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.Job.class, - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder.class); - } - - public static final int JOB_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object jobName_; - /** - * - * - *
-     * Job URI.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 1; - * - * @return The jobName. - */ - @java.lang.Override - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } - } - /** - * - * - *
-     * Job URI.
-     * Format: `projects/<project_id>/jobs/<job_id>`.
-     * 
- * - * string job_name = 1; - * - * @return The bytes for jobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int JOB_CONFIG_FIELD_NUMBER = 2; - private com.google.cloud.audit.BigQueryAuditMetadata.JobConfig jobConfig_; - /** - * - * - *
-     * Job configuration.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - * - * @return Whether the jobConfig field is set. - */ - @java.lang.Override - public boolean hasJobConfig() { - return jobConfig_ != null; - } - /** - * - * - *
-     * Job configuration.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - * - * @return The jobConfig. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getJobConfig() { - return jobConfig_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDefaultInstance() - : jobConfig_; - } - /** - * - * - *
-     * Job configuration.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder getJobConfigOrBuilder() { - return getJobConfig(); - } - - public static final int JOB_STATUS_FIELD_NUMBER = 3; - private com.google.cloud.audit.BigQueryAuditMetadata.JobStatus jobStatus_; - /** - * - * - *
-     * Job status.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - * - * @return Whether the jobStatus field is set. - */ - @java.lang.Override - public boolean hasJobStatus() { - return jobStatus_ != null; - } - /** - * - * - *
-     * Job status.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - * - * @return The jobStatus. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getJobStatus() { - return jobStatus_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.getDefaultInstance() - : jobStatus_; - } - /** - * - * - *
-     * Job status.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder getJobStatusOrBuilder() { - return getJobStatus(); - } - - public static final int JOB_STATS_FIELD_NUMBER = 4; - private com.google.cloud.audit.BigQueryAuditMetadata.JobStats jobStats_; - /** - * - * - *
-     * Job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - * - * @return Whether the jobStats field is set. - */ - @java.lang.Override - public boolean hasJobStats() { - return jobStats_ != null; - } - /** - * - * - *
-     * Job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - * - * @return The jobStats. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats getJobStats() { - return jobStats_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobStats.getDefaultInstance() - : jobStats_; - } - /** - * - * - *
-     * Job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder getJobStatsOrBuilder() { - return getJobStats(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, jobName_); - } - if (jobConfig_ != null) { - output.writeMessage(2, getJobConfig()); - } - if (jobStatus_ != null) { - output.writeMessage(3, getJobStatus()); - } - if (jobStats_ != null) { - output.writeMessage(4, getJobStats()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, jobName_); - } - if (jobConfig_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getJobConfig()); - } - if (jobStatus_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getJobStatus()); - } - if (jobStats_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getJobStats()); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.Job)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.Job other = - (com.google.cloud.audit.BigQueryAuditMetadata.Job) obj; - - if (!getJobName().equals(other.getJobName())) return false; - if (hasJobConfig() != other.hasJobConfig()) return false; - if (hasJobConfig()) { - if (!getJobConfig().equals(other.getJobConfig())) return false; - } - if (hasJobStatus() != other.hasJobStatus()) return false; - if (hasJobStatus()) { - if (!getJobStatus().equals(other.getJobStatus())) return false; - } - if (hasJobStats() != other.hasJobStats()) return false; - if (hasJobStats()) { - if (!getJobStats().equals(other.getJobStats())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getJobName().hashCode(); - if (hasJobConfig()) { - hash = (37 * hash) + JOB_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getJobConfig().hashCode(); - } - if (hasJobStatus()) { - hash = (37 * hash) + JOB_STATUS_FIELD_NUMBER; - hash = (53 * hash) + getJobStatus().hashCode(); - } - if (hasJobStats()) { - hash = (37 * hash) + JOB_STATS_FIELD_NUMBER; - hash = (53 * hash) + getJobStats().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloud.audit.BigQueryAuditMetadata.Job prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * BigQuery job.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Job} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.Job) - com.google.cloud.audit.BigQueryAuditMetadata.JobOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.Job.class, - com.google.cloud.audit.BigQueryAuditMetadata.Job.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.Job.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - jobName_ = ""; - - if (jobConfigBuilder_ == null) { - jobConfig_ = null; - } else { - jobConfig_ = null; - jobConfigBuilder_ = null; - } - if (jobStatusBuilder_ == null) { - jobStatus_ = null; - } else { - jobStatus_ = null; - jobStatusBuilder_ = null; - } - if (jobStatsBuilder_ == null) { - jobStats_ = null; - } else { - jobStats_ = null; - jobStatsBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Job getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Job build() { - com.google.cloud.audit.BigQueryAuditMetadata.Job result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Job buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.Job result = - new com.google.cloud.audit.BigQueryAuditMetadata.Job(this); - result.jobName_ = jobName_; - if (jobConfigBuilder_ == null) { - result.jobConfig_ = jobConfig_; - } else { - result.jobConfig_ = jobConfigBuilder_.build(); - } - if (jobStatusBuilder_ == null) { - result.jobStatus_ = jobStatus_; - } else { - result.jobStatus_ = jobStatusBuilder_.build(); - } - if (jobStatsBuilder_ == null) { - result.jobStats_ = jobStats_; - } else { - result.jobStats_ = jobStatsBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.Job) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.Job) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.Job other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.Job.getDefaultInstance()) - return this; - if (!other.getJobName().isEmpty()) { - jobName_ = other.jobName_; - onChanged(); - } - if (other.hasJobConfig()) { - mergeJobConfig(other.getJobConfig()); - } - if (other.hasJobStatus()) { - mergeJobStatus(other.getJobStatus()); - } - if (other.hasJobStats()) { - mergeJobStats(other.getJobStats()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.Job parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.Job) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object jobName_ = ""; - /** - * - * - *
-       * Job URI.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 1; - * - * @return The jobName. - */ - public java.lang.String getJobName() { - java.lang.Object ref = jobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - jobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Job URI.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 1; - * - * @return The bytes for jobName. - */ - public com.google.protobuf.ByteString getJobNameBytes() { - java.lang.Object ref = jobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - jobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Job URI.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 1; - * - * @param value The jobName to set. - * @return This builder for chaining. - */ - public Builder setJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - jobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Job URI.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 1; - * - * @return This builder for chaining. - */ - public Builder clearJobName() { - - jobName_ = getDefaultInstance().getJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * Job URI.
-       * Format: `projects/<project_id>/jobs/<job_id>`.
-       * 
- * - * string job_name = 1; - * - * @param value The bytes for jobName to set. - * @return This builder for chaining. - */ - public Builder setJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - jobName_ = value; - onChanged(); - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.JobConfig jobConfig_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder> - jobConfigBuilder_; - /** - * - * - *
-       * Job configuration.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - * - * @return Whether the jobConfig field is set. - */ - public boolean hasJobConfig() { - return jobConfigBuilder_ != null || jobConfig_ != null; - } - /** - * - * - *
-       * Job configuration.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - * - * @return The jobConfig. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getJobConfig() { - if (jobConfigBuilder_ == null) { - return jobConfig_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDefaultInstance() - : jobConfig_; - } else { - return jobConfigBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Job configuration.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - */ - public Builder setJobConfig(com.google.cloud.audit.BigQueryAuditMetadata.JobConfig value) { - if (jobConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - jobConfig_ = value; - onChanged(); - } else { - jobConfigBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Job configuration.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - */ - public Builder setJobConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder builderForValue) { - if (jobConfigBuilder_ == null) { - jobConfig_ = builderForValue.build(); - onChanged(); - } else { - jobConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Job configuration.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - */ - public Builder mergeJobConfig(com.google.cloud.audit.BigQueryAuditMetadata.JobConfig value) { - if (jobConfigBuilder_ == null) { - if (jobConfig_ != null) { - jobConfig_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.newBuilder(jobConfig_) - .mergeFrom(value) - .buildPartial(); - } else { - jobConfig_ = value; - } - onChanged(); - } else { - jobConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Job configuration.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - */ - public Builder clearJobConfig() { - if (jobConfigBuilder_ == null) { - jobConfig_ = null; - onChanged(); - } else { - jobConfig_ = null; - jobConfigBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Job configuration.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder getJobConfigBuilder() { - - onChanged(); - return getJobConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Job configuration.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder - getJobConfigOrBuilder() { - if (jobConfigBuilder_ != null) { - return jobConfigBuilder_.getMessageOrBuilder(); - } else { - return jobConfig_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDefaultInstance() - : jobConfig_; - } - } - /** - * - * - *
-       * Job configuration.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig job_config = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder> - getJobConfigFieldBuilder() { - if (jobConfigBuilder_ == null) { - jobConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder>( - getJobConfig(), getParentForChildren(), isClean()); - jobConfig_ = null; - } - return jobConfigBuilder_; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.JobStatus jobStatus_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder> - jobStatusBuilder_; - /** - * - * - *
-       * Job status.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - * - * @return Whether the jobStatus field is set. - */ - public boolean hasJobStatus() { - return jobStatusBuilder_ != null || jobStatus_ != null; - } - /** - * - * - *
-       * Job status.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - * - * @return The jobStatus. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getJobStatus() { - if (jobStatusBuilder_ == null) { - return jobStatus_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.getDefaultInstance() - : jobStatus_; - } else { - return jobStatusBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Job status.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - */ - public Builder setJobStatus(com.google.cloud.audit.BigQueryAuditMetadata.JobStatus value) { - if (jobStatusBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - jobStatus_ = value; - onChanged(); - } else { - jobStatusBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Job status.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - */ - public Builder setJobStatus( - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder builderForValue) { - if (jobStatusBuilder_ == null) { - jobStatus_ = builderForValue.build(); - onChanged(); - } else { - jobStatusBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Job status.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - */ - public Builder mergeJobStatus(com.google.cloud.audit.BigQueryAuditMetadata.JobStatus value) { - if (jobStatusBuilder_ == null) { - if (jobStatus_ != null) { - jobStatus_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.newBuilder(jobStatus_) - .mergeFrom(value) - .buildPartial(); - } else { - jobStatus_ = value; - } - onChanged(); - } else { - jobStatusBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Job status.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - */ - public Builder clearJobStatus() { - if (jobStatusBuilder_ == null) { - jobStatus_ = null; - onChanged(); - } else { - jobStatus_ = null; - jobStatusBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Job status.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder getJobStatusBuilder() { - - onChanged(); - return getJobStatusFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Job status.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder - getJobStatusOrBuilder() { - if (jobStatusBuilder_ != null) { - return jobStatusBuilder_.getMessageOrBuilder(); - } else { - return jobStatus_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.getDefaultInstance() - : jobStatus_; - } - } - /** - * - * - *
-       * Job status.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStatus job_status = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder> - getJobStatusFieldBuilder() { - if (jobStatusBuilder_ == null) { - jobStatusBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder>( - getJobStatus(), getParentForChildren(), isClean()); - jobStatus_ = null; - } - return jobStatusBuilder_; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.JobStats jobStats_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder> - jobStatsBuilder_; - /** - * - * - *
-       * Job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - * - * @return Whether the jobStats field is set. - */ - public boolean hasJobStats() { - return jobStatsBuilder_ != null || jobStats_ != null; - } - /** - * - * - *
-       * Job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - * - * @return The jobStats. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats getJobStats() { - if (jobStatsBuilder_ == null) { - return jobStats_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobStats.getDefaultInstance() - : jobStats_; - } else { - return jobStatsBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - */ - public Builder setJobStats(com.google.cloud.audit.BigQueryAuditMetadata.JobStats value) { - if (jobStatsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - jobStats_ = value; - onChanged(); - } else { - jobStatsBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - */ - public Builder setJobStats( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder builderForValue) { - if (jobStatsBuilder_ == null) { - jobStats_ = builderForValue.build(); - onChanged(); - } else { - jobStatsBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - */ - public Builder mergeJobStats(com.google.cloud.audit.BigQueryAuditMetadata.JobStats value) { - if (jobStatsBuilder_ == null) { - if (jobStats_ != null) { - jobStats_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.newBuilder(jobStats_) - .mergeFrom(value) - .buildPartial(); - } else { - jobStats_ = value; - } - onChanged(); - } else { - jobStatsBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - */ - public Builder clearJobStats() { - if (jobStatsBuilder_ == null) { - jobStats_ = null; - onChanged(); - } else { - jobStats_ = null; - jobStatsBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder getJobStatsBuilder() { - - onChanged(); - return getJobStatsFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder getJobStatsOrBuilder() { - if (jobStatsBuilder_ != null) { - return jobStatsBuilder_.getMessageOrBuilder(); - } else { - return jobStats_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobStats.getDefaultInstance() - : jobStats_; - } - } - /** - * - * - *
-       * Job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats job_stats = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder> - getJobStatsFieldBuilder() { - if (jobStatsBuilder_ == null) { - jobStatsBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder>( - getJobStats(), getParentForChildren(), isClean()); - jobStats_ = null; - } - return jobStatsBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.Job) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.Job) - private static final com.google.cloud.audit.BigQueryAuditMetadata.Job DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.Job(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Job getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Job parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Job(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Job getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface JobConfigOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Job type.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; - * - * @return The enum numeric value on the wire for type. - */ - int getTypeValue(); - /** - * - * - *
-     * Job type.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; - * - * @return The type. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type getType(); - - /** - * - * - *
-     * Query job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - * - * @return Whether the queryConfig field is set. - */ - boolean hasQueryConfig(); - /** - * - * - *
-     * Query job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - * - * @return The queryConfig. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query getQueryConfig(); - /** - * - * - *
-     * Query job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder getQueryConfigOrBuilder(); - - /** - * - * - *
-     * Load job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - * - * @return Whether the loadConfig field is set. - */ - boolean hasLoadConfig(); - /** - * - * - *
-     * Load job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - * - * @return The loadConfig. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load getLoadConfig(); - /** - * - * - *
-     * Load job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder getLoadConfigOrBuilder(); - - /** - * - * - *
-     * Extract job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - * @return Whether the extractConfig field is set. - */ - boolean hasExtractConfig(); - /** - * - * - *
-     * Extract job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - * @return The extractConfig. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract getExtractConfig(); - /** - * - * - *
-     * Extract job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder - getExtractConfigOrBuilder(); - - /** - * - * - *
-     * TableCopy job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - * - * @return Whether the tableCopyConfig field is set. - */ - boolean hasTableCopyConfig(); - /** - * - * - *
-     * TableCopy job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - * - * @return The tableCopyConfig. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy getTableCopyConfig(); - /** - * - * - *
-     * TableCopy job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder - getTableCopyConfigOrBuilder(); - - /** - * - * - *
-     * Labels provided for the job.
-     * 
- * - * map<string, string> labels = 6; - */ - int getLabelsCount(); - /** - * - * - *
-     * Labels provided for the job.
-     * 
- * - * map<string, string> labels = 6; - */ - boolean containsLabels(java.lang.String key); - /** Use {@link #getLabelsMap()} instead. */ - @java.lang.Deprecated - java.util.Map getLabels(); - /** - * - * - *
-     * Labels provided for the job.
-     * 
- * - * map<string, string> labels = 6; - */ - java.util.Map getLabelsMap(); - /** - * - * - *
-     * Labels provided for the job.
-     * 
- * - * map<string, string> labels = 6; - */ - java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue); - /** - * - * - *
-     * Labels provided for the job.
-     * 
- * - * map<string, string> labels = 6; - */ - java.lang.String getLabelsOrThrow(java.lang.String key); - - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ConfigCase getConfigCase(); - } - /** - * - * - *
-   * Job configuration.
-   * See the [Jobs](https://cloud.google.com/bigquery/docs/reference/v2/jobs)
-   * API resource for more details on individual fields.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig} - */ - public static final class JobConfig extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig) - JobConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use JobConfig.newBuilder() to construct. - private JobConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private JobConfig() { - type_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new JobConfig(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private JobConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - type_ = rawValue; - break; - } - case 18: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder subBuilder = - null; - if (configCase_ == 2) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_) - .toBuilder(); - } - config_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_); - config_ = subBuilder.buildPartial(); - } - configCase_ = 2; - break; - } - case 26: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder subBuilder = - null; - if (configCase_ == 3) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_) - .toBuilder(); - } - config_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_); - config_ = subBuilder.buildPartial(); - } - configCase_ = 3; - break; - } - case 34: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder subBuilder = - null; - if (configCase_ == 4) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_) - .toBuilder(); - } - config_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_); - config_ = subBuilder.buildPartial(); - } - configCase_ = 4; - break; - } - case 42: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder - subBuilder = null; - if (configCase_ == 5) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_) - .toBuilder(); - } - config_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_); - config_ = subBuilder.buildPartial(); - } - configCase_ = 5; - break; - } - case 50: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - labels_ = - com.google.protobuf.MapField.newMapField( - LabelsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry labels__ = - input.readMessage( - LabelsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - labels_.getMutableMap().put(labels__.getKey(), labels__.getValue()); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 6: - return internalGetLabels(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder.class); - } - - /** - * - * - *
-     * Job type.
-     * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type} - */ - public enum Type implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Unknown.
-       * 
- * - * TYPE_UNSPECIFIED = 0; - */ - TYPE_UNSPECIFIED(0), - /** - * - * - *
-       * Query job.
-       * 
- * - * QUERY = 1; - */ - QUERY(1), - /** - * - * - *
-       * Table copy job.
-       * 
- * - * COPY = 2; - */ - COPY(2), - /** - * - * - *
-       * Export (extract) job.
-       * 
- * - * EXPORT = 3; - */ - EXPORT(3), - /** - * - * - *
-       * Import (load) job.
-       * 
- * - * IMPORT = 4; - */ - IMPORT(4), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Unknown.
-       * 
- * - * TYPE_UNSPECIFIED = 0; - */ - public static final int TYPE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Query job.
-       * 
- * - * QUERY = 1; - */ - public static final int QUERY_VALUE = 1; - /** - * - * - *
-       * Table copy job.
-       * 
- * - * COPY = 2; - */ - public static final int COPY_VALUE = 2; - /** - * - * - *
-       * Export (extract) job.
-       * 
- * - * EXPORT = 3; - */ - public static final int EXPORT_VALUE = 3; - /** - * - * - *
-       * Import (load) job.
-       * 
- * - * IMPORT = 4; - */ - public static final int IMPORT_VALUE = 4; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Type 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 Type forNumber(int value) { - switch (value) { - case 0: - return TYPE_UNSPECIFIED; - case 1: - return QUERY; - case 2: - return COPY; - case 3: - return EXPORT; - case 4: - return IMPORT; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Type findValueByNumber(int number) { - return Type.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Type[] VALUES = values(); - - public static Type valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Type(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type) - } - - public interface QueryOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-       * The SQL query to run. Truncated if exceeds 50K.
-       * 
- * - * string query = 1; - * - * @return The query. - */ - java.lang.String getQuery(); - /** - * - * - *
-       * The SQL query to run. Truncated if exceeds 50K.
-       * 
- * - * string query = 1; - * - * @return The bytes for query. - */ - com.google.protobuf.ByteString getQueryBytes(); - - /** - * - * - *
-       * True if the query field was truncated.
-       * 
- * - * bool query_truncated = 10; - * - * @return The queryTruncated. - */ - boolean getQueryTruncated(); - - /** - * - * - *
-       * The destination table for the query results.
-       * 
- * - * string destination_table = 2; - * - * @return The destinationTable. - */ - java.lang.String getDestinationTable(); - /** - * - * - *
-       * The destination table for the query results.
-       * 
- * - * string destination_table = 2; - * - * @return The bytes for destinationTable. - */ - com.google.protobuf.ByteString getDestinationTableBytes(); - - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The enum numeric value on the wire for createDisposition. - */ - int getCreateDispositionValue(); - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The createDisposition. - */ - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition(); - - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The enum numeric value on the wire for writeDisposition. - */ - int getWriteDispositionValue(); - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The writeDisposition. - */ - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition(); - - /** - * - * - *
-       * Default dataset for the query.
-       * 
- * - * string default_dataset = 5; - * - * @return The defaultDataset. - */ - java.lang.String getDefaultDataset(); - /** - * - * - *
-       * Default dataset for the query.
-       * 
- * - * string default_dataset = 5; - * - * @return The bytes for defaultDataset. - */ - com.google.protobuf.ByteString getDefaultDatasetBytes(); - - /** - * - * - *
-       * External data sources used in the query.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - java.util.List - getTableDefinitionsList(); - /** - * - * - *
-       * External data sources used in the query.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition getTableDefinitions(int index); - /** - * - * - *
-       * External data sources used in the query.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - int getTableDefinitionsCount(); - /** - * - * - *
-       * External data sources used in the query.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - java.util.List< - ? extends com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder> - getTableDefinitionsOrBuilderList(); - /** - * - * - *
-       * External data sources used in the query.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder - getTableDefinitionsOrBuilder(int index); - - /** - * - * - *
-       * Priority given to the query.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; - * - * - * @return The enum numeric value on the wire for priority. - */ - int getPriorityValue(); - /** - * - * - *
-       * Priority given to the query.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; - * - * - * @return The priority. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority getPriority(); - - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - * - * @return Whether the destinationTableEncryption field is set. - */ - boolean hasDestinationTableEncryption(); - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - * - * @return The destinationTableEncryption. - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDestinationTableEncryption(); - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDestinationTableEncryptionOrBuilder(); - - /** - * - * - *
-       * Type of the query.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; - * - * - * @return The enum numeric value on the wire for statementType. - */ - int getStatementTypeValue(); - /** - * - * - *
-       * Type of the query.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; - * - * - * @return The statementType. - */ - com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType getStatementType(); - } - /** - * - * - *
-     * Query job configuration.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query} - */ - public static final class Query extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) - QueryOrBuilder { - private static final long serialVersionUID = 0L; - // Use Query.newBuilder() to construct. - private Query(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Query() { - query_ = ""; - destinationTable_ = ""; - createDisposition_ = 0; - writeDisposition_ = 0; - defaultDataset_ = ""; - tableDefinitions_ = java.util.Collections.emptyList(); - priority_ = 0; - statementType_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Query(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Query( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - query_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - destinationTable_ = s; - break; - } - case 24: - { - int rawValue = input.readEnum(); - - createDisposition_ = rawValue; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - writeDisposition_ = rawValue; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - defaultDataset_ = s; - break; - } - case 50: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - tableDefinitions_ = - new java.util.ArrayList< - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition>(); - mutable_bitField0_ |= 0x00000001; - } - tableDefinitions_.add( - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.parser(), - extensionRegistry)); - break; - } - case 56: - { - int rawValue = input.readEnum(); - - priority_ = rawValue; - break; - } - case 66: - { - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = - null; - if (destinationTableEncryption_ != null) { - subBuilder = destinationTableEncryption_.toBuilder(); - } - destinationTableEncryption_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(destinationTableEncryption_); - destinationTableEncryption_ = subBuilder.buildPartial(); - } - - break; - } - case 72: - { - int rawValue = input.readEnum(); - - statementType_ = rawValue; - break; - } - case 80: - { - queryTruncated_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - tableDefinitions_ = java.util.Collections.unmodifiableList(tableDefinitions_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder.class); - } - - /** - * - * - *
-       * Priority given to the query.
-       * 
- * - * Protobuf enum {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority} - */ - public enum Priority implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-         * Unknown.
-         * 
- * - * PRIORITY_UNSPECIFIED = 0; - */ - PRIORITY_UNSPECIFIED(0), - /** - * - * - *
-         * Interactive query.
-         * 
- * - * QUERY_INTERACTIVE = 1; - */ - QUERY_INTERACTIVE(1), - /** - * - * - *
-         * Batch query.
-         * 
- * - * QUERY_BATCH = 2; - */ - QUERY_BATCH(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-         * Unknown.
-         * 
- * - * PRIORITY_UNSPECIFIED = 0; - */ - public static final int PRIORITY_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-         * Interactive query.
-         * 
- * - * QUERY_INTERACTIVE = 1; - */ - public static final int QUERY_INTERACTIVE_VALUE = 1; - /** - * - * - *
-         * Batch query.
-         * 
- * - * QUERY_BATCH = 2; - */ - public static final int QUERY_BATCH_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Priority valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static Priority forNumber(int value) { - switch (value) { - case 0: - return PRIORITY_UNSPECIFIED; - case 1: - return QUERY_INTERACTIVE; - case 2: - return QUERY_BATCH; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Priority findValueByNumber(int number) { - return Priority.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final Priority[] VALUES = values(); - - public static Priority valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException( - "EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Priority(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority) - } - - public static final int QUERY_FIELD_NUMBER = 1; - private volatile java.lang.Object query_; - /** - * - * - *
-       * The SQL query to run. Truncated if exceeds 50K.
-       * 
- * - * string query = 1; - * - * @return The query. - */ - @java.lang.Override - public java.lang.String getQuery() { - java.lang.Object ref = query_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - query_ = s; - return s; - } - } - /** - * - * - *
-       * The SQL query to run. Truncated if exceeds 50K.
-       * 
- * - * string query = 1; - * - * @return The bytes for query. - */ - @java.lang.Override - public com.google.protobuf.ByteString getQueryBytes() { - java.lang.Object ref = query_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - query_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int QUERY_TRUNCATED_FIELD_NUMBER = 10; - private boolean queryTruncated_; - /** - * - * - *
-       * True if the query field was truncated.
-       * 
- * - * bool query_truncated = 10; - * - * @return The queryTruncated. - */ - @java.lang.Override - public boolean getQueryTruncated() { - return queryTruncated_; - } - - public static final int DESTINATION_TABLE_FIELD_NUMBER = 2; - private volatile java.lang.Object destinationTable_; - /** - * - * - *
-       * The destination table for the query results.
-       * 
- * - * string destination_table = 2; - * - * @return The destinationTable. - */ - @java.lang.Override - public java.lang.String getDestinationTable() { - java.lang.Object ref = destinationTable_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - destinationTable_ = s; - return s; - } - } - /** - * - * - *
-       * The destination table for the query results.
-       * 
- * - * string destination_table = 2; - * - * @return The bytes for destinationTable. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDestinationTableBytes() { - java.lang.Object ref = destinationTable_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - destinationTable_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATE_DISPOSITION_FIELD_NUMBER = 3; - private int createDisposition_; - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The enum numeric value on the wire for createDisposition. - */ - @java.lang.Override - public int getCreateDispositionValue() { - return createDisposition_; - } - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The createDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( - createDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED - : result; - } - - public static final int WRITE_DISPOSITION_FIELD_NUMBER = 4; - private int writeDisposition_; - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The enum numeric value on the wire for writeDisposition. - */ - @java.lang.Override - public int getWriteDispositionValue() { - return writeDisposition_; - } - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The writeDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( - writeDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED - : result; - } - - public static final int DEFAULT_DATASET_FIELD_NUMBER = 5; - private volatile java.lang.Object defaultDataset_; - /** - * - * - *
-       * Default dataset for the query.
-       * 
- * - * string default_dataset = 5; - * - * @return The defaultDataset. - */ - @java.lang.Override - public java.lang.String getDefaultDataset() { - java.lang.Object ref = defaultDataset_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - defaultDataset_ = s; - return s; - } - } - /** - * - * - *
-       * Default dataset for the query.
-       * 
- * - * string default_dataset = 5; - * - * @return The bytes for defaultDataset. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDefaultDatasetBytes() { - java.lang.Object ref = defaultDataset_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - defaultDataset_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TABLE_DEFINITIONS_FIELD_NUMBER = 6; - private java.util.List - tableDefinitions_; - /** - * - * - *
-       * External data sources used in the query.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - @java.lang.Override - public java.util.List - getTableDefinitionsList() { - return tableDefinitions_; - } - /** - * - * - *
-       * External data sources used in the query.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - @java.lang.Override - public java.util.List< - ? extends com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder> - getTableDefinitionsOrBuilderList() { - return tableDefinitions_; - } - /** - * - * - *
-       * External data sources used in the query.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - @java.lang.Override - public int getTableDefinitionsCount() { - return tableDefinitions_.size(); - } - /** - * - * - *
-       * External data sources used in the query.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition getTableDefinitions( - int index) { - return tableDefinitions_.get(index); - } - /** - * - * - *
-       * External data sources used in the query.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder - getTableDefinitionsOrBuilder(int index) { - return tableDefinitions_.get(index); - } - - public static final int PRIORITY_FIELD_NUMBER = 7; - private int priority_; - /** - * - * - *
-       * Priority given to the query.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; - * - * - * @return The enum numeric value on the wire for priority. - */ - @java.lang.Override - public int getPriorityValue() { - return priority_; - } - /** - * - * - *
-       * Priority given to the query.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; - * - * - * @return The priority. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority getPriority() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority result = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority.valueOf( - priority_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority.UNRECOGNIZED - : result; - } - - public static final int DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER = 8; - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - destinationTableEncryption_; - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - * - * @return Whether the destinationTableEncryption field is set. - */ - @java.lang.Override - public boolean hasDestinationTableEncryption() { - return destinationTableEncryption_ != null; - } - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - * - * @return The destinationTableEncryption. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - getDestinationTableEncryption() { - return destinationTableEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : destinationTableEncryption_; - } - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDestinationTableEncryptionOrBuilder() { - return getDestinationTableEncryption(); - } - - public static final int STATEMENT_TYPE_FIELD_NUMBER = 9; - private int statementType_; - /** - * - * - *
-       * Type of the query.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; - * - * - * @return The enum numeric value on the wire for statementType. - */ - @java.lang.Override - public int getStatementTypeValue() { - return statementType_; - } - /** - * - * - *
-       * Type of the query.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; - * - * - * @return The statementType. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType getStatementType() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType result = - com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType.valueOf(statementType_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType.UNRECOGNIZED - : result; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getQueryBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, query_); - } - if (!getDestinationTableBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, destinationTable_); - } - if (createDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition - .CREATE_DISPOSITION_UNSPECIFIED - .getNumber()) { - output.writeEnum(3, createDisposition_); - } - if (writeDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition - .WRITE_DISPOSITION_UNSPECIFIED - .getNumber()) { - output.writeEnum(4, writeDisposition_); - } - if (!getDefaultDatasetBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, defaultDataset_); - } - for (int i = 0; i < tableDefinitions_.size(); i++) { - output.writeMessage(6, tableDefinitions_.get(i)); - } - if (priority_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority - .PRIORITY_UNSPECIFIED - .getNumber()) { - output.writeEnum(7, priority_); - } - if (destinationTableEncryption_ != null) { - output.writeMessage(8, getDestinationTableEncryption()); - } - if (statementType_ - != com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType - .QUERY_STATEMENT_TYPE_UNSPECIFIED - .getNumber()) { - output.writeEnum(9, statementType_); - } - if (queryTruncated_ != false) { - output.writeBool(10, queryTruncated_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getQueryBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, query_); - } - if (!getDestinationTableBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, destinationTable_); - } - if (createDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition - .CREATE_DISPOSITION_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, createDisposition_); - } - if (writeDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition - .WRITE_DISPOSITION_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, writeDisposition_); - } - if (!getDefaultDatasetBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, defaultDataset_); - } - for (int i = 0; i < tableDefinitions_.size(); i++) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize(6, tableDefinitions_.get(i)); - } - if (priority_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority - .PRIORITY_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, priority_); - } - if (destinationTableEncryption_ != null) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 8, getDestinationTableEncryption()); - } - if (statementType_ - != com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType - .QUERY_STATEMENT_TYPE_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(9, statementType_); - } - if (queryTruncated_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(10, queryTruncated_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) obj; - - if (!getQuery().equals(other.getQuery())) return false; - if (getQueryTruncated() != other.getQueryTruncated()) return false; - if (!getDestinationTable().equals(other.getDestinationTable())) return false; - if (createDisposition_ != other.createDisposition_) return false; - if (writeDisposition_ != other.writeDisposition_) return false; - if (!getDefaultDataset().equals(other.getDefaultDataset())) return false; - if (!getTableDefinitionsList().equals(other.getTableDefinitionsList())) return false; - if (priority_ != other.priority_) return false; - if (hasDestinationTableEncryption() != other.hasDestinationTableEncryption()) return false; - if (hasDestinationTableEncryption()) { - if (!getDestinationTableEncryption().equals(other.getDestinationTableEncryption())) - return false; - } - if (statementType_ != other.statementType_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + QUERY_FIELD_NUMBER; - hash = (53 * hash) + getQuery().hashCode(); - hash = (37 * hash) + QUERY_TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getQueryTruncated()); - hash = (37 * hash) + DESTINATION_TABLE_FIELD_NUMBER; - hash = (53 * hash) + getDestinationTable().hashCode(); - hash = (37 * hash) + CREATE_DISPOSITION_FIELD_NUMBER; - hash = (53 * hash) + createDisposition_; - hash = (37 * hash) + WRITE_DISPOSITION_FIELD_NUMBER; - hash = (53 * hash) + writeDisposition_; - hash = (37 * hash) + DEFAULT_DATASET_FIELD_NUMBER; - hash = (53 * hash) + getDefaultDataset().hashCode(); - if (getTableDefinitionsCount() > 0) { - hash = (37 * hash) + TABLE_DEFINITIONS_FIELD_NUMBER; - hash = (53 * hash) + getTableDefinitionsList().hashCode(); - } - hash = (37 * hash) + PRIORITY_FIELD_NUMBER; - hash = (53 * hash) + priority_; - if (hasDestinationTableEncryption()) { - hash = (37 * hash) + DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER; - hash = (53 * hash) + getDestinationTableEncryption().hashCode(); - } - hash = (37 * hash) + STATEMENT_TYPE_FIELD_NUMBER; - hash = (53 * hash) + statementType_; - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-       * Query job configuration.
-       * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getTableDefinitionsFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - query_ = ""; - - queryTruncated_ = false; - - destinationTable_ = ""; - - createDisposition_ = 0; - - writeDisposition_ = 0; - - defaultDataset_ = ""; - - if (tableDefinitionsBuilder_ == null) { - tableDefinitions_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - tableDefinitionsBuilder_.clear(); - } - priority_ = 0; - - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryption_ = null; - } else { - destinationTableEncryption_ = null; - destinationTableEncryptionBuilder_ = null; - } - statementType_ = 0; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query(this); - int from_bitField0_ = bitField0_; - result.query_ = query_; - result.queryTruncated_ = queryTruncated_; - result.destinationTable_ = destinationTable_; - result.createDisposition_ = createDisposition_; - result.writeDisposition_ = writeDisposition_; - result.defaultDataset_ = defaultDataset_; - if (tableDefinitionsBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - tableDefinitions_ = java.util.Collections.unmodifiableList(tableDefinitions_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.tableDefinitions_ = tableDefinitions_; - } else { - result.tableDefinitions_ = tableDefinitionsBuilder_.build(); - } - result.priority_ = priority_; - if (destinationTableEncryptionBuilder_ == null) { - result.destinationTableEncryption_ = destinationTableEncryption_; - } else { - result.destinationTableEncryption_ = destinationTableEncryptionBuilder_.build(); - } - result.statementType_ = statementType_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance()) - return this; - if (!other.getQuery().isEmpty()) { - query_ = other.query_; - onChanged(); - } - if (other.getQueryTruncated() != false) { - setQueryTruncated(other.getQueryTruncated()); - } - if (!other.getDestinationTable().isEmpty()) { - destinationTable_ = other.destinationTable_; - onChanged(); - } - if (other.createDisposition_ != 0) { - setCreateDispositionValue(other.getCreateDispositionValue()); - } - if (other.writeDisposition_ != 0) { - setWriteDispositionValue(other.getWriteDispositionValue()); - } - if (!other.getDefaultDataset().isEmpty()) { - defaultDataset_ = other.defaultDataset_; - onChanged(); - } - if (tableDefinitionsBuilder_ == null) { - if (!other.tableDefinitions_.isEmpty()) { - if (tableDefinitions_.isEmpty()) { - tableDefinitions_ = other.tableDefinitions_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureTableDefinitionsIsMutable(); - tableDefinitions_.addAll(other.tableDefinitions_); - } - onChanged(); - } - } else { - if (!other.tableDefinitions_.isEmpty()) { - if (tableDefinitionsBuilder_.isEmpty()) { - tableDefinitionsBuilder_.dispose(); - tableDefinitionsBuilder_ = null; - tableDefinitions_ = other.tableDefinitions_; - bitField0_ = (bitField0_ & ~0x00000001); - tableDefinitionsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getTableDefinitionsFieldBuilder() - : null; - } else { - tableDefinitionsBuilder_.addAllMessages(other.tableDefinitions_); - } - } - } - if (other.priority_ != 0) { - setPriorityValue(other.getPriorityValue()); - } - if (other.hasDestinationTableEncryption()) { - mergeDestinationTableEncryption(other.getDestinationTableEncryption()); - } - if (other.statementType_ != 0) { - setStatementTypeValue(other.getStatementTypeValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object query_ = ""; - /** - * - * - *
-         * The SQL query to run. Truncated if exceeds 50K.
-         * 
- * - * string query = 1; - * - * @return The query. - */ - public java.lang.String getQuery() { - java.lang.Object ref = query_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - query_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-         * The SQL query to run. Truncated if exceeds 50K.
-         * 
- * - * string query = 1; - * - * @return The bytes for query. - */ - public com.google.protobuf.ByteString getQueryBytes() { - java.lang.Object ref = query_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - query_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-         * The SQL query to run. Truncated if exceeds 50K.
-         * 
- * - * string query = 1; - * - * @param value The query to set. - * @return This builder for chaining. - */ - public Builder setQuery(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - query_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * The SQL query to run. Truncated if exceeds 50K.
-         * 
- * - * string query = 1; - * - * @return This builder for chaining. - */ - public Builder clearQuery() { - - query_ = getDefaultInstance().getQuery(); - onChanged(); - return this; - } - /** - * - * - *
-         * The SQL query to run. Truncated if exceeds 50K.
-         * 
- * - * string query = 1; - * - * @param value The bytes for query to set. - * @return This builder for chaining. - */ - public Builder setQueryBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - query_ = value; - onChanged(); - return this; - } - - private boolean queryTruncated_; - /** - * - * - *
-         * True if the query field was truncated.
-         * 
- * - * bool query_truncated = 10; - * - * @return The queryTruncated. - */ - @java.lang.Override - public boolean getQueryTruncated() { - return queryTruncated_; - } - /** - * - * - *
-         * True if the query field was truncated.
-         * 
- * - * bool query_truncated = 10; - * - * @param value The queryTruncated to set. - * @return This builder for chaining. - */ - public Builder setQueryTruncated(boolean value) { - - queryTruncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * True if the query field was truncated.
-         * 
- * - * bool query_truncated = 10; - * - * @return This builder for chaining. - */ - public Builder clearQueryTruncated() { - - queryTruncated_ = false; - onChanged(); - return this; - } - - private java.lang.Object destinationTable_ = ""; - /** - * - * - *
-         * The destination table for the query results.
-         * 
- * - * string destination_table = 2; - * - * @return The destinationTable. - */ - public java.lang.String getDestinationTable() { - java.lang.Object ref = destinationTable_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - destinationTable_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-         * The destination table for the query results.
-         * 
- * - * string destination_table = 2; - * - * @return The bytes for destinationTable. - */ - public com.google.protobuf.ByteString getDestinationTableBytes() { - java.lang.Object ref = destinationTable_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - destinationTable_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-         * The destination table for the query results.
-         * 
- * - * string destination_table = 2; - * - * @param value The destinationTable to set. - * @return This builder for chaining. - */ - public Builder setDestinationTable(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - destinationTable_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * The destination table for the query results.
-         * 
- * - * string destination_table = 2; - * - * @return This builder for chaining. - */ - public Builder clearDestinationTable() { - - destinationTable_ = getDefaultInstance().getDestinationTable(); - onChanged(); - return this; - } - /** - * - * - *
-         * The destination table for the query results.
-         * 
- * - * string destination_table = 2; - * - * @param value The bytes for destinationTable to set. - * @return This builder for chaining. - */ - public Builder setDestinationTableBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - destinationTable_ = value; - onChanged(); - return this; - } - - private int createDisposition_ = 0; - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The enum numeric value on the wire for createDisposition. - */ - @java.lang.Override - public int getCreateDispositionValue() { - return createDisposition_; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @param value The enum numeric value on the wire for createDisposition to set. - * @return This builder for chaining. - */ - public Builder setCreateDispositionValue(int value) { - - createDisposition_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The createDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition - getCreateDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( - createDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED - : result; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @param value The createDisposition to set. - * @return This builder for chaining. - */ - public Builder setCreateDisposition( - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition value) { - if (value == null) { - throw new NullPointerException(); - } - - createDisposition_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return This builder for chaining. - */ - public Builder clearCreateDisposition() { - - createDisposition_ = 0; - onChanged(); - return this; - } - - private int writeDisposition_ = 0; - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The enum numeric value on the wire for writeDisposition. - */ - @java.lang.Override - public int getWriteDispositionValue() { - return writeDisposition_; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @param value The enum numeric value on the wire for writeDisposition to set. - * @return This builder for chaining. - */ - public Builder setWriteDispositionValue(int value) { - - writeDisposition_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The writeDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( - writeDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED - : result; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @param value The writeDisposition to set. - * @return This builder for chaining. - */ - public Builder setWriteDisposition( - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition value) { - if (value == null) { - throw new NullPointerException(); - } - - writeDisposition_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return This builder for chaining. - */ - public Builder clearWriteDisposition() { - - writeDisposition_ = 0; - onChanged(); - return this; - } - - private java.lang.Object defaultDataset_ = ""; - /** - * - * - *
-         * Default dataset for the query.
-         * 
- * - * string default_dataset = 5; - * - * @return The defaultDataset. - */ - public java.lang.String getDefaultDataset() { - java.lang.Object ref = defaultDataset_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - defaultDataset_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-         * Default dataset for the query.
-         * 
- * - * string default_dataset = 5; - * - * @return The bytes for defaultDataset. - */ - public com.google.protobuf.ByteString getDefaultDatasetBytes() { - java.lang.Object ref = defaultDataset_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - defaultDataset_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-         * Default dataset for the query.
-         * 
- * - * string default_dataset = 5; - * - * @param value The defaultDataset to set. - * @return This builder for chaining. - */ - public Builder setDefaultDataset(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - defaultDataset_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Default dataset for the query.
-         * 
- * - * string default_dataset = 5; - * - * @return This builder for chaining. - */ - public Builder clearDefaultDataset() { - - defaultDataset_ = getDefaultInstance().getDefaultDataset(); - onChanged(); - return this; - } - /** - * - * - *
-         * Default dataset for the query.
-         * 
- * - * string default_dataset = 5; - * - * @param value The bytes for defaultDataset to set. - * @return This builder for chaining. - */ - public Builder setDefaultDatasetBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - defaultDataset_ = value; - onChanged(); - return this; - } - - private java.util.List - tableDefinitions_ = java.util.Collections.emptyList(); - - private void ensureTableDefinitionsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - tableDefinitions_ = - new java.util.ArrayList< - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition>( - tableDefinitions_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder> - tableDefinitionsBuilder_; - - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public java.util.List - getTableDefinitionsList() { - if (tableDefinitionsBuilder_ == null) { - return java.util.Collections.unmodifiableList(tableDefinitions_); - } else { - return tableDefinitionsBuilder_.getMessageList(); - } - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public int getTableDefinitionsCount() { - if (tableDefinitionsBuilder_ == null) { - return tableDefinitions_.size(); - } else { - return tableDefinitionsBuilder_.getCount(); - } - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition getTableDefinitions( - int index) { - if (tableDefinitionsBuilder_ == null) { - return tableDefinitions_.get(index); - } else { - return tableDefinitionsBuilder_.getMessage(index); - } - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public Builder setTableDefinitions( - int index, com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition value) { - if (tableDefinitionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTableDefinitionsIsMutable(); - tableDefinitions_.set(index, value); - onChanged(); - } else { - tableDefinitionsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public Builder setTableDefinitions( - int index, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder builderForValue) { - if (tableDefinitionsBuilder_ == null) { - ensureTableDefinitionsIsMutable(); - tableDefinitions_.set(index, builderForValue.build()); - onChanged(); - } else { - tableDefinitionsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public Builder addTableDefinitions( - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition value) { - if (tableDefinitionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTableDefinitionsIsMutable(); - tableDefinitions_.add(value); - onChanged(); - } else { - tableDefinitionsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public Builder addTableDefinitions( - int index, com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition value) { - if (tableDefinitionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTableDefinitionsIsMutable(); - tableDefinitions_.add(index, value); - onChanged(); - } else { - tableDefinitionsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public Builder addTableDefinitions( - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder builderForValue) { - if (tableDefinitionsBuilder_ == null) { - ensureTableDefinitionsIsMutable(); - tableDefinitions_.add(builderForValue.build()); - onChanged(); - } else { - tableDefinitionsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public Builder addTableDefinitions( - int index, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder builderForValue) { - if (tableDefinitionsBuilder_ == null) { - ensureTableDefinitionsIsMutable(); - tableDefinitions_.add(index, builderForValue.build()); - onChanged(); - } else { - tableDefinitionsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public Builder addAllTableDefinitions( - java.lang.Iterable< - ? extends com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition> - values) { - if (tableDefinitionsBuilder_ == null) { - ensureTableDefinitionsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, tableDefinitions_); - onChanged(); - } else { - tableDefinitionsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public Builder clearTableDefinitions() { - if (tableDefinitionsBuilder_ == null) { - tableDefinitions_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - tableDefinitionsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public Builder removeTableDefinitions(int index) { - if (tableDefinitionsBuilder_ == null) { - ensureTableDefinitionsIsMutable(); - tableDefinitions_.remove(index); - onChanged(); - } else { - tableDefinitionsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder - getTableDefinitionsBuilder(int index) { - return getTableDefinitionsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder - getTableDefinitionsOrBuilder(int index) { - if (tableDefinitionsBuilder_ == null) { - return tableDefinitions_.get(index); - } else { - return tableDefinitionsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public java.util.List< - ? extends com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder> - getTableDefinitionsOrBuilderList() { - if (tableDefinitionsBuilder_ != null) { - return tableDefinitionsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(tableDefinitions_); - } - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder - addTableDefinitionsBuilder() { - return getTableDefinitionsFieldBuilder() - .addBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition - .getDefaultInstance()); - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder - addTableDefinitionsBuilder(int index) { - return getTableDefinitionsFieldBuilder() - .addBuilder( - index, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition - .getDefaultInstance()); - } - /** - * - * - *
-         * External data sources used in the query.
-         * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.TableDefinition table_definitions = 6; - * - */ - public java.util.List - getTableDefinitionsBuilderList() { - return getTableDefinitionsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder> - getTableDefinitionsFieldBuilder() { - if (tableDefinitionsBuilder_ == null) { - tableDefinitionsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder>( - tableDefinitions_, - ((bitField0_ & 0x00000001) != 0), - getParentForChildren(), - isClean()); - tableDefinitions_ = null; - } - return tableDefinitionsBuilder_; - } - - private int priority_ = 0; - /** - * - * - *
-         * Priority given to the query.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; - * - * - * @return The enum numeric value on the wire for priority. - */ - @java.lang.Override - public int getPriorityValue() { - return priority_; - } - /** - * - * - *
-         * Priority given to the query.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; - * - * - * @param value The enum numeric value on the wire for priority to set. - * @return This builder for chaining. - */ - public Builder setPriorityValue(int value) { - - priority_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Priority given to the query.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; - * - * - * @return The priority. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority getPriority() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority result = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority.valueOf( - priority_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority.UNRECOGNIZED - : result; - } - /** - * - * - *
-         * Priority given to the query.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; - * - * - * @param value The priority to set. - * @return This builder for chaining. - */ - public Builder setPriority( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority value) { - if (value == null) { - throw new NullPointerException(); - } - - priority_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-         * Priority given to the query.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Priority priority = 7; - * - * - * @return This builder for chaining. - */ - public Builder clearPriority() { - - priority_ = 0; - onChanged(); - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - destinationTableEncryption_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - destinationTableEncryptionBuilder_; - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - * - * @return Whether the destinationTableEncryption field is set. - */ - public boolean hasDestinationTableEncryption() { - return destinationTableEncryptionBuilder_ != null || destinationTableEncryption_ != null; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - * - * @return The destinationTableEncryption. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - getDestinationTableEncryption() { - if (destinationTableEncryptionBuilder_ == null) { - return destinationTableEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : destinationTableEncryption_; - } else { - return destinationTableEncryptionBuilder_.getMessage(); - } - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - */ - public Builder setDestinationTableEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (destinationTableEncryptionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - destinationTableEncryption_ = value; - onChanged(); - } else { - destinationTableEncryptionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - */ - public Builder setDestinationTableEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryption_ = builderForValue.build(); - onChanged(); - } else { - destinationTableEncryptionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - */ - public Builder mergeDestinationTableEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (destinationTableEncryptionBuilder_ == null) { - if (destinationTableEncryption_ != null) { - destinationTableEncryption_ = - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder( - destinationTableEncryption_) - .mergeFrom(value) - .buildPartial(); - } else { - destinationTableEncryption_ = value; - } - onChanged(); - } else { - destinationTableEncryptionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - */ - public Builder clearDestinationTableEncryption() { - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryption_ = null; - onChanged(); - } else { - destinationTableEncryption_ = null; - destinationTableEncryptionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder - getDestinationTableEncryptionBuilder() { - - onChanged(); - return getDestinationTableEncryptionFieldBuilder().getBuilder(); - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDestinationTableEncryptionOrBuilder() { - if (destinationTableEncryptionBuilder_ != null) { - return destinationTableEncryptionBuilder_.getMessageOrBuilder(); - } else { - return destinationTableEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : destinationTableEncryption_; - } - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 8; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - getDestinationTableEncryptionFieldBuilder() { - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryptionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( - getDestinationTableEncryption(), getParentForChildren(), isClean()); - destinationTableEncryption_ = null; - } - return destinationTableEncryptionBuilder_; - } - - private int statementType_ = 0; - /** - * - * - *
-         * Type of the query.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; - * - * - * @return The enum numeric value on the wire for statementType. - */ - @java.lang.Override - public int getStatementTypeValue() { - return statementType_; - } - /** - * - * - *
-         * Type of the query.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; - * - * - * @param value The enum numeric value on the wire for statementType to set. - * @return This builder for chaining. - */ - public Builder setStatementTypeValue(int value) { - - statementType_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Type of the query.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; - * - * - * @return The statementType. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType getStatementType() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType result = - com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType.valueOf( - statementType_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType.UNRECOGNIZED - : result; - } - /** - * - * - *
-         * Type of the query.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; - * - * - * @param value The statementType to set. - * @return This builder for chaining. - */ - public Builder setStatementType( - com.google.cloud.audit.BigQueryAuditMetadata.QueryStatementType value) { - if (value == null) { - throw new NullPointerException(); - } - - statementType_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-         * Type of the query.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.QueryStatementType statement_type = 9; - * - * - * @return This builder for chaining. - */ - public Builder clearStatementType() { - - statementType_ = 0; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Query parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Query(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface LoadOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-       * URIs for the data to be imported. Entire list is truncated if exceeds
-       * 40K.
-       * 
- * - * repeated string source_uris = 1; - * - * @return A list containing the sourceUris. - */ - java.util.List getSourceUrisList(); - /** - * - * - *
-       * URIs for the data to be imported. Entire list is truncated if exceeds
-       * 40K.
-       * 
- * - * repeated string source_uris = 1; - * - * @return The count of sourceUris. - */ - int getSourceUrisCount(); - /** - * - * - *
-       * URIs for the data to be imported. Entire list is truncated if exceeds
-       * 40K.
-       * 
- * - * repeated string source_uris = 1; - * - * @param index The index of the element to return. - * @return The sourceUris at the given index. - */ - java.lang.String getSourceUris(int index); - /** - * - * - *
-       * URIs for the data to be imported. Entire list is truncated if exceeds
-       * 40K.
-       * 
- * - * repeated string source_uris = 1; - * - * @param index The index of the value to return. - * @return The bytes of the sourceUris at the given index. - */ - com.google.protobuf.ByteString getSourceUrisBytes(int index); - - /** - * - * - *
-       * True if the source_URIs field was truncated.
-       * 
- * - * bool source_uris_truncated = 7; - * - * @return The sourceUrisTruncated. - */ - boolean getSourceUrisTruncated(); - - /** - * - * - *
-       * The table schema in JSON format. Entire field is truncated if exceeds
-       * 40K.
-       * 
- * - * string schema_json = 2; - * - * @return The schemaJson. - */ - java.lang.String getSchemaJson(); - /** - * - * - *
-       * The table schema in JSON format. Entire field is truncated if exceeds
-       * 40K.
-       * 
- * - * string schema_json = 2; - * - * @return The bytes for schemaJson. - */ - com.google.protobuf.ByteString getSchemaJsonBytes(); - - /** - * - * - *
-       * True if the schema_json field was truncated.
-       * 
- * - * bool schema_json_truncated = 8; - * - * @return The schemaJsonTruncated. - */ - boolean getSchemaJsonTruncated(); - - /** - * - * - *
-       * The destination table for the import.
-       * 
- * - * string destination_table = 3; - * - * @return The destinationTable. - */ - java.lang.String getDestinationTable(); - /** - * - * - *
-       * The destination table for the import.
-       * 
- * - * string destination_table = 3; - * - * @return The bytes for destinationTable. - */ - com.google.protobuf.ByteString getDestinationTableBytes(); - - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; - * - * - * @return The enum numeric value on the wire for createDisposition. - */ - int getCreateDispositionValue(); - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; - * - * - * @return The createDisposition. - */ - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition(); - - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; - * - * - * @return The enum numeric value on the wire for writeDisposition. - */ - int getWriteDispositionValue(); - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; - * - * - * @return The writeDisposition. - */ - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition(); - - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - * - * @return Whether the destinationTableEncryption field is set. - */ - boolean hasDestinationTableEncryption(); - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - * - * @return The destinationTableEncryption. - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDestinationTableEncryption(); - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDestinationTableEncryptionOrBuilder(); - } - /** - * - * - *
-     * Load job configuration.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load} - */ - public static final class Load extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) - LoadOrBuilder { - private static final long serialVersionUID = 0L; - // Use Load.newBuilder() to construct. - private Load(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Load() { - sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; - schemaJson_ = ""; - destinationTable_ = ""; - createDisposition_ = 0; - writeDisposition_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Load(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Load( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - sourceUris_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - sourceUris_.add(s); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - schemaJson_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - destinationTable_ = s; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - createDisposition_ = rawValue; - break; - } - case 40: - { - int rawValue = input.readEnum(); - - writeDisposition_ = rawValue; - break; - } - case 50: - { - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = - null; - if (destinationTableEncryption_ != null) { - subBuilder = destinationTableEncryption_.toBuilder(); - } - destinationTableEncryption_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(destinationTableEncryption_); - destinationTableEncryption_ = subBuilder.buildPartial(); - } - - break; - } - case 56: - { - sourceUrisTruncated_ = input.readBool(); - break; - } - case 64: - { - schemaJsonTruncated_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - sourceUris_ = sourceUris_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder.class); - } - - public static final int SOURCE_URIS_FIELD_NUMBER = 1; - private com.google.protobuf.LazyStringList sourceUris_; - /** - * - * - *
-       * URIs for the data to be imported. Entire list is truncated if exceeds
-       * 40K.
-       * 
- * - * repeated string source_uris = 1; - * - * @return A list containing the sourceUris. - */ - public com.google.protobuf.ProtocolStringList getSourceUrisList() { - return sourceUris_; - } - /** - * - * - *
-       * URIs for the data to be imported. Entire list is truncated if exceeds
-       * 40K.
-       * 
- * - * repeated string source_uris = 1; - * - * @return The count of sourceUris. - */ - public int getSourceUrisCount() { - return sourceUris_.size(); - } - /** - * - * - *
-       * URIs for the data to be imported. Entire list is truncated if exceeds
-       * 40K.
-       * 
- * - * repeated string source_uris = 1; - * - * @param index The index of the element to return. - * @return The sourceUris at the given index. - */ - public java.lang.String getSourceUris(int index) { - return sourceUris_.get(index); - } - /** - * - * - *
-       * URIs for the data to be imported. Entire list is truncated if exceeds
-       * 40K.
-       * 
- * - * repeated string source_uris = 1; - * - * @param index The index of the value to return. - * @return The bytes of the sourceUris at the given index. - */ - public com.google.protobuf.ByteString getSourceUrisBytes(int index) { - return sourceUris_.getByteString(index); - } - - public static final int SOURCE_URIS_TRUNCATED_FIELD_NUMBER = 7; - private boolean sourceUrisTruncated_; - /** - * - * - *
-       * True if the source_URIs field was truncated.
-       * 
- * - * bool source_uris_truncated = 7; - * - * @return The sourceUrisTruncated. - */ - @java.lang.Override - public boolean getSourceUrisTruncated() { - return sourceUrisTruncated_; - } - - public static final int SCHEMA_JSON_FIELD_NUMBER = 2; - private volatile java.lang.Object schemaJson_; - /** - * - * - *
-       * The table schema in JSON format. Entire field is truncated if exceeds
-       * 40K.
-       * 
- * - * string schema_json = 2; - * - * @return The schemaJson. - */ - @java.lang.Override - public java.lang.String getSchemaJson() { - java.lang.Object ref = schemaJson_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - schemaJson_ = s; - return s; - } - } - /** - * - * - *
-       * The table schema in JSON format. Entire field is truncated if exceeds
-       * 40K.
-       * 
- * - * string schema_json = 2; - * - * @return The bytes for schemaJson. - */ - @java.lang.Override - public com.google.protobuf.ByteString getSchemaJsonBytes() { - java.lang.Object ref = schemaJson_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - schemaJson_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SCHEMA_JSON_TRUNCATED_FIELD_NUMBER = 8; - private boolean schemaJsonTruncated_; - /** - * - * - *
-       * True if the schema_json field was truncated.
-       * 
- * - * bool schema_json_truncated = 8; - * - * @return The schemaJsonTruncated. - */ - @java.lang.Override - public boolean getSchemaJsonTruncated() { - return schemaJsonTruncated_; - } - - public static final int DESTINATION_TABLE_FIELD_NUMBER = 3; - private volatile java.lang.Object destinationTable_; - /** - * - * - *
-       * The destination table for the import.
-       * 
- * - * string destination_table = 3; - * - * @return The destinationTable. - */ - @java.lang.Override - public java.lang.String getDestinationTable() { - java.lang.Object ref = destinationTable_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - destinationTable_ = s; - return s; - } - } - /** - * - * - *
-       * The destination table for the import.
-       * 
- * - * string destination_table = 3; - * - * @return The bytes for destinationTable. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDestinationTableBytes() { - java.lang.Object ref = destinationTable_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - destinationTable_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATE_DISPOSITION_FIELD_NUMBER = 4; - private int createDisposition_; - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; - * - * - * @return The enum numeric value on the wire for createDisposition. - */ - @java.lang.Override - public int getCreateDispositionValue() { - return createDisposition_; - } - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; - * - * - * @return The createDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( - createDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED - : result; - } - - public static final int WRITE_DISPOSITION_FIELD_NUMBER = 5; - private int writeDisposition_; - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; - * - * - * @return The enum numeric value on the wire for writeDisposition. - */ - @java.lang.Override - public int getWriteDispositionValue() { - return writeDisposition_; - } - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; - * - * - * @return The writeDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( - writeDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED - : result; - } - - public static final int DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER = 6; - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - destinationTableEncryption_; - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - * - * @return Whether the destinationTableEncryption field is set. - */ - @java.lang.Override - public boolean hasDestinationTableEncryption() { - return destinationTableEncryption_ != null; - } - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - * - * @return The destinationTableEncryption. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - getDestinationTableEncryption() { - return destinationTableEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : destinationTableEncryption_; - } - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDestinationTableEncryptionOrBuilder() { - return getDestinationTableEncryption(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < sourceUris_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, sourceUris_.getRaw(i)); - } - if (!getSchemaJsonBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, schemaJson_); - } - if (!getDestinationTableBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, destinationTable_); - } - if (createDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition - .CREATE_DISPOSITION_UNSPECIFIED - .getNumber()) { - output.writeEnum(4, createDisposition_); - } - if (writeDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition - .WRITE_DISPOSITION_UNSPECIFIED - .getNumber()) { - output.writeEnum(5, writeDisposition_); - } - if (destinationTableEncryption_ != null) { - output.writeMessage(6, getDestinationTableEncryption()); - } - if (sourceUrisTruncated_ != false) { - output.writeBool(7, sourceUrisTruncated_); - } - if (schemaJsonTruncated_ != false) { - output.writeBool(8, schemaJsonTruncated_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - for (int i = 0; i < sourceUris_.size(); i++) { - dataSize += computeStringSizeNoTag(sourceUris_.getRaw(i)); - } - size += dataSize; - size += 1 * getSourceUrisList().size(); - } - if (!getSchemaJsonBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, schemaJson_); - } - if (!getDestinationTableBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, destinationTable_); - } - if (createDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition - .CREATE_DISPOSITION_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, createDisposition_); - } - if (writeDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition - .WRITE_DISPOSITION_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, writeDisposition_); - } - if (destinationTableEncryption_ != null) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 6, getDestinationTableEncryption()); - } - if (sourceUrisTruncated_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(7, sourceUrisTruncated_); - } - if (schemaJsonTruncated_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, schemaJsonTruncated_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) obj; - - if (!getSourceUrisList().equals(other.getSourceUrisList())) return false; - if (getSourceUrisTruncated() != other.getSourceUrisTruncated()) return false; - if (!getSchemaJson().equals(other.getSchemaJson())) return false; - if (getSchemaJsonTruncated() != other.getSchemaJsonTruncated()) return false; - if (!getDestinationTable().equals(other.getDestinationTable())) return false; - if (createDisposition_ != other.createDisposition_) return false; - if (writeDisposition_ != other.writeDisposition_) return false; - if (hasDestinationTableEncryption() != other.hasDestinationTableEncryption()) return false; - if (hasDestinationTableEncryption()) { - if (!getDestinationTableEncryption().equals(other.getDestinationTableEncryption())) - return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getSourceUrisCount() > 0) { - hash = (37 * hash) + SOURCE_URIS_FIELD_NUMBER; - hash = (53 * hash) + getSourceUrisList().hashCode(); - } - hash = (37 * hash) + SOURCE_URIS_TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSourceUrisTruncated()); - hash = (37 * hash) + SCHEMA_JSON_FIELD_NUMBER; - hash = (53 * hash) + getSchemaJson().hashCode(); - hash = (37 * hash) + SCHEMA_JSON_TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSchemaJsonTruncated()); - hash = (37 * hash) + DESTINATION_TABLE_FIELD_NUMBER; - hash = (53 * hash) + getDestinationTable().hashCode(); - hash = (37 * hash) + CREATE_DISPOSITION_FIELD_NUMBER; - hash = (53 * hash) + createDisposition_; - hash = (37 * hash) + WRITE_DISPOSITION_FIELD_NUMBER; - hash = (53 * hash) + writeDisposition_; - if (hasDestinationTableEncryption()) { - hash = (37 * hash) + DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER; - hash = (53 * hash) + getDestinationTableEncryption().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-       * Load job configuration.
-       * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - sourceUrisTruncated_ = false; - - schemaJson_ = ""; - - schemaJsonTruncated_ = false; - - destinationTable_ = ""; - - createDisposition_ = 0; - - writeDisposition_ = 0; - - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryption_ = null; - } else { - destinationTableEncryption_ = null; - destinationTableEncryptionBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load(this); - int from_bitField0_ = bitField0_; - if (((bitField0_ & 0x00000001) != 0)) { - sourceUris_ = sourceUris_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.sourceUris_ = sourceUris_; - result.sourceUrisTruncated_ = sourceUrisTruncated_; - result.schemaJson_ = schemaJson_; - result.schemaJsonTruncated_ = schemaJsonTruncated_; - result.destinationTable_ = destinationTable_; - result.createDisposition_ = createDisposition_; - result.writeDisposition_ = writeDisposition_; - if (destinationTableEncryptionBuilder_ == null) { - result.destinationTableEncryption_ = destinationTableEncryption_; - } else { - result.destinationTableEncryption_ = destinationTableEncryptionBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance()) - return this; - if (!other.sourceUris_.isEmpty()) { - if (sourceUris_.isEmpty()) { - sourceUris_ = other.sourceUris_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureSourceUrisIsMutable(); - sourceUris_.addAll(other.sourceUris_); - } - onChanged(); - } - if (other.getSourceUrisTruncated() != false) { - setSourceUrisTruncated(other.getSourceUrisTruncated()); - } - if (!other.getSchemaJson().isEmpty()) { - schemaJson_ = other.schemaJson_; - onChanged(); - } - if (other.getSchemaJsonTruncated() != false) { - setSchemaJsonTruncated(other.getSchemaJsonTruncated()); - } - if (!other.getDestinationTable().isEmpty()) { - destinationTable_ = other.destinationTable_; - onChanged(); - } - if (other.createDisposition_ != 0) { - setCreateDispositionValue(other.getCreateDispositionValue()); - } - if (other.writeDisposition_ != 0) { - setWriteDispositionValue(other.getWriteDispositionValue()); - } - if (other.hasDestinationTableEncryption()) { - mergeDestinationTableEncryption(other.getDestinationTableEncryption()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private com.google.protobuf.LazyStringList sourceUris_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureSourceUrisIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - sourceUris_ = new com.google.protobuf.LazyStringArrayList(sourceUris_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-         * URIs for the data to be imported. Entire list is truncated if exceeds
-         * 40K.
-         * 
- * - * repeated string source_uris = 1; - * - * @return A list containing the sourceUris. - */ - public com.google.protobuf.ProtocolStringList getSourceUrisList() { - return sourceUris_.getUnmodifiableView(); - } - /** - * - * - *
-         * URIs for the data to be imported. Entire list is truncated if exceeds
-         * 40K.
-         * 
- * - * repeated string source_uris = 1; - * - * @return The count of sourceUris. - */ - public int getSourceUrisCount() { - return sourceUris_.size(); - } - /** - * - * - *
-         * URIs for the data to be imported. Entire list is truncated if exceeds
-         * 40K.
-         * 
- * - * repeated string source_uris = 1; - * - * @param index The index of the element to return. - * @return The sourceUris at the given index. - */ - public java.lang.String getSourceUris(int index) { - return sourceUris_.get(index); - } - /** - * - * - *
-         * URIs for the data to be imported. Entire list is truncated if exceeds
-         * 40K.
-         * 
- * - * repeated string source_uris = 1; - * - * @param index The index of the value to return. - * @return The bytes of the sourceUris at the given index. - */ - public com.google.protobuf.ByteString getSourceUrisBytes(int index) { - return sourceUris_.getByteString(index); - } - /** - * - * - *
-         * URIs for the data to be imported. Entire list is truncated if exceeds
-         * 40K.
-         * 
- * - * repeated string source_uris = 1; - * - * @param index The index to set the value at. - * @param value The sourceUris to set. - * @return This builder for chaining. - */ - public Builder setSourceUris(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSourceUrisIsMutable(); - sourceUris_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-         * URIs for the data to be imported. Entire list is truncated if exceeds
-         * 40K.
-         * 
- * - * repeated string source_uris = 1; - * - * @param value The sourceUris to add. - * @return This builder for chaining. - */ - public Builder addSourceUris(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSourceUrisIsMutable(); - sourceUris_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-         * URIs for the data to be imported. Entire list is truncated if exceeds
-         * 40K.
-         * 
- * - * repeated string source_uris = 1; - * - * @param values The sourceUris to add. - * @return This builder for chaining. - */ - public Builder addAllSourceUris(java.lang.Iterable values) { - ensureSourceUrisIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, sourceUris_); - onChanged(); - return this; - } - /** - * - * - *
-         * URIs for the data to be imported. Entire list is truncated if exceeds
-         * 40K.
-         * 
- * - * repeated string source_uris = 1; - * - * @return This builder for chaining. - */ - public Builder clearSourceUris() { - sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-         * URIs for the data to be imported. Entire list is truncated if exceeds
-         * 40K.
-         * 
- * - * repeated string source_uris = 1; - * - * @param value The bytes of the sourceUris to add. - * @return This builder for chaining. - */ - public Builder addSourceUrisBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureSourceUrisIsMutable(); - sourceUris_.add(value); - onChanged(); - return this; - } - - private boolean sourceUrisTruncated_; - /** - * - * - *
-         * True if the source_URIs field was truncated.
-         * 
- * - * bool source_uris_truncated = 7; - * - * @return The sourceUrisTruncated. - */ - @java.lang.Override - public boolean getSourceUrisTruncated() { - return sourceUrisTruncated_; - } - /** - * - * - *
-         * True if the source_URIs field was truncated.
-         * 
- * - * bool source_uris_truncated = 7; - * - * @param value The sourceUrisTruncated to set. - * @return This builder for chaining. - */ - public Builder setSourceUrisTruncated(boolean value) { - - sourceUrisTruncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * True if the source_URIs field was truncated.
-         * 
- * - * bool source_uris_truncated = 7; - * - * @return This builder for chaining. - */ - public Builder clearSourceUrisTruncated() { - - sourceUrisTruncated_ = false; - onChanged(); - return this; - } - - private java.lang.Object schemaJson_ = ""; - /** - * - * - *
-         * The table schema in JSON format. Entire field is truncated if exceeds
-         * 40K.
-         * 
- * - * string schema_json = 2; - * - * @return The schemaJson. - */ - public java.lang.String getSchemaJson() { - java.lang.Object ref = schemaJson_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - schemaJson_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-         * The table schema in JSON format. Entire field is truncated if exceeds
-         * 40K.
-         * 
- * - * string schema_json = 2; - * - * @return The bytes for schemaJson. - */ - public com.google.protobuf.ByteString getSchemaJsonBytes() { - java.lang.Object ref = schemaJson_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - schemaJson_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-         * The table schema in JSON format. Entire field is truncated if exceeds
-         * 40K.
-         * 
- * - * string schema_json = 2; - * - * @param value The schemaJson to set. - * @return This builder for chaining. - */ - public Builder setSchemaJson(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - schemaJson_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * The table schema in JSON format. Entire field is truncated if exceeds
-         * 40K.
-         * 
- * - * string schema_json = 2; - * - * @return This builder for chaining. - */ - public Builder clearSchemaJson() { - - schemaJson_ = getDefaultInstance().getSchemaJson(); - onChanged(); - return this; - } - /** - * - * - *
-         * The table schema in JSON format. Entire field is truncated if exceeds
-         * 40K.
-         * 
- * - * string schema_json = 2; - * - * @param value The bytes for schemaJson to set. - * @return This builder for chaining. - */ - public Builder setSchemaJsonBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - schemaJson_ = value; - onChanged(); - return this; - } - - private boolean schemaJsonTruncated_; - /** - * - * - *
-         * True if the schema_json field was truncated.
-         * 
- * - * bool schema_json_truncated = 8; - * - * @return The schemaJsonTruncated. - */ - @java.lang.Override - public boolean getSchemaJsonTruncated() { - return schemaJsonTruncated_; - } - /** - * - * - *
-         * True if the schema_json field was truncated.
-         * 
- * - * bool schema_json_truncated = 8; - * - * @param value The schemaJsonTruncated to set. - * @return This builder for chaining. - */ - public Builder setSchemaJsonTruncated(boolean value) { - - schemaJsonTruncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * True if the schema_json field was truncated.
-         * 
- * - * bool schema_json_truncated = 8; - * - * @return This builder for chaining. - */ - public Builder clearSchemaJsonTruncated() { - - schemaJsonTruncated_ = false; - onChanged(); - return this; - } - - private java.lang.Object destinationTable_ = ""; - /** - * - * - *
-         * The destination table for the import.
-         * 
- * - * string destination_table = 3; - * - * @return The destinationTable. - */ - public java.lang.String getDestinationTable() { - java.lang.Object ref = destinationTable_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - destinationTable_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-         * The destination table for the import.
-         * 
- * - * string destination_table = 3; - * - * @return The bytes for destinationTable. - */ - public com.google.protobuf.ByteString getDestinationTableBytes() { - java.lang.Object ref = destinationTable_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - destinationTable_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-         * The destination table for the import.
-         * 
- * - * string destination_table = 3; - * - * @param value The destinationTable to set. - * @return This builder for chaining. - */ - public Builder setDestinationTable(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - destinationTable_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * The destination table for the import.
-         * 
- * - * string destination_table = 3; - * - * @return This builder for chaining. - */ - public Builder clearDestinationTable() { - - destinationTable_ = getDefaultInstance().getDestinationTable(); - onChanged(); - return this; - } - /** - * - * - *
-         * The destination table for the import.
-         * 
- * - * string destination_table = 3; - * - * @param value The bytes for destinationTable to set. - * @return This builder for chaining. - */ - public Builder setDestinationTableBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - destinationTable_ = value; - onChanged(); - return this; - } - - private int createDisposition_ = 0; - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; - * - * - * @return The enum numeric value on the wire for createDisposition. - */ - @java.lang.Override - public int getCreateDispositionValue() { - return createDisposition_; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; - * - * - * @param value The enum numeric value on the wire for createDisposition to set. - * @return This builder for chaining. - */ - public Builder setCreateDispositionValue(int value) { - - createDisposition_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; - * - * - * @return The createDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition - getCreateDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( - createDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED - : result; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; - * - * - * @param value The createDisposition to set. - * @return This builder for chaining. - */ - public Builder setCreateDisposition( - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition value) { - if (value == null) { - throw new NullPointerException(); - } - - createDisposition_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 4; - * - * - * @return This builder for chaining. - */ - public Builder clearCreateDisposition() { - - createDisposition_ = 0; - onChanged(); - return this; - } - - private int writeDisposition_ = 0; - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; - * - * - * @return The enum numeric value on the wire for writeDisposition. - */ - @java.lang.Override - public int getWriteDispositionValue() { - return writeDisposition_; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; - * - * - * @param value The enum numeric value on the wire for writeDisposition to set. - * @return This builder for chaining. - */ - public Builder setWriteDispositionValue(int value) { - - writeDisposition_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; - * - * - * @return The writeDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( - writeDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED - : result; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; - * - * - * @param value The writeDisposition to set. - * @return This builder for chaining. - */ - public Builder setWriteDisposition( - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition value) { - if (value == null) { - throw new NullPointerException(); - } - - writeDisposition_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 5; - * - * - * @return This builder for chaining. - */ - public Builder clearWriteDisposition() { - - writeDisposition_ = 0; - onChanged(); - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - destinationTableEncryption_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - destinationTableEncryptionBuilder_; - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - * - * @return Whether the destinationTableEncryption field is set. - */ - public boolean hasDestinationTableEncryption() { - return destinationTableEncryptionBuilder_ != null || destinationTableEncryption_ != null; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - * - * @return The destinationTableEncryption. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - getDestinationTableEncryption() { - if (destinationTableEncryptionBuilder_ == null) { - return destinationTableEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : destinationTableEncryption_; - } else { - return destinationTableEncryptionBuilder_.getMessage(); - } - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - */ - public Builder setDestinationTableEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (destinationTableEncryptionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - destinationTableEncryption_ = value; - onChanged(); - } else { - destinationTableEncryptionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - */ - public Builder setDestinationTableEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryption_ = builderForValue.build(); - onChanged(); - } else { - destinationTableEncryptionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - */ - public Builder mergeDestinationTableEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (destinationTableEncryptionBuilder_ == null) { - if (destinationTableEncryption_ != null) { - destinationTableEncryption_ = - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder( - destinationTableEncryption_) - .mergeFrom(value) - .buildPartial(); - } else { - destinationTableEncryption_ = value; - } - onChanged(); - } else { - destinationTableEncryptionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - */ - public Builder clearDestinationTableEncryption() { - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryption_ = null; - onChanged(); - } else { - destinationTableEncryption_ = null; - destinationTableEncryptionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder - getDestinationTableEncryptionBuilder() { - - onChanged(); - return getDestinationTableEncryptionFieldBuilder().getBuilder(); - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDestinationTableEncryptionOrBuilder() { - if (destinationTableEncryptionBuilder_ != null) { - return destinationTableEncryptionBuilder_.getMessageOrBuilder(); - } else { - return destinationTableEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : destinationTableEncryption_; - } - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 6; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - getDestinationTableEncryptionFieldBuilder() { - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryptionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( - getDestinationTableEncryption(), getParentForChildren(), isClean()); - destinationTableEncryption_ = null; - } - return destinationTableEncryptionBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Load parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Load(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface ExtractOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-       * URIs where extracted data should be written. Entire list is truncated
-       * if exceeds 50K.
-       * 
- * - * repeated string destination_uris = 1; - * - * @return A list containing the destinationUris. - */ - java.util.List getDestinationUrisList(); - /** - * - * - *
-       * URIs where extracted data should be written. Entire list is truncated
-       * if exceeds 50K.
-       * 
- * - * repeated string destination_uris = 1; - * - * @return The count of destinationUris. - */ - int getDestinationUrisCount(); - /** - * - * - *
-       * URIs where extracted data should be written. Entire list is truncated
-       * if exceeds 50K.
-       * 
- * - * repeated string destination_uris = 1; - * - * @param index The index of the element to return. - * @return The destinationUris at the given index. - */ - java.lang.String getDestinationUris(int index); - /** - * - * - *
-       * URIs where extracted data should be written. Entire list is truncated
-       * if exceeds 50K.
-       * 
- * - * repeated string destination_uris = 1; - * - * @param index The index of the value to return. - * @return The bytes of the destinationUris at the given index. - */ - com.google.protobuf.ByteString getDestinationUrisBytes(int index); - - /** - * - * - *
-       * True if the destination_URIs field was truncated.
-       * 
- * - * bool destination_uris_truncated = 3; - * - * @return The destinationUrisTruncated. - */ - boolean getDestinationUrisTruncated(); - - /** - * - * - *
-       * The source table.
-       * 
- * - * string source_table = 2; - * - * @return Whether the sourceTable field is set. - */ - boolean hasSourceTable(); - /** - * - * - *
-       * The source table.
-       * 
- * - * string source_table = 2; - * - * @return The sourceTable. - */ - java.lang.String getSourceTable(); - /** - * - * - *
-       * The source table.
-       * 
- * - * string source_table = 2; - * - * @return The bytes for sourceTable. - */ - com.google.protobuf.ByteString getSourceTableBytes(); - - /** - * - * - *
-       * The source model.
-       * 
- * - * string source_model = 4; - * - * @return Whether the sourceModel field is set. - */ - boolean hasSourceModel(); - /** - * - * - *
-       * The source model.
-       * 
- * - * string source_model = 4; - * - * @return The sourceModel. - */ - java.lang.String getSourceModel(); - /** - * - * - *
-       * The source model.
-       * 
- * - * string source_model = 4; - * - * @return The bytes for sourceModel. - */ - com.google.protobuf.ByteString getSourceModelBytes(); - - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.SourceCase - getSourceCase(); - } - /** - * - * - *
-     * Extract job configuration.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract} - */ - public static final class Extract extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) - ExtractOrBuilder { - private static final long serialVersionUID = 0L; - // Use Extract.newBuilder() to construct. - private Extract(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Extract() { - destinationUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Extract(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Extract( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - destinationUris_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - destinationUris_.add(s); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - sourceCase_ = 2; - source_ = s; - break; - } - case 24: - { - destinationUrisTruncated_ = input.readBool(); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - sourceCase_ = 4; - source_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - destinationUris_ = destinationUris_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder.class); - } - - private int sourceCase_ = 0; - private java.lang.Object source_; - - public enum SourceCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - SOURCE_TABLE(2), - SOURCE_MODEL(4), - SOURCE_NOT_SET(0); - private final int value; - - private SourceCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static SourceCase valueOf(int value) { - return forNumber(value); - } - - public static SourceCase forNumber(int value) { - switch (value) { - case 2: - return SOURCE_TABLE; - case 4: - return SOURCE_MODEL; - case 0: - return SOURCE_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public SourceCase getSourceCase() { - return SourceCase.forNumber(sourceCase_); - } - - public static final int DESTINATION_URIS_FIELD_NUMBER = 1; - private com.google.protobuf.LazyStringList destinationUris_; - /** - * - * - *
-       * URIs where extracted data should be written. Entire list is truncated
-       * if exceeds 50K.
-       * 
- * - * repeated string destination_uris = 1; - * - * @return A list containing the destinationUris. - */ - public com.google.protobuf.ProtocolStringList getDestinationUrisList() { - return destinationUris_; - } - /** - * - * - *
-       * URIs where extracted data should be written. Entire list is truncated
-       * if exceeds 50K.
-       * 
- * - * repeated string destination_uris = 1; - * - * @return The count of destinationUris. - */ - public int getDestinationUrisCount() { - return destinationUris_.size(); - } - /** - * - * - *
-       * URIs where extracted data should be written. Entire list is truncated
-       * if exceeds 50K.
-       * 
- * - * repeated string destination_uris = 1; - * - * @param index The index of the element to return. - * @return The destinationUris at the given index. - */ - public java.lang.String getDestinationUris(int index) { - return destinationUris_.get(index); - } - /** - * - * - *
-       * URIs where extracted data should be written. Entire list is truncated
-       * if exceeds 50K.
-       * 
- * - * repeated string destination_uris = 1; - * - * @param index The index of the value to return. - * @return The bytes of the destinationUris at the given index. - */ - public com.google.protobuf.ByteString getDestinationUrisBytes(int index) { - return destinationUris_.getByteString(index); - } - - public static final int DESTINATION_URIS_TRUNCATED_FIELD_NUMBER = 3; - private boolean destinationUrisTruncated_; - /** - * - * - *
-       * True if the destination_URIs field was truncated.
-       * 
- * - * bool destination_uris_truncated = 3; - * - * @return The destinationUrisTruncated. - */ - @java.lang.Override - public boolean getDestinationUrisTruncated() { - return destinationUrisTruncated_; - } - - public static final int SOURCE_TABLE_FIELD_NUMBER = 2; - /** - * - * - *
-       * The source table.
-       * 
- * - * string source_table = 2; - * - * @return Whether the sourceTable field is set. - */ - public boolean hasSourceTable() { - return sourceCase_ == 2; - } - /** - * - * - *
-       * The source table.
-       * 
- * - * string source_table = 2; - * - * @return The sourceTable. - */ - public java.lang.String getSourceTable() { - java.lang.Object ref = ""; - if (sourceCase_ == 2) { - ref = source_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (sourceCase_ == 2) { - source_ = s; - } - return s; - } - } - /** - * - * - *
-       * The source table.
-       * 
- * - * string source_table = 2; - * - * @return The bytes for sourceTable. - */ - public com.google.protobuf.ByteString getSourceTableBytes() { - java.lang.Object ref = ""; - if (sourceCase_ == 2) { - ref = source_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (sourceCase_ == 2) { - source_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SOURCE_MODEL_FIELD_NUMBER = 4; - /** - * - * - *
-       * The source model.
-       * 
- * - * string source_model = 4; - * - * @return Whether the sourceModel field is set. - */ - public boolean hasSourceModel() { - return sourceCase_ == 4; - } - /** - * - * - *
-       * The source model.
-       * 
- * - * string source_model = 4; - * - * @return The sourceModel. - */ - public java.lang.String getSourceModel() { - java.lang.Object ref = ""; - if (sourceCase_ == 4) { - ref = source_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (sourceCase_ == 4) { - source_ = s; - } - return s; - } - } - /** - * - * - *
-       * The source model.
-       * 
- * - * string source_model = 4; - * - * @return The bytes for sourceModel. - */ - public com.google.protobuf.ByteString getSourceModelBytes() { - java.lang.Object ref = ""; - if (sourceCase_ == 4) { - ref = source_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (sourceCase_ == 4) { - source_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < destinationUris_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, destinationUris_.getRaw(i)); - } - if (sourceCase_ == 2) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, source_); - } - if (destinationUrisTruncated_ != false) { - output.writeBool(3, destinationUrisTruncated_); - } - if (sourceCase_ == 4) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, source_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - for (int i = 0; i < destinationUris_.size(); i++) { - dataSize += computeStringSizeNoTag(destinationUris_.getRaw(i)); - } - size += dataSize; - size += 1 * getDestinationUrisList().size(); - } - if (sourceCase_ == 2) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, source_); - } - if (destinationUrisTruncated_ != false) { - size += - com.google.protobuf.CodedOutputStream.computeBoolSize(3, destinationUrisTruncated_); - } - if (sourceCase_ == 4) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, source_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) obj; - - if (!getDestinationUrisList().equals(other.getDestinationUrisList())) return false; - if (getDestinationUrisTruncated() != other.getDestinationUrisTruncated()) return false; - if (!getSourceCase().equals(other.getSourceCase())) return false; - switch (sourceCase_) { - case 2: - if (!getSourceTable().equals(other.getSourceTable())) return false; - break; - case 4: - if (!getSourceModel().equals(other.getSourceModel())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getDestinationUrisCount() > 0) { - hash = (37 * hash) + DESTINATION_URIS_FIELD_NUMBER; - hash = (53 * hash) + getDestinationUrisList().hashCode(); - } - hash = (37 * hash) + DESTINATION_URIS_TRUNCATED_FIELD_NUMBER; - hash = - (53 * hash) + com.google.protobuf.Internal.hashBoolean(getDestinationUrisTruncated()); - switch (sourceCase_) { - case 2: - hash = (37 * hash) + SOURCE_TABLE_FIELD_NUMBER; - hash = (53 * hash) + getSourceTable().hashCode(); - break; - case 4: - hash = (37 * hash) + SOURCE_MODEL_FIELD_NUMBER; - hash = (53 * hash) + getSourceModel().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-       * Extract job configuration.
-       * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder.class); - } - - // Construct using - // com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - destinationUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - destinationUrisTruncated_ = false; - - sourceCase_ = 0; - source_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - .getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract(this); - int from_bitField0_ = bitField0_; - if (((bitField0_ & 0x00000001) != 0)) { - destinationUris_ = destinationUris_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.destinationUris_ = destinationUris_; - result.destinationUrisTruncated_ = destinationUrisTruncated_; - if (sourceCase_ == 2) { - result.source_ = source_; - } - if (sourceCase_ == 4) { - result.source_ = source_; - } - result.sourceCase_ = sourceCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) { - return mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - .getDefaultInstance()) return this; - if (!other.destinationUris_.isEmpty()) { - if (destinationUris_.isEmpty()) { - destinationUris_ = other.destinationUris_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureDestinationUrisIsMutable(); - destinationUris_.addAll(other.destinationUris_); - } - onChanged(); - } - if (other.getDestinationUrisTruncated() != false) { - setDestinationUrisTruncated(other.getDestinationUrisTruncated()); - } - switch (other.getSourceCase()) { - case SOURCE_TABLE: - { - sourceCase_ = 2; - source_ = other.source_; - onChanged(); - break; - } - case SOURCE_MODEL: - { - sourceCase_ = 4; - source_ = other.source_; - onChanged(); - break; - } - case SOURCE_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int sourceCase_ = 0; - private java.lang.Object source_; - - public SourceCase getSourceCase() { - return SourceCase.forNumber(sourceCase_); - } - - public Builder clearSource() { - sourceCase_ = 0; - source_ = null; - onChanged(); - return this; - } - - private int bitField0_; - - private com.google.protobuf.LazyStringList destinationUris_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureDestinationUrisIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - destinationUris_ = new com.google.protobuf.LazyStringArrayList(destinationUris_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-         * URIs where extracted data should be written. Entire list is truncated
-         * if exceeds 50K.
-         * 
- * - * repeated string destination_uris = 1; - * - * @return A list containing the destinationUris. - */ - public com.google.protobuf.ProtocolStringList getDestinationUrisList() { - return destinationUris_.getUnmodifiableView(); - } - /** - * - * - *
-         * URIs where extracted data should be written. Entire list is truncated
-         * if exceeds 50K.
-         * 
- * - * repeated string destination_uris = 1; - * - * @return The count of destinationUris. - */ - public int getDestinationUrisCount() { - return destinationUris_.size(); - } - /** - * - * - *
-         * URIs where extracted data should be written. Entire list is truncated
-         * if exceeds 50K.
-         * 
- * - * repeated string destination_uris = 1; - * - * @param index The index of the element to return. - * @return The destinationUris at the given index. - */ - public java.lang.String getDestinationUris(int index) { - return destinationUris_.get(index); - } - /** - * - * - *
-         * URIs where extracted data should be written. Entire list is truncated
-         * if exceeds 50K.
-         * 
- * - * repeated string destination_uris = 1; - * - * @param index The index of the value to return. - * @return The bytes of the destinationUris at the given index. - */ - public com.google.protobuf.ByteString getDestinationUrisBytes(int index) { - return destinationUris_.getByteString(index); - } - /** - * - * - *
-         * URIs where extracted data should be written. Entire list is truncated
-         * if exceeds 50K.
-         * 
- * - * repeated string destination_uris = 1; - * - * @param index The index to set the value at. - * @param value The destinationUris to set. - * @return This builder for chaining. - */ - public Builder setDestinationUris(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureDestinationUrisIsMutable(); - destinationUris_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-         * URIs where extracted data should be written. Entire list is truncated
-         * if exceeds 50K.
-         * 
- * - * repeated string destination_uris = 1; - * - * @param value The destinationUris to add. - * @return This builder for chaining. - */ - public Builder addDestinationUris(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureDestinationUrisIsMutable(); - destinationUris_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-         * URIs where extracted data should be written. Entire list is truncated
-         * if exceeds 50K.
-         * 
- * - * repeated string destination_uris = 1; - * - * @param values The destinationUris to add. - * @return This builder for chaining. - */ - public Builder addAllDestinationUris(java.lang.Iterable values) { - ensureDestinationUrisIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, destinationUris_); - onChanged(); - return this; - } - /** - * - * - *
-         * URIs where extracted data should be written. Entire list is truncated
-         * if exceeds 50K.
-         * 
- * - * repeated string destination_uris = 1; - * - * @return This builder for chaining. - */ - public Builder clearDestinationUris() { - destinationUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-         * URIs where extracted data should be written. Entire list is truncated
-         * if exceeds 50K.
-         * 
- * - * repeated string destination_uris = 1; - * - * @param value The bytes of the destinationUris to add. - * @return This builder for chaining. - */ - public Builder addDestinationUrisBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureDestinationUrisIsMutable(); - destinationUris_.add(value); - onChanged(); - return this; - } - - private boolean destinationUrisTruncated_; - /** - * - * - *
-         * True if the destination_URIs field was truncated.
-         * 
- * - * bool destination_uris_truncated = 3; - * - * @return The destinationUrisTruncated. - */ - @java.lang.Override - public boolean getDestinationUrisTruncated() { - return destinationUrisTruncated_; - } - /** - * - * - *
-         * True if the destination_URIs field was truncated.
-         * 
- * - * bool destination_uris_truncated = 3; - * - * @param value The destinationUrisTruncated to set. - * @return This builder for chaining. - */ - public Builder setDestinationUrisTruncated(boolean value) { - - destinationUrisTruncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * True if the destination_URIs field was truncated.
-         * 
- * - * bool destination_uris_truncated = 3; - * - * @return This builder for chaining. - */ - public Builder clearDestinationUrisTruncated() { - - destinationUrisTruncated_ = false; - onChanged(); - return this; - } - - /** - * - * - *
-         * The source table.
-         * 
- * - * string source_table = 2; - * - * @return Whether the sourceTable field is set. - */ - @java.lang.Override - public boolean hasSourceTable() { - return sourceCase_ == 2; - } - /** - * - * - *
-         * The source table.
-         * 
- * - * string source_table = 2; - * - * @return The sourceTable. - */ - @java.lang.Override - public java.lang.String getSourceTable() { - java.lang.Object ref = ""; - if (sourceCase_ == 2) { - ref = source_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (sourceCase_ == 2) { - source_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-         * The source table.
-         * 
- * - * string source_table = 2; - * - * @return The bytes for sourceTable. - */ - @java.lang.Override - public com.google.protobuf.ByteString getSourceTableBytes() { - java.lang.Object ref = ""; - if (sourceCase_ == 2) { - ref = source_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (sourceCase_ == 2) { - source_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-         * The source table.
-         * 
- * - * string source_table = 2; - * - * @param value The sourceTable to set. - * @return This builder for chaining. - */ - public Builder setSourceTable(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - sourceCase_ = 2; - source_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * The source table.
-         * 
- * - * string source_table = 2; - * - * @return This builder for chaining. - */ - public Builder clearSourceTable() { - if (sourceCase_ == 2) { - sourceCase_ = 0; - source_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-         * The source table.
-         * 
- * - * string source_table = 2; - * - * @param value The bytes for sourceTable to set. - * @return This builder for chaining. - */ - public Builder setSourceTableBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - sourceCase_ = 2; - source_ = value; - onChanged(); - return this; - } - - /** - * - * - *
-         * The source model.
-         * 
- * - * string source_model = 4; - * - * @return Whether the sourceModel field is set. - */ - @java.lang.Override - public boolean hasSourceModel() { - return sourceCase_ == 4; - } - /** - * - * - *
-         * The source model.
-         * 
- * - * string source_model = 4; - * - * @return The sourceModel. - */ - @java.lang.Override - public java.lang.String getSourceModel() { - java.lang.Object ref = ""; - if (sourceCase_ == 4) { - ref = source_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (sourceCase_ == 4) { - source_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-         * The source model.
-         * 
- * - * string source_model = 4; - * - * @return The bytes for sourceModel. - */ - @java.lang.Override - public com.google.protobuf.ByteString getSourceModelBytes() { - java.lang.Object ref = ""; - if (sourceCase_ == 4) { - ref = source_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (sourceCase_ == 4) { - source_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-         * The source model.
-         * 
- * - * string source_model = 4; - * - * @param value The sourceModel to set. - * @return This builder for chaining. - */ - public Builder setSourceModel(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - sourceCase_ = 4; - source_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * The source model.
-         * 
- * - * string source_model = 4; - * - * @return This builder for chaining. - */ - public Builder clearSourceModel() { - if (sourceCase_ == 4) { - sourceCase_ = 0; - source_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-         * The source model.
-         * 
- * - * string source_model = 4; - * - * @param value The bytes for sourceModel to set. - * @return This builder for chaining. - */ - public Builder setSourceModelBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - sourceCase_ = 4; - source_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Extract parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Extract(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface TableCopyOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-       * Source tables. Entire list is truncated if exceeds 50K.
-       * 
- * - * repeated string source_tables = 1; - * - * @return A list containing the sourceTables. - */ - java.util.List getSourceTablesList(); - /** - * - * - *
-       * Source tables. Entire list is truncated if exceeds 50K.
-       * 
- * - * repeated string source_tables = 1; - * - * @return The count of sourceTables. - */ - int getSourceTablesCount(); - /** - * - * - *
-       * Source tables. Entire list is truncated if exceeds 50K.
-       * 
- * - * repeated string source_tables = 1; - * - * @param index The index of the element to return. - * @return The sourceTables at the given index. - */ - java.lang.String getSourceTables(int index); - /** - * - * - *
-       * Source tables. Entire list is truncated if exceeds 50K.
-       * 
- * - * repeated string source_tables = 1; - * - * @param index The index of the value to return. - * @return The bytes of the sourceTables at the given index. - */ - com.google.protobuf.ByteString getSourceTablesBytes(int index); - - /** - * - * - *
-       * True if the source_tables field was truncated.
-       * 
- * - * bool source_tables_truncated = 6; - * - * @return The sourceTablesTruncated. - */ - boolean getSourceTablesTruncated(); - - /** - * - * - *
-       * Destination table.
-       * 
- * - * string destination_table = 2; - * - * @return The destinationTable. - */ - java.lang.String getDestinationTable(); - /** - * - * - *
-       * Destination table.
-       * 
- * - * string destination_table = 2; - * - * @return The bytes for destinationTable. - */ - com.google.protobuf.ByteString getDestinationTableBytes(); - - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The enum numeric value on the wire for createDisposition. - */ - int getCreateDispositionValue(); - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The createDisposition. - */ - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition(); - - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The enum numeric value on the wire for writeDisposition. - */ - int getWriteDispositionValue(); - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The writeDisposition. - */ - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition(); - - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - * - * @return Whether the destinationTableEncryption field is set. - */ - boolean hasDestinationTableEncryption(); - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - * - * @return The destinationTableEncryption. - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDestinationTableEncryption(); - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDestinationTableEncryptionOrBuilder(); - - /** - * - * - *
-       * Supported operation types in the table copy job.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; - * - * @return The enum numeric value on the wire for operationType. - */ - int getOperationTypeValue(); - /** - * - * - *
-       * Supported operation types in the table copy job.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; - * - * @return The operationType. - */ - com.google.cloud.audit.BigQueryAuditMetadata.OperationType getOperationType(); - - /** - * - * - *
-       * Expiration time set on the destination table. Expired tables will be
-       * deleted and their storage reclaimed.
-       * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - * - * @return Whether the destinationExpirationTime field is set. - */ - boolean hasDestinationExpirationTime(); - /** - * - * - *
-       * Expiration time set on the destination table. Expired tables will be
-       * deleted and their storage reclaimed.
-       * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - * - * @return The destinationExpirationTime. - */ - com.google.protobuf.Timestamp getDestinationExpirationTime(); - /** - * - * - *
-       * Expiration time set on the destination table. Expired tables will be
-       * deleted and their storage reclaimed.
-       * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - */ - com.google.protobuf.TimestampOrBuilder getDestinationExpirationTimeOrBuilder(); - } - /** - * - * - *
-     * Table copy job configuration.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy} - */ - public static final class TableCopy extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) - TableCopyOrBuilder { - private static final long serialVersionUID = 0L; - // Use TableCopy.newBuilder() to construct. - private TableCopy(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private TableCopy() { - sourceTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; - destinationTable_ = ""; - createDisposition_ = 0; - writeDisposition_ = 0; - operationType_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TableCopy(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private TableCopy( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - sourceTables_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - sourceTables_.add(s); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - destinationTable_ = s; - break; - } - case 24: - { - int rawValue = input.readEnum(); - - createDisposition_ = rawValue; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - writeDisposition_ = rawValue; - break; - } - case 42: - { - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = - null; - if (destinationTableEncryption_ != null) { - subBuilder = destinationTableEncryption_.toBuilder(); - } - destinationTableEncryption_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(destinationTableEncryption_); - destinationTableEncryption_ = subBuilder.buildPartial(); - } - - break; - } - case 48: - { - sourceTablesTruncated_ = input.readBool(); - break; - } - case 56: - { - int rawValue = input.readEnum(); - - operationType_ = rawValue; - break; - } - case 66: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (destinationExpirationTime_ != null) { - subBuilder = destinationExpirationTime_.toBuilder(); - } - destinationExpirationTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(destinationExpirationTime_); - destinationExpirationTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - sourceTables_ = sourceTables_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder.class); - } - - public static final int SOURCE_TABLES_FIELD_NUMBER = 1; - private com.google.protobuf.LazyStringList sourceTables_; - /** - * - * - *
-       * Source tables. Entire list is truncated if exceeds 50K.
-       * 
- * - * repeated string source_tables = 1; - * - * @return A list containing the sourceTables. - */ - public com.google.protobuf.ProtocolStringList getSourceTablesList() { - return sourceTables_; - } - /** - * - * - *
-       * Source tables. Entire list is truncated if exceeds 50K.
-       * 
- * - * repeated string source_tables = 1; - * - * @return The count of sourceTables. - */ - public int getSourceTablesCount() { - return sourceTables_.size(); - } - /** - * - * - *
-       * Source tables. Entire list is truncated if exceeds 50K.
-       * 
- * - * repeated string source_tables = 1; - * - * @param index The index of the element to return. - * @return The sourceTables at the given index. - */ - public java.lang.String getSourceTables(int index) { - return sourceTables_.get(index); - } - /** - * - * - *
-       * Source tables. Entire list is truncated if exceeds 50K.
-       * 
- * - * repeated string source_tables = 1; - * - * @param index The index of the value to return. - * @return The bytes of the sourceTables at the given index. - */ - public com.google.protobuf.ByteString getSourceTablesBytes(int index) { - return sourceTables_.getByteString(index); - } - - public static final int SOURCE_TABLES_TRUNCATED_FIELD_NUMBER = 6; - private boolean sourceTablesTruncated_; - /** - * - * - *
-       * True if the source_tables field was truncated.
-       * 
- * - * bool source_tables_truncated = 6; - * - * @return The sourceTablesTruncated. - */ - @java.lang.Override - public boolean getSourceTablesTruncated() { - return sourceTablesTruncated_; - } - - public static final int DESTINATION_TABLE_FIELD_NUMBER = 2; - private volatile java.lang.Object destinationTable_; - /** - * - * - *
-       * Destination table.
-       * 
- * - * string destination_table = 2; - * - * @return The destinationTable. - */ - @java.lang.Override - public java.lang.String getDestinationTable() { - java.lang.Object ref = destinationTable_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - destinationTable_ = s; - return s; - } - } - /** - * - * - *
-       * Destination table.
-       * 
- * - * string destination_table = 2; - * - * @return The bytes for destinationTable. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDestinationTableBytes() { - java.lang.Object ref = destinationTable_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - destinationTable_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATE_DISPOSITION_FIELD_NUMBER = 3; - private int createDisposition_; - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The enum numeric value on the wire for createDisposition. - */ - @java.lang.Override - public int getCreateDispositionValue() { - return createDisposition_; - } - /** - * - * - *
-       * Destination table create disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The createDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition getCreateDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( - createDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED - : result; - } - - public static final int WRITE_DISPOSITION_FIELD_NUMBER = 4; - private int writeDisposition_; - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The enum numeric value on the wire for writeDisposition. - */ - @java.lang.Override - public int getWriteDispositionValue() { - return writeDisposition_; - } - /** - * - * - *
-       * Destination table write disposition.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The writeDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( - writeDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED - : result; - } - - public static final int DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER = 5; - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - destinationTableEncryption_; - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - * - * @return Whether the destinationTableEncryption field is set. - */ - @java.lang.Override - public boolean hasDestinationTableEncryption() { - return destinationTableEncryption_ != null; - } - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - * - * @return The destinationTableEncryption. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - getDestinationTableEncryption() { - return destinationTableEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : destinationTableEncryption_; - } - /** - * - * - *
-       * Result table encryption information. Set when non-default encryption is
-       * used.
-       * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDestinationTableEncryptionOrBuilder() { - return getDestinationTableEncryption(); - } - - public static final int OPERATION_TYPE_FIELD_NUMBER = 7; - private int operationType_; - /** - * - * - *
-       * Supported operation types in the table copy job.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; - * - * @return The enum numeric value on the wire for operationType. - */ - @java.lang.Override - public int getOperationTypeValue() { - return operationType_; - } - /** - * - * - *
-       * Supported operation types in the table copy job.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; - * - * @return The operationType. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.OperationType getOperationType() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.OperationType result = - com.google.cloud.audit.BigQueryAuditMetadata.OperationType.valueOf(operationType_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.OperationType.UNRECOGNIZED - : result; - } - - public static final int DESTINATION_EXPIRATION_TIME_FIELD_NUMBER = 8; - private com.google.protobuf.Timestamp destinationExpirationTime_; - /** - * - * - *
-       * Expiration time set on the destination table. Expired tables will be
-       * deleted and their storage reclaimed.
-       * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - * - * @return Whether the destinationExpirationTime field is set. - */ - @java.lang.Override - public boolean hasDestinationExpirationTime() { - return destinationExpirationTime_ != null; - } - /** - * - * - *
-       * Expiration time set on the destination table. Expired tables will be
-       * deleted and their storage reclaimed.
-       * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - * - * @return The destinationExpirationTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getDestinationExpirationTime() { - return destinationExpirationTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : destinationExpirationTime_; - } - /** - * - * - *
-       * Expiration time set on the destination table. Expired tables will be
-       * deleted and their storage reclaimed.
-       * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getDestinationExpirationTimeOrBuilder() { - return getDestinationExpirationTime(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < sourceTables_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, sourceTables_.getRaw(i)); - } - if (!getDestinationTableBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, destinationTable_); - } - if (createDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition - .CREATE_DISPOSITION_UNSPECIFIED - .getNumber()) { - output.writeEnum(3, createDisposition_); - } - if (writeDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition - .WRITE_DISPOSITION_UNSPECIFIED - .getNumber()) { - output.writeEnum(4, writeDisposition_); - } - if (destinationTableEncryption_ != null) { - output.writeMessage(5, getDestinationTableEncryption()); - } - if (sourceTablesTruncated_ != false) { - output.writeBool(6, sourceTablesTruncated_); - } - if (operationType_ - != com.google.cloud.audit.BigQueryAuditMetadata.OperationType.OPERATION_TYPE_UNSPECIFIED - .getNumber()) { - output.writeEnum(7, operationType_); - } - if (destinationExpirationTime_ != null) { - output.writeMessage(8, getDestinationExpirationTime()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - for (int i = 0; i < sourceTables_.size(); i++) { - dataSize += computeStringSizeNoTag(sourceTables_.getRaw(i)); - } - size += dataSize; - size += 1 * getSourceTablesList().size(); - } - if (!getDestinationTableBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, destinationTable_); - } - if (createDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition - .CREATE_DISPOSITION_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, createDisposition_); - } - if (writeDisposition_ - != com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition - .WRITE_DISPOSITION_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, writeDisposition_); - } - if (destinationTableEncryption_ != null) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 5, getDestinationTableEncryption()); - } - if (sourceTablesTruncated_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, sourceTablesTruncated_); - } - if (operationType_ - != com.google.cloud.audit.BigQueryAuditMetadata.OperationType.OPERATION_TYPE_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, operationType_); - } - if (destinationExpirationTime_ != null) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 8, getDestinationExpirationTime()); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) obj; - - if (!getSourceTablesList().equals(other.getSourceTablesList())) return false; - if (getSourceTablesTruncated() != other.getSourceTablesTruncated()) return false; - if (!getDestinationTable().equals(other.getDestinationTable())) return false; - if (createDisposition_ != other.createDisposition_) return false; - if (writeDisposition_ != other.writeDisposition_) return false; - if (hasDestinationTableEncryption() != other.hasDestinationTableEncryption()) return false; - if (hasDestinationTableEncryption()) { - if (!getDestinationTableEncryption().equals(other.getDestinationTableEncryption())) - return false; - } - if (operationType_ != other.operationType_) return false; - if (hasDestinationExpirationTime() != other.hasDestinationExpirationTime()) return false; - if (hasDestinationExpirationTime()) { - if (!getDestinationExpirationTime().equals(other.getDestinationExpirationTime())) - return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getSourceTablesCount() > 0) { - hash = (37 * hash) + SOURCE_TABLES_FIELD_NUMBER; - hash = (53 * hash) + getSourceTablesList().hashCode(); - } - hash = (37 * hash) + SOURCE_TABLES_TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSourceTablesTruncated()); - hash = (37 * hash) + DESTINATION_TABLE_FIELD_NUMBER; - hash = (53 * hash) + getDestinationTable().hashCode(); - hash = (37 * hash) + CREATE_DISPOSITION_FIELD_NUMBER; - hash = (53 * hash) + createDisposition_; - hash = (37 * hash) + WRITE_DISPOSITION_FIELD_NUMBER; - hash = (53 * hash) + writeDisposition_; - if (hasDestinationTableEncryption()) { - hash = (37 * hash) + DESTINATION_TABLE_ENCRYPTION_FIELD_NUMBER; - hash = (53 * hash) + getDestinationTableEncryption().hashCode(); - } - hash = (37 * hash) + OPERATION_TYPE_FIELD_NUMBER; - hash = (53 * hash) + operationType_; - if (hasDestinationExpirationTime()) { - hash = (37 * hash) + DESTINATION_EXPIRATION_TIME_FIELD_NUMBER; - hash = (53 * hash) + getDestinationExpirationTime().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-       * Table copy job configuration.
-       * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder.class); - } - - // Construct using - // com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - sourceTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - sourceTablesTruncated_ = false; - - destinationTable_ = ""; - - createDisposition_ = 0; - - writeDisposition_ = 0; - - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryption_ = null; - } else { - destinationTableEncryption_ = null; - destinationTableEncryptionBuilder_ = null; - } - operationType_ = 0; - - if (destinationExpirationTimeBuilder_ == null) { - destinationExpirationTime_ = null; - } else { - destinationExpirationTime_ = null; - destinationExpirationTimeBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - .getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy(this); - int from_bitField0_ = bitField0_; - if (((bitField0_ & 0x00000001) != 0)) { - sourceTables_ = sourceTables_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.sourceTables_ = sourceTables_; - result.sourceTablesTruncated_ = sourceTablesTruncated_; - result.destinationTable_ = destinationTable_; - result.createDisposition_ = createDisposition_; - result.writeDisposition_ = writeDisposition_; - if (destinationTableEncryptionBuilder_ == null) { - result.destinationTableEncryption_ = destinationTableEncryption_; - } else { - result.destinationTableEncryption_ = destinationTableEncryptionBuilder_.build(); - } - result.operationType_ = operationType_; - if (destinationExpirationTimeBuilder_ == null) { - result.destinationExpirationTime_ = destinationExpirationTime_; - } else { - result.destinationExpirationTime_ = destinationExpirationTimeBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) { - return mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - .getDefaultInstance()) return this; - if (!other.sourceTables_.isEmpty()) { - if (sourceTables_.isEmpty()) { - sourceTables_ = other.sourceTables_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureSourceTablesIsMutable(); - sourceTables_.addAll(other.sourceTables_); - } - onChanged(); - } - if (other.getSourceTablesTruncated() != false) { - setSourceTablesTruncated(other.getSourceTablesTruncated()); - } - if (!other.getDestinationTable().isEmpty()) { - destinationTable_ = other.destinationTable_; - onChanged(); - } - if (other.createDisposition_ != 0) { - setCreateDispositionValue(other.getCreateDispositionValue()); - } - if (other.writeDisposition_ != 0) { - setWriteDispositionValue(other.getWriteDispositionValue()); - } - if (other.hasDestinationTableEncryption()) { - mergeDestinationTableEncryption(other.getDestinationTableEncryption()); - } - if (other.operationType_ != 0) { - setOperationTypeValue(other.getOperationTypeValue()); - } - if (other.hasDestinationExpirationTime()) { - mergeDestinationExpirationTime(other.getDestinationExpirationTime()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private com.google.protobuf.LazyStringList sourceTables_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureSourceTablesIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - sourceTables_ = new com.google.protobuf.LazyStringArrayList(sourceTables_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-         * Source tables. Entire list is truncated if exceeds 50K.
-         * 
- * - * repeated string source_tables = 1; - * - * @return A list containing the sourceTables. - */ - public com.google.protobuf.ProtocolStringList getSourceTablesList() { - return sourceTables_.getUnmodifiableView(); - } - /** - * - * - *
-         * Source tables. Entire list is truncated if exceeds 50K.
-         * 
- * - * repeated string source_tables = 1; - * - * @return The count of sourceTables. - */ - public int getSourceTablesCount() { - return sourceTables_.size(); - } - /** - * - * - *
-         * Source tables. Entire list is truncated if exceeds 50K.
-         * 
- * - * repeated string source_tables = 1; - * - * @param index The index of the element to return. - * @return The sourceTables at the given index. - */ - public java.lang.String getSourceTables(int index) { - return sourceTables_.get(index); - } - /** - * - * - *
-         * Source tables. Entire list is truncated if exceeds 50K.
-         * 
- * - * repeated string source_tables = 1; - * - * @param index The index of the value to return. - * @return The bytes of the sourceTables at the given index. - */ - public com.google.protobuf.ByteString getSourceTablesBytes(int index) { - return sourceTables_.getByteString(index); - } - /** - * - * - *
-         * Source tables. Entire list is truncated if exceeds 50K.
-         * 
- * - * repeated string source_tables = 1; - * - * @param index The index to set the value at. - * @param value The sourceTables to set. - * @return This builder for chaining. - */ - public Builder setSourceTables(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSourceTablesIsMutable(); - sourceTables_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-         * Source tables. Entire list is truncated if exceeds 50K.
-         * 
- * - * repeated string source_tables = 1; - * - * @param value The sourceTables to add. - * @return This builder for chaining. - */ - public Builder addSourceTables(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSourceTablesIsMutable(); - sourceTables_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-         * Source tables. Entire list is truncated if exceeds 50K.
-         * 
- * - * repeated string source_tables = 1; - * - * @param values The sourceTables to add. - * @return This builder for chaining. - */ - public Builder addAllSourceTables(java.lang.Iterable values) { - ensureSourceTablesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, sourceTables_); - onChanged(); - return this; - } - /** - * - * - *
-         * Source tables. Entire list is truncated if exceeds 50K.
-         * 
- * - * repeated string source_tables = 1; - * - * @return This builder for chaining. - */ - public Builder clearSourceTables() { - sourceTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-         * Source tables. Entire list is truncated if exceeds 50K.
-         * 
- * - * repeated string source_tables = 1; - * - * @param value The bytes of the sourceTables to add. - * @return This builder for chaining. - */ - public Builder addSourceTablesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureSourceTablesIsMutable(); - sourceTables_.add(value); - onChanged(); - return this; - } - - private boolean sourceTablesTruncated_; - /** - * - * - *
-         * True if the source_tables field was truncated.
-         * 
- * - * bool source_tables_truncated = 6; - * - * @return The sourceTablesTruncated. - */ - @java.lang.Override - public boolean getSourceTablesTruncated() { - return sourceTablesTruncated_; - } - /** - * - * - *
-         * True if the source_tables field was truncated.
-         * 
- * - * bool source_tables_truncated = 6; - * - * @param value The sourceTablesTruncated to set. - * @return This builder for chaining. - */ - public Builder setSourceTablesTruncated(boolean value) { - - sourceTablesTruncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * True if the source_tables field was truncated.
-         * 
- * - * bool source_tables_truncated = 6; - * - * @return This builder for chaining. - */ - public Builder clearSourceTablesTruncated() { - - sourceTablesTruncated_ = false; - onChanged(); - return this; - } - - private java.lang.Object destinationTable_ = ""; - /** - * - * - *
-         * Destination table.
-         * 
- * - * string destination_table = 2; - * - * @return The destinationTable. - */ - public java.lang.String getDestinationTable() { - java.lang.Object ref = destinationTable_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - destinationTable_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-         * Destination table.
-         * 
- * - * string destination_table = 2; - * - * @return The bytes for destinationTable. - */ - public com.google.protobuf.ByteString getDestinationTableBytes() { - java.lang.Object ref = destinationTable_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - destinationTable_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-         * Destination table.
-         * 
- * - * string destination_table = 2; - * - * @param value The destinationTable to set. - * @return This builder for chaining. - */ - public Builder setDestinationTable(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - destinationTable_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table.
-         * 
- * - * string destination_table = 2; - * - * @return This builder for chaining. - */ - public Builder clearDestinationTable() { - - destinationTable_ = getDefaultInstance().getDestinationTable(); - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table.
-         * 
- * - * string destination_table = 2; - * - * @param value The bytes for destinationTable to set. - * @return This builder for chaining. - */ - public Builder setDestinationTableBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - destinationTable_ = value; - onChanged(); - return this; - } - - private int createDisposition_ = 0; - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The enum numeric value on the wire for createDisposition. - */ - @java.lang.Override - public int getCreateDispositionValue() { - return createDisposition_; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @param value The enum numeric value on the wire for createDisposition to set. - * @return This builder for chaining. - */ - public Builder setCreateDispositionValue(int value) { - - createDisposition_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return The createDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition - getCreateDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.valueOf( - createDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition.UNRECOGNIZED - : result; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @param value The createDisposition to set. - * @return This builder for chaining. - */ - public Builder setCreateDisposition( - com.google.cloud.audit.BigQueryAuditMetadata.CreateDisposition value) { - if (value == null) { - throw new NullPointerException(); - } - - createDisposition_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table create disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.CreateDisposition create_disposition = 3; - * - * - * @return This builder for chaining. - */ - public Builder clearCreateDisposition() { - - createDisposition_ = 0; - onChanged(); - return this; - } - - private int writeDisposition_ = 0; - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The enum numeric value on the wire for writeDisposition. - */ - @java.lang.Override - public int getWriteDispositionValue() { - return writeDisposition_; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @param value The enum numeric value on the wire for writeDisposition to set. - * @return This builder for chaining. - */ - public Builder setWriteDispositionValue(int value) { - - writeDisposition_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return The writeDisposition. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition getWriteDisposition() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition result = - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.valueOf( - writeDisposition_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition.UNRECOGNIZED - : result; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @param value The writeDisposition to set. - * @return This builder for chaining. - */ - public Builder setWriteDisposition( - com.google.cloud.audit.BigQueryAuditMetadata.WriteDisposition value) { - if (value == null) { - throw new NullPointerException(); - } - - writeDisposition_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-         * Destination table write disposition.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.WriteDisposition write_disposition = 4; - * - * - * @return This builder for chaining. - */ - public Builder clearWriteDisposition() { - - writeDisposition_ = 0; - onChanged(); - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - destinationTableEncryption_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - destinationTableEncryptionBuilder_; - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - * - * @return Whether the destinationTableEncryption field is set. - */ - public boolean hasDestinationTableEncryption() { - return destinationTableEncryptionBuilder_ != null || destinationTableEncryption_ != null; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - * - * @return The destinationTableEncryption. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - getDestinationTableEncryption() { - if (destinationTableEncryptionBuilder_ == null) { - return destinationTableEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : destinationTableEncryption_; - } else { - return destinationTableEncryptionBuilder_.getMessage(); - } - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - */ - public Builder setDestinationTableEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (destinationTableEncryptionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - destinationTableEncryption_ = value; - onChanged(); - } else { - destinationTableEncryptionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - */ - public Builder setDestinationTableEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryption_ = builderForValue.build(); - onChanged(); - } else { - destinationTableEncryptionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - */ - public Builder mergeDestinationTableEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (destinationTableEncryptionBuilder_ == null) { - if (destinationTableEncryption_ != null) { - destinationTableEncryption_ = - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder( - destinationTableEncryption_) - .mergeFrom(value) - .buildPartial(); - } else { - destinationTableEncryption_ = value; - } - onChanged(); - } else { - destinationTableEncryptionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - */ - public Builder clearDestinationTableEncryption() { - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryption_ = null; - onChanged(); - } else { - destinationTableEncryption_ = null; - destinationTableEncryptionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder - getDestinationTableEncryptionBuilder() { - - onChanged(); - return getDestinationTableEncryptionFieldBuilder().getBuilder(); - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getDestinationTableEncryptionOrBuilder() { - if (destinationTableEncryptionBuilder_ != null) { - return destinationTableEncryptionBuilder_.getMessageOrBuilder(); - } else { - return destinationTableEncryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : destinationTableEncryption_; - } - } - /** - * - * - *
-         * Result table encryption information. Set when non-default encryption is
-         * used.
-         * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo destination_table_encryption = 5; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - getDestinationTableEncryptionFieldBuilder() { - if (destinationTableEncryptionBuilder_ == null) { - destinationTableEncryptionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( - getDestinationTableEncryption(), getParentForChildren(), isClean()); - destinationTableEncryption_ = null; - } - return destinationTableEncryptionBuilder_; - } - - private int operationType_ = 0; - /** - * - * - *
-         * Supported operation types in the table copy job.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; - * - * @return The enum numeric value on the wire for operationType. - */ - @java.lang.Override - public int getOperationTypeValue() { - return operationType_; - } - /** - * - * - *
-         * Supported operation types in the table copy job.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; - * - * @param value The enum numeric value on the wire for operationType to set. - * @return This builder for chaining. - */ - public Builder setOperationTypeValue(int value) { - - operationType_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Supported operation types in the table copy job.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; - * - * @return The operationType. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.OperationType getOperationType() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.OperationType result = - com.google.cloud.audit.BigQueryAuditMetadata.OperationType.valueOf(operationType_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.OperationType.UNRECOGNIZED - : result; - } - /** - * - * - *
-         * Supported operation types in the table copy job.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; - * - * @param value The operationType to set. - * @return This builder for chaining. - */ - public Builder setOperationType( - com.google.cloud.audit.BigQueryAuditMetadata.OperationType value) { - if (value == null) { - throw new NullPointerException(); - } - - operationType_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-         * Supported operation types in the table copy job.
-         * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.OperationType operation_type = 7; - * - * @return This builder for chaining. - */ - public Builder clearOperationType() { - - operationType_ = 0; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp destinationExpirationTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - destinationExpirationTimeBuilder_; - /** - * - * - *
-         * Expiration time set on the destination table. Expired tables will be
-         * deleted and their storage reclaimed.
-         * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - * - * @return Whether the destinationExpirationTime field is set. - */ - public boolean hasDestinationExpirationTime() { - return destinationExpirationTimeBuilder_ != null || destinationExpirationTime_ != null; - } - /** - * - * - *
-         * Expiration time set on the destination table. Expired tables will be
-         * deleted and their storage reclaimed.
-         * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - * - * @return The destinationExpirationTime. - */ - public com.google.protobuf.Timestamp getDestinationExpirationTime() { - if (destinationExpirationTimeBuilder_ == null) { - return destinationExpirationTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : destinationExpirationTime_; - } else { - return destinationExpirationTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-         * Expiration time set on the destination table. Expired tables will be
-         * deleted and their storage reclaimed.
-         * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - */ - public Builder setDestinationExpirationTime(com.google.protobuf.Timestamp value) { - if (destinationExpirationTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - destinationExpirationTime_ = value; - onChanged(); - } else { - destinationExpirationTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-         * Expiration time set on the destination table. Expired tables will be
-         * deleted and their storage reclaimed.
-         * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - */ - public Builder setDestinationExpirationTime( - com.google.protobuf.Timestamp.Builder builderForValue) { - if (destinationExpirationTimeBuilder_ == null) { - destinationExpirationTime_ = builderForValue.build(); - onChanged(); - } else { - destinationExpirationTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-         * Expiration time set on the destination table. Expired tables will be
-         * deleted and their storage reclaimed.
-         * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - */ - public Builder mergeDestinationExpirationTime(com.google.protobuf.Timestamp value) { - if (destinationExpirationTimeBuilder_ == null) { - if (destinationExpirationTime_ != null) { - destinationExpirationTime_ = - com.google.protobuf.Timestamp.newBuilder(destinationExpirationTime_) - .mergeFrom(value) - .buildPartial(); - } else { - destinationExpirationTime_ = value; - } - onChanged(); - } else { - destinationExpirationTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-         * Expiration time set on the destination table. Expired tables will be
-         * deleted and their storage reclaimed.
-         * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - */ - public Builder clearDestinationExpirationTime() { - if (destinationExpirationTimeBuilder_ == null) { - destinationExpirationTime_ = null; - onChanged(); - } else { - destinationExpirationTime_ = null; - destinationExpirationTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-         * Expiration time set on the destination table. Expired tables will be
-         * deleted and their storage reclaimed.
-         * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - */ - public com.google.protobuf.Timestamp.Builder getDestinationExpirationTimeBuilder() { - - onChanged(); - return getDestinationExpirationTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-         * Expiration time set on the destination table. Expired tables will be
-         * deleted and their storage reclaimed.
-         * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - */ - public com.google.protobuf.TimestampOrBuilder getDestinationExpirationTimeOrBuilder() { - if (destinationExpirationTimeBuilder_ != null) { - return destinationExpirationTimeBuilder_.getMessageOrBuilder(); - } else { - return destinationExpirationTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : destinationExpirationTime_; - } - } - /** - * - * - *
-         * Expiration time set on the destination table. Expired tables will be
-         * deleted and their storage reclaimed.
-         * 
- * - * .google.protobuf.Timestamp destination_expiration_time = 8; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getDestinationExpirationTimeFieldBuilder() { - if (destinationExpirationTimeBuilder_ == null) { - destinationExpirationTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getDestinationExpirationTime(), getParentForChildren(), isClean()); - destinationExpirationTime_ = null; - } - return destinationExpirationTimeBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public TableCopy parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TableCopy(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - private int configCase_ = 0; - private java.lang.Object config_; - - public enum ConfigCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - QUERY_CONFIG(2), - LOAD_CONFIG(3), - EXTRACT_CONFIG(4), - TABLE_COPY_CONFIG(5), - CONFIG_NOT_SET(0); - private final int value; - - private ConfigCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static ConfigCase valueOf(int value) { - return forNumber(value); - } - - public static ConfigCase forNumber(int value) { - switch (value) { - case 2: - return QUERY_CONFIG; - case 3: - return LOAD_CONFIG; - case 4: - return EXTRACT_CONFIG; - case 5: - return TABLE_COPY_CONFIG; - case 0: - return CONFIG_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public ConfigCase getConfigCase() { - return ConfigCase.forNumber(configCase_); - } - - public static final int TYPE_FIELD_NUMBER = 1; - private int type_; - /** - * - * - *
-     * Job type.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; - * - * @return The enum numeric value on the wire for type. - */ - @java.lang.Override - public int getTypeValue() { - return type_; - } - /** - * - * - *
-     * Job type.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; - * - * @return The type. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type getType() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type result = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.valueOf(type_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.UNRECOGNIZED - : result; - } - - public static final int QUERY_CONFIG_FIELD_NUMBER = 2; - /** - * - * - *
-     * Query job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - * - * @return Whether the queryConfig field is set. - */ - @java.lang.Override - public boolean hasQueryConfig() { - return configCase_ == 2; - } - /** - * - * - *
-     * Query job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - * - * @return The queryConfig. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query getQueryConfig() { - if (configCase_ == 2) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); - } - /** - * - * - *
-     * Query job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder - getQueryConfigOrBuilder() { - if (configCase_ == 2) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); - } - - public static final int LOAD_CONFIG_FIELD_NUMBER = 3; - /** - * - * - *
-     * Load job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - * - * @return Whether the loadConfig field is set. - */ - @java.lang.Override - public boolean hasLoadConfig() { - return configCase_ == 3; - } - /** - * - * - *
-     * Load job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - * - * @return The loadConfig. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load getLoadConfig() { - if (configCase_ == 3) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); - } - /** - * - * - *
-     * Load job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder - getLoadConfigOrBuilder() { - if (configCase_ == 3) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); - } - - public static final int EXTRACT_CONFIG_FIELD_NUMBER = 4; - /** - * - * - *
-     * Extract job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - * @return Whether the extractConfig field is set. - */ - @java.lang.Override - public boolean hasExtractConfig() { - return configCase_ == 4; - } - /** - * - * - *
-     * Extract job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - * @return The extractConfig. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract getExtractConfig() { - if (configCase_ == 4) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.getDefaultInstance(); - } - /** - * - * - *
-     * Extract job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder - getExtractConfigOrBuilder() { - if (configCase_ == 4) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.getDefaultInstance(); - } - - public static final int TABLE_COPY_CONFIG_FIELD_NUMBER = 5; - /** - * - * - *
-     * TableCopy job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - * - * @return Whether the tableCopyConfig field is set. - */ - @java.lang.Override - public boolean hasTableCopyConfig() { - return configCase_ == 5; - } - /** - * - * - *
-     * TableCopy job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - * - * @return The tableCopyConfig. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy getTableCopyConfig() { - if (configCase_ == 5) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.getDefaultInstance(); - } - /** - * - * - *
-     * TableCopy job information.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder - getTableCopyConfigOrBuilder() { - if (configCase_ == 5) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.getDefaultInstance(); - } - - public static final int LABELS_FIELD_NUMBER = 6; - - private static final class LabelsDefaultEntryHolder { - static final com.google.protobuf.MapEntry defaultEntry = - com.google.protobuf.MapEntry.newDefaultInstance( - com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - - private com.google.protobuf.MapField labels_; - - private com.google.protobuf.MapField internalGetLabels() { - if (labels_ == null) { - return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); - } - return labels_; - } - - public int getLabelsCount() { - return internalGetLabels().getMap().size(); - } - /** - * - * - *
-     * Labels provided for the job.
-     * 
- * - * map<string, string> labels = 6; - */ - @java.lang.Override - public boolean containsLabels(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetLabels().getMap().containsKey(key); - } - /** Use {@link #getLabelsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getLabels() { - return getLabelsMap(); - } - /** - * - * - *
-     * Labels provided for the job.
-     * 
- * - * map<string, string> labels = 6; - */ - @java.lang.Override - public java.util.Map getLabelsMap() { - return internalGetLabels().getMap(); - } - /** - * - * - *
-     * Labels provided for the job.
-     * 
- * - * map<string, string> labels = 6; - */ - @java.lang.Override - public java.lang.String getLabelsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Labels provided for the job.
-     * 
- * - * map<string, string> labels = 6; - */ - @java.lang.Override - public java.lang.String getLabelsOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (type_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.TYPE_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, type_); - } - if (configCase_ == 2) { - output.writeMessage( - 2, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_); - } - if (configCase_ == 3) { - output.writeMessage( - 3, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_); - } - if (configCase_ == 4) { - output.writeMessage( - 4, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_); - } - if (configCase_ == 5) { - output.writeMessage( - 5, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 6); - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (type_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.TYPE_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, type_); - } - if (configCase_ == 2) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 2, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_); - } - if (configCase_ == 3) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 3, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_); - } - if (configCase_ == 4) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 4, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_); - } - if (configCase_ == 5) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 5, (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_); - } - for (java.util.Map.Entry entry : - internalGetLabels().getMap().entrySet()) { - com.google.protobuf.MapEntry labels__ = - LabelsDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, labels__); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig) obj; - - if (type_ != other.type_) return false; - if (!internalGetLabels().equals(other.internalGetLabels())) return false; - if (!getConfigCase().equals(other.getConfigCase())) return false; - switch (configCase_) { - case 2: - if (!getQueryConfig().equals(other.getQueryConfig())) return false; - break; - case 3: - if (!getLoadConfig().equals(other.getLoadConfig())) return false; - break; - case 4: - if (!getExtractConfig().equals(other.getExtractConfig())) return false; - break; - case 5: - if (!getTableCopyConfig().equals(other.getTableCopyConfig())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TYPE_FIELD_NUMBER; - hash = (53 * hash) + type_; - if (!internalGetLabels().getMap().isEmpty()) { - hash = (37 * hash) + LABELS_FIELD_NUMBER; - hash = (53 * hash) + internalGetLabels().hashCode(); - } - switch (configCase_) { - case 2: - hash = (37 * hash) + QUERY_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getQueryConfig().hashCode(); - break; - case 3: - hash = (37 * hash) + LOAD_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getLoadConfig().hashCode(); - break; - case 4: - hash = (37 * hash) + EXTRACT_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getExtractConfig().hashCode(); - break; - case 5: - hash = (37 * hash) + TABLE_COPY_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getTableCopyConfig().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Job configuration.
-     * See the [Jobs](https://cloud.google.com/bigquery/docs/reference/v2/jobs)
-     * API resource for more details on individual fields.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobConfig} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobConfig) - com.google.cloud.audit.BigQueryAuditMetadata.JobConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 6: - return internalGetLabels(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 6: - return internalGetMutableLabels(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - type_ = 0; - - internalGetMutableLabels().clear(); - configCase_ = 0; - config_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig(this); - int from_bitField0_ = bitField0_; - result.type_ = type_; - if (configCase_ == 2) { - if (queryConfigBuilder_ == null) { - result.config_ = config_; - } else { - result.config_ = queryConfigBuilder_.build(); - } - } - if (configCase_ == 3) { - if (loadConfigBuilder_ == null) { - result.config_ = config_; - } else { - result.config_ = loadConfigBuilder_.build(); - } - } - if (configCase_ == 4) { - if (extractConfigBuilder_ == null) { - result.config_ = config_; - } else { - result.config_ = extractConfigBuilder_.build(); - } - } - if (configCase_ == 5) { - if (tableCopyConfigBuilder_ == null) { - result.config_ = config_; - } else { - result.config_ = tableCopyConfigBuilder_.build(); - } - } - result.labels_ = internalGetLabels(); - result.labels_.makeImmutable(); - result.configCase_ = configCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobConfig) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobConfig) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobConfig other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.getDefaultInstance()) - return this; - if (other.type_ != 0) { - setTypeValue(other.getTypeValue()); - } - internalGetMutableLabels().mergeFrom(other.internalGetLabels()); - switch (other.getConfigCase()) { - case QUERY_CONFIG: - { - mergeQueryConfig(other.getQueryConfig()); - break; - } - case LOAD_CONFIG: - { - mergeLoadConfig(other.getLoadConfig()); - break; - } - case EXTRACT_CONFIG: - { - mergeExtractConfig(other.getExtractConfig()); - break; - } - case TABLE_COPY_CONFIG: - { - mergeTableCopyConfig(other.getTableCopyConfig()); - break; - } - case CONFIG_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int configCase_ = 0; - private java.lang.Object config_; - - public ConfigCase getConfigCase() { - return ConfigCase.forNumber(configCase_); - } - - public Builder clearConfig() { - configCase_ = 0; - config_ = null; - onChanged(); - return this; - } - - private int bitField0_; - - private int type_ = 0; - /** - * - * - *
-       * Job type.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; - * - * @return The enum numeric value on the wire for type. - */ - @java.lang.Override - public int getTypeValue() { - return type_; - } - /** - * - * - *
-       * Job type.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; - * - * @param value The enum numeric value on the wire for type to set. - * @return This builder for chaining. - */ - public Builder setTypeValue(int value) { - - type_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Job type.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; - * - * @return The type. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type getType() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type result = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.valueOf(type_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Job type.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; - * - * @param value The type to set. - * @return This builder for chaining. - */ - public Builder setType(com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type value) { - if (value == null) { - throw new NullPointerException(); - } - - type_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Job type.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Type type = 1; - * - * @return This builder for chaining. - */ - public Builder clearType() { - - type_ = 0; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder> - queryConfigBuilder_; - /** - * - * - *
-       * Query job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - * - * @return Whether the queryConfig field is set. - */ - @java.lang.Override - public boolean hasQueryConfig() { - return configCase_ == 2; - } - /** - * - * - *
-       * Query job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - * - * @return The queryConfig. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query getQueryConfig() { - if (queryConfigBuilder_ == null) { - if (configCase_ == 2) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); - } else { - if (configCase_ == 2) { - return queryConfigBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); - } - } - /** - * - * - *
-       * Query job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - */ - public Builder setQueryConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query value) { - if (queryConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - config_ = value; - onChanged(); - } else { - queryConfigBuilder_.setMessage(value); - } - configCase_ = 2; - return this; - } - /** - * - * - *
-       * Query job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - */ - public Builder setQueryConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder builderForValue) { - if (queryConfigBuilder_ == null) { - config_ = builderForValue.build(); - onChanged(); - } else { - queryConfigBuilder_.setMessage(builderForValue.build()); - } - configCase_ = 2; - return this; - } - /** - * - * - *
-       * Query job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - */ - public Builder mergeQueryConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query value) { - if (queryConfigBuilder_ == null) { - if (configCase_ == 2 - && config_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query - .getDefaultInstance()) { - config_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_) - .mergeFrom(value) - .buildPartial(); - } else { - config_ = value; - } - onChanged(); - } else { - if (configCase_ == 2) { - queryConfigBuilder_.mergeFrom(value); - } - queryConfigBuilder_.setMessage(value); - } - configCase_ = 2; - return this; - } - /** - * - * - *
-       * Query job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - */ - public Builder clearQueryConfig() { - if (queryConfigBuilder_ == null) { - if (configCase_ == 2) { - configCase_ = 0; - config_ = null; - onChanged(); - } - } else { - if (configCase_ == 2) { - configCase_ = 0; - config_ = null; - } - queryConfigBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * Query job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder - getQueryConfigBuilder() { - return getQueryConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Query job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder - getQueryConfigOrBuilder() { - if ((configCase_ == 2) && (queryConfigBuilder_ != null)) { - return queryConfigBuilder_.getMessageOrBuilder(); - } else { - if (configCase_ == 2) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); - } - } - /** - * - * - *
-       * Query job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query query_config = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder> - getQueryConfigFieldBuilder() { - if (queryConfigBuilder_ == null) { - if (!(configCase_ == 2)) { - config_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.getDefaultInstance(); - } - queryConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.QueryOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Query) config_, - getParentForChildren(), - isClean()); - config_ = null; - } - configCase_ = 2; - onChanged(); - ; - return queryConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder> - loadConfigBuilder_; - /** - * - * - *
-       * Load job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - * - * @return Whether the loadConfig field is set. - */ - @java.lang.Override - public boolean hasLoadConfig() { - return configCase_ == 3; - } - /** - * - * - *
-       * Load job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - * - * @return The loadConfig. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load getLoadConfig() { - if (loadConfigBuilder_ == null) { - if (configCase_ == 3) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); - } else { - if (configCase_ == 3) { - return loadConfigBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); - } - } - /** - * - * - *
-       * Load job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - */ - public Builder setLoadConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load value) { - if (loadConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - config_ = value; - onChanged(); - } else { - loadConfigBuilder_.setMessage(value); - } - configCase_ = 3; - return this; - } - /** - * - * - *
-       * Load job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - */ - public Builder setLoadConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder builderForValue) { - if (loadConfigBuilder_ == null) { - config_ = builderForValue.build(); - onChanged(); - } else { - loadConfigBuilder_.setMessage(builderForValue.build()); - } - configCase_ = 3; - return this; - } - /** - * - * - *
-       * Load job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - */ - public Builder mergeLoadConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load value) { - if (loadConfigBuilder_ == null) { - if (configCase_ == 3 - && config_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load - .getDefaultInstance()) { - config_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_) - .mergeFrom(value) - .buildPartial(); - } else { - config_ = value; - } - onChanged(); - } else { - if (configCase_ == 3) { - loadConfigBuilder_.mergeFrom(value); - } - loadConfigBuilder_.setMessage(value); - } - configCase_ = 3; - return this; - } - /** - * - * - *
-       * Load job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - */ - public Builder clearLoadConfig() { - if (loadConfigBuilder_ == null) { - if (configCase_ == 3) { - configCase_ = 0; - config_ = null; - onChanged(); - } - } else { - if (configCase_ == 3) { - configCase_ = 0; - config_ = null; - } - loadConfigBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * Load job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder - getLoadConfigBuilder() { - return getLoadConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Load job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder - getLoadConfigOrBuilder() { - if ((configCase_ == 3) && (loadConfigBuilder_ != null)) { - return loadConfigBuilder_.getMessageOrBuilder(); - } else { - if (configCase_ == 3) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); - } - } - /** - * - * - *
-       * Load job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load load_config = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder> - getLoadConfigFieldBuilder() { - if (loadConfigBuilder_ == null) { - if (!(configCase_ == 3)) { - config_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.getDefaultInstance(); - } - loadConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.LoadOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Load) config_, - getParentForChildren(), - isClean()); - config_ = null; - } - configCase_ = 3; - onChanged(); - ; - return loadConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder> - extractConfigBuilder_; - /** - * - * - *
-       * Extract job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - * - * @return Whether the extractConfig field is set. - */ - @java.lang.Override - public boolean hasExtractConfig() { - return configCase_ == 4; - } - /** - * - * - *
-       * Extract job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - * - * @return The extractConfig. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract getExtractConfig() { - if (extractConfigBuilder_ == null) { - if (configCase_ == 4) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - .getDefaultInstance(); - } else { - if (configCase_ == 4) { - return extractConfigBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - .getDefaultInstance(); - } - } - /** - * - * - *
-       * Extract job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - */ - public Builder setExtractConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract value) { - if (extractConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - config_ = value; - onChanged(); - } else { - extractConfigBuilder_.setMessage(value); - } - configCase_ = 4; - return this; - } - /** - * - * - *
-       * Extract job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - */ - public Builder setExtractConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder builderForValue) { - if (extractConfigBuilder_ == null) { - config_ = builderForValue.build(); - onChanged(); - } else { - extractConfigBuilder_.setMessage(builderForValue.build()); - } - configCase_ = 4; - return this; - } - /** - * - * - *
-       * Extract job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - */ - public Builder mergeExtractConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract value) { - if (extractConfigBuilder_ == null) { - if (configCase_ == 4 - && config_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - .getDefaultInstance()) { - config_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_) - .mergeFrom(value) - .buildPartial(); - } else { - config_ = value; - } - onChanged(); - } else { - if (configCase_ == 4) { - extractConfigBuilder_.mergeFrom(value); - } - extractConfigBuilder_.setMessage(value); - } - configCase_ = 4; - return this; - } - /** - * - * - *
-       * Extract job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - */ - public Builder clearExtractConfig() { - if (extractConfigBuilder_ == null) { - if (configCase_ == 4) { - configCase_ = 0; - config_ = null; - onChanged(); - } - } else { - if (configCase_ == 4) { - configCase_ = 0; - config_ = null; - } - extractConfigBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * Extract job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder - getExtractConfigBuilder() { - return getExtractConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Extract job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder - getExtractConfigOrBuilder() { - if ((configCase_ == 4) && (extractConfigBuilder_ != null)) { - return extractConfigBuilder_.getMessageOrBuilder(); - } else { - if (configCase_ == 4) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract - .getDefaultInstance(); - } - } - /** - * - * - *
-       * Extract job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract extract_config = 4; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder> - getExtractConfigFieldBuilder() { - if (extractConfigBuilder_ == null) { - if (!(configCase_ == 4)) { - config_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.getDefaultInstance(); - } - extractConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.ExtractOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.Extract) config_, - getParentForChildren(), - isClean()); - config_ = null; - } - configCase_ = 4; - onChanged(); - ; - return extractConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder> - tableCopyConfigBuilder_; - /** - * - * - *
-       * TableCopy job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - * - * @return Whether the tableCopyConfig field is set. - */ - @java.lang.Override - public boolean hasTableCopyConfig() { - return configCase_ == 5; - } - /** - * - * - *
-       * TableCopy job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - * - * @return The tableCopyConfig. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy getTableCopyConfig() { - if (tableCopyConfigBuilder_ == null) { - if (configCase_ == 5) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - .getDefaultInstance(); - } else { - if (configCase_ == 5) { - return tableCopyConfigBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - .getDefaultInstance(); - } - } - /** - * - * - *
-       * TableCopy job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - */ - public Builder setTableCopyConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy value) { - if (tableCopyConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - config_ = value; - onChanged(); - } else { - tableCopyConfigBuilder_.setMessage(value); - } - configCase_ = 5; - return this; - } - /** - * - * - *
-       * TableCopy job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - */ - public Builder setTableCopyConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder - builderForValue) { - if (tableCopyConfigBuilder_ == null) { - config_ = builderForValue.build(); - onChanged(); - } else { - tableCopyConfigBuilder_.setMessage(builderForValue.build()); - } - configCase_ = 5; - return this; - } - /** - * - * - *
-       * TableCopy job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - */ - public Builder mergeTableCopyConfig( - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy value) { - if (tableCopyConfigBuilder_ == null) { - if (configCase_ == 5 - && config_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - .getDefaultInstance()) { - config_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_) - .mergeFrom(value) - .buildPartial(); - } else { - config_ = value; - } - onChanged(); - } else { - if (configCase_ == 5) { - tableCopyConfigBuilder_.mergeFrom(value); - } - tableCopyConfigBuilder_.setMessage(value); - } - configCase_ = 5; - return this; - } - /** - * - * - *
-       * TableCopy job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - */ - public Builder clearTableCopyConfig() { - if (tableCopyConfigBuilder_ == null) { - if (configCase_ == 5) { - configCase_ = 0; - config_ = null; - onChanged(); - } - } else { - if (configCase_ == 5) { - configCase_ = 0; - config_ = null; - } - tableCopyConfigBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * TableCopy job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder - getTableCopyConfigBuilder() { - return getTableCopyConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * TableCopy job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder - getTableCopyConfigOrBuilder() { - if ((configCase_ == 5) && (tableCopyConfigBuilder_ != null)) { - return tableCopyConfigBuilder_.getMessageOrBuilder(); - } else { - if (configCase_ == 5) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - .getDefaultInstance(); - } - } - /** - * - * - *
-       * TableCopy job information.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy table_copy_config = 5; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder> - getTableCopyConfigFieldBuilder() { - if (tableCopyConfigBuilder_ == null) { - if (!(configCase_ == 5)) { - config_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy - .getDefaultInstance(); - } - tableCopyConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopyOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.JobConfig.TableCopy) config_, - getParentForChildren(), - isClean()); - config_ = null; - } - configCase_ = 5; - onChanged(); - ; - return tableCopyConfigBuilder_; - } - - private com.google.protobuf.MapField labels_; - - private com.google.protobuf.MapField internalGetLabels() { - if (labels_ == null) { - return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); - } - return labels_; - } - - private com.google.protobuf.MapField - internalGetMutableLabels() { - onChanged(); - ; - if (labels_ == null) { - labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); - } - if (!labels_.isMutable()) { - labels_ = labels_.copy(); - } - return labels_; - } - - public int getLabelsCount() { - return internalGetLabels().getMap().size(); - } - /** - * - * - *
-       * Labels provided for the job.
-       * 
- * - * map<string, string> labels = 6; - */ - @java.lang.Override - public boolean containsLabels(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetLabels().getMap().containsKey(key); - } - /** Use {@link #getLabelsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getLabels() { - return getLabelsMap(); - } - /** - * - * - *
-       * Labels provided for the job.
-       * 
- * - * map<string, string> labels = 6; - */ - @java.lang.Override - public java.util.Map getLabelsMap() { - return internalGetLabels().getMap(); - } - /** - * - * - *
-       * Labels provided for the job.
-       * 
- * - * map<string, string> labels = 6; - */ - @java.lang.Override - public java.lang.String getLabelsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-       * Labels provided for the job.
-       * 
- * - * map<string, string> labels = 6; - */ - @java.lang.Override - public java.lang.String getLabelsOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearLabels() { - internalGetMutableLabels().getMutableMap().clear(); - return this; - } - /** - * - * - *
-       * Labels provided for the job.
-       * 
- * - * map<string, string> labels = 6; - */ - public Builder removeLabels(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableLabels().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableLabels() { - return internalGetMutableLabels().getMutableMap(); - } - /** - * - * - *
-       * Labels provided for the job.
-       * 
- * - * map<string, string> labels = 6; - */ - public Builder putLabels(java.lang.String key, java.lang.String value) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - if (value == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableLabels().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-       * Labels provided for the job.
-       * 
- * - * map<string, string> labels = 6; - */ - public Builder putAllLabels(java.util.Map values) { - internalGetMutableLabels().getMutableMap().putAll(values); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobConfig) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobConfig DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobConfig(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public JobConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new JobConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface TableDefinitionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableDefinition) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Name of the table, used in queries.
-     * 
- * - * string name = 1; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-     * Name of the table, used in queries.
-     * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-     * URIs for the data.
-     * 
- * - * repeated string source_uris = 2; - * - * @return A list containing the sourceUris. - */ - java.util.List getSourceUrisList(); - /** - * - * - *
-     * URIs for the data.
-     * 
- * - * repeated string source_uris = 2; - * - * @return The count of sourceUris. - */ - int getSourceUrisCount(); - /** - * - * - *
-     * URIs for the data.
-     * 
- * - * repeated string source_uris = 2; - * - * @param index The index of the element to return. - * @return The sourceUris at the given index. - */ - java.lang.String getSourceUris(int index); - /** - * - * - *
-     * URIs for the data.
-     * 
- * - * repeated string source_uris = 2; - * - * @param index The index of the value to return. - * @return The bytes of the sourceUris at the given index. - */ - com.google.protobuf.ByteString getSourceUrisBytes(int index); - } - /** - * - * - *
-   * Definition of an external data source used in a query.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDefinition} - */ - public static final class TableDefinition extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableDefinition) - TableDefinitionOrBuilder { - private static final long serialVersionUID = 0L; - // Use TableDefinition.newBuilder() to construct. - private TableDefinition(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private TableDefinition() { - name_ = ""; - sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TableDefinition(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private TableDefinition( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - sourceUris_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - sourceUris_.add(s); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - sourceUris_ = sourceUris_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-     * Name of the table, used in queries.
-     * 
- * - * string name = 1; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-     * Name of the table, used in queries.
-     * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SOURCE_URIS_FIELD_NUMBER = 2; - private com.google.protobuf.LazyStringList sourceUris_; - /** - * - * - *
-     * URIs for the data.
-     * 
- * - * repeated string source_uris = 2; - * - * @return A list containing the sourceUris. - */ - public com.google.protobuf.ProtocolStringList getSourceUrisList() { - return sourceUris_; - } - /** - * - * - *
-     * URIs for the data.
-     * 
- * - * repeated string source_uris = 2; - * - * @return The count of sourceUris. - */ - public int getSourceUrisCount() { - return sourceUris_.size(); - } - /** - * - * - *
-     * URIs for the data.
-     * 
- * - * repeated string source_uris = 2; - * - * @param index The index of the element to return. - * @return The sourceUris at the given index. - */ - public java.lang.String getSourceUris(int index) { - return sourceUris_.get(index); - } - /** - * - * - *
-     * URIs for the data.
-     * 
- * - * repeated string source_uris = 2; - * - * @param index The index of the value to return. - * @return The bytes of the sourceUris at the given index. - */ - public com.google.protobuf.ByteString getSourceUrisBytes(int index) { - return sourceUris_.getByteString(index); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - for (int i = 0; i < sourceUris_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, sourceUris_.getRaw(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - { - int dataSize = 0; - for (int i = 0; i < sourceUris_.size(); i++) { - dataSize += computeStringSizeNoTag(sourceUris_.getRaw(i)); - } - size += dataSize; - size += 1 * getSourceUrisList().size(); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition other = - (com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition) obj; - - if (!getName().equals(other.getName())) return false; - if (!getSourceUrisList().equals(other.getSourceUrisList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (getSourceUrisCount() > 0) { - hash = (37 * hash) + SOURCE_URIS_FIELD_NUMBER; - hash = (53 * hash) + getSourceUrisList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Definition of an external data source used in a query.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableDefinition} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableDefinition) - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinitionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition build() { - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition result = - new com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition(this); - int from_bitField0_ = bitField0_; - result.name_ = name_; - if (((bitField0_ & 0x00000001) != 0)) { - sourceUris_ = sourceUris_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.sourceUris_ = sourceUris_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.sourceUris_.isEmpty()) { - if (sourceUris_.isEmpty()) { - sourceUris_ = other.sourceUris_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureSourceUrisIsMutable(); - sourceUris_.addAll(other.sourceUris_); - } - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object name_ = ""; - /** - * - * - *
-       * Name of the table, used in queries.
-       * 
- * - * string name = 1; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Name of the table, used in queries.
-       * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Name of the table, used in queries.
-       * 
- * - * string name = 1; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Name of the table, used in queries.
-       * 
- * - * string name = 1; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-       * Name of the table, used in queries.
-       * 
- * - * string name = 1; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList sourceUris_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureSourceUrisIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - sourceUris_ = new com.google.protobuf.LazyStringArrayList(sourceUris_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-       * URIs for the data.
-       * 
- * - * repeated string source_uris = 2; - * - * @return A list containing the sourceUris. - */ - public com.google.protobuf.ProtocolStringList getSourceUrisList() { - return sourceUris_.getUnmodifiableView(); - } - /** - * - * - *
-       * URIs for the data.
-       * 
- * - * repeated string source_uris = 2; - * - * @return The count of sourceUris. - */ - public int getSourceUrisCount() { - return sourceUris_.size(); - } - /** - * - * - *
-       * URIs for the data.
-       * 
- * - * repeated string source_uris = 2; - * - * @param index The index of the element to return. - * @return The sourceUris at the given index. - */ - public java.lang.String getSourceUris(int index) { - return sourceUris_.get(index); - } - /** - * - * - *
-       * URIs for the data.
-       * 
- * - * repeated string source_uris = 2; - * - * @param index The index of the value to return. - * @return The bytes of the sourceUris at the given index. - */ - public com.google.protobuf.ByteString getSourceUrisBytes(int index) { - return sourceUris_.getByteString(index); - } - /** - * - * - *
-       * URIs for the data.
-       * 
- * - * repeated string source_uris = 2; - * - * @param index The index to set the value at. - * @param value The sourceUris to set. - * @return This builder for chaining. - */ - public Builder setSourceUris(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSourceUrisIsMutable(); - sourceUris_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-       * URIs for the data.
-       * 
- * - * repeated string source_uris = 2; - * - * @param value The sourceUris to add. - * @return This builder for chaining. - */ - public Builder addSourceUris(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSourceUrisIsMutable(); - sourceUris_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-       * URIs for the data.
-       * 
- * - * repeated string source_uris = 2; - * - * @param values The sourceUris to add. - * @return This builder for chaining. - */ - public Builder addAllSourceUris(java.lang.Iterable values) { - ensureSourceUrisIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, sourceUris_); - onChanged(); - return this; - } - /** - * - * - *
-       * URIs for the data.
-       * 
- * - * repeated string source_uris = 2; - * - * @return This builder for chaining. - */ - public Builder clearSourceUris() { - sourceUris_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-       * URIs for the data.
-       * 
- * - * repeated string source_uris = 2; - * - * @param value The bytes of the sourceUris to add. - * @return This builder for chaining. - */ - public Builder addSourceUrisBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureSourceUrisIsMutable(); - sourceUris_.add(value); - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableDefinition) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableDefinition) - private static final com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public TableDefinition parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TableDefinition(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDefinition - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface JobStatusOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStatus) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * State of the job.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; - * - * @return The enum numeric value on the wire for jobState. - */ - int getJobStateValue(); - /** - * - * - *
-     * State of the job.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; - * - * @return The jobState. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobState getJobState(); - - /** - * - * - *
-     * Job error, if the job failed.
-     * 
- * - * .google.rpc.Status error_result = 2; - * - * @return Whether the errorResult field is set. - */ - boolean hasErrorResult(); - /** - * - * - *
-     * Job error, if the job failed.
-     * 
- * - * .google.rpc.Status error_result = 2; - * - * @return The errorResult. - */ - com.google.rpc.Status getErrorResult(); - /** - * - * - *
-     * Job error, if the job failed.
-     * 
- * - * .google.rpc.Status error_result = 2; - */ - com.google.rpc.StatusOrBuilder getErrorResultOrBuilder(); - - /** - * - * - *
-     * Errors encountered during the running of the job. Does not necessarily
-     * mean that the job has completed or was unsuccessful.
-     * 
- * - * repeated .google.rpc.Status errors = 3; - */ - java.util.List getErrorsList(); - /** - * - * - *
-     * Errors encountered during the running of the job. Does not necessarily
-     * mean that the job has completed or was unsuccessful.
-     * 
- * - * repeated .google.rpc.Status errors = 3; - */ - com.google.rpc.Status getErrors(int index); - /** - * - * - *
-     * Errors encountered during the running of the job. Does not necessarily
-     * mean that the job has completed or was unsuccessful.
-     * 
- * - * repeated .google.rpc.Status errors = 3; - */ - int getErrorsCount(); - /** - * - * - *
-     * Errors encountered during the running of the job. Does not necessarily
-     * mean that the job has completed or was unsuccessful.
-     * 
- * - * repeated .google.rpc.Status errors = 3; - */ - java.util.List getErrorsOrBuilderList(); - /** - * - * - *
-     * Errors encountered during the running of the job. Does not necessarily
-     * mean that the job has completed or was unsuccessful.
-     * 
- * - * repeated .google.rpc.Status errors = 3; - */ - com.google.rpc.StatusOrBuilder getErrorsOrBuilder(int index); - } - /** - * - * - *
-   * Status of a job.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStatus} - */ - public static final class JobStatus extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStatus) - JobStatusOrBuilder { - private static final long serialVersionUID = 0L; - // Use JobStatus.newBuilder() to construct. - private JobStatus(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private JobStatus() { - jobState_ = 0; - errors_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new JobStatus(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private JobStatus( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - jobState_ = rawValue; - break; - } - case 18: - { - com.google.rpc.Status.Builder subBuilder = null; - if (errorResult_ != null) { - subBuilder = errorResult_.toBuilder(); - } - errorResult_ = input.readMessage(com.google.rpc.Status.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(errorResult_); - errorResult_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - errors_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - errors_.add(input.readMessage(com.google.rpc.Status.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - errors_ = java.util.Collections.unmodifiableList(errors_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder.class); - } - - public static final int JOB_STATE_FIELD_NUMBER = 1; - private int jobState_; - /** - * - * - *
-     * State of the job.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; - * - * @return The enum numeric value on the wire for jobState. - */ - @java.lang.Override - public int getJobStateValue() { - return jobState_; - } - /** - * - * - *
-     * State of the job.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; - * - * @return The jobState. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobState getJobState() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobState result = - com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(jobState_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED - : result; - } - - public static final int ERROR_RESULT_FIELD_NUMBER = 2; - private com.google.rpc.Status errorResult_; - /** - * - * - *
-     * Job error, if the job failed.
-     * 
- * - * .google.rpc.Status error_result = 2; - * - * @return Whether the errorResult field is set. - */ - @java.lang.Override - public boolean hasErrorResult() { - return errorResult_ != null; - } - /** - * - * - *
-     * Job error, if the job failed.
-     * 
- * - * .google.rpc.Status error_result = 2; - * - * @return The errorResult. - */ - @java.lang.Override - public com.google.rpc.Status getErrorResult() { - return errorResult_ == null ? com.google.rpc.Status.getDefaultInstance() : errorResult_; - } - /** - * - * - *
-     * Job error, if the job failed.
-     * 
- * - * .google.rpc.Status error_result = 2; - */ - @java.lang.Override - public com.google.rpc.StatusOrBuilder getErrorResultOrBuilder() { - return getErrorResult(); - } - - public static final int ERRORS_FIELD_NUMBER = 3; - private java.util.List errors_; - /** - * - * - *
-     * Errors encountered during the running of the job. Does not necessarily
-     * mean that the job has completed or was unsuccessful.
-     * 
- * - * repeated .google.rpc.Status errors = 3; - */ - @java.lang.Override - public java.util.List getErrorsList() { - return errors_; - } - /** - * - * - *
-     * Errors encountered during the running of the job. Does not necessarily
-     * mean that the job has completed or was unsuccessful.
-     * 
- * - * repeated .google.rpc.Status errors = 3; - */ - @java.lang.Override - public java.util.List getErrorsOrBuilderList() { - return errors_; - } - /** - * - * - *
-     * Errors encountered during the running of the job. Does not necessarily
-     * mean that the job has completed or was unsuccessful.
-     * 
- * - * repeated .google.rpc.Status errors = 3; - */ - @java.lang.Override - public int getErrorsCount() { - return errors_.size(); - } - /** - * - * - *
-     * Errors encountered during the running of the job. Does not necessarily
-     * mean that the job has completed or was unsuccessful.
-     * 
- * - * repeated .google.rpc.Status errors = 3; - */ - @java.lang.Override - public com.google.rpc.Status getErrors(int index) { - return errors_.get(index); - } - /** - * - * - *
-     * Errors encountered during the running of the job. Does not necessarily
-     * mean that the job has completed or was unsuccessful.
-     * 
- * - * repeated .google.rpc.Status errors = 3; - */ - @java.lang.Override - public com.google.rpc.StatusOrBuilder getErrorsOrBuilder(int index) { - return errors_.get(index); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (jobState_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, jobState_); - } - if (errorResult_ != null) { - output.writeMessage(2, getErrorResult()); - } - for (int i = 0; i < errors_.size(); i++) { - output.writeMessage(3, errors_.get(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (jobState_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobState.JOB_STATE_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, jobState_); - } - if (errorResult_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getErrorResult()); - } - for (int i = 0; i < errors_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, errors_.get(i)); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStatus)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStatus) obj; - - if (jobState_ != other.jobState_) return false; - if (hasErrorResult() != other.hasErrorResult()) return false; - if (hasErrorResult()) { - if (!getErrorResult().equals(other.getErrorResult())) return false; - } - if (!getErrorsList().equals(other.getErrorsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + JOB_STATE_FIELD_NUMBER; - hash = (53 * hash) + jobState_; - if (hasErrorResult()) { - hash = (37 * hash) + ERROR_RESULT_FIELD_NUMBER; - hash = (53 * hash) + getErrorResult().hashCode(); - } - if (getErrorsCount() > 0) { - hash = (37 * hash) + ERRORS_FIELD_NUMBER; - hash = (53 * hash) + getErrorsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Status of a job.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStatus} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStatus) - com.google.cloud.audit.BigQueryAuditMetadata.JobStatusOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getErrorsFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - jobState_ = 0; - - if (errorResultBuilder_ == null) { - errorResult_ = null; - } else { - errorResult_ = null; - errorResultBuilder_ = null; - } - if (errorsBuilder_ == null) { - errors_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - errorsBuilder_.clear(); - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobStatus(this); - int from_bitField0_ = bitField0_; - result.jobState_ = jobState_; - if (errorResultBuilder_ == null) { - result.errorResult_ = errorResult_; - } else { - result.errorResult_ = errorResultBuilder_.build(); - } - if (errorsBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - errors_ = java.util.Collections.unmodifiableList(errors_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.errors_ = errors_; - } else { - result.errors_ = errorsBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStatus) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobStatus) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobStatus other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.JobStatus.getDefaultInstance()) - return this; - if (other.jobState_ != 0) { - setJobStateValue(other.getJobStateValue()); - } - if (other.hasErrorResult()) { - mergeErrorResult(other.getErrorResult()); - } - if (errorsBuilder_ == null) { - if (!other.errors_.isEmpty()) { - if (errors_.isEmpty()) { - errors_ = other.errors_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureErrorsIsMutable(); - errors_.addAll(other.errors_); - } - onChanged(); - } - } else { - if (!other.errors_.isEmpty()) { - if (errorsBuilder_.isEmpty()) { - errorsBuilder_.dispose(); - errorsBuilder_ = null; - errors_ = other.errors_; - bitField0_ = (bitField0_ & ~0x00000001); - errorsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getErrorsFieldBuilder() - : null; - } else { - errorsBuilder_.addAllMessages(other.errors_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobStatus parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStatus) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private int jobState_ = 0; - /** - * - * - *
-       * State of the job.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; - * - * @return The enum numeric value on the wire for jobState. - */ - @java.lang.Override - public int getJobStateValue() { - return jobState_; - } - /** - * - * - *
-       * State of the job.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; - * - * @param value The enum numeric value on the wire for jobState to set. - * @return This builder for chaining. - */ - public Builder setJobStateValue(int value) { - - jobState_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * State of the job.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; - * - * @return The jobState. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobState getJobState() { - @SuppressWarnings("deprecation") - com.google.cloud.audit.BigQueryAuditMetadata.JobState result = - com.google.cloud.audit.BigQueryAuditMetadata.JobState.valueOf(jobState_); - return result == null - ? com.google.cloud.audit.BigQueryAuditMetadata.JobState.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * State of the job.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; - * - * @param value The jobState to set. - * @return This builder for chaining. - */ - public Builder setJobState(com.google.cloud.audit.BigQueryAuditMetadata.JobState value) { - if (value == null) { - throw new NullPointerException(); - } - - jobState_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * State of the job.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobState job_state = 1; - * - * @return This builder for chaining. - */ - public Builder clearJobState() { - - jobState_ = 0; - onChanged(); - return this; - } - - private com.google.rpc.Status errorResult_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> - errorResultBuilder_; - /** - * - * - *
-       * Job error, if the job failed.
-       * 
- * - * .google.rpc.Status error_result = 2; - * - * @return Whether the errorResult field is set. - */ - public boolean hasErrorResult() { - return errorResultBuilder_ != null || errorResult_ != null; - } - /** - * - * - *
-       * Job error, if the job failed.
-       * 
- * - * .google.rpc.Status error_result = 2; - * - * @return The errorResult. - */ - public com.google.rpc.Status getErrorResult() { - if (errorResultBuilder_ == null) { - return errorResult_ == null ? com.google.rpc.Status.getDefaultInstance() : errorResult_; - } else { - return errorResultBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Job error, if the job failed.
-       * 
- * - * .google.rpc.Status error_result = 2; - */ - public Builder setErrorResult(com.google.rpc.Status value) { - if (errorResultBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - errorResult_ = value; - onChanged(); - } else { - errorResultBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Job error, if the job failed.
-       * 
- * - * .google.rpc.Status error_result = 2; - */ - public Builder setErrorResult(com.google.rpc.Status.Builder builderForValue) { - if (errorResultBuilder_ == null) { - errorResult_ = builderForValue.build(); - onChanged(); - } else { - errorResultBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Job error, if the job failed.
-       * 
- * - * .google.rpc.Status error_result = 2; - */ - public Builder mergeErrorResult(com.google.rpc.Status value) { - if (errorResultBuilder_ == null) { - if (errorResult_ != null) { - errorResult_ = - com.google.rpc.Status.newBuilder(errorResult_).mergeFrom(value).buildPartial(); - } else { - errorResult_ = value; - } - onChanged(); - } else { - errorResultBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Job error, if the job failed.
-       * 
- * - * .google.rpc.Status error_result = 2; - */ - public Builder clearErrorResult() { - if (errorResultBuilder_ == null) { - errorResult_ = null; - onChanged(); - } else { - errorResult_ = null; - errorResultBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Job error, if the job failed.
-       * 
- * - * .google.rpc.Status error_result = 2; - */ - public com.google.rpc.Status.Builder getErrorResultBuilder() { - - onChanged(); - return getErrorResultFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Job error, if the job failed.
-       * 
- * - * .google.rpc.Status error_result = 2; - */ - public com.google.rpc.StatusOrBuilder getErrorResultOrBuilder() { - if (errorResultBuilder_ != null) { - return errorResultBuilder_.getMessageOrBuilder(); - } else { - return errorResult_ == null ? com.google.rpc.Status.getDefaultInstance() : errorResult_; - } - } - /** - * - * - *
-       * Job error, if the job failed.
-       * 
- * - * .google.rpc.Status error_result = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> - getErrorResultFieldBuilder() { - if (errorResultBuilder_ == null) { - errorResultBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.rpc.Status, - com.google.rpc.Status.Builder, - com.google.rpc.StatusOrBuilder>( - getErrorResult(), getParentForChildren(), isClean()); - errorResult_ = null; - } - return errorResultBuilder_; - } - - private java.util.List errors_ = java.util.Collections.emptyList(); - - private void ensureErrorsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - errors_ = new java.util.ArrayList(errors_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> - errorsBuilder_; - - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public java.util.List getErrorsList() { - if (errorsBuilder_ == null) { - return java.util.Collections.unmodifiableList(errors_); - } else { - return errorsBuilder_.getMessageList(); - } - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public int getErrorsCount() { - if (errorsBuilder_ == null) { - return errors_.size(); - } else { - return errorsBuilder_.getCount(); - } - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public com.google.rpc.Status getErrors(int index) { - if (errorsBuilder_ == null) { - return errors_.get(index); - } else { - return errorsBuilder_.getMessage(index); - } - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public Builder setErrors(int index, com.google.rpc.Status value) { - if (errorsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureErrorsIsMutable(); - errors_.set(index, value); - onChanged(); - } else { - errorsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public Builder setErrors(int index, com.google.rpc.Status.Builder builderForValue) { - if (errorsBuilder_ == null) { - ensureErrorsIsMutable(); - errors_.set(index, builderForValue.build()); - onChanged(); - } else { - errorsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public Builder addErrors(com.google.rpc.Status value) { - if (errorsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureErrorsIsMutable(); - errors_.add(value); - onChanged(); - } else { - errorsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public Builder addErrors(int index, com.google.rpc.Status value) { - if (errorsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureErrorsIsMutable(); - errors_.add(index, value); - onChanged(); - } else { - errorsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public Builder addErrors(com.google.rpc.Status.Builder builderForValue) { - if (errorsBuilder_ == null) { - ensureErrorsIsMutable(); - errors_.add(builderForValue.build()); - onChanged(); - } else { - errorsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public Builder addErrors(int index, com.google.rpc.Status.Builder builderForValue) { - if (errorsBuilder_ == null) { - ensureErrorsIsMutable(); - errors_.add(index, builderForValue.build()); - onChanged(); - } else { - errorsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public Builder addAllErrors(java.lang.Iterable values) { - if (errorsBuilder_ == null) { - ensureErrorsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, errors_); - onChanged(); - } else { - errorsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public Builder clearErrors() { - if (errorsBuilder_ == null) { - errors_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - errorsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public Builder removeErrors(int index) { - if (errorsBuilder_ == null) { - ensureErrorsIsMutable(); - errors_.remove(index); - onChanged(); - } else { - errorsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public com.google.rpc.Status.Builder getErrorsBuilder(int index) { - return getErrorsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public com.google.rpc.StatusOrBuilder getErrorsOrBuilder(int index) { - if (errorsBuilder_ == null) { - return errors_.get(index); - } else { - return errorsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public java.util.List getErrorsOrBuilderList() { - if (errorsBuilder_ != null) { - return errorsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(errors_); - } - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public com.google.rpc.Status.Builder addErrorsBuilder() { - return getErrorsFieldBuilder().addBuilder(com.google.rpc.Status.getDefaultInstance()); - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public com.google.rpc.Status.Builder addErrorsBuilder(int index) { - return getErrorsFieldBuilder() - .addBuilder(index, com.google.rpc.Status.getDefaultInstance()); - } - /** - * - * - *
-       * Errors encountered during the running of the job. Does not necessarily
-       * mean that the job has completed or was unsuccessful.
-       * 
- * - * repeated .google.rpc.Status errors = 3; - */ - public java.util.List getErrorsBuilderList() { - return getErrorsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> - getErrorsFieldBuilder() { - if (errorsBuilder_ == null) { - errorsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.rpc.Status, - com.google.rpc.Status.Builder, - com.google.rpc.StatusOrBuilder>( - errors_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - errors_ = null; - } - return errorsBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStatus) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStatus) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStatus DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobStatus(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public JobStatus parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new JobStatus(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStatus getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface JobStatsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStats) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Job creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 1; - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-     * Job creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 1; - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-     * Job creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-     * Job execution start time.
-     * 
- * - * .google.protobuf.Timestamp start_time = 2; - * - * @return Whether the startTime field is set. - */ - boolean hasStartTime(); - /** - * - * - *
-     * Job execution start time.
-     * 
- * - * .google.protobuf.Timestamp start_time = 2; - * - * @return The startTime. - */ - com.google.protobuf.Timestamp getStartTime(); - /** - * - * - *
-     * Job execution start time.
-     * 
- * - * .google.protobuf.Timestamp start_time = 2; - */ - com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder(); - - /** - * - * - *
-     * Job completion time.
-     * 
- * - * .google.protobuf.Timestamp end_time = 3; - * - * @return Whether the endTime field is set. - */ - boolean hasEndTime(); - /** - * - * - *
-     * Job completion time.
-     * 
- * - * .google.protobuf.Timestamp end_time = 3; - * - * @return The endTime. - */ - com.google.protobuf.Timestamp getEndTime(); - /** - * - * - *
-     * Job completion time.
-     * 
- * - * .google.protobuf.Timestamp end_time = 3; - */ - com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); - - /** - * - * - *
-     * Query job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - * - * @return Whether the queryStats field is set. - */ - boolean hasQueryStats(); - /** - * - * - *
-     * Query job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - * - * @return The queryStats. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query getQueryStats(); - /** - * - * - *
-     * Query job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder getQueryStatsOrBuilder(); - - /** - * - * - *
-     * Load job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - * - * @return Whether the loadStats field is set. - */ - boolean hasLoadStats(); - /** - * - * - *
-     * Load job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - * - * @return The loadStats. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load getLoadStats(); - /** - * - * - *
-     * Load job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder getLoadStatsOrBuilder(); - - /** - * - * - *
-     * Extract job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - * - * @return Whether the extractStats field is set. - */ - boolean hasExtractStats(); - /** - * - * - *
-     * Extract job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - * - * @return The extractStats. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract getExtractStats(); - /** - * - * - *
-     * Extract job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder - getExtractStatsOrBuilder(); - - /** - * - * - *
-     * The total number of slot-ms consumed by the query job.
-     * 
- * - * int64 total_slot_ms = 10; - * - * @return The totalSlotMs. - */ - long getTotalSlotMs(); - - /** - * - * - *
-     * Reservation usage attributed from each tier of a reservation hierarchy.
-     * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - java.util.List - getReservationUsageList(); - /** - * - * - *
-     * Reservation usage attributed from each tier of a reservation hierarchy.
-     * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - getReservationUsage(int index); - /** - * - * - *
-     * Reservation usage attributed from each tier of a reservation hierarchy.
-     * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - int getReservationUsageCount(); - /** - * - * - *
-     * Reservation usage attributed from each tier of a reservation hierarchy.
-     * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - java.util.List< - ? extends - com.google.cloud.audit.BigQueryAuditMetadata.JobStats - .ReservationResourceUsageOrBuilder> - getReservationUsageOrBuilderList(); - /** - * - * - *
-     * Reservation usage attributed from each tier of a reservation hierarchy.
-     * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsageOrBuilder - getReservationUsageOrBuilder(int index); - - /** - * - * - *
-     * Parent job name. Only present for child jobs.
-     * 
- * - * string parent_job_name = 12; - * - * @return The parentJobName. - */ - java.lang.String getParentJobName(); - /** - * - * - *
-     * Parent job name. Only present for child jobs.
-     * 
- * - * string parent_job_name = 12; - * - * @return The bytes for parentJobName. - */ - com.google.protobuf.ByteString getParentJobNameBytes(); - - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtendedCase getExtendedCase(); - } - /** - * - * - *
-   * Job statistics.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats} - */ - public static final class JobStats extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats) - JobStatsOrBuilder { - private static final long serialVersionUID = 0L; - // Use JobStats.newBuilder() to construct. - private JobStats(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private JobStats() { - reservationUsage_ = java.util.Collections.emptyList(); - parentJobName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new JobStats(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private JobStats( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (endTime_ != null) { - subBuilder = endTime_.toBuilder(); - } - endTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(endTime_); - endTime_ = subBuilder.buildPartial(); - } - - break; - } - case 66: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder subBuilder = - null; - if (extendedCase_ == 8) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_) - .toBuilder(); - } - extended_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_); - extended_ = subBuilder.buildPartial(); - } - extendedCase_ = 8; - break; - } - case 74: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder subBuilder = - null; - if (extendedCase_ == 9) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_) - .toBuilder(); - } - extended_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_); - extended_ = subBuilder.buildPartial(); - } - extendedCase_ = 9; - break; - } - case 80: - { - totalSlotMs_ = input.readInt64(); - break; - } - case 90: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - reservationUsage_ = - new java.util.ArrayList< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats - .ReservationResourceUsage>(); - mutable_bitField0_ |= 0x00000001; - } - reservationUsage_.add( - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats - .ReservationResourceUsage.parser(), - extensionRegistry)); - break; - } - case 98: - { - java.lang.String s = input.readStringRequireUtf8(); - - parentJobName_ = s; - break; - } - case 106: - { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder subBuilder = - null; - if (extendedCase_ == 13) { - subBuilder = - ((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_) - .toBuilder(); - } - extended_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_); - extended_ = subBuilder.buildPartial(); - } - extendedCase_ = 13; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - reservationUsage_ = java.util.Collections.unmodifiableList(reservationUsage_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder.class); - } - - public interface QueryOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-       * Total bytes processed by the query job.
-       * 
- * - * int64 total_processed_bytes = 1; - * - * @return The totalProcessedBytes. - */ - long getTotalProcessedBytes(); - - /** - * - * - *
-       * Total bytes billed by the query job.
-       * 
- * - * int64 total_billed_bytes = 2; - * - * @return The totalBilledBytes. - */ - long getTotalBilledBytes(); - - /** - * - * - *
-       * The tier assigned by the CPU-based billing.
-       * 
- * - * int32 billing_tier = 3; - * - * @return The billingTier. - */ - int getBillingTier(); - - /** - * - * - *
-       * Tables accessed by the query job.
-       * 
- * - * repeated string referenced_tables = 6; - * - * @return A list containing the referencedTables. - */ - java.util.List getReferencedTablesList(); - /** - * - * - *
-       * Tables accessed by the query job.
-       * 
- * - * repeated string referenced_tables = 6; - * - * @return The count of referencedTables. - */ - int getReferencedTablesCount(); - /** - * - * - *
-       * Tables accessed by the query job.
-       * 
- * - * repeated string referenced_tables = 6; - * - * @param index The index of the element to return. - * @return The referencedTables at the given index. - */ - java.lang.String getReferencedTables(int index); - /** - * - * - *
-       * Tables accessed by the query job.
-       * 
- * - * repeated string referenced_tables = 6; - * - * @param index The index of the value to return. - * @return The bytes of the referencedTables at the given index. - */ - com.google.protobuf.ByteString getReferencedTablesBytes(int index); - - /** - * - * - *
-       * Views accessed by the query job.
-       * 
- * - * repeated string referenced_views = 7; - * - * @return A list containing the referencedViews. - */ - java.util.List getReferencedViewsList(); - /** - * - * - *
-       * Views accessed by the query job.
-       * 
- * - * repeated string referenced_views = 7; - * - * @return The count of referencedViews. - */ - int getReferencedViewsCount(); - /** - * - * - *
-       * Views accessed by the query job.
-       * 
- * - * repeated string referenced_views = 7; - * - * @param index The index of the element to return. - * @return The referencedViews at the given index. - */ - java.lang.String getReferencedViews(int index); - /** - * - * - *
-       * Views accessed by the query job.
-       * 
- * - * repeated string referenced_views = 7; - * - * @param index The index of the value to return. - * @return The bytes of the referencedViews at the given index. - */ - com.google.protobuf.ByteString getReferencedViewsBytes(int index); - - /** - * - * - *
-       * Routines accessed by the query job.
-       * 
- * - * repeated string referenced_routines = 10; - * - * @return A list containing the referencedRoutines. - */ - java.util.List getReferencedRoutinesList(); - /** - * - * - *
-       * Routines accessed by the query job.
-       * 
- * - * repeated string referenced_routines = 10; - * - * @return The count of referencedRoutines. - */ - int getReferencedRoutinesCount(); - /** - * - * - *
-       * Routines accessed by the query job.
-       * 
- * - * repeated string referenced_routines = 10; - * - * @param index The index of the element to return. - * @return The referencedRoutines at the given index. - */ - java.lang.String getReferencedRoutines(int index); - /** - * - * - *
-       * Routines accessed by the query job.
-       * 
- * - * repeated string referenced_routines = 10; - * - * @param index The index of the value to return. - * @return The bytes of the referencedRoutines at the given index. - */ - com.google.protobuf.ByteString getReferencedRoutinesBytes(int index); - - /** - * - * - *
-       * Number of output rows produced by the query job.
-       * 
- * - * int64 output_row_count = 8; - * - * @return The outputRowCount. - */ - long getOutputRowCount(); - - /** - * - * - *
-       * True if the query job results were read from the query cache.
-       * 
- * - * bool cache_hit = 9; - * - * @return The cacheHit. - */ - boolean getCacheHit(); - } - /** - * - * - *
-     * Query job statistics.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Query} - */ - public static final class Query extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) - QueryOrBuilder { - private static final long serialVersionUID = 0L; - // Use Query.newBuilder() to construct. - private Query(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Query() { - referencedTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; - referencedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; - referencedRoutines_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Query(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Query( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - totalProcessedBytes_ = input.readInt64(); - break; - } - case 16: - { - totalBilledBytes_ = input.readInt64(); - break; - } - case 24: - { - billingTier_ = input.readInt32(); - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - referencedTables_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - referencedTables_.add(s); - break; - } - case 58: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - referencedViews_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - referencedViews_.add(s); - break; - } - case 64: - { - outputRowCount_ = input.readInt64(); - break; - } - case 72: - { - cacheHit_ = input.readBool(); - break; - } - case 82: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - referencedRoutines_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000004; - } - referencedRoutines_.add(s); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - referencedTables_ = referencedTables_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - referencedViews_ = referencedViews_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000004) != 0)) { - referencedRoutines_ = referencedRoutines_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder.class); - } - - public static final int TOTAL_PROCESSED_BYTES_FIELD_NUMBER = 1; - private long totalProcessedBytes_; - /** - * - * - *
-       * Total bytes processed by the query job.
-       * 
- * - * int64 total_processed_bytes = 1; - * - * @return The totalProcessedBytes. - */ - @java.lang.Override - public long getTotalProcessedBytes() { - return totalProcessedBytes_; - } - - public static final int TOTAL_BILLED_BYTES_FIELD_NUMBER = 2; - private long totalBilledBytes_; - /** - * - * - *
-       * Total bytes billed by the query job.
-       * 
- * - * int64 total_billed_bytes = 2; - * - * @return The totalBilledBytes. - */ - @java.lang.Override - public long getTotalBilledBytes() { - return totalBilledBytes_; - } - - public static final int BILLING_TIER_FIELD_NUMBER = 3; - private int billingTier_; - /** - * - * - *
-       * The tier assigned by the CPU-based billing.
-       * 
- * - * int32 billing_tier = 3; - * - * @return The billingTier. - */ - @java.lang.Override - public int getBillingTier() { - return billingTier_; - } - - public static final int REFERENCED_TABLES_FIELD_NUMBER = 6; - private com.google.protobuf.LazyStringList referencedTables_; - /** - * - * - *
-       * Tables accessed by the query job.
-       * 
- * - * repeated string referenced_tables = 6; - * - * @return A list containing the referencedTables. - */ - public com.google.protobuf.ProtocolStringList getReferencedTablesList() { - return referencedTables_; - } - /** - * - * - *
-       * Tables accessed by the query job.
-       * 
- * - * repeated string referenced_tables = 6; - * - * @return The count of referencedTables. - */ - public int getReferencedTablesCount() { - return referencedTables_.size(); - } - /** - * - * - *
-       * Tables accessed by the query job.
-       * 
- * - * repeated string referenced_tables = 6; - * - * @param index The index of the element to return. - * @return The referencedTables at the given index. - */ - public java.lang.String getReferencedTables(int index) { - return referencedTables_.get(index); - } - /** - * - * - *
-       * Tables accessed by the query job.
-       * 
- * - * repeated string referenced_tables = 6; - * - * @param index The index of the value to return. - * @return The bytes of the referencedTables at the given index. - */ - public com.google.protobuf.ByteString getReferencedTablesBytes(int index) { - return referencedTables_.getByteString(index); - } - - public static final int REFERENCED_VIEWS_FIELD_NUMBER = 7; - private com.google.protobuf.LazyStringList referencedViews_; - /** - * - * - *
-       * Views accessed by the query job.
-       * 
- * - * repeated string referenced_views = 7; - * - * @return A list containing the referencedViews. - */ - public com.google.protobuf.ProtocolStringList getReferencedViewsList() { - return referencedViews_; - } - /** - * - * - *
-       * Views accessed by the query job.
-       * 
- * - * repeated string referenced_views = 7; - * - * @return The count of referencedViews. - */ - public int getReferencedViewsCount() { - return referencedViews_.size(); - } - /** - * - * - *
-       * Views accessed by the query job.
-       * 
- * - * repeated string referenced_views = 7; - * - * @param index The index of the element to return. - * @return The referencedViews at the given index. - */ - public java.lang.String getReferencedViews(int index) { - return referencedViews_.get(index); - } - /** - * - * - *
-       * Views accessed by the query job.
-       * 
- * - * repeated string referenced_views = 7; - * - * @param index The index of the value to return. - * @return The bytes of the referencedViews at the given index. - */ - public com.google.protobuf.ByteString getReferencedViewsBytes(int index) { - return referencedViews_.getByteString(index); - } - - public static final int REFERENCED_ROUTINES_FIELD_NUMBER = 10; - private com.google.protobuf.LazyStringList referencedRoutines_; - /** - * - * - *
-       * Routines accessed by the query job.
-       * 
- * - * repeated string referenced_routines = 10; - * - * @return A list containing the referencedRoutines. - */ - public com.google.protobuf.ProtocolStringList getReferencedRoutinesList() { - return referencedRoutines_; - } - /** - * - * - *
-       * Routines accessed by the query job.
-       * 
- * - * repeated string referenced_routines = 10; - * - * @return The count of referencedRoutines. - */ - public int getReferencedRoutinesCount() { - return referencedRoutines_.size(); - } - /** - * - * - *
-       * Routines accessed by the query job.
-       * 
- * - * repeated string referenced_routines = 10; - * - * @param index The index of the element to return. - * @return The referencedRoutines at the given index. - */ - public java.lang.String getReferencedRoutines(int index) { - return referencedRoutines_.get(index); - } - /** - * - * - *
-       * Routines accessed by the query job.
-       * 
- * - * repeated string referenced_routines = 10; - * - * @param index The index of the value to return. - * @return The bytes of the referencedRoutines at the given index. - */ - public com.google.protobuf.ByteString getReferencedRoutinesBytes(int index) { - return referencedRoutines_.getByteString(index); - } - - public static final int OUTPUT_ROW_COUNT_FIELD_NUMBER = 8; - private long outputRowCount_; - /** - * - * - *
-       * Number of output rows produced by the query job.
-       * 
- * - * int64 output_row_count = 8; - * - * @return The outputRowCount. - */ - @java.lang.Override - public long getOutputRowCount() { - return outputRowCount_; - } - - public static final int CACHE_HIT_FIELD_NUMBER = 9; - private boolean cacheHit_; - /** - * - * - *
-       * True if the query job results were read from the query cache.
-       * 
- * - * bool cache_hit = 9; - * - * @return The cacheHit. - */ - @java.lang.Override - public boolean getCacheHit() { - return cacheHit_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (totalProcessedBytes_ != 0L) { - output.writeInt64(1, totalProcessedBytes_); - } - if (totalBilledBytes_ != 0L) { - output.writeInt64(2, totalBilledBytes_); - } - if (billingTier_ != 0) { - output.writeInt32(3, billingTier_); - } - for (int i = 0; i < referencedTables_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString( - output, 6, referencedTables_.getRaw(i)); - } - for (int i = 0; i < referencedViews_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 7, referencedViews_.getRaw(i)); - } - if (outputRowCount_ != 0L) { - output.writeInt64(8, outputRowCount_); - } - if (cacheHit_ != false) { - output.writeBool(9, cacheHit_); - } - for (int i = 0; i < referencedRoutines_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString( - output, 10, referencedRoutines_.getRaw(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (totalProcessedBytes_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, totalProcessedBytes_); - } - if (totalBilledBytes_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, totalBilledBytes_); - } - if (billingTier_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, billingTier_); - } - { - int dataSize = 0; - for (int i = 0; i < referencedTables_.size(); i++) { - dataSize += computeStringSizeNoTag(referencedTables_.getRaw(i)); - } - size += dataSize; - size += 1 * getReferencedTablesList().size(); - } - { - int dataSize = 0; - for (int i = 0; i < referencedViews_.size(); i++) { - dataSize += computeStringSizeNoTag(referencedViews_.getRaw(i)); - } - size += dataSize; - size += 1 * getReferencedViewsList().size(); - } - if (outputRowCount_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(8, outputRowCount_); - } - if (cacheHit_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(9, cacheHit_); - } - { - int dataSize = 0; - for (int i = 0; i < referencedRoutines_.size(); i++) { - dataSize += computeStringSizeNoTag(referencedRoutines_.getRaw(i)); - } - size += dataSize; - size += 1 * getReferencedRoutinesList().size(); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) obj; - - if (getTotalProcessedBytes() != other.getTotalProcessedBytes()) return false; - if (getTotalBilledBytes() != other.getTotalBilledBytes()) return false; - if (getBillingTier() != other.getBillingTier()) return false; - if (!getReferencedTablesList().equals(other.getReferencedTablesList())) return false; - if (!getReferencedViewsList().equals(other.getReferencedViewsList())) return false; - if (!getReferencedRoutinesList().equals(other.getReferencedRoutinesList())) return false; - if (getOutputRowCount() != other.getOutputRowCount()) return false; - if (getCacheHit() != other.getCacheHit()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TOTAL_PROCESSED_BYTES_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalProcessedBytes()); - hash = (37 * hash) + TOTAL_BILLED_BYTES_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalBilledBytes()); - hash = (37 * hash) + BILLING_TIER_FIELD_NUMBER; - hash = (53 * hash) + getBillingTier(); - if (getReferencedTablesCount() > 0) { - hash = (37 * hash) + REFERENCED_TABLES_FIELD_NUMBER; - hash = (53 * hash) + getReferencedTablesList().hashCode(); - } - if (getReferencedViewsCount() > 0) { - hash = (37 * hash) + REFERENCED_VIEWS_FIELD_NUMBER; - hash = (53 * hash) + getReferencedViewsList().hashCode(); - } - if (getReferencedRoutinesCount() > 0) { - hash = (37 * hash) + REFERENCED_ROUTINES_FIELD_NUMBER; - hash = (53 * hash) + getReferencedRoutinesList().hashCode(); - } - hash = (37 * hash) + OUTPUT_ROW_COUNT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getOutputRowCount()); - hash = (37 * hash) + CACHE_HIT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getCacheHit()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-       * Query job statistics.
-       * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Query} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - totalProcessedBytes_ = 0L; - - totalBilledBytes_ = 0L; - - billingTier_ = 0; - - referencedTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - referencedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - referencedRoutines_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - outputRowCount_ = 0L; - - cacheHit_ = false; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query(this); - int from_bitField0_ = bitField0_; - result.totalProcessedBytes_ = totalProcessedBytes_; - result.totalBilledBytes_ = totalBilledBytes_; - result.billingTier_ = billingTier_; - if (((bitField0_ & 0x00000001) != 0)) { - referencedTables_ = referencedTables_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.referencedTables_ = referencedTables_; - if (((bitField0_ & 0x00000002) != 0)) { - referencedViews_ = referencedViews_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.referencedViews_ = referencedViews_; - if (((bitField0_ & 0x00000004) != 0)) { - referencedRoutines_ = referencedRoutines_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.referencedRoutines_ = referencedRoutines_; - result.outputRowCount_ = outputRowCount_; - result.cacheHit_ = cacheHit_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance()) - return this; - if (other.getTotalProcessedBytes() != 0L) { - setTotalProcessedBytes(other.getTotalProcessedBytes()); - } - if (other.getTotalBilledBytes() != 0L) { - setTotalBilledBytes(other.getTotalBilledBytes()); - } - if (other.getBillingTier() != 0) { - setBillingTier(other.getBillingTier()); - } - if (!other.referencedTables_.isEmpty()) { - if (referencedTables_.isEmpty()) { - referencedTables_ = other.referencedTables_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureReferencedTablesIsMutable(); - referencedTables_.addAll(other.referencedTables_); - } - onChanged(); - } - if (!other.referencedViews_.isEmpty()) { - if (referencedViews_.isEmpty()) { - referencedViews_ = other.referencedViews_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureReferencedViewsIsMutable(); - referencedViews_.addAll(other.referencedViews_); - } - onChanged(); - } - if (!other.referencedRoutines_.isEmpty()) { - if (referencedRoutines_.isEmpty()) { - referencedRoutines_ = other.referencedRoutines_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureReferencedRoutinesIsMutable(); - referencedRoutines_.addAll(other.referencedRoutines_); - } - onChanged(); - } - if (other.getOutputRowCount() != 0L) { - setOutputRowCount(other.getOutputRowCount()); - } - if (other.getCacheHit() != false) { - setCacheHit(other.getCacheHit()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private long totalProcessedBytes_; - /** - * - * - *
-         * Total bytes processed by the query job.
-         * 
- * - * int64 total_processed_bytes = 1; - * - * @return The totalProcessedBytes. - */ - @java.lang.Override - public long getTotalProcessedBytes() { - return totalProcessedBytes_; - } - /** - * - * - *
-         * Total bytes processed by the query job.
-         * 
- * - * int64 total_processed_bytes = 1; - * - * @param value The totalProcessedBytes to set. - * @return This builder for chaining. - */ - public Builder setTotalProcessedBytes(long value) { - - totalProcessedBytes_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Total bytes processed by the query job.
-         * 
- * - * int64 total_processed_bytes = 1; - * - * @return This builder for chaining. - */ - public Builder clearTotalProcessedBytes() { - - totalProcessedBytes_ = 0L; - onChanged(); - return this; - } - - private long totalBilledBytes_; - /** - * - * - *
-         * Total bytes billed by the query job.
-         * 
- * - * int64 total_billed_bytes = 2; - * - * @return The totalBilledBytes. - */ - @java.lang.Override - public long getTotalBilledBytes() { - return totalBilledBytes_; - } - /** - * - * - *
-         * Total bytes billed by the query job.
-         * 
- * - * int64 total_billed_bytes = 2; - * - * @param value The totalBilledBytes to set. - * @return This builder for chaining. - */ - public Builder setTotalBilledBytes(long value) { - - totalBilledBytes_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Total bytes billed by the query job.
-         * 
- * - * int64 total_billed_bytes = 2; - * - * @return This builder for chaining. - */ - public Builder clearTotalBilledBytes() { - - totalBilledBytes_ = 0L; - onChanged(); - return this; - } - - private int billingTier_; - /** - * - * - *
-         * The tier assigned by the CPU-based billing.
-         * 
- * - * int32 billing_tier = 3; - * - * @return The billingTier. - */ - @java.lang.Override - public int getBillingTier() { - return billingTier_; - } - /** - * - * - *
-         * The tier assigned by the CPU-based billing.
-         * 
- * - * int32 billing_tier = 3; - * - * @param value The billingTier to set. - * @return This builder for chaining. - */ - public Builder setBillingTier(int value) { - - billingTier_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * The tier assigned by the CPU-based billing.
-         * 
- * - * int32 billing_tier = 3; - * - * @return This builder for chaining. - */ - public Builder clearBillingTier() { - - billingTier_ = 0; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList referencedTables_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureReferencedTablesIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - referencedTables_ = new com.google.protobuf.LazyStringArrayList(referencedTables_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-         * Tables accessed by the query job.
-         * 
- * - * repeated string referenced_tables = 6; - * - * @return A list containing the referencedTables. - */ - public com.google.protobuf.ProtocolStringList getReferencedTablesList() { - return referencedTables_.getUnmodifiableView(); - } - /** - * - * - *
-         * Tables accessed by the query job.
-         * 
- * - * repeated string referenced_tables = 6; - * - * @return The count of referencedTables. - */ - public int getReferencedTablesCount() { - return referencedTables_.size(); - } - /** - * - * - *
-         * Tables accessed by the query job.
-         * 
- * - * repeated string referenced_tables = 6; - * - * @param index The index of the element to return. - * @return The referencedTables at the given index. - */ - public java.lang.String getReferencedTables(int index) { - return referencedTables_.get(index); - } - /** - * - * - *
-         * Tables accessed by the query job.
-         * 
- * - * repeated string referenced_tables = 6; - * - * @param index The index of the value to return. - * @return The bytes of the referencedTables at the given index. - */ - public com.google.protobuf.ByteString getReferencedTablesBytes(int index) { - return referencedTables_.getByteString(index); - } - /** - * - * - *
-         * Tables accessed by the query job.
-         * 
- * - * repeated string referenced_tables = 6; - * - * @param index The index to set the value at. - * @param value The referencedTables to set. - * @return This builder for chaining. - */ - public Builder setReferencedTables(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureReferencedTablesIsMutable(); - referencedTables_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-         * Tables accessed by the query job.
-         * 
- * - * repeated string referenced_tables = 6; - * - * @param value The referencedTables to add. - * @return This builder for chaining. - */ - public Builder addReferencedTables(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureReferencedTablesIsMutable(); - referencedTables_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-         * Tables accessed by the query job.
-         * 
- * - * repeated string referenced_tables = 6; - * - * @param values The referencedTables to add. - * @return This builder for chaining. - */ - public Builder addAllReferencedTables(java.lang.Iterable values) { - ensureReferencedTablesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, referencedTables_); - onChanged(); - return this; - } - /** - * - * - *
-         * Tables accessed by the query job.
-         * 
- * - * repeated string referenced_tables = 6; - * - * @return This builder for chaining. - */ - public Builder clearReferencedTables() { - referencedTables_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-         * Tables accessed by the query job.
-         * 
- * - * repeated string referenced_tables = 6; - * - * @param value The bytes of the referencedTables to add. - * @return This builder for chaining. - */ - public Builder addReferencedTablesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureReferencedTablesIsMutable(); - referencedTables_.add(value); - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList referencedViews_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureReferencedViewsIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - referencedViews_ = new com.google.protobuf.LazyStringArrayList(referencedViews_); - bitField0_ |= 0x00000002; - } - } - /** - * - * - *
-         * Views accessed by the query job.
-         * 
- * - * repeated string referenced_views = 7; - * - * @return A list containing the referencedViews. - */ - public com.google.protobuf.ProtocolStringList getReferencedViewsList() { - return referencedViews_.getUnmodifiableView(); - } - /** - * - * - *
-         * Views accessed by the query job.
-         * 
- * - * repeated string referenced_views = 7; - * - * @return The count of referencedViews. - */ - public int getReferencedViewsCount() { - return referencedViews_.size(); - } - /** - * - * - *
-         * Views accessed by the query job.
-         * 
- * - * repeated string referenced_views = 7; - * - * @param index The index of the element to return. - * @return The referencedViews at the given index. - */ - public java.lang.String getReferencedViews(int index) { - return referencedViews_.get(index); - } - /** - * - * - *
-         * Views accessed by the query job.
-         * 
- * - * repeated string referenced_views = 7; - * - * @param index The index of the value to return. - * @return The bytes of the referencedViews at the given index. - */ - public com.google.protobuf.ByteString getReferencedViewsBytes(int index) { - return referencedViews_.getByteString(index); - } - /** - * - * - *
-         * Views accessed by the query job.
-         * 
- * - * repeated string referenced_views = 7; - * - * @param index The index to set the value at. - * @param value The referencedViews to set. - * @return This builder for chaining. - */ - public Builder setReferencedViews(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureReferencedViewsIsMutable(); - referencedViews_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-         * Views accessed by the query job.
-         * 
- * - * repeated string referenced_views = 7; - * - * @param value The referencedViews to add. - * @return This builder for chaining. - */ - public Builder addReferencedViews(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureReferencedViewsIsMutable(); - referencedViews_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-         * Views accessed by the query job.
-         * 
- * - * repeated string referenced_views = 7; - * - * @param values The referencedViews to add. - * @return This builder for chaining. - */ - public Builder addAllReferencedViews(java.lang.Iterable values) { - ensureReferencedViewsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, referencedViews_); - onChanged(); - return this; - } - /** - * - * - *
-         * Views accessed by the query job.
-         * 
- * - * repeated string referenced_views = 7; - * - * @return This builder for chaining. - */ - public Builder clearReferencedViews() { - referencedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - return this; - } - /** - * - * - *
-         * Views accessed by the query job.
-         * 
- * - * repeated string referenced_views = 7; - * - * @param value The bytes of the referencedViews to add. - * @return This builder for chaining. - */ - public Builder addReferencedViewsBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureReferencedViewsIsMutable(); - referencedViews_.add(value); - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList referencedRoutines_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureReferencedRoutinesIsMutable() { - if (!((bitField0_ & 0x00000004) != 0)) { - referencedRoutines_ = new com.google.protobuf.LazyStringArrayList(referencedRoutines_); - bitField0_ |= 0x00000004; - } - } - /** - * - * - *
-         * Routines accessed by the query job.
-         * 
- * - * repeated string referenced_routines = 10; - * - * @return A list containing the referencedRoutines. - */ - public com.google.protobuf.ProtocolStringList getReferencedRoutinesList() { - return referencedRoutines_.getUnmodifiableView(); - } - /** - * - * - *
-         * Routines accessed by the query job.
-         * 
- * - * repeated string referenced_routines = 10; - * - * @return The count of referencedRoutines. - */ - public int getReferencedRoutinesCount() { - return referencedRoutines_.size(); - } - /** - * - * - *
-         * Routines accessed by the query job.
-         * 
- * - * repeated string referenced_routines = 10; - * - * @param index The index of the element to return. - * @return The referencedRoutines at the given index. - */ - public java.lang.String getReferencedRoutines(int index) { - return referencedRoutines_.get(index); - } - /** - * - * - *
-         * Routines accessed by the query job.
-         * 
- * - * repeated string referenced_routines = 10; - * - * @param index The index of the value to return. - * @return The bytes of the referencedRoutines at the given index. - */ - public com.google.protobuf.ByteString getReferencedRoutinesBytes(int index) { - return referencedRoutines_.getByteString(index); - } - /** - * - * - *
-         * Routines accessed by the query job.
-         * 
- * - * repeated string referenced_routines = 10; - * - * @param index The index to set the value at. - * @param value The referencedRoutines to set. - * @return This builder for chaining. - */ - public Builder setReferencedRoutines(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureReferencedRoutinesIsMutable(); - referencedRoutines_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-         * Routines accessed by the query job.
-         * 
- * - * repeated string referenced_routines = 10; - * - * @param value The referencedRoutines to add. - * @return This builder for chaining. - */ - public Builder addReferencedRoutines(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureReferencedRoutinesIsMutable(); - referencedRoutines_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-         * Routines accessed by the query job.
-         * 
- * - * repeated string referenced_routines = 10; - * - * @param values The referencedRoutines to add. - * @return This builder for chaining. - */ - public Builder addAllReferencedRoutines(java.lang.Iterable values) { - ensureReferencedRoutinesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, referencedRoutines_); - onChanged(); - return this; - } - /** - * - * - *
-         * Routines accessed by the query job.
-         * 
- * - * repeated string referenced_routines = 10; - * - * @return This builder for chaining. - */ - public Builder clearReferencedRoutines() { - referencedRoutines_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - return this; - } - /** - * - * - *
-         * Routines accessed by the query job.
-         * 
- * - * repeated string referenced_routines = 10; - * - * @param value The bytes of the referencedRoutines to add. - * @return This builder for chaining. - */ - public Builder addReferencedRoutinesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureReferencedRoutinesIsMutable(); - referencedRoutines_.add(value); - onChanged(); - return this; - } - - private long outputRowCount_; - /** - * - * - *
-         * Number of output rows produced by the query job.
-         * 
- * - * int64 output_row_count = 8; - * - * @return The outputRowCount. - */ - @java.lang.Override - public long getOutputRowCount() { - return outputRowCount_; - } - /** - * - * - *
-         * Number of output rows produced by the query job.
-         * 
- * - * int64 output_row_count = 8; - * - * @param value The outputRowCount to set. - * @return This builder for chaining. - */ - public Builder setOutputRowCount(long value) { - - outputRowCount_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Number of output rows produced by the query job.
-         * 
- * - * int64 output_row_count = 8; - * - * @return This builder for chaining. - */ - public Builder clearOutputRowCount() { - - outputRowCount_ = 0L; - onChanged(); - return this; - } - - private boolean cacheHit_; - /** - * - * - *
-         * True if the query job results were read from the query cache.
-         * 
- * - * bool cache_hit = 9; - * - * @return The cacheHit. - */ - @java.lang.Override - public boolean getCacheHit() { - return cacheHit_; - } - /** - * - * - *
-         * True if the query job results were read from the query cache.
-         * 
- * - * bool cache_hit = 9; - * - * @param value The cacheHit to set. - * @return This builder for chaining. - */ - public Builder setCacheHit(boolean value) { - - cacheHit_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * True if the query job results were read from the query cache.
-         * 
- * - * bool cache_hit = 9; - * - * @return This builder for chaining. - */ - public Builder clearCacheHit() { - - cacheHit_ = false; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Query parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Query(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface LoadOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-       * Total bytes loaded by the import job.
-       * 
- * - * int64 total_output_bytes = 1; - * - * @return The totalOutputBytes. - */ - long getTotalOutputBytes(); - } - /** - * - * - *
-     * Load job statistics.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Load} - */ - public static final class Load extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) - LoadOrBuilder { - private static final long serialVersionUID = 0L; - // Use Load.newBuilder() to construct. - private Load(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Load() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Load(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Load( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - totalOutputBytes_ = input.readInt64(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder.class); - } - - public static final int TOTAL_OUTPUT_BYTES_FIELD_NUMBER = 1; - private long totalOutputBytes_; - /** - * - * - *
-       * Total bytes loaded by the import job.
-       * 
- * - * int64 total_output_bytes = 1; - * - * @return The totalOutputBytes. - */ - @java.lang.Override - public long getTotalOutputBytes() { - return totalOutputBytes_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (totalOutputBytes_ != 0L) { - output.writeInt64(1, totalOutputBytes_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (totalOutputBytes_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, totalOutputBytes_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) obj; - - if (getTotalOutputBytes() != other.getTotalOutputBytes()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TOTAL_OUTPUT_BYTES_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalOutputBytes()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-       * Load job statistics.
-       * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Load} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - totalOutputBytes_ = 0L; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load(this); - result.totalOutputBytes_ = totalOutputBytes_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance()) - return this; - if (other.getTotalOutputBytes() != 0L) { - setTotalOutputBytes(other.getTotalOutputBytes()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private long totalOutputBytes_; - /** - * - * - *
-         * Total bytes loaded by the import job.
-         * 
- * - * int64 total_output_bytes = 1; - * - * @return The totalOutputBytes. - */ - @java.lang.Override - public long getTotalOutputBytes() { - return totalOutputBytes_; - } - /** - * - * - *
-         * Total bytes loaded by the import job.
-         * 
- * - * int64 total_output_bytes = 1; - * - * @param value The totalOutputBytes to set. - * @return This builder for chaining. - */ - public Builder setTotalOutputBytes(long value) { - - totalOutputBytes_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Total bytes loaded by the import job.
-         * 
- * - * int64 total_output_bytes = 1; - * - * @return This builder for chaining. - */ - public Builder clearTotalOutputBytes() { - - totalOutputBytes_ = 0L; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Load parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Load(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface ExtractOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-       * Total bytes exported by the extract job.
-       * 
- * - * int64 total_input_bytes = 1; - * - * @return The totalInputBytes. - */ - long getTotalInputBytes(); - } - /** - * - * - *
-     * Extract job statistics.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract} - */ - public static final class Extract extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) - ExtractOrBuilder { - private static final long serialVersionUID = 0L; - // Use Extract.newBuilder() to construct. - private Extract(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Extract() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Extract(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Extract( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - totalInputBytes_ = input.readInt64(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder.class); - } - - public static final int TOTAL_INPUT_BYTES_FIELD_NUMBER = 1; - private long totalInputBytes_; - /** - * - * - *
-       * Total bytes exported by the extract job.
-       * 
- * - * int64 total_input_bytes = 1; - * - * @return The totalInputBytes. - */ - @java.lang.Override - public long getTotalInputBytes() { - return totalInputBytes_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (totalInputBytes_ != 0L) { - output.writeInt64(1, totalInputBytes_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (totalInputBytes_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, totalInputBytes_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) obj; - - if (getTotalInputBytes() != other.getTotalInputBytes()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TOTAL_INPUT_BYTES_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalInputBytes()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract - parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-       * Extract job statistics.
-       * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder.class); - } - - // Construct using - // com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - totalInputBytes_ = 0L; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract(this); - result.totalInputBytes_ = totalInputBytes_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance()) - return this; - if (other.getTotalInputBytes() != 0L) { - setTotalInputBytes(other.getTotalInputBytes()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private long totalInputBytes_; - /** - * - * - *
-         * Total bytes exported by the extract job.
-         * 
- * - * int64 total_input_bytes = 1; - * - * @return The totalInputBytes. - */ - @java.lang.Override - public long getTotalInputBytes() { - return totalInputBytes_; - } - /** - * - * - *
-         * Total bytes exported by the extract job.
-         * 
- * - * int64 total_input_bytes = 1; - * - * @param value The totalInputBytes to set. - * @return This builder for chaining. - */ - public Builder setTotalInputBytes(long value) { - - totalInputBytes_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Total bytes exported by the extract job.
-         * 
- * - * int64 total_input_bytes = 1; - * - * @return This builder for chaining. - */ - public Builder clearTotalInputBytes() { - - totalInputBytes_ = 0L; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Extract parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Extract(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface ReservationResourceUsageOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-       * Reservation name or "unreserved" for on-demand resources usage.
-       * 
- * - * string name = 1; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-       * Reservation name or "unreserved" for on-demand resources usage.
-       * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-       * Total slot milliseconds used by the reservation for a particular job.
-       * 
- * - * int64 slot_ms = 2; - * - * @return The slotMs. - */ - long getSlotMs(); - } - /** - * - * - *
-     * Job resource usage breakdown by reservation.
-     * 
- * - * Protobuf type {@code - * google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage} - */ - public static final class ReservationResourceUsage - extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) - ReservationResourceUsageOrBuilder { - private static final long serialVersionUID = 0L; - // Use ReservationResourceUsage.newBuilder() to construct. - private ReservationResourceUsage(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ReservationResourceUsage() { - name_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ReservationResourceUsage(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private ReservationResourceUsage( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 16: - { - slotMs_ = input.readInt64(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-       * Reservation name or "unreserved" for on-demand resources usage.
-       * 
- * - * string name = 1; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-       * Reservation name or "unreserved" for on-demand resources usage.
-       * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SLOT_MS_FIELD_NUMBER = 2; - private long slotMs_; - /** - * - * - *
-       * Total slot milliseconds used by the reservation for a particular job.
-       * 
- * - * int64 slot_ms = 2; - * - * @return The slotMs. - */ - @java.lang.Override - public long getSlotMs() { - return slotMs_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (slotMs_ != 0L) { - output.writeInt64(2, slotMs_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - if (slotMs_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, slotMs_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj - instanceof - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) obj; - - if (!getName().equals(other.getName())) return false; - if (getSlotMs() != other.getSlotMs()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + SLOT_MS_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getSlotMs()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-       * Job resource usage breakdown by reservation.
-       * 
- * - * Protobuf type {@code - * google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsageOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .Builder.class); - } - - // Construct using - // com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - slotMs_ = 0L; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage result = - buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage( - this); - result.name_ = name_; - result.slotMs_ = slotMs_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other - instanceof - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) { - return mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) - other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (other.getSlotMs() != 0L) { - setSlotMs(other.getSlotMs()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-         * Reservation name or "unreserved" for on-demand resources usage.
-         * 
- * - * string name = 1; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-         * Reservation name or "unreserved" for on-demand resources usage.
-         * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-         * Reservation name or "unreserved" for on-demand resources usage.
-         * 
- * - * string name = 1; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Reservation name or "unreserved" for on-demand resources usage.
-         * 
- * - * string name = 1; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-         * Reservation name or "unreserved" for on-demand resources usage.
-         * 
- * - * string name = 1; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private long slotMs_; - /** - * - * - *
-         * Total slot milliseconds used by the reservation for a particular job.
-         * 
- * - * int64 slot_ms = 2; - * - * @return The slotMs. - */ - @java.lang.Override - public long getSlotMs() { - return slotMs_; - } - /** - * - * - *
-         * Total slot milliseconds used by the reservation for a particular job.
-         * 
- * - * int64 slot_ms = 2; - * - * @param value The slotMs to set. - * @return This builder for chaining. - */ - public Builder setSlotMs(long value) { - - slotMs_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Total slot milliseconds used by the reservation for a particular job.
-         * 
- * - * int64 slot_ms = 2; - * - * @return This builder for chaining. - */ - public Builder clearSlotMs() { - - slotMs_ = 0L; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStats - .ReservationResourceUsage - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = - new com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ReservationResourceUsage parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ReservationResourceUsage(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - private int extendedCase_ = 0; - private java.lang.Object extended_; - - public enum ExtendedCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - QUERY_STATS(8), - LOAD_STATS(9), - EXTRACT_STATS(13), - EXTENDED_NOT_SET(0); - private final int value; - - private ExtendedCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static ExtendedCase valueOf(int value) { - return forNumber(value); - } - - public static ExtendedCase forNumber(int value) { - switch (value) { - case 8: - return QUERY_STATS; - case 9: - return LOAD_STATS; - case 13: - return EXTRACT_STATS; - case 0: - return EXTENDED_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public ExtendedCase getExtendedCase() { - return ExtendedCase.forNumber(extendedCase_); - } - - public static final int CREATE_TIME_FIELD_NUMBER = 1; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-     * Job creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 1; - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-     * Job creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 1; - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-     * Job creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int START_TIME_FIELD_NUMBER = 2; - private com.google.protobuf.Timestamp startTime_; - /** - * - * - *
-     * Job execution start time.
-     * 
- * - * .google.protobuf.Timestamp start_time = 2; - * - * @return Whether the startTime field is set. - */ - @java.lang.Override - public boolean hasStartTime() { - return startTime_ != null; - } - /** - * - * - *
-     * Job execution start time.
-     * 
- * - * .google.protobuf.Timestamp start_time = 2; - * - * @return The startTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getStartTime() { - return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; - } - /** - * - * - *
-     * Job execution start time.
-     * 
- * - * .google.protobuf.Timestamp start_time = 2; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { - return getStartTime(); - } - - public static final int END_TIME_FIELD_NUMBER = 3; - private com.google.protobuf.Timestamp endTime_; - /** - * - * - *
-     * Job completion time.
-     * 
- * - * .google.protobuf.Timestamp end_time = 3; - * - * @return Whether the endTime field is set. - */ - @java.lang.Override - public boolean hasEndTime() { - return endTime_ != null; - } - /** - * - * - *
-     * Job completion time.
-     * 
- * - * .google.protobuf.Timestamp end_time = 3; - * - * @return The endTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getEndTime() { - return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; - } - /** - * - * - *
-     * Job completion time.
-     * 
- * - * .google.protobuf.Timestamp end_time = 3; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { - return getEndTime(); - } - - public static final int QUERY_STATS_FIELD_NUMBER = 8; - /** - * - * - *
-     * Query job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - * - * @return Whether the queryStats field is set. - */ - @java.lang.Override - public boolean hasQueryStats() { - return extendedCase_ == 8; - } - /** - * - * - *
-     * Query job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - * - * @return The queryStats. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query getQueryStats() { - if (extendedCase_ == 8) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); - } - /** - * - * - *
-     * Query job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder - getQueryStatsOrBuilder() { - if (extendedCase_ == 8) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); - } - - public static final int LOAD_STATS_FIELD_NUMBER = 9; - /** - * - * - *
-     * Load job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - * - * @return Whether the loadStats field is set. - */ - @java.lang.Override - public boolean hasLoadStats() { - return extendedCase_ == 9; - } - /** - * - * - *
-     * Load job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - * - * @return The loadStats. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load getLoadStats() { - if (extendedCase_ == 9) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); - } - /** - * - * - *
-     * Load job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder - getLoadStatsOrBuilder() { - if (extendedCase_ == 9) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); - } - - public static final int EXTRACT_STATS_FIELD_NUMBER = 13; - /** - * - * - *
-     * Extract job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - * - * @return Whether the extractStats field is set. - */ - @java.lang.Override - public boolean hasExtractStats() { - return extendedCase_ == 13; - } - /** - * - * - *
-     * Extract job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - * - * @return The extractStats. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract getExtractStats() { - if (extendedCase_ == 13) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); - } - /** - * - * - *
-     * Extract job statistics.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder - getExtractStatsOrBuilder() { - if (extendedCase_ == 13) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); - } - - public static final int TOTAL_SLOT_MS_FIELD_NUMBER = 10; - private long totalSlotMs_; - /** - * - * - *
-     * The total number of slot-ms consumed by the query job.
-     * 
- * - * int64 total_slot_ms = 10; - * - * @return The totalSlotMs. - */ - @java.lang.Override - public long getTotalSlotMs() { - return totalSlotMs_; - } - - public static final int RESERVATION_USAGE_FIELD_NUMBER = 11; - private java.util.List< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage> - reservationUsage_; - /** - * - * - *
-     * Reservation usage attributed from each tier of a reservation hierarchy.
-     * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - @java.lang.Override - public java.util.List< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage> - getReservationUsageList() { - return reservationUsage_; - } - /** - * - * - *
-     * Reservation usage attributed from each tier of a reservation hierarchy.
-     * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - @java.lang.Override - public java.util.List< - ? extends - com.google.cloud.audit.BigQueryAuditMetadata.JobStats - .ReservationResourceUsageOrBuilder> - getReservationUsageOrBuilderList() { - return reservationUsage_; - } - /** - * - * - *
-     * Reservation usage attributed from each tier of a reservation hierarchy.
-     * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - @java.lang.Override - public int getReservationUsageCount() { - return reservationUsage_.size(); - } - /** - * - * - *
-     * Reservation usage attributed from each tier of a reservation hierarchy.
-     * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - getReservationUsage(int index) { - return reservationUsage_.get(index); - } - /** - * - * - *
-     * Reservation usage attributed from each tier of a reservation hierarchy.
-     * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsageOrBuilder - getReservationUsageOrBuilder(int index) { - return reservationUsage_.get(index); - } - - public static final int PARENT_JOB_NAME_FIELD_NUMBER = 12; - private volatile java.lang.Object parentJobName_; - /** - * - * - *
-     * Parent job name. Only present for child jobs.
-     * 
- * - * string parent_job_name = 12; - * - * @return The parentJobName. - */ - @java.lang.Override - public java.lang.String getParentJobName() { - java.lang.Object ref = parentJobName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parentJobName_ = s; - return s; - } - } - /** - * - * - *
-     * Parent job name. Only present for child jobs.
-     * 
- * - * string parent_job_name = 12; - * - * @return The bytes for parentJobName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getParentJobNameBytes() { - java.lang.Object ref = parentJobName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parentJobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (createTime_ != null) { - output.writeMessage(1, getCreateTime()); - } - if (startTime_ != null) { - output.writeMessage(2, getStartTime()); - } - if (endTime_ != null) { - output.writeMessage(3, getEndTime()); - } - if (extendedCase_ == 8) { - output.writeMessage( - 8, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_); - } - if (extendedCase_ == 9) { - output.writeMessage( - 9, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_); - } - if (totalSlotMs_ != 0L) { - output.writeInt64(10, totalSlotMs_); - } - for (int i = 0; i < reservationUsage_.size(); i++) { - output.writeMessage(11, reservationUsage_.get(i)); - } - if (!getParentJobNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 12, parentJobName_); - } - if (extendedCase_ == 13) { - output.writeMessage( - 13, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getCreateTime()); - } - if (startTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getStartTime()); - } - if (endTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getEndTime()); - } - if (extendedCase_ == 8) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 8, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_); - } - if (extendedCase_ == 9) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 9, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_); - } - if (totalSlotMs_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(10, totalSlotMs_); - } - for (int i = 0; i < reservationUsage_.size(); i++) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize(11, reservationUsage_.get(i)); - } - if (!getParentJobNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(12, parentJobName_); - } - if (extendedCase_ == 13) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 13, (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.JobStats other = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats) obj; - - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasStartTime() != other.hasStartTime()) return false; - if (hasStartTime()) { - if (!getStartTime().equals(other.getStartTime())) return false; - } - if (hasEndTime() != other.hasEndTime()) return false; - if (hasEndTime()) { - if (!getEndTime().equals(other.getEndTime())) return false; - } - if (getTotalSlotMs() != other.getTotalSlotMs()) return false; - if (!getReservationUsageList().equals(other.getReservationUsageList())) return false; - if (!getParentJobName().equals(other.getParentJobName())) return false; - if (!getExtendedCase().equals(other.getExtendedCase())) return false; - switch (extendedCase_) { - case 8: - if (!getQueryStats().equals(other.getQueryStats())) return false; - break; - case 9: - if (!getLoadStats().equals(other.getLoadStats())) return false; - break; - case 13: - if (!getExtractStats().equals(other.getExtractStats())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasStartTime()) { - hash = (37 * hash) + START_TIME_FIELD_NUMBER; - hash = (53 * hash) + getStartTime().hashCode(); - } - if (hasEndTime()) { - hash = (37 * hash) + END_TIME_FIELD_NUMBER; - hash = (53 * hash) + getEndTime().hashCode(); - } - hash = (37 * hash) + TOTAL_SLOT_MS_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTotalSlotMs()); - if (getReservationUsageCount() > 0) { - hash = (37 * hash) + RESERVATION_USAGE_FIELD_NUMBER; - hash = (53 * hash) + getReservationUsageList().hashCode(); - } - hash = (37 * hash) + PARENT_JOB_NAME_FIELD_NUMBER; - hash = (53 * hash) + getParentJobName().hashCode(); - switch (extendedCase_) { - case 8: - hash = (37 * hash) + QUERY_STATS_FIELD_NUMBER; - hash = (53 * hash) + getQueryStats().hashCode(); - break; - case 9: - hash = (37 * hash) + LOAD_STATS_FIELD_NUMBER; - hash = (53 * hash) + getLoadStats().hashCode(); - break; - case 13: - hash = (37 * hash) + EXTRACT_STATS_FIELD_NUMBER; - hash = (53 * hash) + getExtractStats().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Job statistics.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.JobStats} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.JobStats) - com.google.cloud.audit.BigQueryAuditMetadata.JobStatsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.class, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.JobStats.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getReservationUsageFieldBuilder(); - } - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (startTimeBuilder_ == null) { - startTime_ = null; - } else { - startTime_ = null; - startTimeBuilder_ = null; - } - if (endTimeBuilder_ == null) { - endTime_ = null; - } else { - endTime_ = null; - endTimeBuilder_ = null; - } - totalSlotMs_ = 0L; - - if (reservationUsageBuilder_ == null) { - reservationUsage_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - reservationUsageBuilder_.clear(); - } - parentJobName_ = ""; - - extendedCase_ = 0; - extended_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats build() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats result = - new com.google.cloud.audit.BigQueryAuditMetadata.JobStats(this); - int from_bitField0_ = bitField0_; - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (startTimeBuilder_ == null) { - result.startTime_ = startTime_; - } else { - result.startTime_ = startTimeBuilder_.build(); - } - if (endTimeBuilder_ == null) { - result.endTime_ = endTime_; - } else { - result.endTime_ = endTimeBuilder_.build(); - } - if (extendedCase_ == 8) { - if (queryStatsBuilder_ == null) { - result.extended_ = extended_; - } else { - result.extended_ = queryStatsBuilder_.build(); - } - } - if (extendedCase_ == 9) { - if (loadStatsBuilder_ == null) { - result.extended_ = extended_; - } else { - result.extended_ = loadStatsBuilder_.build(); - } - } - if (extendedCase_ == 13) { - if (extractStatsBuilder_ == null) { - result.extended_ = extended_; - } else { - result.extended_ = extractStatsBuilder_.build(); - } - } - result.totalSlotMs_ = totalSlotMs_; - if (reservationUsageBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - reservationUsage_ = java.util.Collections.unmodifiableList(reservationUsage_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.reservationUsage_ = reservationUsage_; - } else { - result.reservationUsage_ = reservationUsageBuilder_.build(); - } - result.parentJobName_ = parentJobName_; - result.extendedCase_ = extendedCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.JobStats) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.JobStats) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.JobStats other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.JobStats.getDefaultInstance()) - return this; - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasStartTime()) { - mergeStartTime(other.getStartTime()); - } - if (other.hasEndTime()) { - mergeEndTime(other.getEndTime()); - } - if (other.getTotalSlotMs() != 0L) { - setTotalSlotMs(other.getTotalSlotMs()); - } - if (reservationUsageBuilder_ == null) { - if (!other.reservationUsage_.isEmpty()) { - if (reservationUsage_.isEmpty()) { - reservationUsage_ = other.reservationUsage_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureReservationUsageIsMutable(); - reservationUsage_.addAll(other.reservationUsage_); - } - onChanged(); - } - } else { - if (!other.reservationUsage_.isEmpty()) { - if (reservationUsageBuilder_.isEmpty()) { - reservationUsageBuilder_.dispose(); - reservationUsageBuilder_ = null; - reservationUsage_ = other.reservationUsage_; - bitField0_ = (bitField0_ & ~0x00000001); - reservationUsageBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getReservationUsageFieldBuilder() - : null; - } else { - reservationUsageBuilder_.addAllMessages(other.reservationUsage_); - } - } - } - if (!other.getParentJobName().isEmpty()) { - parentJobName_ = other.parentJobName_; - onChanged(); - } - switch (other.getExtendedCase()) { - case QUERY_STATS: - { - mergeQueryStats(other.getQueryStats()); - break; - } - case LOAD_STATS: - { - mergeLoadStats(other.getLoadStats()); - break; - } - case EXTRACT_STATS: - { - mergeExtractStats(other.getExtractStats()); - break; - } - case EXTENDED_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.JobStats parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int extendedCase_ = 0; - private java.lang.Object extended_; - - public ExtendedCase getExtendedCase() { - return ExtendedCase.forNumber(extendedCase_); - } - - public Builder clearExtended() { - extendedCase_ = 0; - extended_ = null; - onChanged(); - return this; - } - - private int bitField0_; - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-       * Job creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 1; - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-       * Job creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 1; - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Job creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Job creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Job creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_) - .mergeFrom(value) - .buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Job creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Job creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Job creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-       * Job creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private com.google.protobuf.Timestamp startTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - startTimeBuilder_; - /** - * - * - *
-       * Job execution start time.
-       * 
- * - * .google.protobuf.Timestamp start_time = 2; - * - * @return Whether the startTime field is set. - */ - public boolean hasStartTime() { - return startTimeBuilder_ != null || startTime_ != null; - } - /** - * - * - *
-       * Job execution start time.
-       * 
- * - * .google.protobuf.Timestamp start_time = 2; - * - * @return The startTime. - */ - public com.google.protobuf.Timestamp getStartTime() { - if (startTimeBuilder_ == null) { - return startTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : startTime_; - } else { - return startTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Job execution start time.
-       * 
- * - * .google.protobuf.Timestamp start_time = 2; - */ - public Builder setStartTime(com.google.protobuf.Timestamp value) { - if (startTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - startTime_ = value; - onChanged(); - } else { - startTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Job execution start time.
-       * 
- * - * .google.protobuf.Timestamp start_time = 2; - */ - public Builder setStartTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (startTimeBuilder_ == null) { - startTime_ = builderForValue.build(); - onChanged(); - } else { - startTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Job execution start time.
-       * 
- * - * .google.protobuf.Timestamp start_time = 2; - */ - public Builder mergeStartTime(com.google.protobuf.Timestamp value) { - if (startTimeBuilder_ == null) { - if (startTime_ != null) { - startTime_ = - com.google.protobuf.Timestamp.newBuilder(startTime_) - .mergeFrom(value) - .buildPartial(); - } else { - startTime_ = value; - } - onChanged(); - } else { - startTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Job execution start time.
-       * 
- * - * .google.protobuf.Timestamp start_time = 2; - */ - public Builder clearStartTime() { - if (startTimeBuilder_ == null) { - startTime_ = null; - onChanged(); - } else { - startTime_ = null; - startTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Job execution start time.
-       * 
- * - * .google.protobuf.Timestamp start_time = 2; - */ - public com.google.protobuf.Timestamp.Builder getStartTimeBuilder() { - - onChanged(); - return getStartTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Job execution start time.
-       * 
- * - * .google.protobuf.Timestamp start_time = 2; - */ - public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { - if (startTimeBuilder_ != null) { - return startTimeBuilder_.getMessageOrBuilder(); - } else { - return startTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : startTime_; - } - } - /** - * - * - *
-       * Job execution start time.
-       * 
- * - * .google.protobuf.Timestamp start_time = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getStartTimeFieldBuilder() { - if (startTimeBuilder_ == null) { - startTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getStartTime(), getParentForChildren(), isClean()); - startTime_ = null; - } - return startTimeBuilder_; - } - - private com.google.protobuf.Timestamp endTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - endTimeBuilder_; - /** - * - * - *
-       * Job completion time.
-       * 
- * - * .google.protobuf.Timestamp end_time = 3; - * - * @return Whether the endTime field is set. - */ - public boolean hasEndTime() { - return endTimeBuilder_ != null || endTime_ != null; - } - /** - * - * - *
-       * Job completion time.
-       * 
- * - * .google.protobuf.Timestamp end_time = 3; - * - * @return The endTime. - */ - public com.google.protobuf.Timestamp getEndTime() { - if (endTimeBuilder_ == null) { - return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; - } else { - return endTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Job completion time.
-       * 
- * - * .google.protobuf.Timestamp end_time = 3; - */ - public Builder setEndTime(com.google.protobuf.Timestamp value) { - if (endTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - endTime_ = value; - onChanged(); - } else { - endTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Job completion time.
-       * 
- * - * .google.protobuf.Timestamp end_time = 3; - */ - public Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (endTimeBuilder_ == null) { - endTime_ = builderForValue.build(); - onChanged(); - } else { - endTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Job completion time.
-       * 
- * - * .google.protobuf.Timestamp end_time = 3; - */ - public Builder mergeEndTime(com.google.protobuf.Timestamp value) { - if (endTimeBuilder_ == null) { - if (endTime_ != null) { - endTime_ = - com.google.protobuf.Timestamp.newBuilder(endTime_).mergeFrom(value).buildPartial(); - } else { - endTime_ = value; - } - onChanged(); - } else { - endTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Job completion time.
-       * 
- * - * .google.protobuf.Timestamp end_time = 3; - */ - public Builder clearEndTime() { - if (endTimeBuilder_ == null) { - endTime_ = null; - onChanged(); - } else { - endTime_ = null; - endTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Job completion time.
-       * 
- * - * .google.protobuf.Timestamp end_time = 3; - */ - public com.google.protobuf.Timestamp.Builder getEndTimeBuilder() { - - onChanged(); - return getEndTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Job completion time.
-       * 
- * - * .google.protobuf.Timestamp end_time = 3; - */ - public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { - if (endTimeBuilder_ != null) { - return endTimeBuilder_.getMessageOrBuilder(); - } else { - return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; - } - } - /** - * - * - *
-       * Job completion time.
-       * 
- * - * .google.protobuf.Timestamp end_time = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getEndTimeFieldBuilder() { - if (endTimeBuilder_ == null) { - endTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getEndTime(), getParentForChildren(), isClean()); - endTime_ = null; - } - return endTimeBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder> - queryStatsBuilder_; - /** - * - * - *
-       * Query job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - * - * @return Whether the queryStats field is set. - */ - @java.lang.Override - public boolean hasQueryStats() { - return extendedCase_ == 8; - } - /** - * - * - *
-       * Query job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - * - * @return The queryStats. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query getQueryStats() { - if (queryStatsBuilder_ == null) { - if (extendedCase_ == 8) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); - } else { - if (extendedCase_ == 8) { - return queryStatsBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); - } - } - /** - * - * - *
-       * Query job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - */ - public Builder setQueryStats( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query value) { - if (queryStatsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - extended_ = value; - onChanged(); - } else { - queryStatsBuilder_.setMessage(value); - } - extendedCase_ = 8; - return this; - } - /** - * - * - *
-       * Query job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - */ - public Builder setQueryStats( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder builderForValue) { - if (queryStatsBuilder_ == null) { - extended_ = builderForValue.build(); - onChanged(); - } else { - queryStatsBuilder_.setMessage(builderForValue.build()); - } - extendedCase_ = 8; - return this; - } - /** - * - * - *
-       * Query job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - */ - public Builder mergeQueryStats( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query value) { - if (queryStatsBuilder_ == null) { - if (extendedCase_ == 8 - && extended_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query - .getDefaultInstance()) { - extended_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_) - .mergeFrom(value) - .buildPartial(); - } else { - extended_ = value; - } - onChanged(); - } else { - if (extendedCase_ == 8) { - queryStatsBuilder_.mergeFrom(value); - } - queryStatsBuilder_.setMessage(value); - } - extendedCase_ = 8; - return this; - } - /** - * - * - *
-       * Query job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - */ - public Builder clearQueryStats() { - if (queryStatsBuilder_ == null) { - if (extendedCase_ == 8) { - extendedCase_ = 0; - extended_ = null; - onChanged(); - } - } else { - if (extendedCase_ == 8) { - extendedCase_ = 0; - extended_ = null; - } - queryStatsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * Query job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder - getQueryStatsBuilder() { - return getQueryStatsFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Query job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder - getQueryStatsOrBuilder() { - if ((extendedCase_ == 8) && (queryStatsBuilder_ != null)) { - return queryStatsBuilder_.getMessageOrBuilder(); - } else { - if (extendedCase_ == 8) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); - } - } - /** - * - * - *
-       * Query job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Query query_stats = 8; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder> - getQueryStatsFieldBuilder() { - if (queryStatsBuilder_ == null) { - if (!(extendedCase_ == 8)) { - extended_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.getDefaultInstance(); - } - queryStatsBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.QueryOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Query) extended_, - getParentForChildren(), - isClean()); - extended_ = null; - } - extendedCase_ = 8; - onChanged(); - ; - return queryStatsBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder> - loadStatsBuilder_; - /** - * - * - *
-       * Load job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - * - * @return Whether the loadStats field is set. - */ - @java.lang.Override - public boolean hasLoadStats() { - return extendedCase_ == 9; - } - /** - * - * - *
-       * Load job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - * - * @return The loadStats. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load getLoadStats() { - if (loadStatsBuilder_ == null) { - if (extendedCase_ == 9) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); - } else { - if (extendedCase_ == 9) { - return loadStatsBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); - } - } - /** - * - * - *
-       * Load job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - */ - public Builder setLoadStats( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load value) { - if (loadStatsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - extended_ = value; - onChanged(); - } else { - loadStatsBuilder_.setMessage(value); - } - extendedCase_ = 9; - return this; - } - /** - * - * - *
-       * Load job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - */ - public Builder setLoadStats( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder builderForValue) { - if (loadStatsBuilder_ == null) { - extended_ = builderForValue.build(); - onChanged(); - } else { - loadStatsBuilder_.setMessage(builderForValue.build()); - } - extendedCase_ = 9; - return this; - } - /** - * - * - *
-       * Load job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - */ - public Builder mergeLoadStats( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load value) { - if (loadStatsBuilder_ == null) { - if (extendedCase_ == 9 - && extended_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load - .getDefaultInstance()) { - extended_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_) - .mergeFrom(value) - .buildPartial(); - } else { - extended_ = value; - } - onChanged(); - } else { - if (extendedCase_ == 9) { - loadStatsBuilder_.mergeFrom(value); - } - loadStatsBuilder_.setMessage(value); - } - extendedCase_ = 9; - return this; - } - /** - * - * - *
-       * Load job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - */ - public Builder clearLoadStats() { - if (loadStatsBuilder_ == null) { - if (extendedCase_ == 9) { - extendedCase_ = 0; - extended_ = null; - onChanged(); - } - } else { - if (extendedCase_ == 9) { - extendedCase_ = 0; - extended_ = null; - } - loadStatsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * Load job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder - getLoadStatsBuilder() { - return getLoadStatsFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Load job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder - getLoadStatsOrBuilder() { - if ((extendedCase_ == 9) && (loadStatsBuilder_ != null)) { - return loadStatsBuilder_.getMessageOrBuilder(); - } else { - if (extendedCase_ == 9) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); - } - } - /** - * - * - *
-       * Load job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Load load_stats = 9; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder> - getLoadStatsFieldBuilder() { - if (loadStatsBuilder_ == null) { - if (!(extendedCase_ == 9)) { - extended_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.getDefaultInstance(); - } - loadStatsBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.LoadOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Load) extended_, - getParentForChildren(), - isClean()); - extended_ = null; - } - extendedCase_ = 9; - onChanged(); - ; - return loadStatsBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder> - extractStatsBuilder_; - /** - * - * - *
-       * Extract job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - * - * @return Whether the extractStats field is set. - */ - @java.lang.Override - public boolean hasExtractStats() { - return extendedCase_ == 13; - } - /** - * - * - *
-       * Extract job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - * - * @return The extractStats. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract getExtractStats() { - if (extractStatsBuilder_ == null) { - if (extendedCase_ == 13) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); - } else { - if (extendedCase_ == 13) { - return extractStatsBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); - } - } - /** - * - * - *
-       * Extract job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - */ - public Builder setExtractStats( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract value) { - if (extractStatsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - extended_ = value; - onChanged(); - } else { - extractStatsBuilder_.setMessage(value); - } - extendedCase_ = 13; - return this; - } - /** - * - * - *
-       * Extract job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - */ - public Builder setExtractStats( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder builderForValue) { - if (extractStatsBuilder_ == null) { - extended_ = builderForValue.build(); - onChanged(); - } else { - extractStatsBuilder_.setMessage(builderForValue.build()); - } - extendedCase_ = 13; - return this; - } - /** - * - * - *
-       * Extract job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - */ - public Builder mergeExtractStats( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract value) { - if (extractStatsBuilder_ == null) { - if (extendedCase_ == 13 - && extended_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract - .getDefaultInstance()) { - extended_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_) - .mergeFrom(value) - .buildPartial(); - } else { - extended_ = value; - } - onChanged(); - } else { - if (extendedCase_ == 13) { - extractStatsBuilder_.mergeFrom(value); - } - extractStatsBuilder_.setMessage(value); - } - extendedCase_ = 13; - return this; - } - /** - * - * - *
-       * Extract job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - */ - public Builder clearExtractStats() { - if (extractStatsBuilder_ == null) { - if (extendedCase_ == 13) { - extendedCase_ = 0; - extended_ = null; - onChanged(); - } - } else { - if (extendedCase_ == 13) { - extendedCase_ = 0; - extended_ = null; - } - extractStatsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * Extract job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder - getExtractStatsBuilder() { - return getExtractStatsFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Extract job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder - getExtractStatsOrBuilder() { - if ((extendedCase_ == 13) && (extractStatsBuilder_ != null)) { - return extractStatsBuilder_.getMessageOrBuilder(); - } else { - if (extendedCase_ == 13) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); - } - } - /** - * - * - *
-       * Extract job statistics.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract extract_stats = 13; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder> - getExtractStatsFieldBuilder() { - if (extractStatsBuilder_ == null) { - if (!(extendedCase_ == 13)) { - extended_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.getDefaultInstance(); - } - extractStatsBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ExtractOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.JobStats.Extract) extended_, - getParentForChildren(), - isClean()); - extended_ = null; - } - extendedCase_ = 13; - onChanged(); - ; - return extractStatsBuilder_; - } - - private long totalSlotMs_; - /** - * - * - *
-       * The total number of slot-ms consumed by the query job.
-       * 
- * - * int64 total_slot_ms = 10; - * - * @return The totalSlotMs. - */ - @java.lang.Override - public long getTotalSlotMs() { - return totalSlotMs_; - } - /** - * - * - *
-       * The total number of slot-ms consumed by the query job.
-       * 
- * - * int64 total_slot_ms = 10; - * - * @param value The totalSlotMs to set. - * @return This builder for chaining. - */ - public Builder setTotalSlotMs(long value) { - - totalSlotMs_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The total number of slot-ms consumed by the query job.
-       * 
- * - * int64 total_slot_ms = 10; - * - * @return This builder for chaining. - */ - public Builder clearTotalSlotMs() { - - totalSlotMs_ = 0L; - onChanged(); - return this; - } - - private java.util.List< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage> - reservationUsage_ = java.util.Collections.emptyList(); - - private void ensureReservationUsageIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - reservationUsage_ = - new java.util.ArrayList< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage>( - reservationUsage_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats - .ReservationResourceUsageOrBuilder> - reservationUsageBuilder_; - - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public java.util.List< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage> - getReservationUsageList() { - if (reservationUsageBuilder_ == null) { - return java.util.Collections.unmodifiableList(reservationUsage_); - } else { - return reservationUsageBuilder_.getMessageList(); - } - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public int getReservationUsageCount() { - if (reservationUsageBuilder_ == null) { - return reservationUsage_.size(); - } else { - return reservationUsageBuilder_.getCount(); - } - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - getReservationUsage(int index) { - if (reservationUsageBuilder_ == null) { - return reservationUsage_.get(index); - } else { - return reservationUsageBuilder_.getMessage(index); - } - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public Builder setReservationUsage( - int index, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage value) { - if (reservationUsageBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureReservationUsageIsMutable(); - reservationUsage_.set(index, value); - onChanged(); - } else { - reservationUsageBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public Builder setReservationUsage( - int index, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder - builderForValue) { - if (reservationUsageBuilder_ == null) { - ensureReservationUsageIsMutable(); - reservationUsage_.set(index, builderForValue.build()); - onChanged(); - } else { - reservationUsageBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public Builder addReservationUsage( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage value) { - if (reservationUsageBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureReservationUsageIsMutable(); - reservationUsage_.add(value); - onChanged(); - } else { - reservationUsageBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public Builder addReservationUsage( - int index, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage value) { - if (reservationUsageBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureReservationUsageIsMutable(); - reservationUsage_.add(index, value); - onChanged(); - } else { - reservationUsageBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public Builder addReservationUsage( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder - builderForValue) { - if (reservationUsageBuilder_ == null) { - ensureReservationUsageIsMutable(); - reservationUsage_.add(builderForValue.build()); - onChanged(); - } else { - reservationUsageBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public Builder addReservationUsage( - int index, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder - builderForValue) { - if (reservationUsageBuilder_ == null) { - ensureReservationUsageIsMutable(); - reservationUsage_.add(index, builderForValue.build()); - onChanged(); - } else { - reservationUsageBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public Builder addAllReservationUsage( - java.lang.Iterable< - ? extends - com.google.cloud.audit.BigQueryAuditMetadata.JobStats - .ReservationResourceUsage> - values) { - if (reservationUsageBuilder_ == null) { - ensureReservationUsageIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, reservationUsage_); - onChanged(); - } else { - reservationUsageBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public Builder clearReservationUsage() { - if (reservationUsageBuilder_ == null) { - reservationUsage_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - reservationUsageBuilder_.clear(); - } - return this; - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public Builder removeReservationUsage(int index) { - if (reservationUsageBuilder_ == null) { - ensureReservationUsageIsMutable(); - reservationUsage_.remove(index); - onChanged(); - } else { - reservationUsageBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder - getReservationUsageBuilder(int index) { - return getReservationUsageFieldBuilder().getBuilder(index); - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsageOrBuilder - getReservationUsageOrBuilder(int index) { - if (reservationUsageBuilder_ == null) { - return reservationUsage_.get(index); - } else { - return reservationUsageBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public java.util.List< - ? extends - com.google.cloud.audit.BigQueryAuditMetadata.JobStats - .ReservationResourceUsageOrBuilder> - getReservationUsageOrBuilderList() { - if (reservationUsageBuilder_ != null) { - return reservationUsageBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(reservationUsage_); - } - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder - addReservationUsageBuilder() { - return getReservationUsageFieldBuilder() - .addBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .getDefaultInstance()); - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage.Builder - addReservationUsageBuilder(int index) { - return getReservationUsageFieldBuilder() - .addBuilder( - index, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .getDefaultInstance()); - } - /** - * - * - *
-       * Reservation usage attributed from each tier of a reservation hierarchy.
-       * 
- * - * - * repeated .google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage reservation_usage = 11; - * - */ - public java.util.List< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .Builder> - getReservationUsageBuilderList() { - return getReservationUsageFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats - .ReservationResourceUsageOrBuilder> - getReservationUsageFieldBuilder() { - if (reservationUsageBuilder_ == null) { - reservationUsageBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats.ReservationResourceUsage - .Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobStats - .ReservationResourceUsageOrBuilder>( - reservationUsage_, - ((bitField0_ & 0x00000001) != 0), - getParentForChildren(), - isClean()); - reservationUsage_ = null; - } - return reservationUsageBuilder_; - } - - private java.lang.Object parentJobName_ = ""; - /** - * - * - *
-       * Parent job name. Only present for child jobs.
-       * 
- * - * string parent_job_name = 12; - * - * @return The parentJobName. - */ - public java.lang.String getParentJobName() { - java.lang.Object ref = parentJobName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parentJobName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Parent job name. Only present for child jobs.
-       * 
- * - * string parent_job_name = 12; - * - * @return The bytes for parentJobName. - */ - public com.google.protobuf.ByteString getParentJobNameBytes() { - java.lang.Object ref = parentJobName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parentJobName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Parent job name. Only present for child jobs.
-       * 
- * - * string parent_job_name = 12; - * - * @param value The parentJobName to set. - * @return This builder for chaining. - */ - public Builder setParentJobName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parentJobName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Parent job name. Only present for child jobs.
-       * 
- * - * string parent_job_name = 12; - * - * @return This builder for chaining. - */ - public Builder clearParentJobName() { - - parentJobName_ = getDefaultInstance().getParentJobName(); - onChanged(); - return this; - } - /** - * - * - *
-       * Parent job name. Only present for child jobs.
-       * 
- * - * string parent_job_name = 12; - * - * @param value The bytes for parentJobName to set. - * @return This builder for chaining. - */ - public Builder setParentJobNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - parentJobName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.JobStats) - private static final com.google.cloud.audit.BigQueryAuditMetadata.JobStats DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.JobStats(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.JobStats getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public JobStats parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new JobStats(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobStats getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface TableOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.Table) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Table URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
-     * 
- * - * string table_name = 1; - * - * @return The tableName. - */ - java.lang.String getTableName(); - /** - * - * - *
-     * Table URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
-     * 
- * - * string table_name = 1; - * - * @return The bytes for tableName. - */ - com.google.protobuf.ByteString getTableNameBytes(); - - /** - * - * - *
-     * A JSON representation of the table's schema. Entire field is truncated
-     * if exceeds 40K.
-     * 
- * - * string schema_json = 3; - * - * @return The schemaJson. - */ - java.lang.String getSchemaJson(); - /** - * - * - *
-     * A JSON representation of the table's schema. Entire field is truncated
-     * if exceeds 40K.
-     * 
- * - * string schema_json = 3; - * - * @return The bytes for schemaJson. - */ - com.google.protobuf.ByteString getSchemaJsonBytes(); - - /** - * - * - *
-     * True if the schema_json field was truncated.
-     * 
- * - * bool schema_json_truncated = 11; - * - * @return The schemaJsonTruncated. - */ - boolean getSchemaJsonTruncated(); - - /** - * - * - *
-     * View metadata. Only present for views.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - * - * @return Whether the view field is set. - */ - boolean hasView(); - /** - * - * - *
-     * View metadata. Only present for views.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - * - * @return The view. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition getView(); - /** - * - * - *
-     * View metadata. Only present for views.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder getViewOrBuilder(); - - /** - * - * - *
-     * Table expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return Whether the expireTime field is set. - */ - boolean hasExpireTime(); - /** - * - * - *
-     * Table expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return The expireTime. - */ - com.google.protobuf.Timestamp getExpireTime(); - /** - * - * - *
-     * Table expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder(); - - /** - * - * - *
-     * The table creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-     * The table creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-     * The table creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-     * The last time metadata update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return Whether the updateTime field is set. - */ - boolean hasUpdateTime(); - /** - * - * - *
-     * The last time metadata update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return The updateTime. - */ - com.google.protobuf.Timestamp getUpdateTime(); - /** - * - * - *
-     * The last time metadata update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); - - /** - * - * - *
-     * The last table truncation time.
-     * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - * - * @return Whether the truncateTime field is set. - */ - boolean hasTruncateTime(); - /** - * - * - *
-     * The last table truncation time.
-     * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - * - * @return The truncateTime. - */ - com.google.protobuf.Timestamp getTruncateTime(); - /** - * - * - *
-     * The last table truncation time.
-     * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - */ - com.google.protobuf.TimestampOrBuilder getTruncateTimeOrBuilder(); - - /** - * - * - *
-     * Table encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - * - * @return Whether the encryption field is set. - */ - boolean hasEncryption(); - /** - * - * - *
-     * Table encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - * - * @return The encryption. - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption(); - /** - * - * - *
-     * Table encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - */ - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder getEncryptionOrBuilder(); - - /** - * - * - *
-     * User-provided metadata for the table.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - * - * @return Whether the tableInfo field is set. - */ - boolean hasTableInfo(); - /** - * - * - *
-     * User-provided metadata for the table.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - * - * @return The tableInfo. - */ - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getTableInfo(); - /** - * - * - *
-     * User-provided metadata for the table.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - */ - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder getTableInfoOrBuilder(); - } - /** - * - * - *
-   * BigQuery table.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Table} - */ - public static final class Table extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.Table) - TableOrBuilder { - private static final long serialVersionUID = 0L; - // Use Table.newBuilder() to construct. - private Table(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Table() { - tableName_ = ""; - schemaJson_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Table(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Table( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableName_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - schemaJson_ = s; - break; - } - case 34: - { - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder - subBuilder = null; - if (view_ != null) { - subBuilder = view_.toBuilder(); - } - view_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(view_); - view_ = subBuilder.buildPartial(); - } - - break; - } - case 42: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (expireTime_ != null) { - subBuilder = expireTime_.toBuilder(); - } - expireTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(expireTime_); - expireTime_ = subBuilder.buildPartial(); - } - - break; - } - case 50: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (updateTime_ != null) { - subBuilder = updateTime_.toBuilder(); - } - updateTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateTime_); - updateTime_ = subBuilder.buildPartial(); - } - - break; - } - case 66: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (truncateTime_ != null) { - subBuilder = truncateTime_.toBuilder(); - } - truncateTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(truncateTime_); - truncateTime_ = subBuilder.buildPartial(); - } - - break; - } - case 74: - { - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder subBuilder = - null; - if (encryption_ != null) { - subBuilder = encryption_.toBuilder(); - } - encryption_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(encryption_); - encryption_ = subBuilder.buildPartial(); - } - - break; - } - case 82: - { - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder subBuilder = null; - if (tableInfo_ != null) { - subBuilder = tableInfo_.toBuilder(); - } - tableInfo_ = - input.readMessage( - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(tableInfo_); - tableInfo_ = subBuilder.buildPartial(); - } - - break; - } - case 88: - { - schemaJsonTruncated_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.Table.class, - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder.class); - } - - public static final int TABLE_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object tableName_; - /** - * - * - *
-     * Table URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
-     * 
- * - * string table_name = 1; - * - * @return The tableName. - */ - @java.lang.Override - public java.lang.String getTableName() { - java.lang.Object ref = tableName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - tableName_ = s; - return s; - } - } - /** - * - * - *
-     * Table URI.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
-     * 
- * - * string table_name = 1; - * - * @return The bytes for tableName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getTableNameBytes() { - java.lang.Object ref = tableName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - tableName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SCHEMA_JSON_FIELD_NUMBER = 3; - private volatile java.lang.Object schemaJson_; - /** - * - * - *
-     * A JSON representation of the table's schema. Entire field is truncated
-     * if exceeds 40K.
-     * 
- * - * string schema_json = 3; - * - * @return The schemaJson. - */ - @java.lang.Override - public java.lang.String getSchemaJson() { - java.lang.Object ref = schemaJson_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - schemaJson_ = s; - return s; - } - } - /** - * - * - *
-     * A JSON representation of the table's schema. Entire field is truncated
-     * if exceeds 40K.
-     * 
- * - * string schema_json = 3; - * - * @return The bytes for schemaJson. - */ - @java.lang.Override - public com.google.protobuf.ByteString getSchemaJsonBytes() { - java.lang.Object ref = schemaJson_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - schemaJson_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SCHEMA_JSON_TRUNCATED_FIELD_NUMBER = 11; - private boolean schemaJsonTruncated_; - /** - * - * - *
-     * True if the schema_json field was truncated.
-     * 
- * - * bool schema_json_truncated = 11; - * - * @return The schemaJsonTruncated. - */ - @java.lang.Override - public boolean getSchemaJsonTruncated() { - return schemaJsonTruncated_; - } - - public static final int VIEW_FIELD_NUMBER = 4; - private com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view_; - /** - * - * - *
-     * View metadata. Only present for views.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - * - * @return Whether the view field is set. - */ - @java.lang.Override - public boolean hasView() { - return view_ != null; - } - /** - * - * - *
-     * View metadata. Only present for views.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - * - * @return The view. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition getView() { - return view_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.getDefaultInstance() - : view_; - } - /** - * - * - *
-     * View metadata. Only present for views.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder - getViewOrBuilder() { - return getView(); - } - - public static final int EXPIRE_TIME_FIELD_NUMBER = 5; - private com.google.protobuf.Timestamp expireTime_; - /** - * - * - *
-     * Table expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return Whether the expireTime field is set. - */ - @java.lang.Override - public boolean hasExpireTime() { - return expireTime_ != null; - } - /** - * - * - *
-     * Table expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return The expireTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getExpireTime() { - return expireTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : expireTime_; - } - /** - * - * - *
-     * Table expiration time.
-     * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder() { - return getExpireTime(); - } - - public static final int CREATE_TIME_FIELD_NUMBER = 6; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-     * The table creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-     * The table creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-     * The table creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int UPDATE_TIME_FIELD_NUMBER = 7; - private com.google.protobuf.Timestamp updateTime_; - /** - * - * - *
-     * The last time metadata update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return Whether the updateTime field is set. - */ - @java.lang.Override - public boolean hasUpdateTime() { - return updateTime_ != null; - } - /** - * - * - *
-     * The last time metadata update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return The updateTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getUpdateTime() { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; - } - /** - * - * - *
-     * The last time metadata update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - return getUpdateTime(); - } - - public static final int TRUNCATE_TIME_FIELD_NUMBER = 8; - private com.google.protobuf.Timestamp truncateTime_; - /** - * - * - *
-     * The last table truncation time.
-     * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - * - * @return Whether the truncateTime field is set. - */ - @java.lang.Override - public boolean hasTruncateTime() { - return truncateTime_ != null; - } - /** - * - * - *
-     * The last table truncation time.
-     * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - * - * @return The truncateTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getTruncateTime() { - return truncateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : truncateTime_; - } - /** - * - * - *
-     * The last table truncation time.
-     * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getTruncateTimeOrBuilder() { - return getTruncateTime(); - } - - public static final int ENCRYPTION_FIELD_NUMBER = 9; - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption_; - /** - * - * - *
-     * Table encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - * - * @return Whether the encryption field is set. - */ - @java.lang.Override - public boolean hasEncryption() { - return encryption_ != null; - } - /** - * - * - *
-     * Table encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - * - * @return The encryption. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption() { - return encryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : encryption_; - } - /** - * - * - *
-     * Table encryption information. Set when non-default encryption is used.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getEncryptionOrBuilder() { - return getEncryption(); - } - - public static final int TABLE_INFO_FIELD_NUMBER = 10; - private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo tableInfo_; - /** - * - * - *
-     * User-provided metadata for the table.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - * - * @return Whether the tableInfo field is set. - */ - @java.lang.Override - public boolean hasTableInfo() { - return tableInfo_ != null; - } - /** - * - * - *
-     * User-provided metadata for the table.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - * - * @return The tableInfo. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getTableInfo() { - return tableInfo_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() - : tableInfo_; - } - /** - * - * - *
-     * User-provided metadata for the table.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder - getTableInfoOrBuilder() { - return getTableInfo(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getTableNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, tableName_); - } - if (!getSchemaJsonBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, schemaJson_); - } - if (view_ != null) { - output.writeMessage(4, getView()); - } - if (expireTime_ != null) { - output.writeMessage(5, getExpireTime()); - } - if (createTime_ != null) { - output.writeMessage(6, getCreateTime()); - } - if (updateTime_ != null) { - output.writeMessage(7, getUpdateTime()); - } - if (truncateTime_ != null) { - output.writeMessage(8, getTruncateTime()); - } - if (encryption_ != null) { - output.writeMessage(9, getEncryption()); - } - if (tableInfo_ != null) { - output.writeMessage(10, getTableInfo()); - } - if (schemaJsonTruncated_ != false) { - output.writeBool(11, schemaJsonTruncated_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getTableNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, tableName_); - } - if (!getSchemaJsonBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, schemaJson_); - } - if (view_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getView()); - } - if (expireTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getExpireTime()); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getCreateTime()); - } - if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getUpdateTime()); - } - if (truncateTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getTruncateTime()); - } - if (encryption_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getEncryption()); - } - if (tableInfo_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getTableInfo()); - } - if (schemaJsonTruncated_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(11, schemaJsonTruncated_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.Table)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.Table other = - (com.google.cloud.audit.BigQueryAuditMetadata.Table) obj; - - if (!getTableName().equals(other.getTableName())) return false; - if (!getSchemaJson().equals(other.getSchemaJson())) return false; - if (getSchemaJsonTruncated() != other.getSchemaJsonTruncated()) return false; - if (hasView() != other.hasView()) return false; - if (hasView()) { - if (!getView().equals(other.getView())) return false; - } - if (hasExpireTime() != other.hasExpireTime()) return false; - if (hasExpireTime()) { - if (!getExpireTime().equals(other.getExpireTime())) return false; - } - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasUpdateTime() != other.hasUpdateTime()) return false; - if (hasUpdateTime()) { - if (!getUpdateTime().equals(other.getUpdateTime())) return false; - } - if (hasTruncateTime() != other.hasTruncateTime()) return false; - if (hasTruncateTime()) { - if (!getTruncateTime().equals(other.getTruncateTime())) return false; - } - if (hasEncryption() != other.hasEncryption()) return false; - if (hasEncryption()) { - if (!getEncryption().equals(other.getEncryption())) return false; - } - if (hasTableInfo() != other.hasTableInfo()) return false; - if (hasTableInfo()) { - if (!getTableInfo().equals(other.getTableInfo())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TABLE_NAME_FIELD_NUMBER; - hash = (53 * hash) + getTableName().hashCode(); - hash = (37 * hash) + SCHEMA_JSON_FIELD_NUMBER; - hash = (53 * hash) + getSchemaJson().hashCode(); - hash = (37 * hash) + SCHEMA_JSON_TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSchemaJsonTruncated()); - if (hasView()) { - hash = (37 * hash) + VIEW_FIELD_NUMBER; - hash = (53 * hash) + getView().hashCode(); - } - if (hasExpireTime()) { - hash = (37 * hash) + EXPIRE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getExpireTime().hashCode(); - } - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasUpdateTime()) { - hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getUpdateTime().hashCode(); - } - if (hasTruncateTime()) { - hash = (37 * hash) + TRUNCATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getTruncateTime().hashCode(); - } - if (hasEncryption()) { - hash = (37 * hash) + ENCRYPTION_FIELD_NUMBER; - hash = (53 * hash) + getEncryption().hashCode(); - } - if (hasTableInfo()) { - hash = (37 * hash) + TABLE_INFO_FIELD_NUMBER; - hash = (53 * hash) + getTableInfo().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloud.audit.BigQueryAuditMetadata.Table prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * BigQuery table.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Table} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.Table) - com.google.cloud.audit.BigQueryAuditMetadata.TableOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.Table.class, - com.google.cloud.audit.BigQueryAuditMetadata.Table.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.Table.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - tableName_ = ""; - - schemaJson_ = ""; - - schemaJsonTruncated_ = false; - - if (viewBuilder_ == null) { - view_ = null; - } else { - view_ = null; - viewBuilder_ = null; - } - if (expireTimeBuilder_ == null) { - expireTime_ = null; - } else { - expireTime_ = null; - expireTimeBuilder_ = null; - } - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (updateTimeBuilder_ == null) { - updateTime_ = null; - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - if (truncateTimeBuilder_ == null) { - truncateTime_ = null; - } else { - truncateTime_ = null; - truncateTimeBuilder_ = null; - } - if (encryptionBuilder_ == null) { - encryption_ = null; - } else { - encryption_ = null; - encryptionBuilder_ = null; - } - if (tableInfoBuilder_ == null) { - tableInfo_ = null; - } else { - tableInfo_ = null; - tableInfoBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Table getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Table build() { - com.google.cloud.audit.BigQueryAuditMetadata.Table result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Table buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.Table result = - new com.google.cloud.audit.BigQueryAuditMetadata.Table(this); - result.tableName_ = tableName_; - result.schemaJson_ = schemaJson_; - result.schemaJsonTruncated_ = schemaJsonTruncated_; - if (viewBuilder_ == null) { - result.view_ = view_; - } else { - result.view_ = viewBuilder_.build(); - } - if (expireTimeBuilder_ == null) { - result.expireTime_ = expireTime_; - } else { - result.expireTime_ = expireTimeBuilder_.build(); - } - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (updateTimeBuilder_ == null) { - result.updateTime_ = updateTime_; - } else { - result.updateTime_ = updateTimeBuilder_.build(); - } - if (truncateTimeBuilder_ == null) { - result.truncateTime_ = truncateTime_; - } else { - result.truncateTime_ = truncateTimeBuilder_.build(); - } - if (encryptionBuilder_ == null) { - result.encryption_ = encryption_; - } else { - result.encryption_ = encryptionBuilder_.build(); - } - if (tableInfoBuilder_ == null) { - result.tableInfo_ = tableInfo_; - } else { - result.tableInfo_ = tableInfoBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.Table) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.Table) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.Table other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.Table.getDefaultInstance()) - return this; - if (!other.getTableName().isEmpty()) { - tableName_ = other.tableName_; - onChanged(); - } - if (!other.getSchemaJson().isEmpty()) { - schemaJson_ = other.schemaJson_; - onChanged(); - } - if (other.getSchemaJsonTruncated() != false) { - setSchemaJsonTruncated(other.getSchemaJsonTruncated()); - } - if (other.hasView()) { - mergeView(other.getView()); - } - if (other.hasExpireTime()) { - mergeExpireTime(other.getExpireTime()); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasUpdateTime()) { - mergeUpdateTime(other.getUpdateTime()); - } - if (other.hasTruncateTime()) { - mergeTruncateTime(other.getTruncateTime()); - } - if (other.hasEncryption()) { - mergeEncryption(other.getEncryption()); - } - if (other.hasTableInfo()) { - mergeTableInfo(other.getTableInfo()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.Table parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.Table) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object tableName_ = ""; - /** - * - * - *
-       * Table URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
-       * 
- * - * string table_name = 1; - * - * @return The tableName. - */ - public java.lang.String getTableName() { - java.lang.Object ref = tableName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - tableName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Table URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
-       * 
- * - * string table_name = 1; - * - * @return The bytes for tableName. - */ - public com.google.protobuf.ByteString getTableNameBytes() { - java.lang.Object ref = tableName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - tableName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Table URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
-       * 
- * - * string table_name = 1; - * - * @param value The tableName to set. - * @return This builder for chaining. - */ - public Builder setTableName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - tableName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Table URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
-       * 
- * - * string table_name = 1; - * - * @return This builder for chaining. - */ - public Builder clearTableName() { - - tableName_ = getDefaultInstance().getTableName(); - onChanged(); - return this; - } - /** - * - * - *
-       * Table URI.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<table_id>`.
-       * 
- * - * string table_name = 1; - * - * @param value The bytes for tableName to set. - * @return This builder for chaining. - */ - public Builder setTableNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - tableName_ = value; - onChanged(); - return this; - } - - private java.lang.Object schemaJson_ = ""; - /** - * - * - *
-       * A JSON representation of the table's schema. Entire field is truncated
-       * if exceeds 40K.
-       * 
- * - * string schema_json = 3; - * - * @return The schemaJson. - */ - public java.lang.String getSchemaJson() { - java.lang.Object ref = schemaJson_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - schemaJson_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * A JSON representation of the table's schema. Entire field is truncated
-       * if exceeds 40K.
-       * 
- * - * string schema_json = 3; - * - * @return The bytes for schemaJson. - */ - public com.google.protobuf.ByteString getSchemaJsonBytes() { - java.lang.Object ref = schemaJson_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - schemaJson_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * A JSON representation of the table's schema. Entire field is truncated
-       * if exceeds 40K.
-       * 
- * - * string schema_json = 3; - * - * @param value The schemaJson to set. - * @return This builder for chaining. - */ - public Builder setSchemaJson(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - schemaJson_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * A JSON representation of the table's schema. Entire field is truncated
-       * if exceeds 40K.
-       * 
- * - * string schema_json = 3; - * - * @return This builder for chaining. - */ - public Builder clearSchemaJson() { - - schemaJson_ = getDefaultInstance().getSchemaJson(); - onChanged(); - return this; - } - /** - * - * - *
-       * A JSON representation of the table's schema. Entire field is truncated
-       * if exceeds 40K.
-       * 
- * - * string schema_json = 3; - * - * @param value The bytes for schemaJson to set. - * @return This builder for chaining. - */ - public Builder setSchemaJsonBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - schemaJson_ = value; - onChanged(); - return this; - } - - private boolean schemaJsonTruncated_; - /** - * - * - *
-       * True if the schema_json field was truncated.
-       * 
- * - * bool schema_json_truncated = 11; - * - * @return The schemaJsonTruncated. - */ - @java.lang.Override - public boolean getSchemaJsonTruncated() { - return schemaJsonTruncated_; - } - /** - * - * - *
-       * True if the schema_json field was truncated.
-       * 
- * - * bool schema_json_truncated = 11; - * - * @param value The schemaJsonTruncated to set. - * @return This builder for chaining. - */ - public Builder setSchemaJsonTruncated(boolean value) { - - schemaJsonTruncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * True if the schema_json field was truncated.
-       * 
- * - * bool schema_json_truncated = 11; - * - * @return This builder for chaining. - */ - public Builder clearSchemaJsonTruncated() { - - schemaJsonTruncated_ = false; - onChanged(); - return this; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition, - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder> - viewBuilder_; - /** - * - * - *
-       * View metadata. Only present for views.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - * - * @return Whether the view field is set. - */ - public boolean hasView() { - return viewBuilder_ != null || view_ != null; - } - /** - * - * - *
-       * View metadata. Only present for views.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - * - * @return The view. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition getView() { - if (viewBuilder_ == null) { - return view_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition - .getDefaultInstance() - : view_; - } else { - return viewBuilder_.getMessage(); - } - } - /** - * - * - *
-       * View metadata. Only present for views.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - */ - public Builder setView( - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition value) { - if (viewBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - view_ = value; - onChanged(); - } else { - viewBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * View metadata. Only present for views.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - */ - public Builder setView( - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder - builderForValue) { - if (viewBuilder_ == null) { - view_ = builderForValue.build(); - onChanged(); - } else { - viewBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * View metadata. Only present for views.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - */ - public Builder mergeView( - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition value) { - if (viewBuilder_ == null) { - if (view_ != null) { - view_ = - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.newBuilder(view_) - .mergeFrom(value) - .buildPartial(); - } else { - view_ = value; - } - onChanged(); - } else { - viewBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * View metadata. Only present for views.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - */ - public Builder clearView() { - if (viewBuilder_ == null) { - view_ = null; - onChanged(); - } else { - view_ = null; - viewBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * View metadata. Only present for views.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder - getViewBuilder() { - - onChanged(); - return getViewFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * View metadata. Only present for views.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder - getViewOrBuilder() { - if (viewBuilder_ != null) { - return viewBuilder_.getMessageOrBuilder(); - } else { - return view_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition - .getDefaultInstance() - : view_; - } - } - /** - * - * - *
-       * View metadata. Only present for views.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition view = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition, - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder> - getViewFieldBuilder() { - if (viewBuilder_ == null) { - viewBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition, - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder>( - getView(), getParentForChildren(), isClean()); - view_ = null; - } - return viewBuilder_; - } - - private com.google.protobuf.Timestamp expireTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - expireTimeBuilder_; - /** - * - * - *
-       * Table expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return Whether the expireTime field is set. - */ - public boolean hasExpireTime() { - return expireTimeBuilder_ != null || expireTime_ != null; - } - /** - * - * - *
-       * Table expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - * - * @return The expireTime. - */ - public com.google.protobuf.Timestamp getExpireTime() { - if (expireTimeBuilder_ == null) { - return expireTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : expireTime_; - } else { - return expireTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Table expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public Builder setExpireTime(com.google.protobuf.Timestamp value) { - if (expireTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - expireTime_ = value; - onChanged(); - } else { - expireTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Table expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public Builder setExpireTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (expireTimeBuilder_ == null) { - expireTime_ = builderForValue.build(); - onChanged(); - } else { - expireTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Table expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public Builder mergeExpireTime(com.google.protobuf.Timestamp value) { - if (expireTimeBuilder_ == null) { - if (expireTime_ != null) { - expireTime_ = - com.google.protobuf.Timestamp.newBuilder(expireTime_) - .mergeFrom(value) - .buildPartial(); - } else { - expireTime_ = value; - } - onChanged(); - } else { - expireTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Table expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public Builder clearExpireTime() { - if (expireTimeBuilder_ == null) { - expireTime_ = null; - onChanged(); - } else { - expireTime_ = null; - expireTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Table expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public com.google.protobuf.Timestamp.Builder getExpireTimeBuilder() { - - onChanged(); - return getExpireTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Table expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder() { - if (expireTimeBuilder_ != null) { - return expireTimeBuilder_.getMessageOrBuilder(); - } else { - return expireTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : expireTime_; - } - } - /** - * - * - *
-       * Table expiration time.
-       * 
- * - * .google.protobuf.Timestamp expire_time = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getExpireTimeFieldBuilder() { - if (expireTimeBuilder_ == null) { - expireTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getExpireTime(), getParentForChildren(), isClean()); - expireTime_ = null; - } - return expireTimeBuilder_; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-       * The table creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-       * The table creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * The table creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * The table creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * The table creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_) - .mergeFrom(value) - .buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * The table creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * The table creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * The table creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-       * The table creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private com.google.protobuf.Timestamp updateTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - updateTimeBuilder_; - /** - * - * - *
-       * The last time metadata update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return Whether the updateTime field is set. - */ - public boolean hasUpdateTime() { - return updateTimeBuilder_ != null || updateTime_ != null; - } - /** - * - * - *
-       * The last time metadata update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - * - * @return The updateTime. - */ - public com.google.protobuf.Timestamp getUpdateTime() { - if (updateTimeBuilder_ == null) { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } else { - return updateTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * The last time metadata update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp value) { - if (updateTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - updateTime_ = value; - onChanged(); - } else { - updateTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * The last time metadata update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (updateTimeBuilder_ == null) { - updateTime_ = builderForValue.build(); - onChanged(); - } else { - updateTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * The last time metadata update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { - if (updateTimeBuilder_ == null) { - if (updateTime_ != null) { - updateTime_ = - com.google.protobuf.Timestamp.newBuilder(updateTime_) - .mergeFrom(value) - .buildPartial(); - } else { - updateTime_ = value; - } - onChanged(); - } else { - updateTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * The last time metadata update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public Builder clearUpdateTime() { - if (updateTimeBuilder_ == null) { - updateTime_ = null; - onChanged(); - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * The last time metadata update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - - onChanged(); - return getUpdateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * The last time metadata update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - if (updateTimeBuilder_ != null) { - return updateTimeBuilder_.getMessageOrBuilder(); - } else { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } - } - /** - * - * - *
-       * The last time metadata update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 7; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getUpdateTimeFieldBuilder() { - if (updateTimeBuilder_ == null) { - updateTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getUpdateTime(), getParentForChildren(), isClean()); - updateTime_ = null; - } - return updateTimeBuilder_; - } - - private com.google.protobuf.Timestamp truncateTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - truncateTimeBuilder_; - /** - * - * - *
-       * The last table truncation time.
-       * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - * - * @return Whether the truncateTime field is set. - */ - public boolean hasTruncateTime() { - return truncateTimeBuilder_ != null || truncateTime_ != null; - } - /** - * - * - *
-       * The last table truncation time.
-       * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - * - * @return The truncateTime. - */ - public com.google.protobuf.Timestamp getTruncateTime() { - if (truncateTimeBuilder_ == null) { - return truncateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : truncateTime_; - } else { - return truncateTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * The last table truncation time.
-       * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - */ - public Builder setTruncateTime(com.google.protobuf.Timestamp value) { - if (truncateTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - truncateTime_ = value; - onChanged(); - } else { - truncateTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * The last table truncation time.
-       * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - */ - public Builder setTruncateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (truncateTimeBuilder_ == null) { - truncateTime_ = builderForValue.build(); - onChanged(); - } else { - truncateTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * The last table truncation time.
-       * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - */ - public Builder mergeTruncateTime(com.google.protobuf.Timestamp value) { - if (truncateTimeBuilder_ == null) { - if (truncateTime_ != null) { - truncateTime_ = - com.google.protobuf.Timestamp.newBuilder(truncateTime_) - .mergeFrom(value) - .buildPartial(); - } else { - truncateTime_ = value; - } - onChanged(); - } else { - truncateTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * The last table truncation time.
-       * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - */ - public Builder clearTruncateTime() { - if (truncateTimeBuilder_ == null) { - truncateTime_ = null; - onChanged(); - } else { - truncateTime_ = null; - truncateTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * The last table truncation time.
-       * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - */ - public com.google.protobuf.Timestamp.Builder getTruncateTimeBuilder() { - - onChanged(); - return getTruncateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * The last table truncation time.
-       * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - */ - public com.google.protobuf.TimestampOrBuilder getTruncateTimeOrBuilder() { - if (truncateTimeBuilder_ != null) { - return truncateTimeBuilder_.getMessageOrBuilder(); - } else { - return truncateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : truncateTime_; - } - } - /** - * - * - *
-       * The last table truncation time.
-       * 
- * - * .google.protobuf.Timestamp truncate_time = 8; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getTruncateTimeFieldBuilder() { - if (truncateTimeBuilder_ == null) { - truncateTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getTruncateTime(), getParentForChildren(), isClean()); - truncateTime_ = null; - } - return truncateTimeBuilder_; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - encryptionBuilder_; - /** - * - * - *
-       * Table encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - * - * @return Whether the encryption field is set. - */ - public boolean hasEncryption() { - return encryptionBuilder_ != null || encryption_ != null; - } - /** - * - * - *
-       * Table encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - * - * @return The encryption. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getEncryption() { - if (encryptionBuilder_ == null) { - return encryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : encryption_; - } else { - return encryptionBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Table encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - */ - public Builder setEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (encryptionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - encryption_ = value; - onChanged(); - } else { - encryptionBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Table encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - */ - public Builder setEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder builderForValue) { - if (encryptionBuilder_ == null) { - encryption_ = builderForValue.build(); - onChanged(); - } else { - encryptionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Table encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - */ - public Builder mergeEncryption( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo value) { - if (encryptionBuilder_ == null) { - if (encryption_ != null) { - encryption_ = - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder(encryption_) - .mergeFrom(value) - .buildPartial(); - } else { - encryption_ = value; - } - onChanged(); - } else { - encryptionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Table encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - */ - public Builder clearEncryption() { - if (encryptionBuilder_ == null) { - encryption_ = null; - onChanged(); - } else { - encryption_ = null; - encryptionBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Table encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder - getEncryptionBuilder() { - - onChanged(); - return getEncryptionFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Table encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder - getEncryptionOrBuilder() { - if (encryptionBuilder_ != null) { - return encryptionBuilder_.getMessageOrBuilder(); - } else { - return encryption_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance() - : encryption_; - } - } - /** - * - * - *
-       * Table encryption information. Set when non-default encryption is used.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo encryption = 9; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder> - getEncryptionFieldBuilder() { - if (encryptionBuilder_ == null) { - encryptionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder>( - getEncryption(), getParentForChildren(), isClean()); - encryption_ = null; - } - return encryptionBuilder_; - } - - private com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo tableInfo_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> - tableInfoBuilder_; - /** - * - * - *
-       * User-provided metadata for the table.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - * - * @return Whether the tableInfo field is set. - */ - public boolean hasTableInfo() { - return tableInfoBuilder_ != null || tableInfo_ != null; - } - /** - * - * - *
-       * User-provided metadata for the table.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - * - * @return The tableInfo. - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getTableInfo() { - if (tableInfoBuilder_ == null) { - return tableInfo_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() - : tableInfo_; - } else { - return tableInfoBuilder_.getMessage(); - } - } - /** - * - * - *
-       * User-provided metadata for the table.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - */ - public Builder setTableInfo(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { - if (tableInfoBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - tableInfo_ = value; - onChanged(); - } else { - tableInfoBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the table.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - */ - public Builder setTableInfo( - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder builderForValue) { - if (tableInfoBuilder_ == null) { - tableInfo_ = builderForValue.build(); - onChanged(); - } else { - tableInfoBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the table.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - */ - public Builder mergeTableInfo(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo value) { - if (tableInfoBuilder_ == null) { - if (tableInfo_ != null) { - tableInfo_ = - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.newBuilder(tableInfo_) - .mergeFrom(value) - .buildPartial(); - } else { - tableInfo_ = value; - } - onChanged(); - } else { - tableInfoBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the table.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - */ - public Builder clearTableInfo() { - if (tableInfoBuilder_ == null) { - tableInfo_ = null; - onChanged(); - } else { - tableInfo_ = null; - tableInfoBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * User-provided metadata for the table.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder getTableInfoBuilder() { - - onChanged(); - return getTableInfoFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * User-provided metadata for the table.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder - getTableInfoOrBuilder() { - if (tableInfoBuilder_ != null) { - return tableInfoBuilder_.getMessageOrBuilder(); - } else { - return tableInfo_ == null - ? com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance() - : tableInfo_; - } - } - /** - * - * - *
-       * User-provided metadata for the table.
-       * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.EntityInfo table_info = 10; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder> - getTableInfoFieldBuilder() { - if (tableInfoBuilder_ == null) { - tableInfoBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder>( - getTableInfo(), getParentForChildren(), isClean()); - tableInfo_ = null; - } - return tableInfoBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.Table) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.Table) - private static final com.google.cloud.audit.BigQueryAuditMetadata.Table DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.Table(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Table getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser
PARSER = - new com.google.protobuf.AbstractParser
() { - @java.lang.Override - public Table parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Table(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser
parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser
getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Table getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface RoutineOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.Routine) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Routine URI.
-     * Format:
-     * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
-     * 
- * - * string routine_name = 1; - * - * @return The routineName. - */ - java.lang.String getRoutineName(); - /** - * - * - *
-     * Routine URI.
-     * Format:
-     * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
-     * 
- * - * string routine_name = 1; - * - * @return The bytes for routineName. - */ - com.google.protobuf.ByteString getRoutineNameBytes(); - - /** - * - * - *
-     * Routine creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-     * Routine creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-     * Routine creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-     * Routine last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 6; - * - * @return Whether the updateTime field is set. - */ - boolean hasUpdateTime(); - /** - * - * - *
-     * Routine last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 6; - * - * @return The updateTime. - */ - com.google.protobuf.Timestamp getUpdateTime(); - /** - * - * - *
-     * Routine last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 6; - */ - com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); - } - /** - * - * - *
-   * User Defined Function (UDF) or Stored Procedure.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Routine} - */ - public static final class Routine extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.Routine) - RoutineOrBuilder { - private static final long serialVersionUID = 0L; - // Use Routine.newBuilder() to construct. - private Routine(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Routine() { - routineName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Routine(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Routine( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - routineName_ = s; - break; - } - case 42: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 50: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (updateTime_ != null) { - subBuilder = updateTime_.toBuilder(); - } - updateTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateTime_); - updateTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.Routine.class, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder.class); - } - - public static final int ROUTINE_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object routineName_; - /** - * - * - *
-     * Routine URI.
-     * Format:
-     * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
-     * 
- * - * string routine_name = 1; - * - * @return The routineName. - */ - @java.lang.Override - public java.lang.String getRoutineName() { - java.lang.Object ref = routineName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - routineName_ = s; - return s; - } - } - /** - * - * - *
-     * Routine URI.
-     * Format:
-     * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
-     * 
- * - * string routine_name = 1; - * - * @return The bytes for routineName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getRoutineNameBytes() { - java.lang.Object ref = routineName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - routineName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATE_TIME_FIELD_NUMBER = 5; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-     * Routine creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-     * Routine creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-     * Routine creation time.
-     * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int UPDATE_TIME_FIELD_NUMBER = 6; - private com.google.protobuf.Timestamp updateTime_; - /** - * - * - *
-     * Routine last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 6; - * - * @return Whether the updateTime field is set. - */ - @java.lang.Override - public boolean hasUpdateTime() { - return updateTime_ != null; - } - /** - * - * - *
-     * Routine last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 6; - * - * @return The updateTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getUpdateTime() { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; - } - /** - * - * - *
-     * Routine last update time.
-     * 
- * - * .google.protobuf.Timestamp update_time = 6; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - return getUpdateTime(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getRoutineNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, routineName_); - } - if (createTime_ != null) { - output.writeMessage(5, getCreateTime()); - } - if (updateTime_ != null) { - output.writeMessage(6, getUpdateTime()); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getRoutineNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, routineName_); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); - } - if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.Routine)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.Routine other = - (com.google.cloud.audit.BigQueryAuditMetadata.Routine) obj; - - if (!getRoutineName().equals(other.getRoutineName())) return false; - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasUpdateTime() != other.hasUpdateTime()) return false; - if (hasUpdateTime()) { - if (!getUpdateTime().equals(other.getUpdateTime())) return false; - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + ROUTINE_NAME_FIELD_NUMBER; - hash = (53 * hash) + getRoutineName().hashCode(); - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasUpdateTime()) { - hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getUpdateTime().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.Routine prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * User Defined Function (UDF) or Stored Procedure.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.Routine} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.Routine) - com.google.cloud.audit.BigQueryAuditMetadata.RoutineOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.Routine.class, - com.google.cloud.audit.BigQueryAuditMetadata.Routine.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.Routine.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - routineName_ = ""; - - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (updateTimeBuilder_ == null) { - updateTime_ = null; - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Routine getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Routine build() { - com.google.cloud.audit.BigQueryAuditMetadata.Routine result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Routine buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.Routine result = - new com.google.cloud.audit.BigQueryAuditMetadata.Routine(this); - result.routineName_ = routineName_; - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (updateTimeBuilder_ == null) { - result.updateTime_ = updateTime_; - } else { - result.updateTime_ = updateTimeBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.Routine) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.Routine) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.Routine other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.Routine.getDefaultInstance()) - return this; - if (!other.getRoutineName().isEmpty()) { - routineName_ = other.routineName_; - onChanged(); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasUpdateTime()) { - mergeUpdateTime(other.getUpdateTime()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.Routine parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.Routine) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object routineName_ = ""; - /** - * - * - *
-       * Routine URI.
-       * Format:
-       * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
-       * 
- * - * string routine_name = 1; - * - * @return The routineName. - */ - public java.lang.String getRoutineName() { - java.lang.Object ref = routineName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - routineName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Routine URI.
-       * Format:
-       * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
-       * 
- * - * string routine_name = 1; - * - * @return The bytes for routineName. - */ - public com.google.protobuf.ByteString getRoutineNameBytes() { - java.lang.Object ref = routineName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - routineName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Routine URI.
-       * Format:
-       * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
-       * 
- * - * string routine_name = 1; - * - * @param value The routineName to set. - * @return This builder for chaining. - */ - public Builder setRoutineName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - routineName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Routine URI.
-       * Format:
-       * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
-       * 
- * - * string routine_name = 1; - * - * @return This builder for chaining. - */ - public Builder clearRoutineName() { - - routineName_ = getDefaultInstance().getRoutineName(); - onChanged(); - return this; - } - /** - * - * - *
-       * Routine URI.
-       * Format:
-       * `projects/<project_id>/datasets/<dataset_id>/routines/<routine_id>`.
-       * 
- * - * string routine_name = 1; - * - * @param value The bytes for routineName to set. - * @return This builder for chaining. - */ - public Builder setRoutineNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - routineName_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-       * Routine creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 5; - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-       * Routine creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 5; - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Routine creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Routine creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Routine creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_) - .mergeFrom(value) - .buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Routine creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Routine creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Routine creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-       * Routine creation time.
-       * 
- * - * .google.protobuf.Timestamp create_time = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private com.google.protobuf.Timestamp updateTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - updateTimeBuilder_; - /** - * - * - *
-       * Routine last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 6; - * - * @return Whether the updateTime field is set. - */ - public boolean hasUpdateTime() { - return updateTimeBuilder_ != null || updateTime_ != null; - } - /** - * - * - *
-       * Routine last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 6; - * - * @return The updateTime. - */ - public com.google.protobuf.Timestamp getUpdateTime() { - if (updateTimeBuilder_ == null) { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } else { - return updateTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Routine last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 6; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp value) { - if (updateTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - updateTime_ = value; - onChanged(); - } else { - updateTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Routine last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 6; - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (updateTimeBuilder_ == null) { - updateTime_ = builderForValue.build(); - onChanged(); - } else { - updateTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Routine last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 6; - */ - public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { - if (updateTimeBuilder_ == null) { - if (updateTime_ != null) { - updateTime_ = - com.google.protobuf.Timestamp.newBuilder(updateTime_) - .mergeFrom(value) - .buildPartial(); - } else { - updateTime_ = value; - } - onChanged(); - } else { - updateTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Routine last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 6; - */ - public Builder clearUpdateTime() { - if (updateTimeBuilder_ == null) { - updateTime_ = null; - onChanged(); - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Routine last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 6; - */ - public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - - onChanged(); - return getUpdateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Routine last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 6; - */ - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - if (updateTimeBuilder_ != null) { - return updateTimeBuilder_.getMessageOrBuilder(); - } else { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } - } - /** - * - * - *
-       * Routine last update time.
-       * 
- * - * .google.protobuf.Timestamp update_time = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getUpdateTimeFieldBuilder() { - if (updateTimeBuilder_ == null) { - updateTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getUpdateTime(), getParentForChildren(), isClean()); - updateTime_ = null; - } - return updateTimeBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.Routine) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.Routine) - private static final com.google.cloud.audit.BigQueryAuditMetadata.Routine DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.Routine(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.Routine getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Routine parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Routine(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.Routine getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface EntityInfoOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.EntityInfo) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * A short name for the entity.
-     * 
- * - * string friendly_name = 1; - * - * @return The friendlyName. - */ - java.lang.String getFriendlyName(); - /** - * - * - *
-     * A short name for the entity.
-     * 
- * - * string friendly_name = 1; - * - * @return The bytes for friendlyName. - */ - com.google.protobuf.ByteString getFriendlyNameBytes(); - - /** - * - * - *
-     * A long description for the entity.
-     * 
- * - * string description = 2; - * - * @return The description. - */ - java.lang.String getDescription(); - /** - * - * - *
-     * A long description for the entity.
-     * 
- * - * string description = 2; - * - * @return The bytes for description. - */ - com.google.protobuf.ByteString getDescriptionBytes(); - - /** - * - * - *
-     * Labels provided for the entity.
-     * 
- * - * map<string, string> labels = 3; - */ - int getLabelsCount(); - /** - * - * - *
-     * Labels provided for the entity.
-     * 
- * - * map<string, string> labels = 3; - */ - boolean containsLabels(java.lang.String key); - /** Use {@link #getLabelsMap()} instead. */ - @java.lang.Deprecated - java.util.Map getLabels(); - /** - * - * - *
-     * Labels provided for the entity.
-     * 
- * - * map<string, string> labels = 3; - */ - java.util.Map getLabelsMap(); - /** - * - * - *
-     * Labels provided for the entity.
-     * 
- * - * map<string, string> labels = 3; - */ - java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue); - /** - * - * - *
-     * Labels provided for the entity.
-     * 
- * - * map<string, string> labels = 3; - */ - java.lang.String getLabelsOrThrow(java.lang.String key); - } - /** - * - * - *
-   * User-provided metadata for an entity, for e.g. dataset, table or model.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.EntityInfo} - */ - public static final class EntityInfo extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.EntityInfo) - EntityInfoOrBuilder { - private static final long serialVersionUID = 0L; - // Use EntityInfo.newBuilder() to construct. - private EntityInfo(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private EntityInfo() { - friendlyName_ = ""; - description_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new EntityInfo(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private EntityInfo( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - friendlyName_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - description_ = s; - break; - } - case 26: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - labels_ = - com.google.protobuf.MapField.newMapField( - LabelsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry labels__ = - input.readMessage( - LabelsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - labels_.getMutableMap().put(labels__.getKey(), labels__.getValue()); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 3: - return internalGetLabels(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.class, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder.class); - } - - public static final int FRIENDLY_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object friendlyName_; - /** - * - * - *
-     * A short name for the entity.
-     * 
- * - * string friendly_name = 1; - * - * @return The friendlyName. - */ - @java.lang.Override - public java.lang.String getFriendlyName() { - java.lang.Object ref = friendlyName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - friendlyName_ = s; - return s; - } - } - /** - * - * - *
-     * A short name for the entity.
-     * 
- * - * string friendly_name = 1; - * - * @return The bytes for friendlyName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getFriendlyNameBytes() { - java.lang.Object ref = friendlyName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - friendlyName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DESCRIPTION_FIELD_NUMBER = 2; - private volatile java.lang.Object description_; - /** - * - * - *
-     * A long description for the entity.
-     * 
- * - * string description = 2; - * - * @return The description. - */ - @java.lang.Override - public java.lang.String getDescription() { - java.lang.Object ref = description_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - description_ = s; - return s; - } - } - /** - * - * - *
-     * A long description for the entity.
-     * 
- * - * string description = 2; - * - * @return The bytes for description. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int LABELS_FIELD_NUMBER = 3; - - private static final class LabelsDefaultEntryHolder { - static final com.google.protobuf.MapEntry defaultEntry = - com.google.protobuf.MapEntry.newDefaultInstance( - com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - - private com.google.protobuf.MapField labels_; - - private com.google.protobuf.MapField internalGetLabels() { - if (labels_ == null) { - return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); - } - return labels_; - } - - public int getLabelsCount() { - return internalGetLabels().getMap().size(); - } - /** - * - * - *
-     * Labels provided for the entity.
-     * 
- * - * map<string, string> labels = 3; - */ - @java.lang.Override - public boolean containsLabels(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetLabels().getMap().containsKey(key); - } - /** Use {@link #getLabelsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getLabels() { - return getLabelsMap(); - } - /** - * - * - *
-     * Labels provided for the entity.
-     * 
- * - * map<string, string> labels = 3; - */ - @java.lang.Override - public java.util.Map getLabelsMap() { - return internalGetLabels().getMap(); - } - /** - * - * - *
-     * Labels provided for the entity.
-     * 
- * - * map<string, string> labels = 3; - */ - @java.lang.Override - public java.lang.String getLabelsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Labels provided for the entity.
-     * 
- * - * map<string, string> labels = 3; - */ - @java.lang.Override - public java.lang.String getLabelsOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getFriendlyNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, friendlyName_); - } - if (!getDescriptionBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 3); - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getFriendlyNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, friendlyName_); - } - if (!getDescriptionBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); - } - for (java.util.Map.Entry entry : - internalGetLabels().getMap().entrySet()) { - com.google.protobuf.MapEntry labels__ = - LabelsDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, labels__); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo other = - (com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo) obj; - - if (!getFriendlyName().equals(other.getFriendlyName())) return false; - if (!getDescription().equals(other.getDescription())) return false; - if (!internalGetLabels().equals(other.internalGetLabels())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + FRIENDLY_NAME_FIELD_NUMBER; - hash = (53 * hash) + getFriendlyName().hashCode(); - hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; - hash = (53 * hash) + getDescription().hashCode(); - if (!internalGetLabels().getMap().isEmpty()) { - hash = (37 * hash) + LABELS_FIELD_NUMBER; - hash = (53 * hash) + internalGetLabels().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * User-provided metadata for an entity, for e.g. dataset, table or model.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.EntityInfo} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.EntityInfo) - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfoOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 3: - return internalGetLabels(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 3: - return internalGetMutableLabels(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.class, - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - friendlyName_ = ""; - - description_ = ""; - - internalGetMutableLabels().clear(); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo build() { - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo result = - new com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo(this); - int from_bitField0_ = bitField0_; - result.friendlyName_ = friendlyName_; - result.description_ = description_; - result.labels_ = internalGetLabels(); - result.labels_.makeImmutable(); - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo.getDefaultInstance()) - return this; - if (!other.getFriendlyName().isEmpty()) { - friendlyName_ = other.friendlyName_; - onChanged(); - } - if (!other.getDescription().isEmpty()) { - description_ = other.description_; - onChanged(); - } - internalGetMutableLabels().mergeFrom(other.internalGetLabels()); - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.lang.Object friendlyName_ = ""; - /** - * - * - *
-       * A short name for the entity.
-       * 
- * - * string friendly_name = 1; - * - * @return The friendlyName. - */ - public java.lang.String getFriendlyName() { - java.lang.Object ref = friendlyName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - friendlyName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * A short name for the entity.
-       * 
- * - * string friendly_name = 1; - * - * @return The bytes for friendlyName. - */ - public com.google.protobuf.ByteString getFriendlyNameBytes() { - java.lang.Object ref = friendlyName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - friendlyName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * A short name for the entity.
-       * 
- * - * string friendly_name = 1; - * - * @param value The friendlyName to set. - * @return This builder for chaining. - */ - public Builder setFriendlyName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - friendlyName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * A short name for the entity.
-       * 
- * - * string friendly_name = 1; - * - * @return This builder for chaining. - */ - public Builder clearFriendlyName() { - - friendlyName_ = getDefaultInstance().getFriendlyName(); - onChanged(); - return this; - } - /** - * - * - *
-       * A short name for the entity.
-       * 
- * - * string friendly_name = 1; - * - * @param value The bytes for friendlyName to set. - * @return This builder for chaining. - */ - public Builder setFriendlyNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - friendlyName_ = value; - onChanged(); - return this; - } - - private java.lang.Object description_ = ""; - /** - * - * - *
-       * A long description for the entity.
-       * 
- * - * string description = 2; - * - * @return The description. - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - description_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * A long description for the entity.
-       * 
- * - * string description = 2; - * - * @return The bytes for description. - */ - public com.google.protobuf.ByteString getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * A long description for the entity.
-       * 
- * - * string description = 2; - * - * @param value The description to set. - * @return This builder for chaining. - */ - public Builder setDescription(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - description_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * A long description for the entity.
-       * 
- * - * string description = 2; - * - * @return This builder for chaining. - */ - public Builder clearDescription() { - - description_ = getDefaultInstance().getDescription(); - onChanged(); - return this; - } - /** - * - * - *
-       * A long description for the entity.
-       * 
- * - * string description = 2; - * - * @param value The bytes for description to set. - * @return This builder for chaining. - */ - public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - description_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.MapField labels_; - - private com.google.protobuf.MapField internalGetLabels() { - if (labels_ == null) { - return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); - } - return labels_; - } - - private com.google.protobuf.MapField - internalGetMutableLabels() { - onChanged(); - ; - if (labels_ == null) { - labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); - } - if (!labels_.isMutable()) { - labels_ = labels_.copy(); - } - return labels_; - } - - public int getLabelsCount() { - return internalGetLabels().getMap().size(); - } - /** - * - * - *
-       * Labels provided for the entity.
-       * 
- * - * map<string, string> labels = 3; - */ - @java.lang.Override - public boolean containsLabels(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - return internalGetLabels().getMap().containsKey(key); - } - /** Use {@link #getLabelsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getLabels() { - return getLabelsMap(); - } - /** - * - * - *
-       * Labels provided for the entity.
-       * 
- * - * map<string, string> labels = 3; - */ - @java.lang.Override - public java.util.Map getLabelsMap() { - return internalGetLabels().getMap(); - } - /** - * - * - *
-       * Labels provided for the entity.
-       * 
- * - * map<string, string> labels = 3; - */ - @java.lang.Override - public java.lang.String getLabelsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-       * Labels provided for the entity.
-       * 
- * - * map<string, string> labels = 3; - */ - @java.lang.Override - public java.lang.String getLabelsOrThrow(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - java.util.Map map = internalGetLabels().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearLabels() { - internalGetMutableLabels().getMutableMap().clear(); - return this; - } - /** - * - * - *
-       * Labels provided for the entity.
-       * 
- * - * map<string, string> labels = 3; - */ - public Builder removeLabels(java.lang.String key) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableLabels().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableLabels() { - return internalGetMutableLabels().getMutableMap(); - } - /** - * - * - *
-       * Labels provided for the entity.
-       * 
- * - * map<string, string> labels = 3; - */ - public Builder putLabels(java.lang.String key, java.lang.String value) { - if (key == null) { - throw new java.lang.NullPointerException(); - } - if (value == null) { - throw new java.lang.NullPointerException(); - } - internalGetMutableLabels().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-       * Labels provided for the entity.
-       * 
- * - * map<string, string> labels = 3; - */ - public Builder putAllLabels(java.util.Map values) { - internalGetMutableLabels().getMutableMap().putAll(values); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.EntityInfo) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.EntityInfo) - private static final com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public EntityInfo parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new EntityInfo(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EntityInfo getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface TableViewDefinitionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * SQL query defining the view. Truncated if exceeds 40K.
-     * 
- * - * string query = 1; - * - * @return The query. - */ - java.lang.String getQuery(); - /** - * - * - *
-     * SQL query defining the view. Truncated if exceeds 40K.
-     * 
- * - * string query = 1; - * - * @return The bytes for query. - */ - com.google.protobuf.ByteString getQueryBytes(); - - /** - * - * - *
-     * True if the schema_json field was truncated.
-     * 
- * - * bool query_truncated = 2; - * - * @return The queryTruncated. - */ - boolean getQueryTruncated(); - } - /** - * - * - *
-   * View definition.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition} - */ - public static final class TableViewDefinition extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) - TableViewDefinitionOrBuilder { - private static final long serialVersionUID = 0L; - // Use TableViewDefinition.newBuilder() to construct. - private TableViewDefinition(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private TableViewDefinition() { - query_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TableViewDefinition(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private TableViewDefinition( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - query_ = s; - break; - } - case 16: - { - queryTruncated_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder.class); - } - - public static final int QUERY_FIELD_NUMBER = 1; - private volatile java.lang.Object query_; - /** - * - * - *
-     * SQL query defining the view. Truncated if exceeds 40K.
-     * 
- * - * string query = 1; - * - * @return The query. - */ - @java.lang.Override - public java.lang.String getQuery() { - java.lang.Object ref = query_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - query_ = s; - return s; - } - } - /** - * - * - *
-     * SQL query defining the view. Truncated if exceeds 40K.
-     * 
- * - * string query = 1; - * - * @return The bytes for query. - */ - @java.lang.Override - public com.google.protobuf.ByteString getQueryBytes() { - java.lang.Object ref = query_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - query_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int QUERY_TRUNCATED_FIELD_NUMBER = 2; - private boolean queryTruncated_; - /** - * - * - *
-     * True if the schema_json field was truncated.
-     * 
- * - * bool query_truncated = 2; - * - * @return The queryTruncated. - */ - @java.lang.Override - public boolean getQueryTruncated() { - return queryTruncated_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getQueryBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, query_); - } - if (queryTruncated_ != false) { - output.writeBool(2, queryTruncated_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getQueryBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, query_); - } - if (queryTruncated_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, queryTruncated_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition other = - (com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) obj; - - if (!getQuery().equals(other.getQuery())) return false; - if (getQueryTruncated() != other.getQueryTruncated()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + QUERY_FIELD_NUMBER; - hash = (53 * hash) + getQuery().hashCode(); - hash = (37 * hash) + QUERY_TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getQueryTruncated()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition - parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * View definition.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinitionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.class, - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.Builder.class); - } - - // Construct using - // com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - query_ = ""; - - queryTruncated_ = false; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition - .getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition build() { - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition result = - new com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition(this); - result.query_ = query_; - result.queryTruncated_ = queryTruncated_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) { - return mergeFrom( - (com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition - .getDefaultInstance()) return this; - if (!other.getQuery().isEmpty()) { - query_ = other.query_; - onChanged(); - } - if (other.getQueryTruncated() != false) { - setQueryTruncated(other.getQueryTruncated()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object query_ = ""; - /** - * - * - *
-       * SQL query defining the view. Truncated if exceeds 40K.
-       * 
- * - * string query = 1; - * - * @return The query. - */ - public java.lang.String getQuery() { - java.lang.Object ref = query_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - query_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * SQL query defining the view. Truncated if exceeds 40K.
-       * 
- * - * string query = 1; - * - * @return The bytes for query. - */ - public com.google.protobuf.ByteString getQueryBytes() { - java.lang.Object ref = query_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - query_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * SQL query defining the view. Truncated if exceeds 40K.
-       * 
- * - * string query = 1; - * - * @param value The query to set. - * @return This builder for chaining. - */ - public Builder setQuery(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - query_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * SQL query defining the view. Truncated if exceeds 40K.
-       * 
- * - * string query = 1; - * - * @return This builder for chaining. - */ - public Builder clearQuery() { - - query_ = getDefaultInstance().getQuery(); - onChanged(); - return this; - } - /** - * - * - *
-       * SQL query defining the view. Truncated if exceeds 40K.
-       * 
- * - * string query = 1; - * - * @param value The bytes for query to set. - * @return This builder for chaining. - */ - public Builder setQueryBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - query_ = value; - onChanged(); - return this; - } - - private boolean queryTruncated_; - /** - * - * - *
-       * True if the schema_json field was truncated.
-       * 
- * - * bool query_truncated = 2; - * - * @return The queryTruncated. - */ - @java.lang.Override - public boolean getQueryTruncated() { - return queryTruncated_; - } - /** - * - * - *
-       * True if the schema_json field was truncated.
-       * 
- * - * bool query_truncated = 2; - * - * @param value The queryTruncated to set. - * @return This builder for chaining. - */ - public Builder setQueryTruncated(boolean value) { - - queryTruncated_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * True if the schema_json field was truncated.
-       * 
- * - * bool query_truncated = 2; - * - * @return This builder for chaining. - */ - public Builder clearQueryTruncated() { - - queryTruncated_ = false; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition) - private static final com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public TableViewDefinition parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TableViewDefinition(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableViewDefinition - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface BigQueryAclOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * IAM policy for the resource.
-     * 
- * - * .google.iam.v1.Policy policy = 1; - * - * @return Whether the policy field is set. - */ - boolean hasPolicy(); - /** - * - * - *
-     * IAM policy for the resource.
-     * 
- * - * .google.iam.v1.Policy policy = 1; - * - * @return The policy. - */ - com.google.iam.v1.Policy getPolicy(); - /** - * - * - *
-     * IAM policy for the resource.
-     * 
- * - * .google.iam.v1.Policy policy = 1; - */ - com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder(); - - /** - * - * - *
-     * List of authorized views for a dataset.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-     * 
- * - * repeated string authorized_views = 2; - * - * @return A list containing the authorizedViews. - */ - java.util.List getAuthorizedViewsList(); - /** - * - * - *
-     * List of authorized views for a dataset.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-     * 
- * - * repeated string authorized_views = 2; - * - * @return The count of authorizedViews. - */ - int getAuthorizedViewsCount(); - /** - * - * - *
-     * List of authorized views for a dataset.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-     * 
- * - * repeated string authorized_views = 2; - * - * @param index The index of the element to return. - * @return The authorizedViews at the given index. - */ - java.lang.String getAuthorizedViews(int index); - /** - * - * - *
-     * List of authorized views for a dataset.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-     * 
- * - * repeated string authorized_views = 2; - * - * @param index The index of the value to return. - * @return The bytes of the authorizedViews at the given index. - */ - com.google.protobuf.ByteString getAuthorizedViewsBytes(int index); - } - /** - * - * - *
-   * An access control list.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl} - */ - public static final class BigQueryAcl extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) - BigQueryAclOrBuilder { - private static final long serialVersionUID = 0L; - // Use BigQueryAcl.newBuilder() to construct. - private BigQueryAcl(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BigQueryAcl() { - authorizedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new BigQueryAcl(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private BigQueryAcl( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - 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; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - authorizedViews_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - authorizedViews_.add(s); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - authorizedViews_ = authorizedViews_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.class, - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder.class); - } - - public static final int POLICY_FIELD_NUMBER = 1; - private com.google.iam.v1.Policy policy_; - /** - * - * - *
-     * IAM policy for the resource.
-     * 
- * - * .google.iam.v1.Policy policy = 1; - * - * @return Whether the policy field is set. - */ - @java.lang.Override - public boolean hasPolicy() { - return policy_ != null; - } - /** - * - * - *
-     * IAM policy for the resource.
-     * 
- * - * .google.iam.v1.Policy policy = 1; - * - * @return The policy. - */ - @java.lang.Override - public com.google.iam.v1.Policy getPolicy() { - return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_; - } - /** - * - * - *
-     * IAM policy for the resource.
-     * 
- * - * .google.iam.v1.Policy policy = 1; - */ - @java.lang.Override - public com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder() { - return getPolicy(); - } - - public static final int AUTHORIZED_VIEWS_FIELD_NUMBER = 2; - private com.google.protobuf.LazyStringList authorizedViews_; - /** - * - * - *
-     * List of authorized views for a dataset.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-     * 
- * - * repeated string authorized_views = 2; - * - * @return A list containing the authorizedViews. - */ - public com.google.protobuf.ProtocolStringList getAuthorizedViewsList() { - return authorizedViews_; - } - /** - * - * - *
-     * List of authorized views for a dataset.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-     * 
- * - * repeated string authorized_views = 2; - * - * @return The count of authorizedViews. - */ - public int getAuthorizedViewsCount() { - return authorizedViews_.size(); - } - /** - * - * - *
-     * List of authorized views for a dataset.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-     * 
- * - * repeated string authorized_views = 2; - * - * @param index The index of the element to return. - * @return The authorizedViews at the given index. - */ - public java.lang.String getAuthorizedViews(int index) { - return authorizedViews_.get(index); - } - /** - * - * - *
-     * List of authorized views for a dataset.
-     * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-     * 
- * - * repeated string authorized_views = 2; - * - * @param index The index of the value to return. - * @return The bytes of the authorizedViews at the given index. - */ - public com.google.protobuf.ByteString getAuthorizedViewsBytes(int index) { - return authorizedViews_.getByteString(index); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (policy_ != null) { - output.writeMessage(1, getPolicy()); - } - for (int i = 0; i < authorizedViews_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, authorizedViews_.getRaw(i)); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (policy_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getPolicy()); - } - { - int dataSize = 0; - for (int i = 0; i < authorizedViews_.size(); i++) { - dataSize += computeStringSizeNoTag(authorizedViews_.getRaw(i)); - } - size += dataSize; - size += 1 * getAuthorizedViewsList().size(); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl other = - (com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) obj; - - if (hasPolicy() != other.hasPolicy()) return false; - if (hasPolicy()) { - if (!getPolicy().equals(other.getPolicy())) return false; - } - if (!getAuthorizedViewsList().equals(other.getAuthorizedViewsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasPolicy()) { - hash = (37 * hash) + POLICY_FIELD_NUMBER; - hash = (53 * hash) + getPolicy().hashCode(); - } - if (getAuthorizedViewsCount() > 0) { - hash = (37 * hash) + AUTHORIZED_VIEWS_FIELD_NUMBER; - hash = (53 * hash) + getAuthorizedViewsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * An access control list.
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAclOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.class, - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (policyBuilder_ == null) { - policy_ = null; - } else { - policy_ = null; - policyBuilder_ = null; - } - authorizedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl build() { - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl result = - new com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl(this); - int from_bitField0_ = bitField0_; - if (policyBuilder_ == null) { - result.policy_ = policy_; - } else { - result.policy_ = policyBuilder_.build(); - } - if (((bitField0_ & 0x00000001) != 0)) { - authorizedViews_ = authorizedViews_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.authorizedViews_ = authorizedViews_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl.getDefaultInstance()) - return this; - if (other.hasPolicy()) { - mergePolicy(other.getPolicy()); - } - if (!other.authorizedViews_.isEmpty()) { - if (authorizedViews_.isEmpty()) { - authorizedViews_ = other.authorizedViews_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureAuthorizedViewsIsMutable(); - authorizedViews_.addAll(other.authorizedViews_); - } - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private com.google.iam.v1.Policy policy_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.iam.v1.Policy, - com.google.iam.v1.Policy.Builder, - com.google.iam.v1.PolicyOrBuilder> - policyBuilder_; - /** - * - * - *
-       * IAM policy for the resource.
-       * 
- * - * .google.iam.v1.Policy policy = 1; - * - * @return Whether the policy field is set. - */ - public boolean hasPolicy() { - return policyBuilder_ != null || policy_ != null; - } - /** - * - * - *
-       * IAM policy for the resource.
-       * 
- * - * .google.iam.v1.Policy policy = 1; - * - * @return The policy. - */ - public com.google.iam.v1.Policy getPolicy() { - if (policyBuilder_ == null) { - return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_; - } else { - return policyBuilder_.getMessage(); - } - } - /** - * - * - *
-       * IAM policy for the resource.
-       * 
- * - * .google.iam.v1.Policy policy = 1; - */ - public Builder setPolicy(com.google.iam.v1.Policy value) { - if (policyBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - policy_ = value; - onChanged(); - } else { - policyBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * IAM policy for the resource.
-       * 
- * - * .google.iam.v1.Policy policy = 1; - */ - public Builder setPolicy(com.google.iam.v1.Policy.Builder builderForValue) { - if (policyBuilder_ == null) { - policy_ = builderForValue.build(); - onChanged(); - } else { - policyBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * IAM policy for the resource.
-       * 
- * - * .google.iam.v1.Policy policy = 1; - */ - public Builder mergePolicy(com.google.iam.v1.Policy value) { - if (policyBuilder_ == null) { - if (policy_ != null) { - policy_ = com.google.iam.v1.Policy.newBuilder(policy_).mergeFrom(value).buildPartial(); - } else { - policy_ = value; - } - onChanged(); - } else { - policyBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * IAM policy for the resource.
-       * 
- * - * .google.iam.v1.Policy policy = 1; - */ - public Builder clearPolicy() { - if (policyBuilder_ == null) { - policy_ = null; - onChanged(); - } else { - policy_ = null; - policyBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * IAM policy for the resource.
-       * 
- * - * .google.iam.v1.Policy policy = 1; - */ - public com.google.iam.v1.Policy.Builder getPolicyBuilder() { - - onChanged(); - return getPolicyFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * IAM policy for the resource.
-       * 
- * - * .google.iam.v1.Policy policy = 1; - */ - public com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder() { - if (policyBuilder_ != null) { - return policyBuilder_.getMessageOrBuilder(); - } else { - return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_; - } - } - /** - * - * - *
-       * IAM policy for the resource.
-       * 
- * - * .google.iam.v1.Policy policy = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - 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< - com.google.iam.v1.Policy, - com.google.iam.v1.Policy.Builder, - com.google.iam.v1.PolicyOrBuilder>( - getPolicy(), getParentForChildren(), isClean()); - policy_ = null; - } - return policyBuilder_; - } - - private com.google.protobuf.LazyStringList authorizedViews_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureAuthorizedViewsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - authorizedViews_ = new com.google.protobuf.LazyStringArrayList(authorizedViews_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-       * List of authorized views for a dataset.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-       * 
- * - * repeated string authorized_views = 2; - * - * @return A list containing the authorizedViews. - */ - public com.google.protobuf.ProtocolStringList getAuthorizedViewsList() { - return authorizedViews_.getUnmodifiableView(); - } - /** - * - * - *
-       * List of authorized views for a dataset.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-       * 
- * - * repeated string authorized_views = 2; - * - * @return The count of authorizedViews. - */ - public int getAuthorizedViewsCount() { - return authorizedViews_.size(); - } - /** - * - * - *
-       * List of authorized views for a dataset.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-       * 
- * - * repeated string authorized_views = 2; - * - * @param index The index of the element to return. - * @return The authorizedViews at the given index. - */ - public java.lang.String getAuthorizedViews(int index) { - return authorizedViews_.get(index); - } - /** - * - * - *
-       * List of authorized views for a dataset.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-       * 
- * - * repeated string authorized_views = 2; - * - * @param index The index of the value to return. - * @return The bytes of the authorizedViews at the given index. - */ - public com.google.protobuf.ByteString getAuthorizedViewsBytes(int index) { - return authorizedViews_.getByteString(index); - } - /** - * - * - *
-       * List of authorized views for a dataset.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-       * 
- * - * repeated string authorized_views = 2; - * - * @param index The index to set the value at. - * @param value The authorizedViews to set. - * @return This builder for chaining. - */ - public Builder setAuthorizedViews(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureAuthorizedViewsIsMutable(); - authorizedViews_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-       * List of authorized views for a dataset.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-       * 
- * - * repeated string authorized_views = 2; - * - * @param value The authorizedViews to add. - * @return This builder for chaining. - */ - public Builder addAuthorizedViews(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureAuthorizedViewsIsMutable(); - authorizedViews_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-       * List of authorized views for a dataset.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-       * 
- * - * repeated string authorized_views = 2; - * - * @param values The authorizedViews to add. - * @return This builder for chaining. - */ - public Builder addAllAuthorizedViews(java.lang.Iterable values) { - ensureAuthorizedViewsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, authorizedViews_); - onChanged(); - return this; - } - /** - * - * - *
-       * List of authorized views for a dataset.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-       * 
- * - * repeated string authorized_views = 2; - * - * @return This builder for chaining. - */ - public Builder clearAuthorizedViews() { - authorizedViews_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-       * List of authorized views for a dataset.
-       * Format: `projects/<project_id>/datasets/<dataset_id>/tables/<view_id>`.
-       * 
- * - * repeated string authorized_views = 2; - * - * @param value The bytes of the authorizedViews to add. - * @return This builder for chaining. - */ - public Builder addAuthorizedViewsBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureAuthorizedViewsIsMutable(); - authorizedViews_.add(value); - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl) - private static final com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BigQueryAcl parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BigQueryAcl(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.BigQueryAcl getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface EncryptionInfoOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Cloud kms key identifier.
-     * Format:
-     * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
-     * 
- * - * string kms_key_name = 1; - * - * @return The kmsKeyName. - */ - java.lang.String getKmsKeyName(); - /** - * - * - *
-     * Cloud kms key identifier.
-     * Format:
-     * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
-     * 
- * - * string kms_key_name = 1; - * - * @return The bytes for kmsKeyName. - */ - com.google.protobuf.ByteString getKmsKeyNameBytes(); - } - /** - * - * - *
-   * Encryption properties for a table or a job
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo} - */ - public static final class EncryptionInfo extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) - EncryptionInfoOrBuilder { - private static final long serialVersionUID = 0L; - // Use EncryptionInfo.newBuilder() to construct. - private EncryptionInfo(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private EncryptionInfo() { - kmsKeyName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new EncryptionInfo(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private EncryptionInfo( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - kmsKeyName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - 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); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.class, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder.class); - } - - public static final int KMS_KEY_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object kmsKeyName_; - /** - * - * - *
-     * Cloud kms key identifier.
-     * Format:
-     * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
-     * 
- * - * string kms_key_name = 1; - * - * @return The kmsKeyName. - */ - @java.lang.Override - public java.lang.String getKmsKeyName() { - java.lang.Object ref = kmsKeyName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - kmsKeyName_ = s; - return s; - } - } - /** - * - * - *
-     * Cloud kms key identifier.
-     * Format:
-     * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
-     * 
- * - * string kms_key_name = 1; - * - * @return The bytes for kmsKeyName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getKmsKeyNameBytes() { - java.lang.Object ref = kmsKeyName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - kmsKeyName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getKmsKeyNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, kmsKeyName_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getKmsKeyNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, kmsKeyName_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo other = - (com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) obj; - - if (!getKmsKeyName().equals(other.getKmsKeyName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + KMS_KEY_NAME_FIELD_NUMBER; - hash = (53 * hash) + getKmsKeyName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Encryption properties for a table or a job
-     * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfoOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.class, - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - kmsKeyName_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo build() { - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo result = - new com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo(this); - result.kmsKeyName_ = kmsKeyName_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo other) { - if (other - == com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo.getDefaultInstance()) - return this; - if (!other.getKmsKeyName().isEmpty()) { - kmsKeyName_ = other.kmsKeyName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object kmsKeyName_ = ""; - /** - * - * - *
-       * Cloud kms key identifier.
-       * Format:
-       * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
-       * 
- * - * string kms_key_name = 1; - * - * @return The kmsKeyName. - */ - public java.lang.String getKmsKeyName() { - java.lang.Object ref = kmsKeyName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - kmsKeyName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Cloud kms key identifier.
-       * Format:
-       * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
-       * 
- * - * string kms_key_name = 1; - * - * @return The bytes for kmsKeyName. - */ - public com.google.protobuf.ByteString getKmsKeyNameBytes() { - java.lang.Object ref = kmsKeyName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - kmsKeyName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Cloud kms key identifier.
-       * Format:
-       * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
-       * 
- * - * string kms_key_name = 1; - * - * @param value The kmsKeyName to set. - * @return This builder for chaining. - */ - public Builder setKmsKeyName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - kmsKeyName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Cloud kms key identifier.
-       * Format:
-       * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
-       * 
- * - * string kms_key_name = 1; - * - * @return This builder for chaining. - */ - public Builder clearKmsKeyName() { - - kmsKeyName_ = getDefaultInstance().getKmsKeyName(); - onChanged(); - return this; - } - /** - * - * - *
-       * Cloud kms key identifier.
-       * Format:
-       * `projects/<project_id>/locations/<location>/keyRings/<key_ring_name>/cryptoKeys/<key_name>`
-       * 
- * - * string kms_key_name = 1; - * - * @param value The bytes for kmsKeyName to set. - * @return This builder for chaining. - */ - public Builder setKmsKeyNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - kmsKeyName_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo) - private static final com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public EncryptionInfo parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new EncryptionInfo(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.EncryptionInfo getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - private int eventCase_ = 0; - private java.lang.Object event_; - - public enum EventCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - JOB_INSERTION(1), - JOB_CHANGE(2), - DATASET_CREATION(3), - DATASET_CHANGE(4), - DATASET_DELETION(5), - TABLE_CREATION(6), - TABLE_CHANGE(8), - TABLE_DELETION(9), - TABLE_DATA_READ(10), - TABLE_DATA_CHANGE(11), - MODEL_DELETION(12), - MODEL_CREATION(13), - MODEL_METADATA_CHANGE(14), - MODEL_DATA_CHANGE(15), - MODEL_DATA_READ(19), - ROUTINE_CREATION(16), - ROUTINE_CHANGE(17), - ROUTINE_DELETION(18), - EVENT_NOT_SET(0); - private final int value; - - private EventCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static EventCase valueOf(int value) { - return forNumber(value); - } - - public static EventCase forNumber(int value) { - switch (value) { - case 1: - return JOB_INSERTION; - case 2: - return JOB_CHANGE; - case 3: - return DATASET_CREATION; - case 4: - return DATASET_CHANGE; - case 5: - return DATASET_DELETION; - case 6: - return TABLE_CREATION; - case 8: - return TABLE_CHANGE; - case 9: - return TABLE_DELETION; - case 10: - return TABLE_DATA_READ; - case 11: - return TABLE_DATA_CHANGE; - case 12: - return MODEL_DELETION; - case 13: - return MODEL_CREATION; - case 14: - return MODEL_METADATA_CHANGE; - case 15: - return MODEL_DATA_CHANGE; - case 19: - return MODEL_DATA_READ; - case 16: - return ROUTINE_CREATION; - case 17: - return ROUTINE_CHANGE; - case 18: - return ROUTINE_DELETION; - case 0: - return EVENT_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public EventCase getEventCase() { - return EventCase.forNumber(eventCase_); - } - - public static final int JOB_INSERTION_FIELD_NUMBER = 1; - /** - * - * - *
-   * Job insertion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - * - * @return Whether the jobInsertion field is set. - */ - @java.lang.Override - public boolean hasJobInsertion() { - return eventCase_ == 1; - } - /** - * - * - *
-   * Job insertion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - * - * @return The jobInsertion. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getJobInsertion() { - if (eventCase_ == 1) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); - } - /** - * - * - *
-   * Job insertion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder - getJobInsertionOrBuilder() { - if (eventCase_ == 1) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); - } - - public static final int JOB_CHANGE_FIELD_NUMBER = 2; - /** - * - * - *
-   * Job state change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - * - * @return Whether the jobChange field is set. - */ - @java.lang.Override - public boolean hasJobChange() { - return eventCase_ == 2; - } - /** - * - * - *
-   * Job state change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - * - * @return The jobChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobChange getJobChange() { - if (eventCase_ == 2) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); - } - /** - * - * - *
-   * Job state change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder getJobChangeOrBuilder() { - if (eventCase_ == 2) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); - } - - public static final int DATASET_CREATION_FIELD_NUMBER = 3; - /** - * - * - *
-   * Dataset creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - * - * @return Whether the datasetCreation field is set. - */ - @java.lang.Override - public boolean hasDatasetCreation() { - return eventCase_ == 3; - } - /** - * - * - *
-   * Dataset creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - * - * @return The datasetCreation. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation getDatasetCreation() { - if (eventCase_ == 3) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); - } - /** - * - * - *
-   * Dataset creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder - getDatasetCreationOrBuilder() { - if (eventCase_ == 3) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); - } - - public static final int DATASET_CHANGE_FIELD_NUMBER = 4; - /** - * - * - *
-   * Dataset change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - * - * @return Whether the datasetChange field is set. - */ - @java.lang.Override - public boolean hasDatasetChange() { - return eventCase_ == 4; - } - /** - * - * - *
-   * Dataset change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - * - * @return The datasetChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange getDatasetChange() { - if (eventCase_ == 4) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); - } - /** - * - * - *
-   * Dataset change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder - getDatasetChangeOrBuilder() { - if (eventCase_ == 4) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); - } - - public static final int DATASET_DELETION_FIELD_NUMBER = 5; - /** - * - * - *
-   * Dataset deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - * - * @return Whether the datasetDeletion field is set. - */ - @java.lang.Override - public boolean hasDatasetDeletion() { - return eventCase_ == 5; - } - /** - * - * - *
-   * Dataset deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - * - * @return The datasetDeletion. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion getDatasetDeletion() { - if (eventCase_ == 5) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); - } - /** - * - * - *
-   * Dataset deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder - getDatasetDeletionOrBuilder() { - if (eventCase_ == 5) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); - } - - public static final int TABLE_CREATION_FIELD_NUMBER = 6; - /** - * - * - *
-   * Table creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - * - * @return Whether the tableCreation field is set. - */ - @java.lang.Override - public boolean hasTableCreation() { - return eventCase_ == 6; - } - /** - * - * - *
-   * Table creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - * - * @return The tableCreation. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation getTableCreation() { - if (eventCase_ == 6) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); - } - /** - * - * - *
-   * Table creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder - getTableCreationOrBuilder() { - if (eventCase_ == 6) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); - } - - public static final int TABLE_CHANGE_FIELD_NUMBER = 8; - /** - * - * - *
-   * Table metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - * - * @return Whether the tableChange field is set. - */ - @java.lang.Override - public boolean hasTableChange() { - return eventCase_ == 8; - } - /** - * - * - *
-   * Table metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - * - * @return The tableChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableChange getTableChange() { - if (eventCase_ == 8) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); - } - /** - * - * - *
-   * Table metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder - getTableChangeOrBuilder() { - if (eventCase_ == 8) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); - } - - public static final int TABLE_DELETION_FIELD_NUMBER = 9; - /** - * - * - *
-   * Table deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - * - * @return Whether the tableDeletion field is set. - */ - @java.lang.Override - public boolean hasTableDeletion() { - return eventCase_ == 9; - } - /** - * - * - *
-   * Table deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - * - * @return The tableDeletion. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion getTableDeletion() { - if (eventCase_ == 9) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); - } - /** - * - * - *
-   * Table deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder - getTableDeletionOrBuilder() { - if (eventCase_ == 9) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); - } - - public static final int TABLE_DATA_READ_FIELD_NUMBER = 10; - /** - * - * - *
-   * Table data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - * - * @return Whether the tableDataRead field is set. - */ - @java.lang.Override - public boolean hasTableDataRead() { - return eventCase_ == 10; - } - /** - * - * - *
-   * Table data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - * - * @return The tableDataRead. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead getTableDataRead() { - if (eventCase_ == 10) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); - } - /** - * - * - *
-   * Table data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder - getTableDataReadOrBuilder() { - if (eventCase_ == 10) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); - } - - public static final int TABLE_DATA_CHANGE_FIELD_NUMBER = 11; - /** - * - * - *
-   * Table data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - * @return Whether the tableDataChange field is set. - */ - @java.lang.Override - public boolean hasTableDataChange() { - return eventCase_ == 11; - } - /** - * - * - *
-   * Table data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - * @return The tableDataChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange getTableDataChange() { - if (eventCase_ == 11) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); - } - /** - * - * - *
-   * Table data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder - getTableDataChangeOrBuilder() { - if (eventCase_ == 11) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); - } - - public static final int MODEL_DELETION_FIELD_NUMBER = 12; - /** - * - * - *
-   * Model deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - * - * @return Whether the modelDeletion field is set. - */ - @java.lang.Override - public boolean hasModelDeletion() { - return eventCase_ == 12; - } - /** - * - * - *
-   * Model deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - * - * @return The modelDeletion. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion getModelDeletion() { - if (eventCase_ == 12) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); - } - /** - * - * - *
-   * Model deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder - getModelDeletionOrBuilder() { - if (eventCase_ == 12) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); - } - - public static final int MODEL_CREATION_FIELD_NUMBER = 13; - /** - * - * - *
-   * Model creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - * - * @return Whether the modelCreation field is set. - */ - @java.lang.Override - public boolean hasModelCreation() { - return eventCase_ == 13; - } - /** - * - * - *
-   * Model creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - * - * @return The modelCreation. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation getModelCreation() { - if (eventCase_ == 13) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); - } - /** - * - * - *
-   * Model creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder - getModelCreationOrBuilder() { - if (eventCase_ == 13) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); - } - - public static final int MODEL_METADATA_CHANGE_FIELD_NUMBER = 14; - /** - * - * - *
-   * Model metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - * - * @return Whether the modelMetadataChange field is set. - */ - @java.lang.Override - public boolean hasModelMetadataChange() { - return eventCase_ == 14; - } - /** - * - * - *
-   * Model metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - * - * @return The modelMetadataChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange getModelMetadataChange() { - if (eventCase_ == 14) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.getDefaultInstance(); - } - /** - * - * - *
-   * Model metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder - getModelMetadataChangeOrBuilder() { - if (eventCase_ == 14) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.getDefaultInstance(); - } - - public static final int MODEL_DATA_CHANGE_FIELD_NUMBER = 15; - /** - * - * - *
-   * Model data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - * @return Whether the modelDataChange field is set. - */ - @java.lang.Override - public boolean hasModelDataChange() { - return eventCase_ == 15; - } - /** - * - * - *
-   * Model data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - * @return The modelDataChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange getModelDataChange() { - if (eventCase_ == 15) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); - } - /** - * - * - *
-   * Model data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder - getModelDataChangeOrBuilder() { - if (eventCase_ == 15) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); - } - - public static final int MODEL_DATA_READ_FIELD_NUMBER = 19; - /** - * - * - *
-   * Model data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - * - * @return Whether the modelDataRead field is set. - */ - @java.lang.Override - public boolean hasModelDataRead() { - return eventCase_ == 19; - } - /** - * - * - *
-   * Model data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - * - * @return The modelDataRead. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead getModelDataRead() { - if (eventCase_ == 19) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); - } - /** - * - * - *
-   * Model data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder - getModelDataReadOrBuilder() { - if (eventCase_ == 19) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); - } - - public static final int ROUTINE_CREATION_FIELD_NUMBER = 16; - /** - * - * - *
-   * Routine creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - * - * @return Whether the routineCreation field is set. - */ - @java.lang.Override - public boolean hasRoutineCreation() { - return eventCase_ == 16; - } - /** - * - * - *
-   * Routine creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - * - * @return The routineCreation. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation getRoutineCreation() { - if (eventCase_ == 16) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); - } - /** - * - * - *
-   * Routine creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder - getRoutineCreationOrBuilder() { - if (eventCase_ == 16) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); - } - - public static final int ROUTINE_CHANGE_FIELD_NUMBER = 17; - /** - * - * - *
-   * Routine change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - * - * @return Whether the routineChange field is set. - */ - @java.lang.Override - public boolean hasRoutineChange() { - return eventCase_ == 17; - } - /** - * - * - *
-   * Routine change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - * - * @return The routineChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange getRoutineChange() { - if (eventCase_ == 17) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); - } - /** - * - * - *
-   * Routine change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder - getRoutineChangeOrBuilder() { - if (eventCase_ == 17) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); - } - - public static final int ROUTINE_DELETION_FIELD_NUMBER = 18; - /** - * - * - *
-   * Routine deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - * - * @return Whether the routineDeletion field is set. - */ - @java.lang.Override - public boolean hasRoutineDeletion() { - return eventCase_ == 18; - } - /** - * - * - *
-   * Routine deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - * - * @return The routineDeletion. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion getRoutineDeletion() { - if (eventCase_ == 18) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); - } - /** - * - * - *
-   * Routine deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder - getRoutineDeletionOrBuilder() { - if (eventCase_ == 18) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (eventCase_ == 1) { - output.writeMessage(1, (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_); - } - if (eventCase_ == 2) { - output.writeMessage(2, (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_); - } - if (eventCase_ == 3) { - output.writeMessage(3, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_); - } - if (eventCase_ == 4) { - output.writeMessage(4, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_); - } - if (eventCase_ == 5) { - output.writeMessage(5, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_); - } - if (eventCase_ == 6) { - output.writeMessage(6, (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_); - } - if (eventCase_ == 8) { - output.writeMessage(8, (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_); - } - if (eventCase_ == 9) { - output.writeMessage(9, (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_); - } - if (eventCase_ == 10) { - output.writeMessage(10, (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_); - } - if (eventCase_ == 11) { - output.writeMessage( - 11, (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_); - } - if (eventCase_ == 12) { - output.writeMessage(12, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_); - } - if (eventCase_ == 13) { - output.writeMessage(13, (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_); - } - if (eventCase_ == 14) { - output.writeMessage( - 14, (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_); - } - if (eventCase_ == 15) { - output.writeMessage( - 15, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_); - } - if (eventCase_ == 16) { - output.writeMessage( - 16, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_); - } - if (eventCase_ == 17) { - output.writeMessage(17, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_); - } - if (eventCase_ == 18) { - output.writeMessage( - 18, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_); - } - if (eventCase_ == 19) { - output.writeMessage(19, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (eventCase_ == 1) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 1, (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_); - } - if (eventCase_ == 2) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 2, (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_); - } - if (eventCase_ == 3) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 3, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_); - } - if (eventCase_ == 4) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 4, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_); - } - if (eventCase_ == 5) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 5, (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_); - } - if (eventCase_ == 6) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 6, (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_); - } - if (eventCase_ == 8) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 8, (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_); - } - if (eventCase_ == 9) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 9, (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_); - } - if (eventCase_ == 10) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 10, (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_); - } - if (eventCase_ == 11) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 11, (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_); - } - if (eventCase_ == 12) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 12, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_); - } - if (eventCase_ == 13) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 13, (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_); - } - if (eventCase_ == 14) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 14, (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_); - } - if (eventCase_ == 15) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 15, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_); - } - if (eventCase_ == 16) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 16, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_); - } - if (eventCase_ == 17) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 17, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_); - } - if (eventCase_ == 18) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 18, (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_); - } - if (eventCase_ == 19) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 19, (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.audit.BigQueryAuditMetadata)) { - return super.equals(obj); - } - com.google.cloud.audit.BigQueryAuditMetadata other = - (com.google.cloud.audit.BigQueryAuditMetadata) obj; - - if (!getEventCase().equals(other.getEventCase())) return false; - switch (eventCase_) { - case 1: - if (!getJobInsertion().equals(other.getJobInsertion())) return false; - break; - case 2: - if (!getJobChange().equals(other.getJobChange())) return false; - break; - case 3: - if (!getDatasetCreation().equals(other.getDatasetCreation())) return false; - break; - case 4: - if (!getDatasetChange().equals(other.getDatasetChange())) return false; - break; - case 5: - if (!getDatasetDeletion().equals(other.getDatasetDeletion())) return false; - break; - case 6: - if (!getTableCreation().equals(other.getTableCreation())) return false; - break; - case 8: - if (!getTableChange().equals(other.getTableChange())) return false; - break; - case 9: - if (!getTableDeletion().equals(other.getTableDeletion())) return false; - break; - case 10: - if (!getTableDataRead().equals(other.getTableDataRead())) return false; - break; - case 11: - if (!getTableDataChange().equals(other.getTableDataChange())) return false; - break; - case 12: - if (!getModelDeletion().equals(other.getModelDeletion())) return false; - break; - case 13: - if (!getModelCreation().equals(other.getModelCreation())) return false; - break; - case 14: - if (!getModelMetadataChange().equals(other.getModelMetadataChange())) return false; - break; - case 15: - if (!getModelDataChange().equals(other.getModelDataChange())) return false; - break; - case 19: - if (!getModelDataRead().equals(other.getModelDataRead())) return false; - break; - case 16: - if (!getRoutineCreation().equals(other.getRoutineCreation())) return false; - break; - case 17: - if (!getRoutineChange().equals(other.getRoutineChange())) return false; - break; - case 18: - if (!getRoutineDeletion().equals(other.getRoutineDeletion())) return false; - break; - case 0: - default: - } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (eventCase_) { - case 1: - hash = (37 * hash) + JOB_INSERTION_FIELD_NUMBER; - hash = (53 * hash) + getJobInsertion().hashCode(); - break; - case 2: - hash = (37 * hash) + JOB_CHANGE_FIELD_NUMBER; - hash = (53 * hash) + getJobChange().hashCode(); - break; - case 3: - hash = (37 * hash) + DATASET_CREATION_FIELD_NUMBER; - hash = (53 * hash) + getDatasetCreation().hashCode(); - break; - case 4: - hash = (37 * hash) + DATASET_CHANGE_FIELD_NUMBER; - hash = (53 * hash) + getDatasetChange().hashCode(); - break; - case 5: - hash = (37 * hash) + DATASET_DELETION_FIELD_NUMBER; - hash = (53 * hash) + getDatasetDeletion().hashCode(); - break; - case 6: - hash = (37 * hash) + TABLE_CREATION_FIELD_NUMBER; - hash = (53 * hash) + getTableCreation().hashCode(); - break; - case 8: - hash = (37 * hash) + TABLE_CHANGE_FIELD_NUMBER; - hash = (53 * hash) + getTableChange().hashCode(); - break; - case 9: - hash = (37 * hash) + TABLE_DELETION_FIELD_NUMBER; - hash = (53 * hash) + getTableDeletion().hashCode(); - break; - case 10: - hash = (37 * hash) + TABLE_DATA_READ_FIELD_NUMBER; - hash = (53 * hash) + getTableDataRead().hashCode(); - break; - case 11: - hash = (37 * hash) + TABLE_DATA_CHANGE_FIELD_NUMBER; - hash = (53 * hash) + getTableDataChange().hashCode(); - break; - case 12: - hash = (37 * hash) + MODEL_DELETION_FIELD_NUMBER; - hash = (53 * hash) + getModelDeletion().hashCode(); - break; - case 13: - hash = (37 * hash) + MODEL_CREATION_FIELD_NUMBER; - hash = (53 * hash) + getModelCreation().hashCode(); - break; - case 14: - hash = (37 * hash) + MODEL_METADATA_CHANGE_FIELD_NUMBER; - hash = (53 * hash) + getModelMetadataChange().hashCode(); - break; - case 15: - hash = (37 * hash) + MODEL_DATA_CHANGE_FIELD_NUMBER; - hash = (53 * hash) + getModelDataChange().hashCode(); - break; - case 19: - hash = (37 * hash) + MODEL_DATA_READ_FIELD_NUMBER; - hash = (53 * hash) + getModelDataRead().hashCode(); - break; - case 16: - hash = (37 * hash) + ROUTINE_CREATION_FIELD_NUMBER; - hash = (53 * hash) + getRoutineCreation().hashCode(); - break; - case 17: - hash = (37 * hash) + ROUTINE_CHANGE_FIELD_NUMBER; - hash = (53 * hash) + getRoutineChange().hashCode(); - break; - case 18: - hash = (37 * hash) + ROUTINE_DELETION_FIELD_NUMBER; - hash = (53 * hash) + getRoutineDeletion().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloud.audit.BigQueryAuditMetadata prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Audit log format for BigQuery cloud audit logs metadata.
-   * 
- * - * Protobuf type {@code google.cloud.audit.BigQueryAuditMetadata} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.audit.BigQueryAuditMetadata) - com.google.cloud.audit.BigQueryAuditMetadataOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.audit.BigQueryAuditMetadata.class, - com.google.cloud.audit.BigQueryAuditMetadata.Builder.class); - } - - // Construct using com.google.cloud.audit.BigQueryAuditMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - eventCase_ = 0; - event_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.audit.BigQueryAuditMetadataProto - .internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata getDefaultInstanceForType() { - return com.google.cloud.audit.BigQueryAuditMetadata.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata build() { - com.google.cloud.audit.BigQueryAuditMetadata result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata buildPartial() { - com.google.cloud.audit.BigQueryAuditMetadata result = - new com.google.cloud.audit.BigQueryAuditMetadata(this); - if (eventCase_ == 1) { - if (jobInsertionBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = jobInsertionBuilder_.build(); - } - } - if (eventCase_ == 2) { - if (jobChangeBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = jobChangeBuilder_.build(); - } - } - if (eventCase_ == 3) { - if (datasetCreationBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = datasetCreationBuilder_.build(); - } - } - if (eventCase_ == 4) { - if (datasetChangeBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = datasetChangeBuilder_.build(); - } - } - if (eventCase_ == 5) { - if (datasetDeletionBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = datasetDeletionBuilder_.build(); - } - } - if (eventCase_ == 6) { - if (tableCreationBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = tableCreationBuilder_.build(); - } - } - if (eventCase_ == 8) { - if (tableChangeBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = tableChangeBuilder_.build(); - } - } - if (eventCase_ == 9) { - if (tableDeletionBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = tableDeletionBuilder_.build(); - } - } - if (eventCase_ == 10) { - if (tableDataReadBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = tableDataReadBuilder_.build(); - } - } - if (eventCase_ == 11) { - if (tableDataChangeBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = tableDataChangeBuilder_.build(); - } - } - if (eventCase_ == 12) { - if (modelDeletionBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = modelDeletionBuilder_.build(); - } - } - if (eventCase_ == 13) { - if (modelCreationBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = modelCreationBuilder_.build(); - } - } - if (eventCase_ == 14) { - if (modelMetadataChangeBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = modelMetadataChangeBuilder_.build(); - } - } - if (eventCase_ == 15) { - if (modelDataChangeBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = modelDataChangeBuilder_.build(); - } - } - if (eventCase_ == 19) { - if (modelDataReadBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = modelDataReadBuilder_.build(); - } - } - if (eventCase_ == 16) { - if (routineCreationBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = routineCreationBuilder_.build(); - } - } - if (eventCase_ == 17) { - if (routineChangeBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = routineChangeBuilder_.build(); - } - } - if (eventCase_ == 18) { - if (routineDeletionBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = routineDeletionBuilder_.build(); - } - } - result.eventCase_ = eventCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloud.audit.BigQueryAuditMetadata) { - return mergeFrom((com.google.cloud.audit.BigQueryAuditMetadata) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloud.audit.BigQueryAuditMetadata other) { - if (other == com.google.cloud.audit.BigQueryAuditMetadata.getDefaultInstance()) return this; - switch (other.getEventCase()) { - case JOB_INSERTION: - { - mergeJobInsertion(other.getJobInsertion()); - break; - } - case JOB_CHANGE: - { - mergeJobChange(other.getJobChange()); - break; - } - case DATASET_CREATION: - { - mergeDatasetCreation(other.getDatasetCreation()); - break; - } - case DATASET_CHANGE: - { - mergeDatasetChange(other.getDatasetChange()); - break; - } - case DATASET_DELETION: - { - mergeDatasetDeletion(other.getDatasetDeletion()); - break; - } - case TABLE_CREATION: - { - mergeTableCreation(other.getTableCreation()); - break; - } - case TABLE_CHANGE: - { - mergeTableChange(other.getTableChange()); - break; - } - case TABLE_DELETION: - { - mergeTableDeletion(other.getTableDeletion()); - break; - } - case TABLE_DATA_READ: - { - mergeTableDataRead(other.getTableDataRead()); - break; - } - case TABLE_DATA_CHANGE: - { - mergeTableDataChange(other.getTableDataChange()); - break; - } - case MODEL_DELETION: - { - mergeModelDeletion(other.getModelDeletion()); - break; - } - case MODEL_CREATION: - { - mergeModelCreation(other.getModelCreation()); - break; - } - case MODEL_METADATA_CHANGE: - { - mergeModelMetadataChange(other.getModelMetadataChange()); - break; - } - case MODEL_DATA_CHANGE: - { - mergeModelDataChange(other.getModelDataChange()); - break; - } - case MODEL_DATA_READ: - { - mergeModelDataRead(other.getModelDataRead()); - break; - } - case ROUTINE_CREATION: - { - mergeRoutineCreation(other.getRoutineCreation()); - break; - } - case ROUTINE_CHANGE: - { - mergeRoutineChange(other.getRoutineChange()); - break; - } - case ROUTINE_DELETION: - { - mergeRoutineDeletion(other.getRoutineDeletion()); - break; - } - case EVENT_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.audit.BigQueryAuditMetadata parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloud.audit.BigQueryAuditMetadata) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int eventCase_ = 0; - private java.lang.Object event_; - - public EventCase getEventCase() { - return EventCase.forNumber(eventCase_); - } - - public Builder clearEvent() { - eventCase_ = 0; - event_ = null; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion, - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder> - jobInsertionBuilder_; - /** - * - * - *
-     * Job insertion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - * - * @return Whether the jobInsertion field is set. - */ - @java.lang.Override - public boolean hasJobInsertion() { - return eventCase_ == 1; - } - /** - * - * - *
-     * Job insertion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - * - * @return The jobInsertion. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getJobInsertion() { - if (jobInsertionBuilder_ == null) { - if (eventCase_ == 1) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); - } else { - if (eventCase_ == 1) { - return jobInsertionBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); - } - } - /** - * - * - *
-     * Job insertion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - */ - public Builder setJobInsertion( - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion value) { - if (jobInsertionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - jobInsertionBuilder_.setMessage(value); - } - eventCase_ = 1; - return this; - } - /** - * - * - *
-     * Job insertion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - */ - public Builder setJobInsertion( - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder builderForValue) { - if (jobInsertionBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - jobInsertionBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 1; - return this; - } - /** - * - * - *
-     * Job insertion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - */ - public Builder mergeJobInsertion( - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion value) { - if (jobInsertionBuilder_ == null) { - if (eventCase_ == 1 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 1) { - jobInsertionBuilder_.mergeFrom(value); - } - jobInsertionBuilder_.setMessage(value); - } - eventCase_ = 1; - return this; - } - /** - * - * - *
-     * Job insertion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - */ - public Builder clearJobInsertion() { - if (jobInsertionBuilder_ == null) { - if (eventCase_ == 1) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 1) { - eventCase_ = 0; - event_ = null; - } - jobInsertionBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Job insertion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder - getJobInsertionBuilder() { - return getJobInsertionFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Job insertion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder - getJobInsertionOrBuilder() { - if ((eventCase_ == 1) && (jobInsertionBuilder_ != null)) { - return jobInsertionBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 1) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); - } - } - /** - * - * - *
-     * Job insertion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion, - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder> - getJobInsertionFieldBuilder() { - if (jobInsertionBuilder_ == null) { - if (!(eventCase_ == 1)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.getDefaultInstance(); - } - jobInsertionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion, - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 1; - onChanged(); - ; - return jobInsertionBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobChange, - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder> - jobChangeBuilder_; - /** - * - * - *
-     * Job state change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - * - * @return Whether the jobChange field is set. - */ - @java.lang.Override - public boolean hasJobChange() { - return eventCase_ == 2; - } - /** - * - * - *
-     * Job state change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - * - * @return The jobChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobChange getJobChange() { - if (jobChangeBuilder_ == null) { - if (eventCase_ == 2) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); - } else { - if (eventCase_ == 2) { - return jobChangeBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Job state change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - */ - public Builder setJobChange(com.google.cloud.audit.BigQueryAuditMetadata.JobChange value) { - if (jobChangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - jobChangeBuilder_.setMessage(value); - } - eventCase_ = 2; - return this; - } - /** - * - * - *
-     * Job state change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - */ - public Builder setJobChange( - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder builderForValue) { - if (jobChangeBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - jobChangeBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 2; - return this; - } - /** - * - * - *
-     * Job state change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - */ - public Builder mergeJobChange(com.google.cloud.audit.BigQueryAuditMetadata.JobChange value) { - if (jobChangeBuilder_ == null) { - if (eventCase_ == 2 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 2) { - jobChangeBuilder_.mergeFrom(value); - } - jobChangeBuilder_.setMessage(value); - } - eventCase_ = 2; - return this; - } - /** - * - * - *
-     * Job state change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - */ - public Builder clearJobChange() { - if (jobChangeBuilder_ == null) { - if (eventCase_ == 2) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 2) { - eventCase_ = 0; - event_ = null; - } - jobChangeBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Job state change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder getJobChangeBuilder() { - return getJobChangeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Job state change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder getJobChangeOrBuilder() { - if ((eventCase_ == 2) && (jobChangeBuilder_ != null)) { - return jobChangeBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 2) { - return (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Job state change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobChange, - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder> - getJobChangeFieldBuilder() { - if (jobChangeBuilder_ == null) { - if (!(eventCase_ == 2)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.JobChange.getDefaultInstance(); - } - jobChangeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.JobChange, - com.google.cloud.audit.BigQueryAuditMetadata.JobChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.JobChange) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 2; - onChanged(); - ; - return jobChangeBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder> - datasetCreationBuilder_; - /** - * - * - *
-     * Dataset creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - * - * @return Whether the datasetCreation field is set. - */ - @java.lang.Override - public boolean hasDatasetCreation() { - return eventCase_ == 3; - } - /** - * - * - *
-     * Dataset creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - * - * @return The datasetCreation. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation getDatasetCreation() { - if (datasetCreationBuilder_ == null) { - if (eventCase_ == 3) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); - } else { - if (eventCase_ == 3) { - return datasetCreationBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); - } - } - /** - * - * - *
-     * Dataset creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - */ - public Builder setDatasetCreation( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation value) { - if (datasetCreationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - datasetCreationBuilder_.setMessage(value); - } - eventCase_ = 3; - return this; - } - /** - * - * - *
-     * Dataset creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - */ - public Builder setDatasetCreation( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder builderForValue) { - if (datasetCreationBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - datasetCreationBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 3; - return this; - } - /** - * - * - *
-     * Dataset creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - */ - public Builder mergeDatasetCreation( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation value) { - if (datasetCreationBuilder_ == null) { - if (eventCase_ == 3 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 3) { - datasetCreationBuilder_.mergeFrom(value); - } - datasetCreationBuilder_.setMessage(value); - } - eventCase_ = 3; - return this; - } - /** - * - * - *
-     * Dataset creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - */ - public Builder clearDatasetCreation() { - if (datasetCreationBuilder_ == null) { - if (eventCase_ == 3) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 3) { - eventCase_ = 0; - event_ = null; - } - datasetCreationBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Dataset creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder - getDatasetCreationBuilder() { - return getDatasetCreationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Dataset creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder - getDatasetCreationOrBuilder() { - if ((eventCase_ == 3) && (datasetCreationBuilder_ != null)) { - return datasetCreationBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 3) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); - } - } - /** - * - * - *
-     * Dataset creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder> - getDatasetCreationFieldBuilder() { - if (datasetCreationBuilder_ == null) { - if (!(eventCase_ == 3)) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.getDefaultInstance(); - } - datasetCreationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 3; - onChanged(); - ; - return datasetCreationBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder> - datasetChangeBuilder_; - /** - * - * - *
-     * Dataset change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - * - * @return Whether the datasetChange field is set. - */ - @java.lang.Override - public boolean hasDatasetChange() { - return eventCase_ == 4; - } - /** - * - * - *
-     * Dataset change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - * - * @return The datasetChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange getDatasetChange() { - if (datasetChangeBuilder_ == null) { - if (eventCase_ == 4) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); - } else { - if (eventCase_ == 4) { - return datasetChangeBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Dataset change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - */ - public Builder setDatasetChange( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange value) { - if (datasetChangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - datasetChangeBuilder_.setMessage(value); - } - eventCase_ = 4; - return this; - } - /** - * - * - *
-     * Dataset change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - */ - public Builder setDatasetChange( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder builderForValue) { - if (datasetChangeBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - datasetChangeBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 4; - return this; - } - /** - * - * - *
-     * Dataset change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - */ - public Builder mergeDatasetChange( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange value) { - if (datasetChangeBuilder_ == null) { - if (eventCase_ == 4 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 4) { - datasetChangeBuilder_.mergeFrom(value); - } - datasetChangeBuilder_.setMessage(value); - } - eventCase_ = 4; - return this; - } - /** - * - * - *
-     * Dataset change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - */ - public Builder clearDatasetChange() { - if (datasetChangeBuilder_ == null) { - if (eventCase_ == 4) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 4) { - eventCase_ = 0; - event_ = null; - } - datasetChangeBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Dataset change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder - getDatasetChangeBuilder() { - return getDatasetChangeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Dataset change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder - getDatasetChangeOrBuilder() { - if ((eventCase_ == 4) && (datasetChangeBuilder_ != null)) { - return datasetChangeBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 4) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Dataset change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder> - getDatasetChangeFieldBuilder() { - if (datasetChangeBuilder_ == null) { - if (!(eventCase_ == 4)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.getDefaultInstance(); - } - datasetChangeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 4; - onChanged(); - ; - return datasetChangeBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder> - datasetDeletionBuilder_; - /** - * - * - *
-     * Dataset deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - * - * @return Whether the datasetDeletion field is set. - */ - @java.lang.Override - public boolean hasDatasetDeletion() { - return eventCase_ == 5; - } - /** - * - * - *
-     * Dataset deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - * - * @return The datasetDeletion. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion getDatasetDeletion() { - if (datasetDeletionBuilder_ == null) { - if (eventCase_ == 5) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); - } else { - if (eventCase_ == 5) { - return datasetDeletionBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); - } - } - /** - * - * - *
-     * Dataset deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - */ - public Builder setDatasetDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion value) { - if (datasetDeletionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - datasetDeletionBuilder_.setMessage(value); - } - eventCase_ = 5; - return this; - } - /** - * - * - *
-     * Dataset deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - */ - public Builder setDatasetDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder builderForValue) { - if (datasetDeletionBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - datasetDeletionBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 5; - return this; - } - /** - * - * - *
-     * Dataset deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - */ - public Builder mergeDatasetDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion value) { - if (datasetDeletionBuilder_ == null) { - if (eventCase_ == 5 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 5) { - datasetDeletionBuilder_.mergeFrom(value); - } - datasetDeletionBuilder_.setMessage(value); - } - eventCase_ = 5; - return this; - } - /** - * - * - *
-     * Dataset deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - */ - public Builder clearDatasetDeletion() { - if (datasetDeletionBuilder_ == null) { - if (eventCase_ == 5) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 5) { - eventCase_ = 0; - event_ = null; - } - datasetDeletionBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Dataset deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder - getDatasetDeletionBuilder() { - return getDatasetDeletionFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Dataset deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder - getDatasetDeletionOrBuilder() { - if ((eventCase_ == 5) && (datasetDeletionBuilder_ != null)) { - return datasetDeletionBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 5) { - return (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); - } - } - /** - * - * - *
-     * Dataset deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder> - getDatasetDeletionFieldBuilder() { - if (datasetDeletionBuilder_ == null) { - if (!(eventCase_ == 5)) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.getDefaultInstance(); - } - datasetDeletionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 5; - onChanged(); - ; - return datasetDeletionBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation, - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder> - tableCreationBuilder_; - /** - * - * - *
-     * Table creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - * - * @return Whether the tableCreation field is set. - */ - @java.lang.Override - public boolean hasTableCreation() { - return eventCase_ == 6; - } - /** - * - * - *
-     * Table creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - * - * @return The tableCreation. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation getTableCreation() { - if (tableCreationBuilder_ == null) { - if (eventCase_ == 6) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); - } else { - if (eventCase_ == 6) { - return tableCreationBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); - } - } - /** - * - * - *
-     * Table creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - */ - public Builder setTableCreation( - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation value) { - if (tableCreationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - tableCreationBuilder_.setMessage(value); - } - eventCase_ = 6; - return this; - } - /** - * - * - *
-     * Table creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - */ - public Builder setTableCreation( - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder builderForValue) { - if (tableCreationBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - tableCreationBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 6; - return this; - } - /** - * - * - *
-     * Table creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - */ - public Builder mergeTableCreation( - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation value) { - if (tableCreationBuilder_ == null) { - if (eventCase_ == 6 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableCreation - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 6) { - tableCreationBuilder_.mergeFrom(value); - } - tableCreationBuilder_.setMessage(value); - } - eventCase_ = 6; - return this; - } - /** - * - * - *
-     * Table creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - */ - public Builder clearTableCreation() { - if (tableCreationBuilder_ == null) { - if (eventCase_ == 6) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 6) { - eventCase_ = 0; - event_ = null; - } - tableCreationBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Table creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder - getTableCreationBuilder() { - return getTableCreationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Table creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder - getTableCreationOrBuilder() { - if ((eventCase_ == 6) && (tableCreationBuilder_ != null)) { - return tableCreationBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 6) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); - } - } - /** - * - * - *
-     * Table creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation, - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder> - getTableCreationFieldBuilder() { - if (tableCreationBuilder_ == null) { - if (!(eventCase_ == 6)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.getDefaultInstance(); - } - tableCreationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation, - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.TableCreation) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 6; - onChanged(); - ; - return tableCreationBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableChange, - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder> - tableChangeBuilder_; - /** - * - * - *
-     * Table metadata change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - * - * @return Whether the tableChange field is set. - */ - @java.lang.Override - public boolean hasTableChange() { - return eventCase_ == 8; - } - /** - * - * - *
-     * Table metadata change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - * - * @return The tableChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableChange getTableChange() { - if (tableChangeBuilder_ == null) { - if (eventCase_ == 8) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); - } else { - if (eventCase_ == 8) { - return tableChangeBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Table metadata change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - */ - public Builder setTableChange(com.google.cloud.audit.BigQueryAuditMetadata.TableChange value) { - if (tableChangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - tableChangeBuilder_.setMessage(value); - } - eventCase_ = 8; - return this; - } - /** - * - * - *
-     * Table metadata change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - */ - public Builder setTableChange( - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder builderForValue) { - if (tableChangeBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - tableChangeBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 8; - return this; - } - /** - * - * - *
-     * Table metadata change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - */ - public Builder mergeTableChange( - com.google.cloud.audit.BigQueryAuditMetadata.TableChange value) { - if (tableChangeBuilder_ == null) { - if (eventCase_ == 8 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 8) { - tableChangeBuilder_.mergeFrom(value); - } - tableChangeBuilder_.setMessage(value); - } - eventCase_ = 8; - return this; - } - /** - * - * - *
-     * Table metadata change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - */ - public Builder clearTableChange() { - if (tableChangeBuilder_ == null) { - if (eventCase_ == 8) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 8) { - eventCase_ = 0; - event_ = null; - } - tableChangeBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Table metadata change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder - getTableChangeBuilder() { - return getTableChangeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Table metadata change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder - getTableChangeOrBuilder() { - if ((eventCase_ == 8) && (tableChangeBuilder_ != null)) { - return tableChangeBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 8) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Table metadata change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableChange, - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder> - getTableChangeFieldBuilder() { - if (tableChangeBuilder_ == null) { - if (!(eventCase_ == 8)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.TableChange.getDefaultInstance(); - } - tableChangeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableChange, - com.google.cloud.audit.BigQueryAuditMetadata.TableChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.TableChange) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 8; - onChanged(); - ; - return tableChangeBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder> - tableDeletionBuilder_; - /** - * - * - *
-     * Table deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - * - * @return Whether the tableDeletion field is set. - */ - @java.lang.Override - public boolean hasTableDeletion() { - return eventCase_ == 9; - } - /** - * - * - *
-     * Table deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - * - * @return The tableDeletion. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion getTableDeletion() { - if (tableDeletionBuilder_ == null) { - if (eventCase_ == 9) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); - } else { - if (eventCase_ == 9) { - return tableDeletionBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); - } - } - /** - * - * - *
-     * Table deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - */ - public Builder setTableDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion value) { - if (tableDeletionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - tableDeletionBuilder_.setMessage(value); - } - eventCase_ = 9; - return this; - } - /** - * - * - *
-     * Table deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - */ - public Builder setTableDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder builderForValue) { - if (tableDeletionBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - tableDeletionBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 9; - return this; - } - /** - * - * - *
-     * Table deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - */ - public Builder mergeTableDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion value) { - if (tableDeletionBuilder_ == null) { - if (eventCase_ == 9 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 9) { - tableDeletionBuilder_.mergeFrom(value); - } - tableDeletionBuilder_.setMessage(value); - } - eventCase_ = 9; - return this; - } - /** - * - * - *
-     * Table deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - */ - public Builder clearTableDeletion() { - if (tableDeletionBuilder_ == null) { - if (eventCase_ == 9) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 9) { - eventCase_ = 0; - event_ = null; - } - tableDeletionBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Table deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder - getTableDeletionBuilder() { - return getTableDeletionFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Table deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder - getTableDeletionOrBuilder() { - if ((eventCase_ == 9) && (tableDeletionBuilder_ != null)) { - return tableDeletionBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 9) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); - } - } - /** - * - * - *
-     * Table deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder> - getTableDeletionFieldBuilder() { - if (tableDeletionBuilder_ == null) { - if (!(eventCase_ == 9)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.getDefaultInstance(); - } - tableDeletionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 9; - onChanged(); - ; - return tableDeletionBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder> - tableDataReadBuilder_; - /** - * - * - *
-     * Table data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - * - * @return Whether the tableDataRead field is set. - */ - @java.lang.Override - public boolean hasTableDataRead() { - return eventCase_ == 10; - } - /** - * - * - *
-     * Table data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - * - * @return The tableDataRead. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead getTableDataRead() { - if (tableDataReadBuilder_ == null) { - if (eventCase_ == 10) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); - } else { - if (eventCase_ == 10) { - return tableDataReadBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); - } - } - /** - * - * - *
-     * Table data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - */ - public Builder setTableDataRead( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead value) { - if (tableDataReadBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - tableDataReadBuilder_.setMessage(value); - } - eventCase_ = 10; - return this; - } - /** - * - * - *
-     * Table data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - */ - public Builder setTableDataRead( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder builderForValue) { - if (tableDataReadBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - tableDataReadBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 10; - return this; - } - /** - * - * - *
-     * Table data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - */ - public Builder mergeTableDataRead( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead value) { - if (tableDataReadBuilder_ == null) { - if (eventCase_ == 10 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 10) { - tableDataReadBuilder_.mergeFrom(value); - } - tableDataReadBuilder_.setMessage(value); - } - eventCase_ = 10; - return this; - } - /** - * - * - *
-     * Table data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - */ - public Builder clearTableDataRead() { - if (tableDataReadBuilder_ == null) { - if (eventCase_ == 10) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 10) { - eventCase_ = 0; - event_ = null; - } - tableDataReadBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Table data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder - getTableDataReadBuilder() { - return getTableDataReadFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Table data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder - getTableDataReadOrBuilder() { - if ((eventCase_ == 10) && (tableDataReadBuilder_ != null)) { - return tableDataReadBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 10) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); - } - } - /** - * - * - *
-     * Table data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder> - getTableDataReadFieldBuilder() { - if (tableDataReadBuilder_ == null) { - if (!(eventCase_ == 10)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.getDefaultInstance(); - } - tableDataReadBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 10; - onChanged(); - ; - return tableDataReadBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder> - tableDataChangeBuilder_; - /** - * - * - *
-     * Table data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - * - * @return Whether the tableDataChange field is set. - */ - @java.lang.Override - public boolean hasTableDataChange() { - return eventCase_ == 11; - } - /** - * - * - *
-     * Table data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - * - * @return The tableDataChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange getTableDataChange() { - if (tableDataChangeBuilder_ == null) { - if (eventCase_ == 11) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); - } else { - if (eventCase_ == 11) { - return tableDataChangeBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Table data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - */ - public Builder setTableDataChange( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange value) { - if (tableDataChangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - tableDataChangeBuilder_.setMessage(value); - } - eventCase_ = 11; - return this; - } - /** - * - * - *
-     * Table data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - */ - public Builder setTableDataChange( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder builderForValue) { - if (tableDataChangeBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - tableDataChangeBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 11; - return this; - } - /** - * - * - *
-     * Table data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - */ - public Builder mergeTableDataChange( - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange value) { - if (tableDataChangeBuilder_ == null) { - if (eventCase_ == 11 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 11) { - tableDataChangeBuilder_.mergeFrom(value); - } - tableDataChangeBuilder_.setMessage(value); - } - eventCase_ = 11; - return this; - } - /** - * - * - *
-     * Table data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - */ - public Builder clearTableDataChange() { - if (tableDataChangeBuilder_ == null) { - if (eventCase_ == 11) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 11) { - eventCase_ = 0; - event_ = null; - } - tableDataChangeBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Table data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder - getTableDataChangeBuilder() { - return getTableDataChangeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Table data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder - getTableDataChangeOrBuilder() { - if ((eventCase_ == 11) && (tableDataChangeBuilder_ != null)) { - return tableDataChangeBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 11) { - return (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Table data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder> - getTableDataChangeFieldBuilder() { - if (tableDataChangeBuilder_ == null) { - if (!(eventCase_ == 11)) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.getDefaultInstance(); - } - tableDataChangeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 11; - onChanged(); - ; - return tableDataChangeBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder> - modelDeletionBuilder_; - /** - * - * - *
-     * Model deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - * - * @return Whether the modelDeletion field is set. - */ - @java.lang.Override - public boolean hasModelDeletion() { - return eventCase_ == 12; - } - /** - * - * - *
-     * Model deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - * - * @return The modelDeletion. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion getModelDeletion() { - if (modelDeletionBuilder_ == null) { - if (eventCase_ == 12) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); - } else { - if (eventCase_ == 12) { - return modelDeletionBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); - } - } - /** - * - * - *
-     * Model deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - */ - public Builder setModelDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion value) { - if (modelDeletionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - modelDeletionBuilder_.setMessage(value); - } - eventCase_ = 12; - return this; - } - /** - * - * - *
-     * Model deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - */ - public Builder setModelDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder builderForValue) { - if (modelDeletionBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - modelDeletionBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 12; - return this; - } - /** - * - * - *
-     * Model deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - */ - public Builder mergeModelDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion value) { - if (modelDeletionBuilder_ == null) { - if (eventCase_ == 12 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 12) { - modelDeletionBuilder_.mergeFrom(value); - } - modelDeletionBuilder_.setMessage(value); - } - eventCase_ = 12; - return this; - } - /** - * - * - *
-     * Model deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - */ - public Builder clearModelDeletion() { - if (modelDeletionBuilder_ == null) { - if (eventCase_ == 12) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 12) { - eventCase_ = 0; - event_ = null; - } - modelDeletionBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Model deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder - getModelDeletionBuilder() { - return getModelDeletionFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Model deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder - getModelDeletionOrBuilder() { - if ((eventCase_ == 12) && (modelDeletionBuilder_ != null)) { - return modelDeletionBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 12) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); - } - } - /** - * - * - *
-     * Model deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder> - getModelDeletionFieldBuilder() { - if (modelDeletionBuilder_ == null) { - if (!(eventCase_ == 12)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.getDefaultInstance(); - } - modelDeletionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 12; - onChanged(); - ; - return modelDeletionBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation, - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder> - modelCreationBuilder_; - /** - * - * - *
-     * Model creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - * - * @return Whether the modelCreation field is set. - */ - @java.lang.Override - public boolean hasModelCreation() { - return eventCase_ == 13; - } - /** - * - * - *
-     * Model creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - * - * @return The modelCreation. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation getModelCreation() { - if (modelCreationBuilder_ == null) { - if (eventCase_ == 13) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); - } else { - if (eventCase_ == 13) { - return modelCreationBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); - } - } - /** - * - * - *
-     * Model creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - */ - public Builder setModelCreation( - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation value) { - if (modelCreationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - modelCreationBuilder_.setMessage(value); - } - eventCase_ = 13; - return this; - } - /** - * - * - *
-     * Model creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - */ - public Builder setModelCreation( - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder builderForValue) { - if (modelCreationBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - modelCreationBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 13; - return this; - } - /** - * - * - *
-     * Model creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - */ - public Builder mergeModelCreation( - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation value) { - if (modelCreationBuilder_ == null) { - if (eventCase_ == 13 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 13) { - modelCreationBuilder_.mergeFrom(value); - } - modelCreationBuilder_.setMessage(value); - } - eventCase_ = 13; - return this; - } - /** - * - * - *
-     * Model creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - */ - public Builder clearModelCreation() { - if (modelCreationBuilder_ == null) { - if (eventCase_ == 13) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 13) { - eventCase_ = 0; - event_ = null; - } - modelCreationBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Model creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder - getModelCreationBuilder() { - return getModelCreationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Model creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder - getModelCreationOrBuilder() { - if ((eventCase_ == 13) && (modelCreationBuilder_ != null)) { - return modelCreationBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 13) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); - } - } - /** - * - * - *
-     * Model creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation, - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder> - getModelCreationFieldBuilder() { - if (modelCreationBuilder_ == null) { - if (!(eventCase_ == 13)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.getDefaultInstance(); - } - modelCreationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation, - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 13; - onChanged(); - ; - return modelCreationBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange, - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder> - modelMetadataChangeBuilder_; - /** - * - * - *
-     * Model metadata change event.
-     * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - * - * @return Whether the modelMetadataChange field is set. - */ - @java.lang.Override - public boolean hasModelMetadataChange() { - return eventCase_ == 14; - } - /** - * - * - *
-     * Model metadata change event.
-     * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - * - * @return The modelMetadataChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - getModelMetadataChange() { - if (modelMetadataChangeBuilder_ == null) { - if (eventCase_ == 14) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - .getDefaultInstance(); - } else { - if (eventCase_ == 14) { - return modelMetadataChangeBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - .getDefaultInstance(); - } - } - /** - * - * - *
-     * Model metadata change event.
-     * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - */ - public Builder setModelMetadataChange( - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange value) { - if (modelMetadataChangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - modelMetadataChangeBuilder_.setMessage(value); - } - eventCase_ = 14; - return this; - } - /** - * - * - *
-     * Model metadata change event.
-     * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - */ - public Builder setModelMetadataChange( - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder builderForValue) { - if (modelMetadataChangeBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - modelMetadataChangeBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 14; - return this; - } - /** - * - * - *
-     * Model metadata change event.
-     * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - */ - public Builder mergeModelMetadataChange( - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange value) { - if (modelMetadataChangeBuilder_ == null) { - if (eventCase_ == 14 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 14) { - modelMetadataChangeBuilder_.mergeFrom(value); - } - modelMetadataChangeBuilder_.setMessage(value); - } - eventCase_ = 14; - return this; - } - /** - * - * - *
-     * Model metadata change event.
-     * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - */ - public Builder clearModelMetadataChange() { - if (modelMetadataChangeBuilder_ == null) { - if (eventCase_ == 14) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 14) { - eventCase_ = 0; - event_ = null; - } - modelMetadataChangeBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Model metadata change event.
-     * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder - getModelMetadataChangeBuilder() { - return getModelMetadataChangeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Model metadata change event.
-     * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder - getModelMetadataChangeOrBuilder() { - if ((eventCase_ == 14) && (modelMetadataChangeBuilder_ != null)) { - return modelMetadataChangeBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 14) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange - .getDefaultInstance(); - } - } - /** - * - * - *
-     * Model metadata change event.
-     * 
- * - * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange, - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder> - getModelMetadataChangeFieldBuilder() { - if (modelMetadataChangeBuilder_ == null) { - if (!(eventCase_ == 14)) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.getDefaultInstance(); - } - modelMetadataChangeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange, - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 14; - onChanged(); - ; - return modelMetadataChangeBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder> - modelDataChangeBuilder_; - /** - * - * - *
-     * Model data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - * - * @return Whether the modelDataChange field is set. - */ - @java.lang.Override - public boolean hasModelDataChange() { - return eventCase_ == 15; - } - /** - * - * - *
-     * Model data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - * - * @return The modelDataChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange getModelDataChange() { - if (modelDataChangeBuilder_ == null) { - if (eventCase_ == 15) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); - } else { - if (eventCase_ == 15) { - return modelDataChangeBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Model data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - */ - public Builder setModelDataChange( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange value) { - if (modelDataChangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - modelDataChangeBuilder_.setMessage(value); - } - eventCase_ = 15; - return this; - } - /** - * - * - *
-     * Model data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - */ - public Builder setModelDataChange( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder builderForValue) { - if (modelDataChangeBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - modelDataChangeBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 15; - return this; - } - /** - * - * - *
-     * Model data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - */ - public Builder mergeModelDataChange( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange value) { - if (modelDataChangeBuilder_ == null) { - if (eventCase_ == 15 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 15) { - modelDataChangeBuilder_.mergeFrom(value); - } - modelDataChangeBuilder_.setMessage(value); - } - eventCase_ = 15; - return this; - } - /** - * - * - *
-     * Model data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - */ - public Builder clearModelDataChange() { - if (modelDataChangeBuilder_ == null) { - if (eventCase_ == 15) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 15) { - eventCase_ = 0; - event_ = null; - } - modelDataChangeBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Model data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - */ - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder - getModelDataChangeBuilder() { - return getModelDataChangeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Model data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder - getModelDataChangeOrBuilder() { - if ((eventCase_ == 15) && (modelDataChangeBuilder_ != null)) { - return modelDataChangeBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 15) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Model data change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder> - getModelDataChangeFieldBuilder() { - if (modelDataChangeBuilder_ == null) { - if (!(eventCase_ == 15)) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.getDefaultInstance(); - } - modelDataChangeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 15; - onChanged(); - ; - return modelDataChangeBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder> - modelDataReadBuilder_; - /** - * - * - *
-     * Model data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - * - * @return Whether the modelDataRead field is set. - */ - @java.lang.Override - public boolean hasModelDataRead() { - return eventCase_ == 19; - } - /** - * - * - *
-     * Model data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - * - * @return The modelDataRead. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead getModelDataRead() { - if (modelDataReadBuilder_ == null) { - if (eventCase_ == 19) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); - } else { - if (eventCase_ == 19) { - return modelDataReadBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); - } - } - /** - * - * - *
-     * Model data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - */ - public Builder setModelDataRead( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead value) { - if (modelDataReadBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - modelDataReadBuilder_.setMessage(value); - } - eventCase_ = 19; - return this; - } - /** - * - * - *
-     * Model data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - */ - public Builder setModelDataRead( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder builderForValue) { - if (modelDataReadBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - modelDataReadBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 19; - return this; - } - /** - * - * - *
-     * Model data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - */ - public Builder mergeModelDataRead( - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead value) { - if (modelDataReadBuilder_ == null) { - if (eventCase_ == 19 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 19) { - modelDataReadBuilder_.mergeFrom(value); - } - modelDataReadBuilder_.setMessage(value); - } - eventCase_ = 19; - return this; - } - /** - * - * - *
-     * Model data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - */ - public Builder clearModelDataRead() { - if (modelDataReadBuilder_ == null) { - if (eventCase_ == 19) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 19) { - eventCase_ = 0; - event_ = null; - } - modelDataReadBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Model data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder - getModelDataReadBuilder() { - return getModelDataReadFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Model data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder - getModelDataReadOrBuilder() { - if ((eventCase_ == 19) && (modelDataReadBuilder_ != null)) { - return modelDataReadBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 19) { - return (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); - } - } - /** - * - * - *
-     * Model data read event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder> - getModelDataReadFieldBuilder() { - if (modelDataReadBuilder_ == null) { - if (!(eventCase_ == 19)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.getDefaultInstance(); - } - modelDataReadBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 19; - onChanged(); - ; - return modelDataReadBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder> - routineCreationBuilder_; - /** - * - * - *
-     * Routine creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - * - * @return Whether the routineCreation field is set. - */ - @java.lang.Override - public boolean hasRoutineCreation() { - return eventCase_ == 16; - } - /** - * - * - *
-     * Routine creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - * - * @return The routineCreation. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation getRoutineCreation() { - if (routineCreationBuilder_ == null) { - if (eventCase_ == 16) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); - } else { - if (eventCase_ == 16) { - return routineCreationBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); - } - } - /** - * - * - *
-     * Routine creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - */ - public Builder setRoutineCreation( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation value) { - if (routineCreationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - routineCreationBuilder_.setMessage(value); - } - eventCase_ = 16; - return this; - } - /** - * - * - *
-     * Routine creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - */ - public Builder setRoutineCreation( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder builderForValue) { - if (routineCreationBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - routineCreationBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 16; - return this; - } - /** - * - * - *
-     * Routine creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - */ - public Builder mergeRoutineCreation( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation value) { - if (routineCreationBuilder_ == null) { - if (eventCase_ == 16 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 16) { - routineCreationBuilder_.mergeFrom(value); - } - routineCreationBuilder_.setMessage(value); - } - eventCase_ = 16; - return this; - } - /** - * - * - *
-     * Routine creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - */ - public Builder clearRoutineCreation() { - if (routineCreationBuilder_ == null) { - if (eventCase_ == 16) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 16) { - eventCase_ = 0; - event_ = null; - } - routineCreationBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Routine creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder - getRoutineCreationBuilder() { - return getRoutineCreationFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Routine creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder - getRoutineCreationOrBuilder() { - if ((eventCase_ == 16) && (routineCreationBuilder_ != null)) { - return routineCreationBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 16) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); - } - } - /** - * - * - *
-     * Routine creation event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder> - getRoutineCreationFieldBuilder() { - if (routineCreationBuilder_ == null) { - if (!(eventCase_ == 16)) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.getDefaultInstance(); - } - routineCreationBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 16; - onChanged(); - ; - return routineCreationBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder> - routineChangeBuilder_; - /** - * - * - *
-     * Routine change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - * - * @return Whether the routineChange field is set. - */ - @java.lang.Override - public boolean hasRoutineChange() { - return eventCase_ == 17; - } - /** - * - * - *
-     * Routine change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - * - * @return The routineChange. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange getRoutineChange() { - if (routineChangeBuilder_ == null) { - if (eventCase_ == 17) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); - } else { - if (eventCase_ == 17) { - return routineChangeBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Routine change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - */ - public Builder setRoutineChange( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange value) { - if (routineChangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - routineChangeBuilder_.setMessage(value); - } - eventCase_ = 17; - return this; - } - /** - * - * - *
-     * Routine change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - */ - public Builder setRoutineChange( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder builderForValue) { - if (routineChangeBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - routineChangeBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 17; - return this; - } - /** - * - * - *
-     * Routine change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - */ - public Builder mergeRoutineChange( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange value) { - if (routineChangeBuilder_ == null) { - if (eventCase_ == 17 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 17) { - routineChangeBuilder_.mergeFrom(value); - } - routineChangeBuilder_.setMessage(value); - } - eventCase_ = 17; - return this; - } - /** - * - * - *
-     * Routine change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - */ - public Builder clearRoutineChange() { - if (routineChangeBuilder_ == null) { - if (eventCase_ == 17) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 17) { - eventCase_ = 0; - event_ = null; - } - routineChangeBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Routine change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder - getRoutineChangeBuilder() { - return getRoutineChangeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Routine change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder - getRoutineChangeOrBuilder() { - if ((eventCase_ == 17) && (routineChangeBuilder_ != null)) { - return routineChangeBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 17) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); - } - } - /** - * - * - *
-     * Routine change event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder> - getRoutineChangeFieldBuilder() { - if (routineChangeBuilder_ == null) { - if (!(eventCase_ == 17)) { - event_ = com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.getDefaultInstance(); - } - routineChangeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 17; - onChanged(); - ; - return routineChangeBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder> - routineDeletionBuilder_; - /** - * - * - *
-     * Routine deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - * - * @return Whether the routineDeletion field is set. - */ - @java.lang.Override - public boolean hasRoutineDeletion() { - return eventCase_ == 18; - } - /** - * - * - *
-     * Routine deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - * - * @return The routineDeletion. - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion getRoutineDeletion() { - if (routineDeletionBuilder_ == null) { - if (eventCase_ == 18) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); - } else { - if (eventCase_ == 18) { - return routineDeletionBuilder_.getMessage(); - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); - } - } - /** - * - * - *
-     * Routine deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - */ - public Builder setRoutineDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion value) { - if (routineDeletionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - routineDeletionBuilder_.setMessage(value); - } - eventCase_ = 18; - return this; - } - /** - * - * - *
-     * Routine deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - */ - public Builder setRoutineDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder builderForValue) { - if (routineDeletionBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - routineDeletionBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 18; - return this; - } - /** - * - * - *
-     * Routine deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - */ - public Builder mergeRoutineDeletion( - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion value) { - if (routineDeletionBuilder_ == null) { - if (eventCase_ == 18 - && event_ - != com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion - .getDefaultInstance()) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.newBuilder( - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 18) { - routineDeletionBuilder_.mergeFrom(value); - } - routineDeletionBuilder_.setMessage(value); - } - eventCase_ = 18; - return this; - } - /** - * - * - *
-     * Routine deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - */ - public Builder clearRoutineDeletion() { - if (routineDeletionBuilder_ == null) { - if (eventCase_ == 18) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 18) { - eventCase_ = 0; - event_ = null; - } - routineDeletionBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Routine deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - */ - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder - getRoutineDeletionBuilder() { - return getRoutineDeletionFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Routine deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - */ - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder - getRoutineDeletionOrBuilder() { - if ((eventCase_ == 18) && (routineDeletionBuilder_ != null)) { - return routineDeletionBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 18) { - return (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_; - } - return com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); - } - } - /** - * - * - *
-     * Routine deletion event.
-     * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder> - getRoutineDeletionFieldBuilder() { - if (routineDeletionBuilder_ == null) { - if (!(eventCase_ == 18)) { - event_ = - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.getDefaultInstance(); - } - routineDeletionBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion.Builder, - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder>( - (com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 18; - onChanged(); - ; - return routineDeletionBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.cloud.audit.BigQueryAuditMetadata) - } - - // @@protoc_insertion_point(class_scope:google.cloud.audit.BigQueryAuditMetadata) - private static final com.google.cloud.audit.BigQueryAuditMetadata DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloud.audit.BigQueryAuditMetadata(); - } - - public static com.google.cloud.audit.BigQueryAuditMetadata getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BigQueryAuditMetadata parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BigQueryAuditMetadata(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloud.audit.BigQueryAuditMetadata getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataOrBuilder.java b/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataOrBuilder.java deleted file mode 100644 index b81239a0..00000000 --- a/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataOrBuilder.java +++ /dev/null @@ -1,667 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/audit/bigquery_audit_metadata.proto - -package com.google.cloud.audit; - -public interface BigQueryAuditMetadataOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.audit.BigQueryAuditMetadata) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Job insertion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - * - * @return Whether the jobInsertion field is set. - */ - boolean hasJobInsertion(); - /** - * - * - *
-   * Job insertion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - * - * @return The jobInsertion. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertion getJobInsertion(); - /** - * - * - *
-   * Job insertion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobInsertion job_insertion = 1; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobInsertionOrBuilder getJobInsertionOrBuilder(); - - /** - * - * - *
-   * Job state change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - * - * @return Whether the jobChange field is set. - */ - boolean hasJobChange(); - /** - * - * - *
-   * Job state change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - * - * @return The jobChange. - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobChange getJobChange(); - /** - * - * - *
-   * Job state change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.JobChange job_change = 2; - */ - com.google.cloud.audit.BigQueryAuditMetadata.JobChangeOrBuilder getJobChangeOrBuilder(); - - /** - * - * - *
-   * Dataset creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - * - * @return Whether the datasetCreation field is set. - */ - boolean hasDatasetCreation(); - /** - * - * - *
-   * Dataset creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - * - * @return The datasetCreation. - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreation getDatasetCreation(); - /** - * - * - *
-   * Dataset creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetCreation dataset_creation = 3; - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetCreationOrBuilder - getDatasetCreationOrBuilder(); - - /** - * - * - *
-   * Dataset change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - * - * @return Whether the datasetChange field is set. - */ - boolean hasDatasetChange(); - /** - * - * - *
-   * Dataset change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - * - * @return The datasetChange. - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChange getDatasetChange(); - /** - * - * - *
-   * Dataset change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetChange dataset_change = 4; - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetChangeOrBuilder getDatasetChangeOrBuilder(); - - /** - * - * - *
-   * Dataset deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - * - * @return Whether the datasetDeletion field is set. - */ - boolean hasDatasetDeletion(); - /** - * - * - *
-   * Dataset deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - * - * @return The datasetDeletion. - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion getDatasetDeletion(); - /** - * - * - *
-   * Dataset deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.DatasetDeletion dataset_deletion = 5; - */ - com.google.cloud.audit.BigQueryAuditMetadata.DatasetDeletionOrBuilder - getDatasetDeletionOrBuilder(); - - /** - * - * - *
-   * Table creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - * - * @return Whether the tableCreation field is set. - */ - boolean hasTableCreation(); - /** - * - * - *
-   * Table creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - * - * @return The tableCreation. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableCreation getTableCreation(); - /** - * - * - *
-   * Table creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableCreation table_creation = 6; - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableCreationOrBuilder getTableCreationOrBuilder(); - - /** - * - * - *
-   * Table metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - * - * @return Whether the tableChange field is set. - */ - boolean hasTableChange(); - /** - * - * - *
-   * Table metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - * - * @return The tableChange. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableChange getTableChange(); - /** - * - * - *
-   * Table metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableChange table_change = 8; - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableChangeOrBuilder getTableChangeOrBuilder(); - - /** - * - * - *
-   * Table deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - * - * @return Whether the tableDeletion field is set. - */ - boolean hasTableDeletion(); - /** - * - * - *
-   * Table deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - * - * @return The tableDeletion. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletion getTableDeletion(); - /** - * - * - *
-   * Table deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDeletion table_deletion = 9; - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDeletionOrBuilder getTableDeletionOrBuilder(); - - /** - * - * - *
-   * Table data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - * - * @return Whether the tableDataRead field is set. - */ - boolean hasTableDataRead(); - /** - * - * - *
-   * Table data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - * - * @return The tableDataRead. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDataRead getTableDataRead(); - /** - * - * - *
-   * Table data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataRead table_data_read = 10; - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDataReadOrBuilder getTableDataReadOrBuilder(); - - /** - * - * - *
-   * Table data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - * @return Whether the tableDataChange field is set. - */ - boolean hasTableDataChange(); - /** - * - * - *
-   * Table data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - * - * @return The tableDataChange. - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChange getTableDataChange(); - /** - * - * - *
-   * Table data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.TableDataChange table_data_change = 11; - */ - com.google.cloud.audit.BigQueryAuditMetadata.TableDataChangeOrBuilder - getTableDataChangeOrBuilder(); - - /** - * - * - *
-   * Model deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - * - * @return Whether the modelDeletion field is set. - */ - boolean hasModelDeletion(); - /** - * - * - *
-   * Model deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - * - * @return The modelDeletion. - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletion getModelDeletion(); - /** - * - * - *
-   * Model deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDeletion model_deletion = 12; - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelDeletionOrBuilder getModelDeletionOrBuilder(); - - /** - * - * - *
-   * Model creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - * - * @return Whether the modelCreation field is set. - */ - boolean hasModelCreation(); - /** - * - * - *
-   * Model creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - * - * @return The modelCreation. - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreation getModelCreation(); - /** - * - * - *
-   * Model creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelCreation model_creation = 13; - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelCreationOrBuilder getModelCreationOrBuilder(); - - /** - * - * - *
-   * Model metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - * - * @return Whether the modelMetadataChange field is set. - */ - boolean hasModelMetadataChange(); - /** - * - * - *
-   * Model metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - * - * @return The modelMetadataChange. - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange getModelMetadataChange(); - /** - * - * - *
-   * Model metadata change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChange model_metadata_change = 14; - * - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelMetadataChangeOrBuilder - getModelMetadataChangeOrBuilder(); - - /** - * - * - *
-   * Model data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - * @return Whether the modelDataChange field is set. - */ - boolean hasModelDataChange(); - /** - * - * - *
-   * Model data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - * - * @return The modelDataChange. - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChange getModelDataChange(); - /** - * - * - *
-   * Model data change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataChange model_data_change = 15; - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataChangeOrBuilder - getModelDataChangeOrBuilder(); - - /** - * - * - *
-   * Model data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - * - * @return Whether the modelDataRead field is set. - */ - boolean hasModelDataRead(); - /** - * - * - *
-   * Model data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - * - * @return The modelDataRead. - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataRead getModelDataRead(); - /** - * - * - *
-   * Model data read event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.ModelDataRead model_data_read = 19; - */ - com.google.cloud.audit.BigQueryAuditMetadata.ModelDataReadOrBuilder getModelDataReadOrBuilder(); - - /** - * - * - *
-   * Routine creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - * - * @return Whether the routineCreation field is set. - */ - boolean hasRoutineCreation(); - /** - * - * - *
-   * Routine creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - * - * @return The routineCreation. - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreation getRoutineCreation(); - /** - * - * - *
-   * Routine creation event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineCreation routine_creation = 16; - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineCreationOrBuilder - getRoutineCreationOrBuilder(); - - /** - * - * - *
-   * Routine change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - * - * @return Whether the routineChange field is set. - */ - boolean hasRoutineChange(); - /** - * - * - *
-   * Routine change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - * - * @return The routineChange. - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChange getRoutineChange(); - /** - * - * - *
-   * Routine change event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineChange routine_change = 17; - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineChangeOrBuilder getRoutineChangeOrBuilder(); - - /** - * - * - *
-   * Routine deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - * - * @return Whether the routineDeletion field is set. - */ - boolean hasRoutineDeletion(); - /** - * - * - *
-   * Routine deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - * - * @return The routineDeletion. - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion getRoutineDeletion(); - /** - * - * - *
-   * Routine deletion event.
-   * 
- * - * .google.cloud.audit.BigQueryAuditMetadata.RoutineDeletion routine_deletion = 18; - */ - com.google.cloud.audit.BigQueryAuditMetadata.RoutineDeletionOrBuilder - getRoutineDeletionOrBuilder(); - - public com.google.cloud.audit.BigQueryAuditMetadata.EventCase getEventCase(); -} diff --git a/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataProto.java b/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataProto.java deleted file mode 100644 index 0b7c50e9..00000000 --- a/proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataProto.java +++ /dev/null @@ -1,1033 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/audit/bigquery_audit_metadata.proto - -package com.google.cloud.audit; - -public final class BigQueryAuditMetadataProto { - private BigQueryAuditMetadataProto() {} - - 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_cloud_audit_BigQueryAuditMetadata_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { - return descriptor; - } - - private static com.google.protobuf.Descriptors.FileDescriptor descriptor; - - static { - java.lang.String[] descriptorData = { - "\n0google/cloud/audit/bigquery_audit_meta" - + "data.proto\022\022google.cloud.audit\032\032google/i" - + "am/v1/policy.proto\032\036google/protobuf/dura" - + "tion.proto\032\037google/protobuf/timestamp.pr" - + "oto\032\027google/rpc/status.proto\"\301a\n\025BigQuer" - + "yAuditMetadata\022O\n\rjob_insertion\030\001 \001(\01326." - + "google.cloud.audit.BigQueryAuditMetadata" - + ".JobInsertionH\000\022I\n\njob_change\030\002 \001(\01323.go" - + "ogle.cloud.audit.BigQueryAuditMetadata.J" - + "obChangeH\000\022U\n\020dataset_creation\030\003 \001(\01329.g" - + "oogle.cloud.audit.BigQueryAuditMetadata." - + "DatasetCreationH\000\022Q\n\016dataset_change\030\004 \001(" - + "\01327.google.cloud.audit.BigQueryAuditMeta" - + "data.DatasetChangeH\000\022U\n\020dataset_deletion" - + "\030\005 \001(\01329.google.cloud.audit.BigQueryAudi" - + "tMetadata.DatasetDeletionH\000\022Q\n\016table_cre" - + "ation\030\006 \001(\01327.google.cloud.audit.BigQuer" - + "yAuditMetadata.TableCreationH\000\022M\n\014table_" - + "change\030\010 \001(\01325.google.cloud.audit.BigQue" - + "ryAuditMetadata.TableChangeH\000\022Q\n\016table_d" - + "eletion\030\t \001(\01327.google.cloud.audit.BigQu" - + "eryAuditMetadata.TableDeletionH\000\022R\n\017tabl" - + "e_data_read\030\n \001(\01327.google.cloud.audit.B" - + "igQueryAuditMetadata.TableDataReadH\000\022V\n\021" - + "table_data_change\030\013 \001(\01329.google.cloud.a" - + "udit.BigQueryAuditMetadata.TableDataChan" - + "geH\000\022Q\n\016model_deletion\030\014 \001(\01327.google.cl" - + "oud.audit.BigQueryAuditMetadata.ModelDel" - + "etionH\000\022Q\n\016model_creation\030\r \001(\01327.google" - + ".cloud.audit.BigQueryAuditMetadata.Model" - + "CreationH\000\022^\n\025model_metadata_change\030\016 \001(" - + "\0132=.google.cloud.audit.BigQueryAuditMeta" - + "data.ModelMetadataChangeH\000\022V\n\021model_data" - + "_change\030\017 \001(\01329.google.cloud.audit.BigQu" - + "eryAuditMetadata.ModelDataChangeH\000\022R\n\017mo" - + "del_data_read\030\023 \001(\01327.google.cloud.audit" - + ".BigQueryAuditMetadata.ModelDataReadH\000\022U" - + "\n\020routine_creation\030\020 \001(\01329.google.cloud." - + "audit.BigQueryAuditMetadata.RoutineCreat" - + "ionH\000\022Q\n\016routine_change\030\021 \001(\01327.google.c" - + "loud.audit.BigQueryAuditMetadata.Routine" - + "ChangeH\000\022U\n\020routine_deletion\030\022 \001(\01329.goo" - + "gle.cloud.audit.BigQueryAuditMetadata.Ro" - + "utineDeletionH\000\032\346\001\n\014JobInsertion\022:\n\003job\030" - + "\001 \001(\0132-.google.cloud.audit.BigQueryAudit" - + "Metadata.Job\022M\n\006reason\030\002 \001(\0162=.google.cl" - + "oud.audit.BigQueryAuditMetadata.JobInser" - + "tion.Reason\"K\n\006Reason\022\026\n\022REASON_UNSPECIF" - + "IED\020\000\022\026\n\022JOB_INSERT_REQUEST\020\001\022\021\n\rQUERY_R" - + "EQUEST\020\002\032\316\001\n\tJobChange\022B\n\006before\030\001 \001(\01622" - + ".google.cloud.audit.BigQueryAuditMetadat" - + "a.JobState\022A\n\005after\030\002 \001(\01622.google.cloud" - + ".audit.BigQueryAuditMetadata.JobState\022:\n" - + "\003job\030\003 \001(\0132-.google.cloud.audit.BigQuery" - + "AuditMetadata.Job\032\362\001\n\017DatasetCreation\022B\n" - + "\007dataset\030\001 \001(\01321.google.cloud.audit.BigQ" - + "ueryAuditMetadata.Dataset\022P\n\006reason\030\002 \001(" - + "\0162@.google.cloud.audit.BigQueryAuditMeta" - + "data.DatasetCreation.Reason\022\020\n\010job_name\030" - + "\003 \001(\t\"7\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022" - + "\n\n\006CREATE\020\001\022\t\n\005QUERY\020\002\032\202\002\n\rDatasetChange" - + "\022B\n\007dataset\030\001 \001(\01321.google.cloud.audit.B" - + "igQueryAuditMetadata.Dataset\022N\n\006reason\030\002" - + " \001(\0162>.google.cloud.audit.BigQueryAuditM" - + "etadata.DatasetChange.Reason\022\020\n\010job_name" - + "\030\003 \001(\t\"K\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000" - + "\022\n\n\006UPDATE\020\001\022\022\n\016SET_IAM_POLICY\020\002\022\t\n\005QUER" - + "Y\020\003\032\256\001\n\017DatasetDeletion\022P\n\006reason\030\001 \001(\0162" - + "@.google.cloud.audit.BigQueryAuditMetada" - + "ta.DatasetDeletion.Reason\022\020\n\010job_name\030\002 " - + "\001(\t\"7\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022\n\n" - + "\006DELETE\020\001\022\t\n\005QUERY\020\002\032\201\002\n\rTableCreation\022>" - + "\n\005table\030\001 \001(\0132/.google.cloud.audit.BigQu" - + "eryAuditMetadata.Table\022N\n\006reason\030\003 \001(\0162>" - + ".google.cloud.audit.BigQueryAuditMetadat" - + "a.TableCreation.Reason\022\020\n\010job_name\030\004 \001(\t" - + "\"N\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022\007\n\003JO" - + "B\020\001\022\t\n\005QUERY\020\002\022\030\n\024TABLE_INSERT_REQUEST\020\003" - + "\032\336\001\n\rModelCreation\022>\n\005model\030\001 \001(\0132/.goog" - + "le.cloud.audit.BigQueryAuditMetadata.Mod" - + "el\022N\n\006reason\030\003 \001(\0162>.google.cloud.audit." - + "BigQueryAuditMetadata.ModelCreation.Reas" - + "on\022\020\n\010job_name\030\004 \001(\t\"+\n\006Reason\022\026\n\022REASON" - + "_UNSPECIFIED\020\000\022\t\n\005QUERY\020\002\032\202\002\n\017RoutineCre" - + "ation\022B\n\007routine\030\001 \001(\01321.google.cloud.au" - + "dit.BigQueryAuditMetadata.Routine\022P\n\006rea" - + "son\030\003 \001(\0162@.google.cloud.audit.BigQueryA" - + "uditMetadata.RoutineCreation.Reason\022\020\n\010j" - + "ob_name\030\004 \001(\t\"G\n\006Reason\022\026\n\022REASON_UNSPEC" - + "IFIED\020\000\022\t\n\005QUERY\020\001\022\032\n\026ROUTINE_INSERT_REQ" - + "UEST\020\002\032\227\003\n\rTableDataRead\022\016\n\006fields\030\002 \003(\t" - + "\022\030\n\020fields_truncated\030\010 \001(\010\022\023\n\013policy_tag" - + "s\030\t \003(\t\022\035\n\025policy_tags_truncated\030\n \001(\010\022N" - + "\n\006reason\030\003 \001(\0162>.google.cloud.audit.BigQ" - + "ueryAuditMetadata.TableDataRead.Reason\022\020" - + "\n\010job_name\030\004 \001(\t\022\024\n\014session_name\030\005 \001(\t\"\257" - + "\001\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022\007\n\003JOB" - + "\020\001\022\032\n\026TABLEDATA_LIST_REQUEST\020\002\022\035\n\031GET_QU" - + "ERY_RESULTS_REQUEST\020\003\022\021\n\rQUERY_REQUEST\020\004" - + "\022\027\n\023CREATE_READ_SESSION\020\005\022\035\n\031MATERIALIZE" - + "D_VIEW_REFRESH\020\006\032\220\002\n\013TableChange\022>\n\005tabl" - + "e\030\001 \001(\0132/.google.cloud.audit.BigQueryAud" - + "itMetadata.Table\022\021\n\ttruncated\030\004 \001(\010\022L\n\006r" - + "eason\030\005 \001(\0162<.google.cloud.audit.BigQuer" - + "yAuditMetadata.TableChange.Reason\022\020\n\010job" - + "_name\030\006 \001(\t\"N\n\006Reason\022\026\n\022REASON_UNSPECIF" - + "IED\020\000\022\030\n\024TABLE_UPDATE_REQUEST\020\001\022\007\n\003JOB\020\002" - + "\022\t\n\005QUERY\020\003\032\203\002\n\023ModelMetadataChange\022>\n\005m" - + "odel\030\001 \001(\0132/.google.cloud.audit.BigQuery" - + "AuditMetadata.Model\022T\n\006reason\030\002 \001(\0162D.go" - + "ogle.cloud.audit.BigQueryAuditMetadata.M" - + "odelMetadataChange.Reason\022\020\n\010job_name\030\003 " - + "\001(\t\"D\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022\027\n" - + "\023MODEL_PATCH_REQUEST\020\001\022\t\n\005QUERY\020\002\032\376\001\n\rRo" - + "utineChange\022B\n\007routine\030\001 \001(\01321.google.cl" - + "oud.audit.BigQueryAuditMetadata.Routine\022" - + "N\n\006reason\030\003 \001(\0162>.google.cloud.audit.Big" - + "QueryAuditMetadata.RoutineChange.Reason\022" - + "\020\n\010job_name\030\004 \001(\t\"G\n\006Reason\022\026\n\022REASON_UN" - + "SPECIFIED\020\000\022\t\n\005QUERY\020\001\022\032\n\026ROUTINE_UPDATE" - + "_REQUEST\020\002\032\272\002\n\017TableDataChange\022\032\n\022delete" - + "d_rows_count\030\001 \001(\003\022\033\n\023inserted_rows_coun" - + "t\030\002 \001(\003\022\021\n\ttruncated\030\003 \001(\010\022P\n\006reason\030\004 \001" - + "(\0162@.google.cloud.audit.BigQueryAuditMet" - + "adata.TableDataChange.Reason\022\020\n\010job_name" - + "\030\005 \001(\t\022\023\n\013stream_name\030\006 \001(\t\"b\n\006Reason\022\026\n" - + "\022REASON_UNSPECIFIED\020\000\022\007\n\003JOB\020\001\022\t\n\005QUERY\020" - + "\002\022\035\n\031MATERIALIZED_VIEW_REFRESH\020\003\022\r\n\tWRIT" - + "E_API\020\004\032\242\001\n\017ModelDataChange\022P\n\006reason\030\001 " - + "\001(\0162@.google.cloud.audit.BigQueryAuditMe" - + "tadata.ModelDataChange.Reason\022\020\n\010job_nam" - + "e\030\002 \001(\t\"+\n\006Reason\022\026\n\022REASON_UNSPECIFIED\020" - + "\000\022\t\n\005QUERY\020\001\032\234\001\n\rModelDataRead\022N\n\006reason" - + "\030\001 \001(\0162>.google.cloud.audit.BigQueryAudi" - + "tMetadata.ModelDataRead.Reason\022\020\n\010job_na" - + "me\030\002 \001(\t\")\n\006Reason\022\026\n\022REASON_UNSPECIFIED" - + "\020\000\022\007\n\003JOB\020\001\032\251\003\n\007Dataset\022\024\n\014dataset_name\030" - + "\001 \001(\t\022/\n\013create_time\030\003 \001(\0132\032.google.prot" - + "obuf.Timestamp\022/\n\013update_time\030\004 \001(\0132\032.go" - + "ogle.protobuf.Timestamp\022B\n\003acl\030\005 \001(\01325.g" - + "oogle.cloud.audit.BigQueryAuditMetadata." - + "BigQueryAcl\022@\n\035default_table_expire_dura" - + "tion\030\006 \001(\0132\031.google.protobuf.Duration\022J\n" - + "\014dataset_info\030\007 \001(\01324.google.cloud.audit" - + ".BigQueryAuditMetadata.EntityInfo\022T\n\022def" - + "ault_encryption\030\010 \001(\01328.google.cloud.aud" - + "it.BigQueryAuditMetadata.EncryptionInfo\032" - + "\305\001\n\rTableDeletion\022N\n\006reason\030\001 \001(\0162>.goog" - + "le.cloud.audit.BigQueryAuditMetadata.Tab" - + "leDeletion.Reason\022\020\n\010job_name\030\002 \001(\t\"R\n\006R" - + "eason\022\026\n\022REASON_UNSPECIFIED\020\000\022\030\n\024TABLE_D" - + "ELETE_REQUEST\020\002\022\013\n\007EXPIRED\020\003\022\t\n\005QUERY\020\004\032" - + "\305\001\n\rModelDeletion\022N\n\006reason\030\001 \001(\0162>.goog" - + "le.cloud.audit.BigQueryAuditMetadata.Mod" - + "elDeletion.Reason\022\020\n\010job_name\030\002 \001(\t\"R\n\006R" - + "eason\022\026\n\022REASON_UNSPECIFIED\020\000\022\030\n\024MODEL_D" - + "ELETE_REQUEST\020\001\022\013\n\007EXPIRED\020\002\022\t\n\005QUERY\020\003\032" - + "\306\002\n\005Model\022\022\n\nmodel_name\030\001 \001(\t\022H\n\nmodel_i" - + "nfo\030\002 \001(\01324.google.cloud.audit.BigQueryA" - + "uditMetadata.EntityInfo\022/\n\013expire_time\030\005" - + " \001(\0132\032.google.protobuf.Timestamp\022/\n\013crea" - + "te_time\030\006 \001(\0132\032.google.protobuf.Timestam" - + "p\022/\n\013update_time\030\007 \001(\0132\032.google.protobuf" - + ".Timestamp\022L\n\nencryption\030\010 \001(\01328.google." - + "cloud.audit.BigQueryAuditMetadata.Encryp" - + "tionInfo\032\202\002\n\017RoutineDeletion\022B\n\007routine\030" - + "\001 \001(\01321.google.cloud.audit.BigQueryAudit" - + "Metadata.Routine\022P\n\006reason\030\003 \001(\0162@.googl" - + "e.cloud.audit.BigQueryAuditMetadata.Rout" - + "ineDeletion.Reason\022\020\n\010job_name\030\004 \001(\t\"G\n\006" - + "Reason\022\026\n\022REASON_UNSPECIFIED\020\000\022\t\n\005QUERY\020" - + "\001\022\032\n\026ROUTINE_DELETE_REQUEST\020\002\032\360\001\n\003Job\022\020\n" - + "\010job_name\030\001 \001(\t\022G\n\njob_config\030\002 \001(\01323.go" - + "ogle.cloud.audit.BigQueryAuditMetadata.J" - + "obConfig\022G\n\njob_status\030\003 \001(\01323.google.cl" - + "oud.audit.BigQueryAuditMetadata.JobStatu" - + "s\022E\n\tjob_stats\030\004 \001(\01322.google.cloud.audi" - + "t.BigQueryAuditMetadata.JobStats\032\350\022\n\tJob" - + "Config\022F\n\004type\030\001 \001(\01628.google.cloud.audi" - + "t.BigQueryAuditMetadata.JobConfig.Type\022Q" - + "\n\014query_config\030\002 \001(\01329.google.cloud.audi" - + "t.BigQueryAuditMetadata.JobConfig.QueryH" - + "\000\022O\n\013load_config\030\003 \001(\01328.google.cloud.au" - + "dit.BigQueryAuditMetadata.JobConfig.Load" - + "H\000\022U\n\016extract_config\030\004 \001(\0132;.google.clou" - + "d.audit.BigQueryAuditMetadata.JobConfig." - + "ExtractH\000\022Z\n\021table_copy_config\030\005 \001(\0132=.g" - + "oogle.cloud.audit.BigQueryAuditMetadata." - + "JobConfig.TableCopyH\000\022O\n\006labels\030\006 \003(\0132?." - + "google.cloud.audit.BigQueryAuditMetadata" - + ".JobConfig.LabelsEntry\032\303\005\n\005Query\022\r\n\005quer" - + "y\030\001 \001(\t\022\027\n\017query_truncated\030\n \001(\010\022\031\n\021dest" - + "ination_table\030\002 \001(\t\022W\n\022create_dispositio" - + "n\030\003 \001(\0162;.google.cloud.audit.BigQueryAud" - + "itMetadata.CreateDisposition\022U\n\021write_di" - + "sposition\030\004 \001(\0162:.google.cloud.audit.Big" - + "QueryAuditMetadata.WriteDisposition\022\027\n\017d" - + "efault_dataset\030\005 \001(\t\022T\n\021table_definition" - + "s\030\006 \003(\01329.google.cloud.audit.BigQueryAud" - + "itMetadata.TableDefinition\022T\n\010priority\030\007" - + " \001(\0162B.google.cloud.audit.BigQueryAuditM" - + "etadata.JobConfig.Query.Priority\022^\n\034dest" - + "ination_table_encryption\030\010 \001(\01328.google." - + "cloud.audit.BigQueryAuditMetadata.Encryp" - + "tionInfo\022T\n\016statement_type\030\t \001(\0162<.googl" - + "e.cloud.audit.BigQueryAuditMetadata.Quer" - + "yStatementType\"L\n\010Priority\022\030\n\024PRIORITY_U" - + "NSPECIFIED\020\000\022\025\n\021QUERY_INTERACTIVE\020\001\022\017\n\013Q" - + "UERY_BATCH\020\002\032\231\003\n\004Load\022\023\n\013source_uris\030\001 \003" - + "(\t\022\035\n\025source_uris_truncated\030\007 \001(\010\022\023\n\013sch" - + "ema_json\030\002 \001(\t\022\035\n\025schema_json_truncated\030" - + "\010 \001(\010\022\031\n\021destination_table\030\003 \001(\t\022W\n\022crea" - + "te_disposition\030\004 \001(\0162;.google.cloud.audi" - + "t.BigQueryAuditMetadata.CreateDispositio" - + "n\022U\n\021write_disposition\030\005 \001(\0162:.google.cl" - + "oud.audit.BigQueryAuditMetadata.WriteDis" - + "position\022^\n\034destination_table_encryption" - + "\030\006 \001(\01328.google.cloud.audit.BigQueryAudi" - + "tMetadata.EncryptionInfo\032\201\001\n\007Extract\022\030\n\020" - + "destination_uris\030\001 \003(\t\022\"\n\032destination_ur" - + "is_truncated\030\003 \001(\010\022\026\n\014source_table\030\002 \001(\t" - + "H\000\022\026\n\014source_model\030\004 \001(\tH\000B\010\n\006source\032\200\004\n" - + "\tTableCopy\022\025\n\rsource_tables\030\001 \003(\t\022\037\n\027sou" - + "rce_tables_truncated\030\006 \001(\010\022\031\n\021destinatio" - + "n_table\030\002 \001(\t\022W\n\022create_disposition\030\003 \001(" - + "\0162;.google.cloud.audit.BigQueryAuditMeta" - + "data.CreateDisposition\022U\n\021write_disposit" - + "ion\030\004 \001(\0162:.google.cloud.audit.BigQueryA" - + "uditMetadata.WriteDisposition\022^\n\034destina" - + "tion_table_encryption\030\005 \001(\01328.google.clo" - + "ud.audit.BigQueryAuditMetadata.Encryptio" - + "nInfo\022O\n\016operation_type\030\007 \001(\01627.google.c" - + "loud.audit.BigQueryAuditMetadata.Operati" - + "onType\022?\n\033destination_expiration_time\030\010 " - + "\001(\0132\032.google.protobuf.Timestamp\032-\n\013Label" - + "sEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"I" - + "\n\004Type\022\024\n\020TYPE_UNSPECIFIED\020\000\022\t\n\005QUERY\020\001\022" - + "\010\n\004COPY\020\002\022\n\n\006EXPORT\020\003\022\n\n\006IMPORT\020\004B\010\n\006con" - + "fig\0324\n\017TableDefinition\022\014\n\004name\030\001 \001(\t\022\023\n\013" - + "source_uris\030\002 \003(\t\032\240\001\n\tJobStatus\022E\n\tjob_s" - + "tate\030\001 \001(\01622.google.cloud.audit.BigQuery" - + "AuditMetadata.JobState\022(\n\014error_result\030\002" - + " \001(\0132\022.google.rpc.Status\022\"\n\006errors\030\003 \003(\013" - + "2\022.google.rpc.Status\032\221\007\n\010JobStats\022/\n\013cre" - + "ate_time\030\001 \001(\0132\032.google.protobuf.Timesta" - + "mp\022.\n\nstart_time\030\002 \001(\0132\032.google.protobuf" - + ".Timestamp\022,\n\010end_time\030\003 \001(\0132\032.google.pr" - + "otobuf.Timestamp\022O\n\013query_stats\030\010 \001(\01328." - + "google.cloud.audit.BigQueryAuditMetadata" - + ".JobStats.QueryH\000\022M\n\nload_stats\030\t \001(\01327." - + "google.cloud.audit.BigQueryAuditMetadata" - + ".JobStats.LoadH\000\022S\n\rextract_stats\030\r \001(\0132" - + ":.google.cloud.audit.BigQueryAuditMetada" - + "ta.JobStats.ExtractH\000\022\025\n\rtotal_slot_ms\030\n" - + " \001(\003\022f\n\021reservation_usage\030\013 \003(\0132K.google" - + ".cloud.audit.BigQueryAuditMetadata.JobSt" - + "ats.ReservationResourceUsage\022\027\n\017parent_j" - + "ob_name\030\014 \001(\t\032\327\001\n\005Query\022\035\n\025total_process" - + "ed_bytes\030\001 \001(\003\022\032\n\022total_billed_bytes\030\002 \001" - + "(\003\022\024\n\014billing_tier\030\003 \001(\005\022\031\n\021referenced_t" - + "ables\030\006 \003(\t\022\030\n\020referenced_views\030\007 \003(\t\022\033\n" - + "\023referenced_routines\030\n \003(\t\022\030\n\020output_row" - + "_count\030\010 \001(\003\022\021\n\tcache_hit\030\t \001(\010\032\"\n\004Load\022" - + "\032\n\022total_output_bytes\030\001 \001(\003\032$\n\007Extract\022\031" - + "\n\021total_input_bytes\030\001 \001(\003\0329\n\030Reservation" - + "ResourceUsage\022\014\n\004name\030\001 \001(\t\022\017\n\007slot_ms\030\002" - + " \001(\003B\n\n\010extended\032\372\003\n\005Table\022\022\n\ntable_name" - + "\030\001 \001(\t\022\023\n\013schema_json\030\003 \001(\t\022\035\n\025schema_js" - + "on_truncated\030\013 \001(\010\022K\n\004view\030\004 \001(\0132=.googl" - + "e.cloud.audit.BigQueryAuditMetadata.Tabl" - + "eViewDefinition\022/\n\013expire_time\030\005 \001(\0132\032.g" - + "oogle.protobuf.Timestamp\022/\n\013create_time\030" - + "\006 \001(\0132\032.google.protobuf.Timestamp\022/\n\013upd" - + "ate_time\030\007 \001(\0132\032.google.protobuf.Timesta" - + "mp\0221\n\rtruncate_time\030\010 \001(\0132\032.google.proto" - + "buf.Timestamp\022L\n\nencryption\030\t \001(\01328.goog" - + "le.cloud.audit.BigQueryAuditMetadata.Enc" - + "ryptionInfo\022H\n\ntable_info\030\n \001(\01324.google" - + ".cloud.audit.BigQueryAuditMetadata.Entit" - + "yInfo\032\201\001\n\007Routine\022\024\n\014routine_name\030\001 \001(\t\022" - + "/\n\013create_time\030\005 \001(\0132\032.google.protobuf.T" - + "imestamp\022/\n\013update_time\030\006 \001(\0132\032.google.p" - + "rotobuf.Timestamp\032\271\001\n\nEntityInfo\022\025\n\rfrie" - + "ndly_name\030\001 \001(\t\022\023\n\013description\030\002 \001(\t\022P\n\006" - + "labels\030\003 \003(\0132@.google.cloud.audit.BigQue" - + "ryAuditMetadata.EntityInfo.LabelsEntry\032-" - + "\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(" - + "\t:\0028\001\032=\n\023TableViewDefinition\022\r\n\005query\030\001 " - + "\001(\t\022\027\n\017query_truncated\030\002 \001(\010\032N\n\013BigQuery" - + "Acl\022%\n\006policy\030\001 \001(\0132\025.google.iam.v1.Poli" - + "cy\022\030\n\020authorized_views\030\002 \003(\t\032&\n\016Encrypti" - + "onInfo\022\024\n\014kms_key_name\030\001 \001(\t\"l\n\020WriteDis" - + "position\022!\n\035WRITE_DISPOSITION_UNSPECIFIE" - + "D\020\000\022\017\n\013WRITE_EMPTY\020\001\022\022\n\016WRITE_TRUNCATE\020\002" - + "\022\020\n\014WRITE_APPEND\020\003\"T\n\rOperationType\022\036\n\032O" - + "PERATION_TYPE_UNSPECIFIED\020\000\022\010\n\004COPY\020\001\022\014\n" - + "\010SNAPSHOT\020\002\022\013\n\007RESTORE\020\003\"_\n\021CreateDispos" - + "ition\022\"\n\036CREATE_DISPOSITION_UNSPECIFIED\020" - + "\000\022\020\n\014CREATE_NEVER\020\001\022\024\n\020CREATE_IF_NEEDED\020" - + "\002\"I\n\010JobState\022\031\n\025JOB_STATE_UNSPECIFIED\020\000" - + "\022\013\n\007PENDING\020\001\022\013\n\007RUNNING\020\002\022\010\n\004DONE\020\003\"\360\004\n" - + "\022QueryStatementType\022$\n QUERY_STATEMENT_T" - + "YPE_UNSPECIFIED\020\000\022\n\n\006SELECT\020\001\022\n\n\006ASSERT\020" - + "\027\022\n\n\006INSERT\020\002\022\n\n\006UPDATE\020\003\022\n\n\006DELETE\020\004\022\t\n" - + "\005MERGE\020\005\022\020\n\014CREATE_TABLE\020\006\022\032\n\026CREATE_TAB" - + "LE_AS_SELECT\020\007\022\017\n\013CREATE_VIEW\020\010\022\020\n\014CREAT" - + "E_MODEL\020\t\022\034\n\030CREATE_MATERIALIZED_VIEW\020\r\022" - + "\023\n\017CREATE_FUNCTION\020\016\022\024\n\020CREATE_PROCEDURE" - + "\020\024\022\021\n\rCREATE_SCHEMA\0205\022\016\n\nDROP_TABLE\020\n\022\027\n" - + "\023DROP_EXTERNAL_TABLE\020!\022\r\n\tDROP_VIEW\020\013\022\016\n" - + "\nDROP_MODEL\020\014\022\032\n\026DROP_MATERIALIZED_VIEW\020" - + "\017\022\021\n\rDROP_FUNCTION\020\020\022\022\n\016DROP_PROCEDURE\020\025" - + "\022\017\n\013DROP_SCHEMA\0206\022\017\n\013ALTER_TABLE\020\021\022\016\n\nAL" - + "TER_VIEW\020\022\022\033\n\027ALTER_MATERIALIZED_VIEW\020\026\022" - + "\020\n\014ALTER_SCHEMA\0207\022\n\n\006SCRIPT\020\023\022\022\n\016TRUNCAT" - + "E_TABLE\020\032\022\031\n\025CREATE_EXTERNAL_TABLE\020\033\022\017\n\013" - + "EXPORT_DATA\020\034\022\010\n\004CALL\020\035B\007\n\005eventB\237\001\n\026com" - + ".google.cloud.auditB\032BigQueryAuditMetada" - + "taProtoP\001Z7google.golang.org/genproto/go" - + "ogleapis/cloud/audit;audit\242\002\003GCA\252\002\022Googl" - + "e.Cloud.Audit\312\002\022Google\\Cloud\\Auditb\006prot" - + "o3" - }; - descriptor = - com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( - descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - com.google.iam.v1.PolicyProto.getDescriptor(), - com.google.protobuf.DurationProto.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - com.google.rpc.StatusProto.getDescriptor(), - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_cloud_audit_BigQueryAuditMetadata_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor, - new java.lang.String[] { - "JobInsertion", - "JobChange", - "DatasetCreation", - "DatasetChange", - "DatasetDeletion", - "TableCreation", - "TableChange", - "TableDeletion", - "TableDataRead", - "TableDataChange", - "ModelDeletion", - "ModelCreation", - "ModelMetadataChange", - "ModelDataChange", - "ModelDataRead", - "RoutineCreation", - "RoutineChange", - "RoutineDeletion", - "Event", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(0); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobInsertion_descriptor, - new java.lang.String[] { - "Job", "Reason", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(1); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobChange_descriptor, - new java.lang.String[] { - "Before", "After", "Job", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(2); - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetCreation_descriptor, - new java.lang.String[] { - "Dataset", "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(3); - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetChange_descriptor, - new java.lang.String[] { - "Dataset", "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(4); - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_DatasetDeletion_descriptor, - new java.lang.String[] { - "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(5); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableCreation_descriptor, - new java.lang.String[] { - "Table", "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(6); - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelCreation_descriptor, - new java.lang.String[] { - "Model", "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(7); - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineCreation_descriptor, - new java.lang.String[] { - "Routine", "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(8); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataRead_descriptor, - new java.lang.String[] { - "Fields", - "FieldsTruncated", - "PolicyTags", - "PolicyTagsTruncated", - "Reason", - "JobName", - "SessionName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor.getNestedTypes().get(9); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableChange_descriptor, - new java.lang.String[] { - "Table", "Truncated", "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(10); - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelMetadataChange_descriptor, - new java.lang.String[] { - "Model", "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(11); - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineChange_descriptor, - new java.lang.String[] { - "Routine", "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(12); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDataChange_descriptor, - new java.lang.String[] { - "DeletedRowsCount", - "InsertedRowsCount", - "Truncated", - "Reason", - "JobName", - "StreamName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(13); - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataChange_descriptor, - new java.lang.String[] { - "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(14); - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDataRead_descriptor, - new java.lang.String[] { - "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(15); - internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_Dataset_descriptor, - new java.lang.String[] { - "DatasetName", - "CreateTime", - "UpdateTime", - "Acl", - "DefaultTableExpireDuration", - "DatasetInfo", - "DefaultEncryption", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(16); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDeletion_descriptor, - new java.lang.String[] { - "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(17); - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_ModelDeletion_descriptor, - new java.lang.String[] { - "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(18); - internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_Model_descriptor, - new java.lang.String[] { - "ModelName", "ModelInfo", "ExpireTime", "CreateTime", "UpdateTime", "Encryption", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(19); - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_RoutineDeletion_descriptor, - new java.lang.String[] { - "Routine", "Reason", "JobName", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(20); - internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_Job_descriptor, - new java.lang.String[] { - "JobName", "JobConfig", "JobStatus", "JobStats", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(21); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor, - new java.lang.String[] { - "Type", - "QueryConfig", - "LoadConfig", - "ExtractConfig", - "TableCopyConfig", - "Labels", - "Config", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor - .getNestedTypes() - .get(0); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Query_descriptor, - new java.lang.String[] { - "Query", - "QueryTruncated", - "DestinationTable", - "CreateDisposition", - "WriteDisposition", - "DefaultDataset", - "TableDefinitions", - "Priority", - "DestinationTableEncryption", - "StatementType", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor - .getNestedTypes() - .get(1); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Load_descriptor, - new java.lang.String[] { - "SourceUris", - "SourceUrisTruncated", - "SchemaJson", - "SchemaJsonTruncated", - "DestinationTable", - "CreateDisposition", - "WriteDisposition", - "DestinationTableEncryption", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor - .getNestedTypes() - .get(2); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_Extract_descriptor, - new java.lang.String[] { - "DestinationUris", "DestinationUrisTruncated", "SourceTable", "SourceModel", "Source", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor - .getNestedTypes() - .get(3); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_TableCopy_descriptor, - new java.lang.String[] { - "SourceTables", - "SourceTablesTruncated", - "DestinationTable", - "CreateDisposition", - "WriteDisposition", - "DestinationTableEncryption", - "OperationType", - "DestinationExpirationTime", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_descriptor - .getNestedTypes() - .get(4); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobConfig_LabelsEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(22); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableDefinition_descriptor, - new java.lang.String[] { - "Name", "SourceUris", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(23); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStatus_descriptor, - new java.lang.String[] { - "JobState", "ErrorResult", "Errors", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(24); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor, - new java.lang.String[] { - "CreateTime", - "StartTime", - "EndTime", - "QueryStats", - "LoadStats", - "ExtractStats", - "TotalSlotMs", - "ReservationUsage", - "ParentJobName", - "Extended", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor - .getNestedTypes() - .get(0); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Query_descriptor, - new java.lang.String[] { - "TotalProcessedBytes", - "TotalBilledBytes", - "BillingTier", - "ReferencedTables", - "ReferencedViews", - "ReferencedRoutines", - "OutputRowCount", - "CacheHit", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor - .getNestedTypes() - .get(1); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Load_descriptor, - new java.lang.String[] { - "TotalOutputBytes", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor - .getNestedTypes() - .get(2); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_Extract_descriptor, - new java.lang.String[] { - "TotalInputBytes", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_descriptor - .getNestedTypes() - .get(3); - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_JobStats_ReservationResourceUsage_descriptor, - new java.lang.String[] { - "Name", "SlotMs", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(25); - internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_Table_descriptor, - new java.lang.String[] { - "TableName", - "SchemaJson", - "SchemaJsonTruncated", - "View", - "ExpireTime", - "CreateTime", - "UpdateTime", - "TruncateTime", - "Encryption", - "TableInfo", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(26); - internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_Routine_descriptor, - new java.lang.String[] { - "RoutineName", "CreateTime", "UpdateTime", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(27); - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor, - new java.lang.String[] { - "FriendlyName", "Description", "Labels", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_descriptor - .getNestedTypes() - .get(0); - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_EntityInfo_LabelsEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(28); - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_TableViewDefinition_descriptor, - new java.lang.String[] { - "Query", "QueryTruncated", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(29); - internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_BigQueryAcl_descriptor, - new java.lang.String[] { - "Policy", "AuthorizedViews", - }); - internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor = - internal_static_google_cloud_audit_BigQueryAuditMetadata_descriptor - .getNestedTypes() - .get(30); - internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_audit_BigQueryAuditMetadata_EncryptionInfo_descriptor, - new java.lang.String[] { - "KmsKeyName", - }); - com.google.iam.v1.PolicyProto.getDescriptor(); - com.google.protobuf.DurationProto.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - com.google.rpc.StatusProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-common-protos/src/main/proto/google/cloud/audit/bigquery_audit_metadata.proto b/proto-google-common-protos/src/main/proto/google/cloud/audit/bigquery_audit_metadata.proto deleted file mode 100644 index f3a87ac5..00000000 --- a/proto-google-common-protos/src/main/proto/google/cloud/audit/bigquery_audit_metadata.proto +++ /dev/null @@ -1,1184 +0,0 @@ -// Copyright 2021 Google LLC -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -syntax = "proto3"; - -package google.cloud.audit; - -import "google/iam/v1/policy.proto"; -import "google/protobuf/duration.proto"; -import "google/protobuf/timestamp.proto"; -import "google/rpc/status.proto"; - -option csharp_namespace = "Google.Cloud.Audit"; -option go_package = "google.golang.org/genproto/googleapis/cloud/audit;audit"; -option java_multiple_files = true; -option java_outer_classname = "BigQueryAuditMetadataProto"; -option java_package = "com.google.cloud.audit"; -option objc_class_prefix = "GCA"; -option php_namespace = "Google\\Cloud\\Audit"; - -// Audit log format for BigQuery cloud audit logs metadata. -// -message BigQueryAuditMetadata { - // Job insertion event. - message JobInsertion { - // Describes how the job was inserted. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Job was inserted using the jobs.insert API. - JOB_INSERT_REQUEST = 1; - - // Job was inserted using the jobs.query RPC. - QUERY_REQUEST = 2; - } - - // Job metadata. - Job job = 1; - - // Describes how the job was inserted. - Reason reason = 2; - } - - // Job state change event. - message JobChange { - // Job state before the job state change. - JobState before = 1; - - // Job state after the job state change. - JobState after = 2; - - // Job metadata. - Job job = 3; - } - - // Dataset creation event. - message DatasetCreation { - // Describes how the dataset was created. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Dataset was created using the datasets.create API. - CREATE = 1; - - // Dataset was created using a query job, e.g., CREATE SCHEMA statement. - QUERY = 2; - } - - // Dataset metadata. - Dataset dataset = 1; - - // Describes how the dataset was created. - Reason reason = 2; - - // The URI of the job that created the dataset. - // Present if the reason is QUERY. - // - // Format: `projects//jobs/`. - string job_name = 3; - } - - // Dataset change event. - message DatasetChange { - // Describes how the dataset was changed. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Dataset was changed using the datasets.update or datasets.patch API. - UPDATE = 1; - - // Dataset was changed using the SetIamPolicy API. - SET_IAM_POLICY = 2; - - // Dataset was changed using a query job, e.g., ALTER SCHEMA statement. - QUERY = 3; - } - - // Dataset metadata after the change. - Dataset dataset = 1; - - // Describes how the dataset was changed. - Reason reason = 2; - - // The URI of the job that updated the dataset. - // Present if the reason is QUERY. - // - // Format: `projects//jobs/`. - string job_name = 3; - } - - // Dataset deletion event. - message DatasetDeletion { - // Describes how the dataset was deleted. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Dataset was deleted using the datasets.delete API. - DELETE = 1; - - // Dataset was deleted using a query job, e.g., DROP SCHEMA statement. - QUERY = 2; - } - - // Describes how the dataset was deleted. - Reason reason = 1; - - // The URI of the job that deleted the dataset. - // Present if the reason is QUERY. - // - // Format: `projects//jobs/`. - string job_name = 2; - } - - // Table creation event. - message TableCreation { - // Describes how the table was created. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Table was created as a destination table during a query, load or copy - // job. - JOB = 1; - - // Table was created using a DDL query. - QUERY = 2; - - // Table was created using the tables.create API. - TABLE_INSERT_REQUEST = 3; - } - - // Table metadata. - Table table = 1; - - // Describes how the table was created. - Reason reason = 3; - - // The URI of the job that created a table. - // Present if the reason is JOB or QUERY. - // - // Format: `projects//jobs/`. - string job_name = 4; - } - - // Model creation event. - message ModelCreation { - // Describes how the model was created. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Model was created using a DDL query. - QUERY = 2; - } - - // Model metadata. - Model model = 1; - - // Describes how the model was created. - Reason reason = 3; - - // The URI of the job that created the model. - // - // Format: `projects//jobs/`. - string job_name = 4; - } - - // Routine creation event. - message RoutineCreation { - // Describes how the routine was created. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Routine was created using a DDL query. - QUERY = 1; - - // Routine was created using the routines.create API. - ROUTINE_INSERT_REQUEST = 2; - } - - // Created routine. - Routine routine = 1; - - // Describes how the routine was created. - Reason reason = 3; - - // The URI of the job that created the routine. - // - // Format: `projects//jobs/`. - string job_name = 4; - } - - // Table data read event. - message TableDataRead { - // Describes how the table data was read. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Table was used as a source table during a BigQuery job. - JOB = 1; - - // Table data was accessed using the tabledata.list API. - TABLEDATA_LIST_REQUEST = 2; - - // Table data was accessed using the jobs.getQueryResults API. - GET_QUERY_RESULTS_REQUEST = 3; - - // Table data was accessed using the jobs.query RPC. - QUERY_REQUEST = 4; - - // Table data was accessed using storage.CreateReadSession API. - CREATE_READ_SESSION = 5; - - // Table data was accessed during a materialized view refresh. - MATERIALIZED_VIEW_REFRESH = 6; - } - - // List of the accessed fields. Entire list is truncated if the record size - // exceeds 100K. - repeated string fields = 2; - - // True if the fields list was truncated. - bool fields_truncated = 8; - - // List of the referenced policy tags. That is, policy tags attached to the - // accessed fields or their ancestors. - // Policy tag resource name is a string of the format: - // `projects//locations//taxonomies//policyTags/` - repeated string policy_tags = 9; - - // True if the policy tag list was truncated. At most 100 policy tags can be - // saved. - bool policy_tags_truncated = 10; - - // Describes how the table data was read. - Reason reason = 3; - - // The URI of the job that read a table. - // Present if the reason is JOB but can be redacted for privacy reasons. - // - // Format: `projects//jobs/`. - string job_name = 4; - - // The URI of the read session that read a table. - // Present if the reason is CREATE_READ_SESSION. - // - // Format: - // `projects//locations//sessions/`. - string session_name = 5; - } - - // Table metadata change event. - message TableChange { - // Describes how the table metadata was changed. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Table metadata was updated using the tables.update or tables.patch API. - TABLE_UPDATE_REQUEST = 1; - - // Table was used as a job destination table. - JOB = 2; - - // Table metadata was updated using a DML or DDL query. - QUERY = 3; - } - - // Updated table metadata. - Table table = 1; - - // True if the table was truncated. - bool truncated = 4; - - // Describes how the table metadata was changed. - Reason reason = 5; - - // The URI of the job that changed a table. - // Present if the reason is JOB or QUERY. - // - // Format: `projects//jobs/`. - string job_name = 6; - } - - // Model metadata change event. - message ModelMetadataChange { - // Describes how the model metadata was changed. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Model metadata was updated using the models.patch API. - MODEL_PATCH_REQUEST = 1; - - // Model metadata was updated using a DDL query. - QUERY = 2; - } - - // Updated model. - Model model = 1; - - // Describes how the model metadata was changed. - Reason reason = 2; - - // The URI of the job that changed the model metadata. - // Present if and only if the reason is QUERY. - // - // Format: `projects//jobs/`. - string job_name = 3; - } - - // Routine change event. - message RoutineChange { - // Describes how the routine was updated. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Routine was updated using a DDL query. - QUERY = 1; - - // Routine was updated using the routines.update or routines.patch API. - ROUTINE_UPDATE_REQUEST = 2; - } - - // Updated routine. - Routine routine = 1; - - // Describes how the routine was updated. - Reason reason = 3; - - // The URI of the job that updated the routine. - // - // Format: `projects//jobs/`. - string job_name = 4; - } - - // Table data change event. - message TableDataChange { - // Describes how the table data was changed. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Table was used as a job destination table. - JOB = 1; - - // Table data was updated using a DML or DDL query. - QUERY = 2; - - // Table data was updated during a materialized view refresh. - MATERIALIZED_VIEW_REFRESH = 3; - - // Table data was added using the Write API. - WRITE_API = 4; - } - - // Number of deleted rows. - int64 deleted_rows_count = 1; - - // Number of inserted rows. - int64 inserted_rows_count = 2; - - // True if the table was truncated. - bool truncated = 3; - - // Describes how the table data was changed. - Reason reason = 4; - - // The URI of the job that changed a table. - // - // Format: `projects//jobs/`. - string job_name = 5; - - // If written from WRITE_API, the name of the stream. - // - // Format: - // `projects//datasets//tables//streams/` - string stream_name = 6; - } - - // Model data change event. - message ModelDataChange { - // Describes how the model data was changed. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Model data was changed using a DDL query. - QUERY = 1; - } - - // Describes how the model data was changed. - Reason reason = 1; - - // The URI of the job that changed the model data. - // - // Format: `projects//jobs/`. - string job_name = 2; - } - - // Model data read event. - message ModelDataRead { - // Describes how the model data was read. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Model was used as a source model during a BigQuery job. - JOB = 1; - } - - // Describes how the model data was read. - Reason reason = 1; - - // The URI of the job that read the model data. - // - // Format: `projects//jobs/`. - string job_name = 2; - } - - // BigQuery dataset. - message Dataset { - // Dataset URI. - // - // Format: `projects//datasets/`. - string dataset_name = 1; - - // Dataset creation time. - google.protobuf.Timestamp create_time = 3; - - // Dataset metadata last update time. - google.protobuf.Timestamp update_time = 4; - - // The access control list for the dataset. - BigQueryAcl acl = 5; - - // Default expiration time for tables in the dataset. - google.protobuf.Duration default_table_expire_duration = 6; - - // User-provided metadata for the dataset. - EntityInfo dataset_info = 7; - - // Default encryption for tables in the dataset. - EncryptionInfo default_encryption = 8; - } - - // Table deletion event. - message TableDeletion { - // Describes how the table was deleted. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Table was deleted using the tables.delete API. - TABLE_DELETE_REQUEST = 2; - - // Table expired. - EXPIRED = 3; - - // Table deleted using a DDL query. - QUERY = 4; - } - - // Describes how the table was deleted. - Reason reason = 1; - - // The URI of the job that deleted a table. - // Present if the reason is QUERY. - // - // Format: `projects//jobs/`. - string job_name = 2; - } - - // Model deletion event. - message ModelDeletion { - // Describes how the model was deleted. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Model was deleted using the models.delete API. - MODEL_DELETE_REQUEST = 1; - - // Model expired. - EXPIRED = 2; - - // Model was deleted using DDL query. - QUERY = 3; - } - - // Describes how the model was deleted. - Reason reason = 1; - - // The URI of the job that deleted a model. - // Present if the reason is QUERY. - // - // Format: `projects//jobs/`. - string job_name = 2; - } - - // Trained BigQuery ML model. - message Model { - // Model URI. - // - // Format: `projects//datasets//models/`. - string model_name = 1; - - // User-provided metadata for the model. - EntityInfo model_info = 2; - - // Model expiration time. - google.protobuf.Timestamp expire_time = 5; - - // Model creation time. - google.protobuf.Timestamp create_time = 6; - - // Model last update time. - google.protobuf.Timestamp update_time = 7; - - // Model encryption information. Set when non-default encryption is used. - EncryptionInfo encryption = 8; - } - - // Routine deletion event. - message RoutineDeletion { - // Describes how the routine was deleted. - enum Reason { - // Unknown. - REASON_UNSPECIFIED = 0; - - // Routine was deleted using DDL query. - QUERY = 1; - - // Routine was deleted using the API. - ROUTINE_DELETE_REQUEST = 2; - } - - // Deleted routine. - Routine routine = 1; - - // Describes how the routine was deleted. - Reason reason = 3; - - // The URI of the job that deleted the routine. - // Present if the reason is QUERY. - // - // Format: `projects//jobs/`. - string job_name = 4; - } - - // BigQuery job. - message Job { - // Job URI. - // - // Format: `projects//jobs/`. - string job_name = 1; - - // Job configuration. - JobConfig job_config = 2; - - // Job status. - JobStatus job_status = 3; - - // Job statistics. - JobStats job_stats = 4; - } - - // Job configuration. - // See the [Jobs](https://cloud.google.com/bigquery/docs/reference/v2/jobs) - // API resource for more details on individual fields. - message JobConfig { - // Query job configuration. - message Query { - // Priority given to the query. - enum Priority { - // Unknown. - PRIORITY_UNSPECIFIED = 0; - - // Interactive query. - QUERY_INTERACTIVE = 1; - - // Batch query. - QUERY_BATCH = 2; - } - - // The SQL query to run. Truncated if exceeds 50K. - string query = 1; - - // True if the query field was truncated. - bool query_truncated = 10; - - // The destination table for the query results. - string destination_table = 2; - - // Destination table create disposition. - CreateDisposition create_disposition = 3; - - // Destination table write disposition. - WriteDisposition write_disposition = 4; - - // Default dataset for the query. - string default_dataset = 5; - - // External data sources used in the query. - repeated TableDefinition table_definitions = 6; - - // Priority given to the query. - Priority priority = 7; - - // Result table encryption information. Set when non-default encryption is - // used. - EncryptionInfo destination_table_encryption = 8; - - // Type of the query. - QueryStatementType statement_type = 9; - } - - // Load job configuration. - message Load { - // URIs for the data to be imported. Entire list is truncated if exceeds - // 40K. - repeated string source_uris = 1; - - // True if the source_URIs field was truncated. - bool source_uris_truncated = 7; - - // The table schema in JSON format. Entire field is truncated if exceeds - // 40K. - string schema_json = 2; - - // True if the schema_json field was truncated. - bool schema_json_truncated = 8; - - // The destination table for the import. - string destination_table = 3; - - // Destination table create disposition. - CreateDisposition create_disposition = 4; - - // Destination table write disposition. - WriteDisposition write_disposition = 5; - - // Result table encryption information. Set when non-default encryption is - // used. - EncryptionInfo destination_table_encryption = 6; - } - - // Extract job configuration. - message Extract { - // URIs where extracted data should be written. Entire list is truncated - // if exceeds 50K. - repeated string destination_uris = 1; - - // True if the destination_URIs field was truncated. - bool destination_uris_truncated = 3; - - oneof source { - // The source table. - string source_table = 2; - - // The source model. - string source_model = 4; - } - } - - // Table copy job configuration. - message TableCopy { - // Source tables. Entire list is truncated if exceeds 50K. - repeated string source_tables = 1; - - // True if the source_tables field was truncated. - bool source_tables_truncated = 6; - - // Destination table. - string destination_table = 2; - - // Destination table create disposition. - CreateDisposition create_disposition = 3; - - // Destination table write disposition. - WriteDisposition write_disposition = 4; - - // Result table encryption information. Set when non-default encryption is - // used. - EncryptionInfo destination_table_encryption = 5; - - // Supported operation types in the table copy job. - OperationType operation_type = 7; - - // Expiration time set on the destination table. Expired tables will be - // deleted and their storage reclaimed. - google.protobuf.Timestamp destination_expiration_time = 8; - } - - // Job type. - enum Type { - // Unknown. - TYPE_UNSPECIFIED = 0; - - // Query job. - QUERY = 1; - - // Table copy job. - COPY = 2; - - // Export (extract) job. - EXPORT = 3; - - // Import (load) job. - IMPORT = 4; - } - - // Job type. - Type type = 1; - - // Job configuration information. - oneof config { - // Query job information. - Query query_config = 2; - - // Load job information. - Load load_config = 3; - - // Extract job information. - Extract extract_config = 4; - - // TableCopy job information. - TableCopy table_copy_config = 5; - } - - // Labels provided for the job. - map labels = 6; - } - - // Definition of an external data source used in a query. - message TableDefinition { - // Name of the table, used in queries. - string name = 1; - - // URIs for the data. - repeated string source_uris = 2; - } - - // Status of a job. - message JobStatus { - // State of the job. - JobState job_state = 1; - - // Job error, if the job failed. - google.rpc.Status error_result = 2; - - // Errors encountered during the running of the job. Does not necessarily - // mean that the job has completed or was unsuccessful. - repeated google.rpc.Status errors = 3; - } - - // Job statistics. - message JobStats { - // Query job statistics. - message Query { - // Total bytes processed by the query job. - int64 total_processed_bytes = 1; - - // Total bytes billed by the query job. - int64 total_billed_bytes = 2; - - // The tier assigned by the CPU-based billing. - int32 billing_tier = 3; - - // Tables accessed by the query job. - repeated string referenced_tables = 6; - - // Views accessed by the query job. - repeated string referenced_views = 7; - - // Routines accessed by the query job. - repeated string referenced_routines = 10; - - // Number of output rows produced by the query job. - int64 output_row_count = 8; - - // True if the query job results were read from the query cache. - bool cache_hit = 9; - } - - // Load job statistics. - message Load { - // Total bytes loaded by the import job. - int64 total_output_bytes = 1; - } - - // Extract job statistics. - message Extract { - // Total bytes exported by the extract job. - int64 total_input_bytes = 1; - } - - // Job resource usage breakdown by reservation. - message ReservationResourceUsage { - // Reservation name or "unreserved" for on-demand resources usage. - string name = 1; - - // Total slot milliseconds used by the reservation for a particular job. - int64 slot_ms = 2; - } - - // Job creation time. - google.protobuf.Timestamp create_time = 1; - - // Job execution start time. - google.protobuf.Timestamp start_time = 2; - - // Job completion time. - google.protobuf.Timestamp end_time = 3; - - // Statistics specific to the job type. - oneof extended { - // Query job statistics. - Query query_stats = 8; - - // Load job statistics. - Load load_stats = 9; - - // Extract job statistics. - Extract extract_stats = 13; - } - - // The total number of slot-ms consumed by the query job. - int64 total_slot_ms = 10; - - // Reservation usage attributed from each tier of a reservation hierarchy. - repeated ReservationResourceUsage reservation_usage = 11; - - // Parent job name. Only present for child jobs. - string parent_job_name = 12; - } - - // Describes whether a job should overwrite or append the existing destination - // table if it already exists. - enum WriteDisposition { - // Unknown. - WRITE_DISPOSITION_UNSPECIFIED = 0; - - // This job should only be writing to empty tables. - WRITE_EMPTY = 1; - - // This job will truncate the existing table data. - WRITE_TRUNCATE = 2; - - // This job will append to the table. - WRITE_APPEND = 3; - } - - // BigQuery table. - message Table { - // Table URI. - // - // Format: `projects//datasets//tables/`. - string table_name = 1; - - // A JSON representation of the table's schema. Entire field is truncated - // if exceeds 40K. - string schema_json = 3; - - // True if the schema_json field was truncated. - bool schema_json_truncated = 11; - - // View metadata. Only present for views. - TableViewDefinition view = 4; - - // Table expiration time. - google.protobuf.Timestamp expire_time = 5; - - // The table creation time. - google.protobuf.Timestamp create_time = 6; - - // The last time metadata update time. - google.protobuf.Timestamp update_time = 7; - - // The last table truncation time. - google.protobuf.Timestamp truncate_time = 8; - - // Table encryption information. Set when non-default encryption is used. - EncryptionInfo encryption = 9; - - // User-provided metadata for the table. - EntityInfo table_info = 10; - } - - // User Defined Function (UDF) or Stored Procedure. - message Routine { - // Routine URI. - // - // Format: - // `projects//datasets//routines/`. - string routine_name = 1; - - // Routine creation time. - google.protobuf.Timestamp create_time = 5; - - // Routine last update time. - google.protobuf.Timestamp update_time = 6; - } - - // Table copy job operation type. - enum OperationType { - // Unspecified operation type. - OPERATION_TYPE_UNSPECIFIED = 0; - - // The source and the destination table have the same table type. - COPY = 1; - - // The source table type is TABLE and - // the destination table type is SNAPSHOT. - SNAPSHOT = 2; - - // The source table type is SNAPSHOT and - // the destination table type is TABLE. - RESTORE = 3; - } - - // User-provided metadata for an entity, for e.g. dataset, table or model. - message EntityInfo { - // A short name for the entity. - string friendly_name = 1; - - // A long description for the entity. - string description = 2; - - // Labels provided for the entity. - map labels = 3; - } - - // View definition. - message TableViewDefinition { - // SQL query defining the view. Truncated if exceeds 40K. - string query = 1; - - // True if the schema_json field was truncated. - bool query_truncated = 2; - } - - // An access control list. - message BigQueryAcl { - // IAM policy for the resource. - google.iam.v1.Policy policy = 1; - - // List of authorized views for a dataset. - // - // Format: `projects//datasets//tables/`. - repeated string authorized_views = 2; - } - - // Encryption properties for a table or a job - message EncryptionInfo { - // Cloud kms key identifier. - // - // Format: - // `projects//locations//keyRings//cryptoKeys/` - string kms_key_name = 1; - } - - // Describes whether a job should create a destination table if it doesn't - // exist. - enum CreateDisposition { - // Unknown. - CREATE_DISPOSITION_UNSPECIFIED = 0; - - // This job should never create tables. - CREATE_NEVER = 1; - - // This job should create a table if it doesn't already exist. - CREATE_IF_NEEDED = 2; - } - - // State of a job. - enum JobState { - // State unknown. - JOB_STATE_UNSPECIFIED = 0; - - // Job is waiting for the resources. - PENDING = 1; - - // Job is running. - RUNNING = 2; - - // Job is done. - DONE = 3; - } - - // Type of the statement (e.g. SELECT, INSERT, CREATE_TABLE, CREATE_MODEL..) - enum QueryStatementType { - // Unknown. - QUERY_STATEMENT_TYPE_UNSPECIFIED = 0; - - // SELECT ... FROM <Table list> ... - SELECT = 1; - - // ASSERT <condition> AS 'description' - ASSERT = 23; - - // INSERT INTO <Table> .... - INSERT = 2; - - // UPDATE <Table> SET ... - UPDATE = 3; - - // DELETE <Table> ... - DELETE = 4; - - // MERGE INTO <Table> .... - MERGE = 5; - - // CREATE TABLE <Table> <column list> - CREATE_TABLE = 6; - - // CREATE TABLE <Table> AS SELECT - CREATE_TABLE_AS_SELECT = 7; - - // CREATE VIEW <View> - CREATE_VIEW = 8; - - // CREATE MODEL <Model> AS <Query> - CREATE_MODEL = 9; - - // CREATE MATERIALIZED VIEW <View> AS ... - CREATE_MATERIALIZED_VIEW = 13; - - // CREATE FUNCTION <Function>(<Signature>) AS ... - CREATE_FUNCTION = 14; - - // CREATE PROCEDURE <Procedure> - CREATE_PROCEDURE = 20; - - // CREATE SCHEMA <Schema> - CREATE_SCHEMA = 53; - - // DROP TABLE <Table> - DROP_TABLE = 10; - - // DROP EXTERNAL TABLE <Table> - DROP_EXTERNAL_TABLE = 33; - - // DROP VIEW <View> - DROP_VIEW = 11; - - // DROP MODEL <Model> - DROP_MODEL = 12; - - // DROP MATERIALIZED VIEW <View> - DROP_MATERIALIZED_VIEW = 15; - - // DROP FUNCTION <Function> - DROP_FUNCTION = 16; - - // DROP PROCEDURE <Procedure> - DROP_PROCEDURE = 21; - - // DROP SCHEMA <Schema> - DROP_SCHEMA = 54; - - // ALTER TABLE <Table> - ALTER_TABLE = 17; - - // ALTER VIEW <View> - ALTER_VIEW = 18; - - // ALTER MATERIALIZED_VIEW <view> - ALTER_MATERIALIZED_VIEW = 22; - - // ALTER SCHEMA <Schema> - ALTER_SCHEMA = 55; - - // Script - SCRIPT = 19; - - // TRUNCATE TABLE <Table> - TRUNCATE_TABLE = 26; - - // CREATE EXTERNAL TABLE <TABLE> - CREATE_EXTERNAL_TABLE = 27; - - // EXPORT DATA; - EXPORT_DATA = 28; - - // CALL <stored procedure> - CALL = 29; - } - - // BigQuery event information. - oneof event { - // Job insertion event. - JobInsertion job_insertion = 1; - - // Job state change event. - JobChange job_change = 2; - - // Dataset creation event. - DatasetCreation dataset_creation = 3; - - // Dataset change event. - DatasetChange dataset_change = 4; - - // Dataset deletion event. - DatasetDeletion dataset_deletion = 5; - - // Table creation event. - TableCreation table_creation = 6; - - // Table metadata change event. - TableChange table_change = 8; - - // Table deletion event. - TableDeletion table_deletion = 9; - - // Table data read event. - TableDataRead table_data_read = 10; - - // Table data change event. - TableDataChange table_data_change = 11; - - // Model deletion event. - ModelDeletion model_deletion = 12; - - // Model creation event. - ModelCreation model_creation = 13; - - // Model metadata change event. - ModelMetadataChange model_metadata_change = 14; - - // Model data change event. - ModelDataChange model_data_change = 15; - - // Model data read event. - ModelDataRead model_data_read = 19; - - // Routine creation event. - RoutineCreation routine_creation = 16; - - // Routine change event. - RoutineChange routine_change = 17; - - // Routine deletion event. - RoutineDeletion routine_deletion = 18; - } -} diff --git a/synth.py b/synth.py index 8ac4ef49..ff68d5d5 100644 --- a/synth.py +++ b/synth.py @@ -96,6 +96,11 @@ def build_grpc(target): java.format_code("proto-google-common-protos/src") java.format_code("grpc-google-common-protos/src") +os.remove("proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadata.java") +os.remove("proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataOrBuilder.java") +os.remove("proto-google-common-protos/src/main/java/com/google/cloud/audit/BigQueryAuditMetadataProto.java") +os.remove("proto-google-common-protos/src/main/proto/google/cloud/audit/bigquery_audit_metadata.proto") + java.common_templates(excludes=[ 'README.md', 'samples/*',