diff --git a/codacy-conf.json b/codacy-conf.json index 156abaccb39a..d3c4145bcd4e 100644 --- a/codacy-conf.json +++ b/codacy-conf.json @@ -698,7 +698,7 @@ }, { "patternId": "design_FieldDeclarationsShouldBeAtStartOfClass", - "enabled": true + "enabled": false }, { "patternId": "unnecessary_UnnecessaryConversionTemporary", @@ -986,7 +986,7 @@ }, { "patternId": "unnecessary_UselessParentheses", - "enabled": true + "enabled": false }, { "patternId": "design_IdempotentOperations", @@ -994,7 +994,7 @@ }, { "patternId": "braces_IfStmtsMustUseBraces", - "enabled": true + "enabled": false }, { "patternId": "strings_UseIndexOfChar", diff --git a/google-api-grpc/grpc-google-cloud-dlp-v2beta1/pom.xml b/google-api-grpc/grpc-google-cloud-dlp-v2beta1/pom.xml deleted file mode 100644 index c5d0689e585b..000000000000 --- a/google-api-grpc/grpc-google-cloud-dlp-v2beta1/pom.xml +++ /dev/null @@ -1,31 +0,0 @@ - - 4.0.0 - grpc-google-cloud-dlp-v2beta1 - 0.12.1-SNAPSHOT - grpc-google-cloud-dlp-v2beta1 - GRPC library for grpc-google-cloud-dlp-v2beta1 - - com.google.api.grpc - google-api-grpc - 0.12.1-SNAPSHOT - - - - io.grpc - grpc-stub - compile - - - io.grpc - grpc-protobuf - compile - - - com.google.api.grpc - proto-google-cloud-dlp-v2beta1 - compile - - - \ No newline at end of file diff --git a/google-api-grpc/grpc-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DlpServiceGrpc.java b/google-api-grpc/grpc-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DlpServiceGrpc.java deleted file mode 100644 index 5d26e51cb104..000000000000 --- a/google-api-grpc/grpc-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DlpServiceGrpc.java +++ /dev/null @@ -1,1002 +0,0 @@ -package com.google.privacy.dlp.v2beta1; - -import static io.grpc.MethodDescriptor.generateFullMethodName; -import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall; -import static io.grpc.stub.ClientCalls.asyncClientStreamingCall; -import static io.grpc.stub.ClientCalls.asyncServerStreamingCall; -import static io.grpc.stub.ClientCalls.asyncUnaryCall; -import static io.grpc.stub.ClientCalls.blockingServerStreamingCall; -import static io.grpc.stub.ClientCalls.blockingUnaryCall; -import static io.grpc.stub.ClientCalls.futureUnaryCall; -import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall; -import static io.grpc.stub.ServerCalls.asyncClientStreamingCall; -import static io.grpc.stub.ServerCalls.asyncServerStreamingCall; -import static io.grpc.stub.ServerCalls.asyncUnaryCall; -import static io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall; -import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall; - -/** - *
- * The DLP API is a service that allows clients
- * to detect the presence of Personally Identifiable Information (PII) and other
- * privacy-sensitive data in user-supplied, unstructured data streams, like text
- * blocks or images.
- * The service also includes methods for sensitive data redaction and
- * scheduling of data scans on Google Cloud Platform based data sets.
- * 
- */ -@javax.annotation.Generated( - value = "by gRPC proto compiler (version 1.10.0)", - comments = "Source: google/privacy/dlp/v2beta1/dlp.proto") -public final class DlpServiceGrpc { - - private DlpServiceGrpc() {} - - public static final String SERVICE_NAME = "google.privacy.dlp.v2beta1.DlpService"; - - // Static method descriptors that strictly reflect the proto. - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getInspectContentMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_INSPECT_CONTENT = getInspectContentMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getInspectContentMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getInspectContentMethod() { - return getInspectContentMethodHelper(); - } - - private static io.grpc.MethodDescriptor getInspectContentMethodHelper() { - io.grpc.MethodDescriptor getInspectContentMethod; - if ((getInspectContentMethod = DlpServiceGrpc.getInspectContentMethod) == null) { - synchronized (DlpServiceGrpc.class) { - if ((getInspectContentMethod = DlpServiceGrpc.getInspectContentMethod) == null) { - DlpServiceGrpc.getInspectContentMethod = getInspectContentMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.privacy.dlp.v2beta1.DlpService", "InspectContent")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.InspectContentRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.InspectContentResponse.getDefaultInstance())) - .setSchemaDescriptor(new DlpServiceMethodDescriptorSupplier("InspectContent")) - .build(); - } - } - } - return getInspectContentMethod; - } - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getRedactContentMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_REDACT_CONTENT = getRedactContentMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getRedactContentMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getRedactContentMethod() { - return getRedactContentMethodHelper(); - } - - private static io.grpc.MethodDescriptor getRedactContentMethodHelper() { - io.grpc.MethodDescriptor getRedactContentMethod; - if ((getRedactContentMethod = DlpServiceGrpc.getRedactContentMethod) == null) { - synchronized (DlpServiceGrpc.class) { - if ((getRedactContentMethod = DlpServiceGrpc.getRedactContentMethod) == null) { - DlpServiceGrpc.getRedactContentMethod = getRedactContentMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.privacy.dlp.v2beta1.DlpService", "RedactContent")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.RedactContentRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.RedactContentResponse.getDefaultInstance())) - .setSchemaDescriptor(new DlpServiceMethodDescriptorSupplier("RedactContent")) - .build(); - } - } - } - return getRedactContentMethod; - } - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getDeidentifyContentMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_DEIDENTIFY_CONTENT = getDeidentifyContentMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getDeidentifyContentMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getDeidentifyContentMethod() { - return getDeidentifyContentMethodHelper(); - } - - private static io.grpc.MethodDescriptor getDeidentifyContentMethodHelper() { - io.grpc.MethodDescriptor getDeidentifyContentMethod; - if ((getDeidentifyContentMethod = DlpServiceGrpc.getDeidentifyContentMethod) == null) { - synchronized (DlpServiceGrpc.class) { - if ((getDeidentifyContentMethod = DlpServiceGrpc.getDeidentifyContentMethod) == null) { - DlpServiceGrpc.getDeidentifyContentMethod = getDeidentifyContentMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.privacy.dlp.v2beta1.DlpService", "DeidentifyContent")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.DeidentifyContentRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.DeidentifyContentResponse.getDefaultInstance())) - .setSchemaDescriptor(new DlpServiceMethodDescriptorSupplier("DeidentifyContent")) - .build(); - } - } - } - return getDeidentifyContentMethod; - } - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getCreateInspectOperationMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_CREATE_INSPECT_OPERATION = getCreateInspectOperationMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getCreateInspectOperationMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getCreateInspectOperationMethod() { - return getCreateInspectOperationMethodHelper(); - } - - private static io.grpc.MethodDescriptor getCreateInspectOperationMethodHelper() { - io.grpc.MethodDescriptor getCreateInspectOperationMethod; - if ((getCreateInspectOperationMethod = DlpServiceGrpc.getCreateInspectOperationMethod) == null) { - synchronized (DlpServiceGrpc.class) { - if ((getCreateInspectOperationMethod = DlpServiceGrpc.getCreateInspectOperationMethod) == null) { - DlpServiceGrpc.getCreateInspectOperationMethod = getCreateInspectOperationMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.privacy.dlp.v2beta1.DlpService", "CreateInspectOperation")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new DlpServiceMethodDescriptorSupplier("CreateInspectOperation")) - .build(); - } - } - } - return getCreateInspectOperationMethod; - } - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getAnalyzeDataSourceRiskMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_ANALYZE_DATA_SOURCE_RISK = getAnalyzeDataSourceRiskMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getAnalyzeDataSourceRiskMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getAnalyzeDataSourceRiskMethod() { - return getAnalyzeDataSourceRiskMethodHelper(); - } - - private static io.grpc.MethodDescriptor getAnalyzeDataSourceRiskMethodHelper() { - io.grpc.MethodDescriptor getAnalyzeDataSourceRiskMethod; - if ((getAnalyzeDataSourceRiskMethod = DlpServiceGrpc.getAnalyzeDataSourceRiskMethod) == null) { - synchronized (DlpServiceGrpc.class) { - if ((getAnalyzeDataSourceRiskMethod = DlpServiceGrpc.getAnalyzeDataSourceRiskMethod) == null) { - DlpServiceGrpc.getAnalyzeDataSourceRiskMethod = getAnalyzeDataSourceRiskMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.privacy.dlp.v2beta1.DlpService", "AnalyzeDataSourceRisk")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new DlpServiceMethodDescriptorSupplier("AnalyzeDataSourceRisk")) - .build(); - } - } - } - return getAnalyzeDataSourceRiskMethod; - } - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getListInspectFindingsMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_LIST_INSPECT_FINDINGS = getListInspectFindingsMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getListInspectFindingsMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getListInspectFindingsMethod() { - return getListInspectFindingsMethodHelper(); - } - - private static io.grpc.MethodDescriptor getListInspectFindingsMethodHelper() { - io.grpc.MethodDescriptor getListInspectFindingsMethod; - if ((getListInspectFindingsMethod = DlpServiceGrpc.getListInspectFindingsMethod) == null) { - synchronized (DlpServiceGrpc.class) { - if ((getListInspectFindingsMethod = DlpServiceGrpc.getListInspectFindingsMethod) == null) { - DlpServiceGrpc.getListInspectFindingsMethod = getListInspectFindingsMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.privacy.dlp.v2beta1.DlpService", "ListInspectFindings")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse.getDefaultInstance())) - .setSchemaDescriptor(new DlpServiceMethodDescriptorSupplier("ListInspectFindings")) - .build(); - } - } - } - return getListInspectFindingsMethod; - } - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getListInfoTypesMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_LIST_INFO_TYPES = getListInfoTypesMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getListInfoTypesMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getListInfoTypesMethod() { - return getListInfoTypesMethodHelper(); - } - - private static io.grpc.MethodDescriptor getListInfoTypesMethodHelper() { - io.grpc.MethodDescriptor getListInfoTypesMethod; - if ((getListInfoTypesMethod = DlpServiceGrpc.getListInfoTypesMethod) == null) { - synchronized (DlpServiceGrpc.class) { - if ((getListInfoTypesMethod = DlpServiceGrpc.getListInfoTypesMethod) == null) { - DlpServiceGrpc.getListInfoTypesMethod = getListInfoTypesMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.privacy.dlp.v2beta1.DlpService", "ListInfoTypes")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.ListInfoTypesRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.ListInfoTypesResponse.getDefaultInstance())) - .setSchemaDescriptor(new DlpServiceMethodDescriptorSupplier("ListInfoTypes")) - .build(); - } - } - } - return getListInfoTypesMethod; - } - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @java.lang.Deprecated // Use {@link #getListRootCategoriesMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_LIST_ROOT_CATEGORIES = getListRootCategoriesMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getListRootCategoriesMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getListRootCategoriesMethod() { - return getListRootCategoriesMethodHelper(); - } - - private static io.grpc.MethodDescriptor getListRootCategoriesMethodHelper() { - io.grpc.MethodDescriptor getListRootCategoriesMethod; - if ((getListRootCategoriesMethod = DlpServiceGrpc.getListRootCategoriesMethod) == null) { - synchronized (DlpServiceGrpc.class) { - if ((getListRootCategoriesMethod = DlpServiceGrpc.getListRootCategoriesMethod) == null) { - DlpServiceGrpc.getListRootCategoriesMethod = getListRootCategoriesMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.privacy.dlp.v2beta1.DlpService", "ListRootCategories")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse.getDefaultInstance())) - .setSchemaDescriptor(new DlpServiceMethodDescriptorSupplier("ListRootCategories")) - .build(); - } - } - } - return getListRootCategoriesMethod; - } - - /** - * Creates a new async stub that supports all call types for the service - */ - public static DlpServiceStub newStub(io.grpc.Channel channel) { - return new DlpServiceStub(channel); - } - - /** - * Creates a new blocking-style stub that supports unary and streaming output calls on the service - */ - public static DlpServiceBlockingStub newBlockingStub( - io.grpc.Channel channel) { - return new DlpServiceBlockingStub(channel); - } - - /** - * Creates a new ListenableFuture-style stub that supports unary calls on the service - */ - public static DlpServiceFutureStub newFutureStub( - io.grpc.Channel channel) { - return new DlpServiceFutureStub(channel); - } - - /** - *
-   * The DLP API is a service that allows clients
-   * to detect the presence of Personally Identifiable Information (PII) and other
-   * privacy-sensitive data in user-supplied, unstructured data streams, like text
-   * blocks or images.
-   * The service also includes methods for sensitive data redaction and
-   * scheduling of data scans on Google Cloud Platform based data sets.
-   * 
- */ - public static abstract class DlpServiceImplBase implements io.grpc.BindableService { - - /** - *
-     * Finds potentially sensitive info in a list of strings.
-     * This method has limits on input size, processing time, and output size.
-     * 
- */ - public void inspectContent(com.google.privacy.dlp.v2beta1.InspectContentRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getInspectContentMethodHelper(), responseObserver); - } - - /** - *
-     * Redacts potentially sensitive info from a list of strings.
-     * This method has limits on input size, processing time, and output size.
-     * 
- */ - public void redactContent(com.google.privacy.dlp.v2beta1.RedactContentRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getRedactContentMethodHelper(), responseObserver); - } - - /** - *
-     * De-identifies potentially sensitive info from a list of strings.
-     * This method has limits on input size and output size.
-     * 
- */ - public void deidentifyContent(com.google.privacy.dlp.v2beta1.DeidentifyContentRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getDeidentifyContentMethodHelper(), responseObserver); - } - - /** - *
-     * Schedules a job scanning content in a Google Cloud Platform data
-     * repository.
-     * 
- */ - public void createInspectOperation(com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getCreateInspectOperationMethodHelper(), responseObserver); - } - - /** - *
-     * Schedules a job to compute risk analysis metrics over content in a Google
-     * Cloud Platform repository.
-     * 
- */ - public void analyzeDataSourceRisk(com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getAnalyzeDataSourceRiskMethodHelper(), responseObserver); - } - - /** - *
-     * Returns list of results for given inspect operation result set id.
-     * 
- */ - public void listInspectFindings(com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getListInspectFindingsMethodHelper(), responseObserver); - } - - /** - *
-     * Returns sensitive information types for given category.
-     * 
- */ - public void listInfoTypes(com.google.privacy.dlp.v2beta1.ListInfoTypesRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getListInfoTypesMethodHelper(), responseObserver); - } - - /** - *
-     * Returns the list of root categories of sensitive information.
-     * 
- */ - public void listRootCategories(com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getListRootCategoriesMethodHelper(), responseObserver); - } - - @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() { - return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) - .addMethod( - getInspectContentMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.privacy.dlp.v2beta1.InspectContentRequest, - com.google.privacy.dlp.v2beta1.InspectContentResponse>( - this, METHODID_INSPECT_CONTENT))) - .addMethod( - getRedactContentMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.privacy.dlp.v2beta1.RedactContentRequest, - com.google.privacy.dlp.v2beta1.RedactContentResponse>( - this, METHODID_REDACT_CONTENT))) - .addMethod( - getDeidentifyContentMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.privacy.dlp.v2beta1.DeidentifyContentRequest, - com.google.privacy.dlp.v2beta1.DeidentifyContentResponse>( - this, METHODID_DEIDENTIFY_CONTENT))) - .addMethod( - getCreateInspectOperationMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest, - com.google.longrunning.Operation>( - this, METHODID_CREATE_INSPECT_OPERATION))) - .addMethod( - getAnalyzeDataSourceRiskMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest, - com.google.longrunning.Operation>( - this, METHODID_ANALYZE_DATA_SOURCE_RISK))) - .addMethod( - getListInspectFindingsMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest, - com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse>( - this, METHODID_LIST_INSPECT_FINDINGS))) - .addMethod( - getListInfoTypesMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.privacy.dlp.v2beta1.ListInfoTypesRequest, - com.google.privacy.dlp.v2beta1.ListInfoTypesResponse>( - this, METHODID_LIST_INFO_TYPES))) - .addMethod( - getListRootCategoriesMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest, - com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse>( - this, METHODID_LIST_ROOT_CATEGORIES))) - .build(); - } - } - - /** - *
-   * The DLP API is a service that allows clients
-   * to detect the presence of Personally Identifiable Information (PII) and other
-   * privacy-sensitive data in user-supplied, unstructured data streams, like text
-   * blocks or images.
-   * The service also includes methods for sensitive data redaction and
-   * scheduling of data scans on Google Cloud Platform based data sets.
-   * 
- */ - public static final class DlpServiceStub extends io.grpc.stub.AbstractStub { - private DlpServiceStub(io.grpc.Channel channel) { - super(channel); - } - - private DlpServiceStub(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected DlpServiceStub build(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { - return new DlpServiceStub(channel, callOptions); - } - - /** - *
-     * Finds potentially sensitive info in a list of strings.
-     * This method has limits on input size, processing time, and output size.
-     * 
- */ - public void inspectContent(com.google.privacy.dlp.v2beta1.InspectContentRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getInspectContentMethodHelper(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Redacts potentially sensitive info from a list of strings.
-     * This method has limits on input size, processing time, and output size.
-     * 
- */ - public void redactContent(com.google.privacy.dlp.v2beta1.RedactContentRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getRedactContentMethodHelper(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * De-identifies potentially sensitive info from a list of strings.
-     * This method has limits on input size and output size.
-     * 
- */ - public void deidentifyContent(com.google.privacy.dlp.v2beta1.DeidentifyContentRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getDeidentifyContentMethodHelper(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Schedules a job scanning content in a Google Cloud Platform data
-     * repository.
-     * 
- */ - public void createInspectOperation(com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getCreateInspectOperationMethodHelper(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Schedules a job to compute risk analysis metrics over content in a Google
-     * Cloud Platform repository.
-     * 
- */ - public void analyzeDataSourceRisk(com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getAnalyzeDataSourceRiskMethodHelper(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Returns list of results for given inspect operation result set id.
-     * 
- */ - public void listInspectFindings(com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getListInspectFindingsMethodHelper(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Returns sensitive information types for given category.
-     * 
- */ - public void listInfoTypes(com.google.privacy.dlp.v2beta1.ListInfoTypesRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getListInfoTypesMethodHelper(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Returns the list of root categories of sensitive information.
-     * 
- */ - public void listRootCategories(com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnaryCall( - getChannel().newCall(getListRootCategoriesMethodHelper(), getCallOptions()), request, responseObserver); - } - } - - /** - *
-   * The DLP API is a service that allows clients
-   * to detect the presence of Personally Identifiable Information (PII) and other
-   * privacy-sensitive data in user-supplied, unstructured data streams, like text
-   * blocks or images.
-   * The service also includes methods for sensitive data redaction and
-   * scheduling of data scans on Google Cloud Platform based data sets.
-   * 
- */ - public static final class DlpServiceBlockingStub extends io.grpc.stub.AbstractStub { - private DlpServiceBlockingStub(io.grpc.Channel channel) { - super(channel); - } - - private DlpServiceBlockingStub(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected DlpServiceBlockingStub build(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { - return new DlpServiceBlockingStub(channel, callOptions); - } - - /** - *
-     * Finds potentially sensitive info in a list of strings.
-     * This method has limits on input size, processing time, and output size.
-     * 
- */ - public com.google.privacy.dlp.v2beta1.InspectContentResponse inspectContent(com.google.privacy.dlp.v2beta1.InspectContentRequest request) { - return blockingUnaryCall( - getChannel(), getInspectContentMethodHelper(), getCallOptions(), request); - } - - /** - *
-     * Redacts potentially sensitive info from a list of strings.
-     * This method has limits on input size, processing time, and output size.
-     * 
- */ - public com.google.privacy.dlp.v2beta1.RedactContentResponse redactContent(com.google.privacy.dlp.v2beta1.RedactContentRequest request) { - return blockingUnaryCall( - getChannel(), getRedactContentMethodHelper(), getCallOptions(), request); - } - - /** - *
-     * De-identifies potentially sensitive info from a list of strings.
-     * This method has limits on input size and output size.
-     * 
- */ - public com.google.privacy.dlp.v2beta1.DeidentifyContentResponse deidentifyContent(com.google.privacy.dlp.v2beta1.DeidentifyContentRequest request) { - return blockingUnaryCall( - getChannel(), getDeidentifyContentMethodHelper(), getCallOptions(), request); - } - - /** - *
-     * Schedules a job scanning content in a Google Cloud Platform data
-     * repository.
-     * 
- */ - public com.google.longrunning.Operation createInspectOperation(com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest request) { - return blockingUnaryCall( - getChannel(), getCreateInspectOperationMethodHelper(), getCallOptions(), request); - } - - /** - *
-     * Schedules a job to compute risk analysis metrics over content in a Google
-     * Cloud Platform repository.
-     * 
- */ - public com.google.longrunning.Operation analyzeDataSourceRisk(com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest request) { - return blockingUnaryCall( - getChannel(), getAnalyzeDataSourceRiskMethodHelper(), getCallOptions(), request); - } - - /** - *
-     * Returns list of results for given inspect operation result set id.
-     * 
- */ - public com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse listInspectFindings(com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest request) { - return blockingUnaryCall( - getChannel(), getListInspectFindingsMethodHelper(), getCallOptions(), request); - } - - /** - *
-     * Returns sensitive information types for given category.
-     * 
- */ - public com.google.privacy.dlp.v2beta1.ListInfoTypesResponse listInfoTypes(com.google.privacy.dlp.v2beta1.ListInfoTypesRequest request) { - return blockingUnaryCall( - getChannel(), getListInfoTypesMethodHelper(), getCallOptions(), request); - } - - /** - *
-     * Returns the list of root categories of sensitive information.
-     * 
- */ - public com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse listRootCategories(com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest request) { - return blockingUnaryCall( - getChannel(), getListRootCategoriesMethodHelper(), getCallOptions(), request); - } - } - - /** - *
-   * The DLP API is a service that allows clients
-   * to detect the presence of Personally Identifiable Information (PII) and other
-   * privacy-sensitive data in user-supplied, unstructured data streams, like text
-   * blocks or images.
-   * The service also includes methods for sensitive data redaction and
-   * scheduling of data scans on Google Cloud Platform based data sets.
-   * 
- */ - public static final class DlpServiceFutureStub extends io.grpc.stub.AbstractStub { - private DlpServiceFutureStub(io.grpc.Channel channel) { - super(channel); - } - - private DlpServiceFutureStub(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected DlpServiceFutureStub build(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { - return new DlpServiceFutureStub(channel, callOptions); - } - - /** - *
-     * Finds potentially sensitive info in a list of strings.
-     * This method has limits on input size, processing time, and output size.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture inspectContent( - com.google.privacy.dlp.v2beta1.InspectContentRequest request) { - return futureUnaryCall( - getChannel().newCall(getInspectContentMethodHelper(), getCallOptions()), request); - } - - /** - *
-     * Redacts potentially sensitive info from a list of strings.
-     * This method has limits on input size, processing time, and output size.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture redactContent( - com.google.privacy.dlp.v2beta1.RedactContentRequest request) { - return futureUnaryCall( - getChannel().newCall(getRedactContentMethodHelper(), getCallOptions()), request); - } - - /** - *
-     * De-identifies potentially sensitive info from a list of strings.
-     * This method has limits on input size and output size.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture deidentifyContent( - com.google.privacy.dlp.v2beta1.DeidentifyContentRequest request) { - return futureUnaryCall( - getChannel().newCall(getDeidentifyContentMethodHelper(), getCallOptions()), request); - } - - /** - *
-     * Schedules a job scanning content in a Google Cloud Platform data
-     * repository.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture createInspectOperation( - com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest request) { - return futureUnaryCall( - getChannel().newCall(getCreateInspectOperationMethodHelper(), getCallOptions()), request); - } - - /** - *
-     * Schedules a job to compute risk analysis metrics over content in a Google
-     * Cloud Platform repository.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture analyzeDataSourceRisk( - com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest request) { - return futureUnaryCall( - getChannel().newCall(getAnalyzeDataSourceRiskMethodHelper(), getCallOptions()), request); - } - - /** - *
-     * Returns list of results for given inspect operation result set id.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture listInspectFindings( - com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest request) { - return futureUnaryCall( - getChannel().newCall(getListInspectFindingsMethodHelper(), getCallOptions()), request); - } - - /** - *
-     * Returns sensitive information types for given category.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture listInfoTypes( - com.google.privacy.dlp.v2beta1.ListInfoTypesRequest request) { - return futureUnaryCall( - getChannel().newCall(getListInfoTypesMethodHelper(), getCallOptions()), request); - } - - /** - *
-     * Returns the list of root categories of sensitive information.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture listRootCategories( - com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest request) { - return futureUnaryCall( - getChannel().newCall(getListRootCategoriesMethodHelper(), getCallOptions()), request); - } - } - - private static final int METHODID_INSPECT_CONTENT = 0; - private static final int METHODID_REDACT_CONTENT = 1; - private static final int METHODID_DEIDENTIFY_CONTENT = 2; - private static final int METHODID_CREATE_INSPECT_OPERATION = 3; - private static final int METHODID_ANALYZE_DATA_SOURCE_RISK = 4; - private static final int METHODID_LIST_INSPECT_FINDINGS = 5; - private static final int METHODID_LIST_INFO_TYPES = 6; - private static final int METHODID_LIST_ROOT_CATEGORIES = 7; - - private static final class MethodHandlers implements - io.grpc.stub.ServerCalls.UnaryMethod, - io.grpc.stub.ServerCalls.ServerStreamingMethod, - io.grpc.stub.ServerCalls.ClientStreamingMethod, - io.grpc.stub.ServerCalls.BidiStreamingMethod { - private final DlpServiceImplBase serviceImpl; - private final int methodId; - - MethodHandlers(DlpServiceImplBase serviceImpl, int methodId) { - this.serviceImpl = serviceImpl; - this.methodId = methodId; - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - case METHODID_INSPECT_CONTENT: - serviceImpl.inspectContent((com.google.privacy.dlp.v2beta1.InspectContentRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_REDACT_CONTENT: - serviceImpl.redactContent((com.google.privacy.dlp.v2beta1.RedactContentRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_DEIDENTIFY_CONTENT: - serviceImpl.deidentifyContent((com.google.privacy.dlp.v2beta1.DeidentifyContentRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_CREATE_INSPECT_OPERATION: - serviceImpl.createInspectOperation((com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_ANALYZE_DATA_SOURCE_RISK: - serviceImpl.analyzeDataSourceRisk((com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_INSPECT_FINDINGS: - serviceImpl.listInspectFindings((com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_INFO_TYPES: - serviceImpl.listInfoTypes((com.google.privacy.dlp.v2beta1.ListInfoTypesRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_ROOT_CATEGORIES: - serviceImpl.listRootCategories((com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - default: - throw new AssertionError(); - } - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public io.grpc.stub.StreamObserver invoke( - io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - default: - throw new AssertionError(); - } - } - } - - private static abstract class DlpServiceBaseDescriptorSupplier - implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { - DlpServiceBaseDescriptorSupplier() {} - - @java.lang.Override - public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.getDescriptor(); - } - - @java.lang.Override - public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { - return getFileDescriptor().findServiceByName("DlpService"); - } - } - - private static final class DlpServiceFileDescriptorSupplier - extends DlpServiceBaseDescriptorSupplier { - DlpServiceFileDescriptorSupplier() {} - } - - private static final class DlpServiceMethodDescriptorSupplier - extends DlpServiceBaseDescriptorSupplier - implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { - private final String methodName; - - DlpServiceMethodDescriptorSupplier(String methodName) { - this.methodName = methodName; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { - return getServiceDescriptor().findMethodByName(methodName); - } - } - - private static volatile io.grpc.ServiceDescriptor serviceDescriptor; - - public static io.grpc.ServiceDescriptor getServiceDescriptor() { - io.grpc.ServiceDescriptor result = serviceDescriptor; - if (result == null) { - synchronized (DlpServiceGrpc.class) { - result = serviceDescriptor; - if (result == null) { - serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) - .setSchemaDescriptor(new DlpServiceFileDescriptorSupplier()) - .addMethod(getInspectContentMethodHelper()) - .addMethod(getRedactContentMethodHelper()) - .addMethod(getDeidentifyContentMethodHelper()) - .addMethod(getCreateInspectOperationMethodHelper()) - .addMethod(getAnalyzeDataSourceRiskMethodHelper()) - .addMethod(getListInspectFindingsMethodHelper()) - .addMethod(getListInfoTypesMethodHelper()) - .addMethod(getListRootCategoriesMethodHelper()) - .build(); - } - } - } - return result; - } -} diff --git a/google-api-grpc/grpc-google-cloud-cloudiot-v1/pom.xml b/google-api-grpc/grpc-google-cloud-iot-v1/pom.xml similarity index 77% rename from google-api-grpc/grpc-google-cloud-cloudiot-v1/pom.xml rename to google-api-grpc/grpc-google-cloud-iot-v1/pom.xml index f17ba8986003..562c1df967c3 100644 --- a/google-api-grpc/grpc-google-cloud-cloudiot-v1/pom.xml +++ b/google-api-grpc/grpc-google-cloud-iot-v1/pom.xml @@ -2,10 +2,10 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 - grpc-google-cloud-cloudiot-v1 - 0.12.1-SNAPSHOT - grpc-google-cloud-cloudiot-v1 - GRPC library for grpc-google-cloud-cloudiot-v1 + grpc-google-cloud-iot-v1 + 0.12.1-SNAPSHOT + grpc-google-cloud-iot-v1 + GRPC library for grpc-google-cloud-iot-v1 com.google.api.grpc google-api-grpc @@ -24,7 +24,7 @@ com.google.api.grpc - proto-google-cloud-cloudiot-v1 + proto-google-cloud-iot-v1 compile diff --git a/google-api-grpc/grpc-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceManagerGrpc.java b/google-api-grpc/grpc-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceManagerGrpc.java similarity index 100% rename from google-api-grpc/grpc-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceManagerGrpc.java rename to google-api-grpc/grpc-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceManagerGrpc.java diff --git a/google-api-grpc/grpc-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorGrpc.java b/google-api-grpc/grpc-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorGrpc.java index 3440b19728ef..e7b853ac2d2e 100644 --- a/google-api-grpc/grpc-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorGrpc.java +++ b/google-api-grpc/grpc-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorGrpc.java @@ -69,6 +69,43 @@ com.google.cloud.vision.v1.BatchAnnotateImagesResponse> getBatchAnnotateImagesMe } return getBatchAnnotateImagesMethod; } + @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") + @java.lang.Deprecated // Use {@link #getAsyncBatchAnnotateFilesMethod()} instead. + public static final io.grpc.MethodDescriptor METHOD_ASYNC_BATCH_ANNOTATE_FILES = getAsyncBatchAnnotateFilesMethodHelper(); + + private static volatile io.grpc.MethodDescriptor getAsyncBatchAnnotateFilesMethod; + + @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") + public static io.grpc.MethodDescriptor getAsyncBatchAnnotateFilesMethod() { + return getAsyncBatchAnnotateFilesMethodHelper(); + } + + private static io.grpc.MethodDescriptor getAsyncBatchAnnotateFilesMethodHelper() { + io.grpc.MethodDescriptor getAsyncBatchAnnotateFilesMethod; + if ((getAsyncBatchAnnotateFilesMethod = ImageAnnotatorGrpc.getAsyncBatchAnnotateFilesMethod) == null) { + synchronized (ImageAnnotatorGrpc.class) { + if ((getAsyncBatchAnnotateFilesMethod = ImageAnnotatorGrpc.getAsyncBatchAnnotateFilesMethod) == null) { + ImageAnnotatorGrpc.getAsyncBatchAnnotateFilesMethod = getAsyncBatchAnnotateFilesMethod = + io.grpc.MethodDescriptor.newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName( + "google.cloud.vision.v1.ImageAnnotator", "AsyncBatchAnnotateFiles")) + .setSampledToLocalTracing(true) + .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest.getDefaultInstance())) + .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new ImageAnnotatorMethodDescriptorSupplier("AsyncBatchAnnotateFiles")) + .build(); + } + } + } + return getAsyncBatchAnnotateFilesMethod; + } /** * Creates a new async stub that supports all call types for the service @@ -112,6 +149,21 @@ public void batchAnnotateImages(com.google.cloud.vision.v1.BatchAnnotateImagesRe asyncUnimplementedUnaryCall(getBatchAnnotateImagesMethodHelper(), responseObserver); } + /** + *
+     * Run asynchronous image detection and annotation for a list of generic
+     * files, such as PDF files, which may contain multiple pages and multiple
+     * images per page. Progress and results can be retrieved through the
+     * `google.longrunning.Operations` interface.
+     * `Operation.metadata` contains `OperationMetadata` (metadata).
+     * `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results).
+     * 
+ */ + public void asyncBatchAnnotateFiles(com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnimplementedUnaryCall(getAsyncBatchAnnotateFilesMethodHelper(), responseObserver); + } + @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() { return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) .addMethod( @@ -121,6 +173,13 @@ public void batchAnnotateImages(com.google.cloud.vision.v1.BatchAnnotateImagesRe com.google.cloud.vision.v1.BatchAnnotateImagesRequest, com.google.cloud.vision.v1.BatchAnnotateImagesResponse>( this, METHODID_BATCH_ANNOTATE_IMAGES))) + .addMethod( + getAsyncBatchAnnotateFilesMethodHelper(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest, + com.google.longrunning.Operation>( + this, METHODID_ASYNC_BATCH_ANNOTATE_FILES))) .build(); } } @@ -158,6 +217,22 @@ public void batchAnnotateImages(com.google.cloud.vision.v1.BatchAnnotateImagesRe asyncUnaryCall( getChannel().newCall(getBatchAnnotateImagesMethodHelper(), getCallOptions()), request, responseObserver); } + + /** + *
+     * Run asynchronous image detection and annotation for a list of generic
+     * files, such as PDF files, which may contain multiple pages and multiple
+     * images per page. Progress and results can be retrieved through the
+     * `google.longrunning.Operations` interface.
+     * `Operation.metadata` contains `OperationMetadata` (metadata).
+     * `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results).
+     * 
+ */ + public void asyncBatchAnnotateFiles(com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnaryCall( + getChannel().newCall(getAsyncBatchAnnotateFilesMethodHelper(), getCallOptions()), request, responseObserver); + } } /** @@ -192,6 +267,21 @@ public com.google.cloud.vision.v1.BatchAnnotateImagesResponse batchAnnotateImage return blockingUnaryCall( getChannel(), getBatchAnnotateImagesMethodHelper(), getCallOptions(), request); } + + /** + *
+     * Run asynchronous image detection and annotation for a list of generic
+     * files, such as PDF files, which may contain multiple pages and multiple
+     * images per page. Progress and results can be retrieved through the
+     * `google.longrunning.Operations` interface.
+     * `Operation.metadata` contains `OperationMetadata` (metadata).
+     * `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results).
+     * 
+ */ + public com.google.longrunning.Operation asyncBatchAnnotateFiles(com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest request) { + return blockingUnaryCall( + getChannel(), getAsyncBatchAnnotateFilesMethodHelper(), getCallOptions(), request); + } } /** @@ -227,9 +317,26 @@ public com.google.common.util.concurrent.ListenableFuture + * Run asynchronous image detection and annotation for a list of generic + * files, such as PDF files, which may contain multiple pages and multiple + * images per page. Progress and results can be retrieved through the + * `google.longrunning.Operations` interface. + * `Operation.metadata` contains `OperationMetadata` (metadata). + * `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). + * + */ + public com.google.common.util.concurrent.ListenableFuture asyncBatchAnnotateFiles( + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest request) { + return futureUnaryCall( + getChannel().newCall(getAsyncBatchAnnotateFilesMethodHelper(), getCallOptions()), request); + } } private static final int METHODID_BATCH_ANNOTATE_IMAGES = 0; + private static final int METHODID_ASYNC_BATCH_ANNOTATE_FILES = 1; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -252,6 +359,10 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv serviceImpl.batchAnnotateImages((com.google.cloud.vision.v1.BatchAnnotateImagesRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_ASYNC_BATCH_ANNOTATE_FILES: + serviceImpl.asyncBatchAnnotateFiles((com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; default: throw new AssertionError(); } @@ -314,6 +425,7 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) .setSchemaDescriptor(new ImageAnnotatorFileDescriptorSupplier()) .addMethod(getBatchAnnotateImagesMethodHelper()) + .addMethod(getAsyncBatchAnnotateFilesMethodHelper()) .build(); } } diff --git a/google-api-grpc/pom.xml b/google-api-grpc/pom.xml index 37c720b4f4cd..cee1b7c5f9f8 100644 --- a/google-api-grpc/pom.xml +++ b/google-api-grpc/pom.xml @@ -186,16 +186,6 @@ proto-google-cloud-datastore-v1 0.12.1-SNAPSHOT - - com.google.api.grpc - proto-google-cloud-dlp-v2beta1 - 0.12.1-SNAPSHOT - - - com.google.api.grpc - grpc-google-cloud-dlp-v2beta1 - 0.12.1-SNAPSHOT - com.google.api.grpc proto-google-cloud-dlp-v2 @@ -468,13 +458,13 @@ com.google.api.grpc - proto-google-cloud-cloudiot-v1 - 0.12.1-SNAPSHOT + proto-google-cloud-iot-v1 + 0.12.1-SNAPSHOT com.google.api.grpc - grpc-google-cloud-cloudiot-v1 - 0.12.1-SNAPSHOT + grpc-google-cloud-iot-v1 + 0.12.1-SNAPSHOT com.google.api.grpc @@ -508,7 +498,6 @@ grpc-google-cloud-dialogflow-v2 grpc-google-cloud-dialogflow-v2beta1 grpc-google-cloud-dlp-v2 - grpc-google-cloud-dlp-v2beta1 grpc-google-cloud-error-reporting-v1beta1 grpc-google-cloud-firestore-v1beta1 grpc-google-cloud-language-v1 @@ -533,7 +522,7 @@ grpc-google-cloud-vision-v1 grpc-google-cloud-vision-v1p1beta1 grpc-google-cloud-vision-v1p2beta1 - grpc-google-cloud-cloudiot-v1 + grpc-google-cloud-iot-v1 grpc-google-cloud-redis-v1beta1 grpc-google-cloud-websecurityscanner-v1alpha proto-google-cloud-bigquerydatatransfer-v1 @@ -545,7 +534,6 @@ proto-google-cloud-dialogflow-v2 proto-google-cloud-dialogflow-v2beta1 proto-google-cloud-dlp-v2 - proto-google-cloud-dlp-v2beta1 proto-google-cloud-error-reporting-v1beta1 proto-google-cloud-firestore-v1beta1 proto-google-cloud-language-v1 @@ -570,7 +558,7 @@ proto-google-cloud-vision-v1 proto-google-cloud-vision-v1p1beta1 proto-google-cloud-vision-v1p2beta1 - proto-google-cloud-cloudiot-v1 + proto-google-cloud-iot-v1 proto-google-cloud-redis-v1beta1 proto-google-cloud-websecurityscanner-v1alpha @@ -647,7 +635,7 @@ true true true - google-cloud-bom + ${project.artifactId} jar diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/pom.xml b/google-api-grpc/proto-google-cloud-dlp-v2beta1/pom.xml deleted file mode 100644 index fc23a6b340e9..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/pom.xml +++ /dev/null @@ -1,31 +0,0 @@ - - 4.0.0 - proto-google-cloud-dlp-v2beta1 - 0.12.1-SNAPSHOT - proto-google-cloud-dlp-v2beta1 - PROTO library for proto-google-cloud-dlp-v2beta1 - - com.google.api.grpc - google-api-grpc - 0.12.1-SNAPSHOT - - - - com.google.protobuf - protobuf-java - compile - - - com.google.api - api-common - compile - - - com.google.api.grpc - proto-google-common-protos - compile - - - \ No newline at end of file diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/AnalyzeDataSourceRiskRequest.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/AnalyzeDataSourceRiskRequest.java deleted file mode 100644 index 466352d42464..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/AnalyzeDataSourceRiskRequest.java +++ /dev/null @@ -1,855 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Request for creating a risk analysis operation.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest} - */ -public final class AnalyzeDataSourceRiskRequest extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest) - AnalyzeDataSourceRiskRequestOrBuilder { -private static final long serialVersionUID = 0L; - // Use AnalyzeDataSourceRiskRequest.newBuilder() to construct. - private AnalyzeDataSourceRiskRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private AnalyzeDataSourceRiskRequest() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private AnalyzeDataSourceRiskRequest( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder subBuilder = null; - if (privacyMetric_ != null) { - subBuilder = privacyMetric_.toBuilder(); - } - privacyMetric_ = input.readMessage(com.google.privacy.dlp.v2beta1.PrivacyMetric.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(privacyMetric_); - privacyMetric_ = subBuilder.buildPartial(); - } - - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.BigQueryTable.Builder subBuilder = null; - if (sourceTable_ != null) { - subBuilder = sourceTable_.toBuilder(); - } - sourceTable_ = input.readMessage(com.google.privacy.dlp.v2beta1.BigQueryTable.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(sourceTable_); - sourceTable_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_AnalyzeDataSourceRiskRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_AnalyzeDataSourceRiskRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest.class, com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest.Builder.class); - } - - public static final int PRIVACY_METRIC_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.PrivacyMetric privacyMetric_; - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public boolean hasPrivacyMetric() { - return privacyMetric_ != null; - } - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric getPrivacyMetric() { - return privacyMetric_ == null ? com.google.privacy.dlp.v2beta1.PrivacyMetric.getDefaultInstance() : privacyMetric_; - } - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder getPrivacyMetricOrBuilder() { - return getPrivacyMetric(); - } - - public static final int SOURCE_TABLE_FIELD_NUMBER = 3; - private com.google.privacy.dlp.v2beta1.BigQueryTable sourceTable_; - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public boolean hasSourceTable() { - return sourceTable_ != null; - } - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable getSourceTable() { - return sourceTable_ == null ? com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance() : sourceTable_; - } - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getSourceTableOrBuilder() { - return getSourceTable(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (privacyMetric_ != null) { - output.writeMessage(1, getPrivacyMetric()); - } - if (sourceTable_ != null) { - output.writeMessage(3, getSourceTable()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (privacyMetric_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getPrivacyMetric()); - } - if (sourceTable_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, getSourceTable()); - } - 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.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest other = (com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest) obj; - - boolean result = true; - result = result && (hasPrivacyMetric() == other.hasPrivacyMetric()); - if (hasPrivacyMetric()) { - result = result && getPrivacyMetric() - .equals(other.getPrivacyMetric()); - } - result = result && (hasSourceTable() == other.hasSourceTable()); - if (hasSourceTable()) { - result = result && getSourceTable() - .equals(other.getSourceTable()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasPrivacyMetric()) { - hash = (37 * hash) + PRIVACY_METRIC_FIELD_NUMBER; - hash = (53 * hash) + getPrivacyMetric().hashCode(); - } - if (hasSourceTable()) { - hash = (37 * hash) + SOURCE_TABLE_FIELD_NUMBER; - hash = (53 * hash) + getSourceTable().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest 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.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest 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.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest 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.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Request for creating a risk analysis operation.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest) - com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_AnalyzeDataSourceRiskRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_AnalyzeDataSourceRiskRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest.class, com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (privacyMetricBuilder_ == null) { - privacyMetric_ = null; - } else { - privacyMetric_ = null; - privacyMetricBuilder_ = null; - } - if (sourceTableBuilder_ == null) { - sourceTable_ = null; - } else { - sourceTable_ = null; - sourceTableBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_AnalyzeDataSourceRiskRequest_descriptor; - } - - public com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest build() { - com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest buildPartial() { - com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest result = new com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest(this); - if (privacyMetricBuilder_ == null) { - result.privacyMetric_ = privacyMetric_; - } else { - result.privacyMetric_ = privacyMetricBuilder_.build(); - } - if (sourceTableBuilder_ == null) { - result.sourceTable_ = sourceTable_; - } else { - result.sourceTable_ = sourceTableBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest) { - return mergeFrom((com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest other) { - if (other == com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest.getDefaultInstance()) return this; - if (other.hasPrivacyMetric()) { - mergePrivacyMetric(other.getPrivacyMetric()); - } - if (other.hasSourceTable()) { - mergeSourceTable(other.getSourceTable()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.PrivacyMetric privacyMetric_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric, com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder> privacyMetricBuilder_; - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public boolean hasPrivacyMetric() { - return privacyMetricBuilder_ != null || privacyMetric_ != null; - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric getPrivacyMetric() { - if (privacyMetricBuilder_ == null) { - return privacyMetric_ == null ? com.google.privacy.dlp.v2beta1.PrivacyMetric.getDefaultInstance() : privacyMetric_; - } else { - return privacyMetricBuilder_.getMessage(); - } - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public Builder setPrivacyMetric(com.google.privacy.dlp.v2beta1.PrivacyMetric value) { - if (privacyMetricBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - privacyMetric_ = value; - onChanged(); - } else { - privacyMetricBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public Builder setPrivacyMetric( - com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder builderForValue) { - if (privacyMetricBuilder_ == null) { - privacyMetric_ = builderForValue.build(); - onChanged(); - } else { - privacyMetricBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public Builder mergePrivacyMetric(com.google.privacy.dlp.v2beta1.PrivacyMetric value) { - if (privacyMetricBuilder_ == null) { - if (privacyMetric_ != null) { - privacyMetric_ = - com.google.privacy.dlp.v2beta1.PrivacyMetric.newBuilder(privacyMetric_).mergeFrom(value).buildPartial(); - } else { - privacyMetric_ = value; - } - onChanged(); - } else { - privacyMetricBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public Builder clearPrivacyMetric() { - if (privacyMetricBuilder_ == null) { - privacyMetric_ = null; - onChanged(); - } else { - privacyMetric_ = null; - privacyMetricBuilder_ = null; - } - - return this; - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder getPrivacyMetricBuilder() { - - onChanged(); - return getPrivacyMetricFieldBuilder().getBuilder(); - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder getPrivacyMetricOrBuilder() { - if (privacyMetricBuilder_ != null) { - return privacyMetricBuilder_.getMessageOrBuilder(); - } else { - return privacyMetric_ == null ? - com.google.privacy.dlp.v2beta1.PrivacyMetric.getDefaultInstance() : privacyMetric_; - } - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric, com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder> - getPrivacyMetricFieldBuilder() { - if (privacyMetricBuilder_ == null) { - privacyMetricBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric, com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder>( - getPrivacyMetric(), - getParentForChildren(), - isClean()); - privacyMetric_ = null; - } - return privacyMetricBuilder_; - } - - private com.google.privacy.dlp.v2beta1.BigQueryTable sourceTable_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder> sourceTableBuilder_; - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public boolean hasSourceTable() { - return sourceTableBuilder_ != null || sourceTable_ != null; - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable getSourceTable() { - if (sourceTableBuilder_ == null) { - return sourceTable_ == null ? com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance() : sourceTable_; - } else { - return sourceTableBuilder_.getMessage(); - } - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public Builder setSourceTable(com.google.privacy.dlp.v2beta1.BigQueryTable value) { - if (sourceTableBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - sourceTable_ = value; - onChanged(); - } else { - sourceTableBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public Builder setSourceTable( - com.google.privacy.dlp.v2beta1.BigQueryTable.Builder builderForValue) { - if (sourceTableBuilder_ == null) { - sourceTable_ = builderForValue.build(); - onChanged(); - } else { - sourceTableBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public Builder mergeSourceTable(com.google.privacy.dlp.v2beta1.BigQueryTable value) { - if (sourceTableBuilder_ == null) { - if (sourceTable_ != null) { - sourceTable_ = - com.google.privacy.dlp.v2beta1.BigQueryTable.newBuilder(sourceTable_).mergeFrom(value).buildPartial(); - } else { - sourceTable_ = value; - } - onChanged(); - } else { - sourceTableBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public Builder clearSourceTable() { - if (sourceTableBuilder_ == null) { - sourceTable_ = null; - onChanged(); - } else { - sourceTable_ = null; - sourceTableBuilder_ = null; - } - - return this; - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable.Builder getSourceTableBuilder() { - - onChanged(); - return getSourceTableFieldBuilder().getBuilder(); - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getSourceTableOrBuilder() { - if (sourceTableBuilder_ != null) { - return sourceTableBuilder_.getMessageOrBuilder(); - } else { - return sourceTable_ == null ? - com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance() : sourceTable_; - } - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder> - getSourceTableFieldBuilder() { - if (sourceTableBuilder_ == null) { - sourceTableBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder>( - getSourceTable(), - getParentForChildren(), - isClean()); - sourceTable_ = null; - } - return sourceTableBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest) - private static final com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest(); - } - - public static com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public AnalyzeDataSourceRiskRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new AnalyzeDataSourceRiskRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/AnalyzeDataSourceRiskRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/AnalyzeDataSourceRiskRequestOrBuilder.java deleted file mode 100644 index b3a9e6591191..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/AnalyzeDataSourceRiskRequestOrBuilder.java +++ /dev/null @@ -1,59 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface AnalyzeDataSourceRiskRequestOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - boolean hasPrivacyMetric(); - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetric getPrivacyMetric(); - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric privacy_metric = 1; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder getPrivacyMetricOrBuilder(); - - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - boolean hasSourceTable(); - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - com.google.privacy.dlp.v2beta1.BigQueryTable getSourceTable(); - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable source_table = 3; - */ - com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getSourceTableOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryOptions.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryOptions.java deleted file mode 100644 index ed2ef8bd3c8e..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryOptions.java +++ /dev/null @@ -1,1089 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Options defining BigQuery table and row identifiers.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.BigQueryOptions} - */ -public final class BigQueryOptions extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.BigQueryOptions) - BigQueryOptionsOrBuilder { -private static final long serialVersionUID = 0L; - // Use BigQueryOptions.newBuilder() to construct. - private BigQueryOptions(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private BigQueryOptions() { - identifyingFields_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private BigQueryOptions( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.BigQueryTable.Builder subBuilder = null; - if (tableReference_ != null) { - subBuilder = tableReference_.toBuilder(); - } - tableReference_ = input.readMessage(com.google.privacy.dlp.v2beta1.BigQueryTable.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(tableReference_); - tableReference_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - identifyingFields_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - identifyingFields_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry)); - 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_ & 0x00000002) == 0x00000002)) { - identifyingFields_ = java.util.Collections.unmodifiableList(identifyingFields_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_BigQueryOptions_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_BigQueryOptions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.BigQueryOptions.class, com.google.privacy.dlp.v2beta1.BigQueryOptions.Builder.class); - } - - private int bitField0_; - public static final int TABLE_REFERENCE_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.BigQueryTable tableReference_; - /** - *
-   * Complete BigQuery table reference.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public boolean hasTableReference() { - return tableReference_ != null; - } - /** - *
-   * Complete BigQuery table reference.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable getTableReference() { - return tableReference_ == null ? com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance() : tableReference_; - } - /** - *
-   * Complete BigQuery table reference.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getTableReferenceOrBuilder() { - return getTableReference(); - } - - public static final int IDENTIFYING_FIELDS_FIELD_NUMBER = 2; - private java.util.List identifyingFields_; - /** - *
-   * References to fields uniquely identifying rows within the table.
-   * Nested fields in the format, like `person.birthdate.year`, are allowed.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public java.util.List getIdentifyingFieldsList() { - return identifyingFields_; - } - /** - *
-   * References to fields uniquely identifying rows within the table.
-   * Nested fields in the format, like `person.birthdate.year`, are allowed.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public java.util.List - getIdentifyingFieldsOrBuilderList() { - return identifyingFields_; - } - /** - *
-   * References to fields uniquely identifying rows within the table.
-   * Nested fields in the format, like `person.birthdate.year`, are allowed.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public int getIdentifyingFieldsCount() { - return identifyingFields_.size(); - } - /** - *
-   * References to fields uniquely identifying rows within the table.
-   * Nested fields in the format, like `person.birthdate.year`, are allowed.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId getIdentifyingFields(int index) { - return identifyingFields_.get(index); - } - /** - *
-   * References to fields uniquely identifying rows within the table.
-   * Nested fields in the format, like `person.birthdate.year`, are allowed.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getIdentifyingFieldsOrBuilder( - int index) { - return identifyingFields_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (tableReference_ != null) { - output.writeMessage(1, getTableReference()); - } - for (int i = 0; i < identifyingFields_.size(); i++) { - output.writeMessage(2, identifyingFields_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (tableReference_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getTableReference()); - } - for (int i = 0; i < identifyingFields_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, identifyingFields_.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.privacy.dlp.v2beta1.BigQueryOptions)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.BigQueryOptions other = (com.google.privacy.dlp.v2beta1.BigQueryOptions) obj; - - boolean result = true; - result = result && (hasTableReference() == other.hasTableReference()); - if (hasTableReference()) { - result = result && getTableReference() - .equals(other.getTableReference()); - } - result = result && getIdentifyingFieldsList() - .equals(other.getIdentifyingFieldsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasTableReference()) { - hash = (37 * hash) + TABLE_REFERENCE_FIELD_NUMBER; - hash = (53 * hash) + getTableReference().hashCode(); - } - if (getIdentifyingFieldsCount() > 0) { - hash = (37 * hash) + IDENTIFYING_FIELDS_FIELD_NUMBER; - hash = (53 * hash) + getIdentifyingFieldsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.BigQueryOptions parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BigQueryOptions parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.BigQueryOptions parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BigQueryOptions 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.privacy.dlp.v2beta1.BigQueryOptions parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BigQueryOptions parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.BigQueryOptions parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BigQueryOptions 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.privacy.dlp.v2beta1.BigQueryOptions parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BigQueryOptions 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.privacy.dlp.v2beta1.BigQueryOptions parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BigQueryOptions parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.BigQueryOptions prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Options defining BigQuery table and row identifiers.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.BigQueryOptions} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.BigQueryOptions) - com.google.privacy.dlp.v2beta1.BigQueryOptionsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_BigQueryOptions_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_BigQueryOptions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.BigQueryOptions.class, com.google.privacy.dlp.v2beta1.BigQueryOptions.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.BigQueryOptions.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getIdentifyingFieldsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (tableReferenceBuilder_ == null) { - tableReference_ = null; - } else { - tableReference_ = null; - tableReferenceBuilder_ = null; - } - if (identifyingFieldsBuilder_ == null) { - identifyingFields_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - identifyingFieldsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_BigQueryOptions_descriptor; - } - - public com.google.privacy.dlp.v2beta1.BigQueryOptions getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.BigQueryOptions.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.BigQueryOptions build() { - com.google.privacy.dlp.v2beta1.BigQueryOptions result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.BigQueryOptions buildPartial() { - com.google.privacy.dlp.v2beta1.BigQueryOptions result = new com.google.privacy.dlp.v2beta1.BigQueryOptions(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (tableReferenceBuilder_ == null) { - result.tableReference_ = tableReference_; - } else { - result.tableReference_ = tableReferenceBuilder_.build(); - } - if (identifyingFieldsBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - identifyingFields_ = java.util.Collections.unmodifiableList(identifyingFields_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.identifyingFields_ = identifyingFields_; - } else { - result.identifyingFields_ = identifyingFieldsBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.BigQueryOptions) { - return mergeFrom((com.google.privacy.dlp.v2beta1.BigQueryOptions)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.BigQueryOptions other) { - if (other == com.google.privacy.dlp.v2beta1.BigQueryOptions.getDefaultInstance()) return this; - if (other.hasTableReference()) { - mergeTableReference(other.getTableReference()); - } - if (identifyingFieldsBuilder_ == null) { - if (!other.identifyingFields_.isEmpty()) { - if (identifyingFields_.isEmpty()) { - identifyingFields_ = other.identifyingFields_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureIdentifyingFieldsIsMutable(); - identifyingFields_.addAll(other.identifyingFields_); - } - onChanged(); - } - } else { - if (!other.identifyingFields_.isEmpty()) { - if (identifyingFieldsBuilder_.isEmpty()) { - identifyingFieldsBuilder_.dispose(); - identifyingFieldsBuilder_ = null; - identifyingFields_ = other.identifyingFields_; - bitField0_ = (bitField0_ & ~0x00000002); - identifyingFieldsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getIdentifyingFieldsFieldBuilder() : null; - } else { - identifyingFieldsBuilder_.addAllMessages(other.identifyingFields_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.BigQueryOptions parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.BigQueryOptions) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private com.google.privacy.dlp.v2beta1.BigQueryTable tableReference_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder> tableReferenceBuilder_; - /** - *
-     * Complete BigQuery table reference.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public boolean hasTableReference() { - return tableReferenceBuilder_ != null || tableReference_ != null; - } - /** - *
-     * Complete BigQuery table reference.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable getTableReference() { - if (tableReferenceBuilder_ == null) { - return tableReference_ == null ? com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance() : tableReference_; - } else { - return tableReferenceBuilder_.getMessage(); - } - } - /** - *
-     * Complete BigQuery table reference.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public Builder setTableReference(com.google.privacy.dlp.v2beta1.BigQueryTable value) { - if (tableReferenceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - tableReference_ = value; - onChanged(); - } else { - tableReferenceBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Complete BigQuery table reference.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public Builder setTableReference( - com.google.privacy.dlp.v2beta1.BigQueryTable.Builder builderForValue) { - if (tableReferenceBuilder_ == null) { - tableReference_ = builderForValue.build(); - onChanged(); - } else { - tableReferenceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Complete BigQuery table reference.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public Builder mergeTableReference(com.google.privacy.dlp.v2beta1.BigQueryTable value) { - if (tableReferenceBuilder_ == null) { - if (tableReference_ != null) { - tableReference_ = - com.google.privacy.dlp.v2beta1.BigQueryTable.newBuilder(tableReference_).mergeFrom(value).buildPartial(); - } else { - tableReference_ = value; - } - onChanged(); - } else { - tableReferenceBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Complete BigQuery table reference.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public Builder clearTableReference() { - if (tableReferenceBuilder_ == null) { - tableReference_ = null; - onChanged(); - } else { - tableReference_ = null; - tableReferenceBuilder_ = null; - } - - return this; - } - /** - *
-     * Complete BigQuery table reference.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable.Builder getTableReferenceBuilder() { - - onChanged(); - return getTableReferenceFieldBuilder().getBuilder(); - } - /** - *
-     * Complete BigQuery table reference.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getTableReferenceOrBuilder() { - if (tableReferenceBuilder_ != null) { - return tableReferenceBuilder_.getMessageOrBuilder(); - } else { - return tableReference_ == null ? - com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance() : tableReference_; - } - } - /** - *
-     * Complete BigQuery table reference.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder> - getTableReferenceFieldBuilder() { - if (tableReferenceBuilder_ == null) { - tableReferenceBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder>( - getTableReference(), - getParentForChildren(), - isClean()); - tableReference_ = null; - } - return tableReferenceBuilder_; - } - - private java.util.List identifyingFields_ = - java.util.Collections.emptyList(); - private void ensureIdentifyingFieldsIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - identifyingFields_ = new java.util.ArrayList(identifyingFields_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> identifyingFieldsBuilder_; - - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public java.util.List getIdentifyingFieldsList() { - if (identifyingFieldsBuilder_ == null) { - return java.util.Collections.unmodifiableList(identifyingFields_); - } else { - return identifyingFieldsBuilder_.getMessageList(); - } - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public int getIdentifyingFieldsCount() { - if (identifyingFieldsBuilder_ == null) { - return identifyingFields_.size(); - } else { - return identifyingFieldsBuilder_.getCount(); - } - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId getIdentifyingFields(int index) { - if (identifyingFieldsBuilder_ == null) { - return identifyingFields_.get(index); - } else { - return identifyingFieldsBuilder_.getMessage(index); - } - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public Builder setIdentifyingFields( - int index, com.google.privacy.dlp.v2beta1.FieldId value) { - if (identifyingFieldsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureIdentifyingFieldsIsMutable(); - identifyingFields_.set(index, value); - onChanged(); - } else { - identifyingFieldsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public Builder setIdentifyingFields( - int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (identifyingFieldsBuilder_ == null) { - ensureIdentifyingFieldsIsMutable(); - identifyingFields_.set(index, builderForValue.build()); - onChanged(); - } else { - identifyingFieldsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public Builder addIdentifyingFields(com.google.privacy.dlp.v2beta1.FieldId value) { - if (identifyingFieldsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureIdentifyingFieldsIsMutable(); - identifyingFields_.add(value); - onChanged(); - } else { - identifyingFieldsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public Builder addIdentifyingFields( - int index, com.google.privacy.dlp.v2beta1.FieldId value) { - if (identifyingFieldsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureIdentifyingFieldsIsMutable(); - identifyingFields_.add(index, value); - onChanged(); - } else { - identifyingFieldsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public Builder addIdentifyingFields( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (identifyingFieldsBuilder_ == null) { - ensureIdentifyingFieldsIsMutable(); - identifyingFields_.add(builderForValue.build()); - onChanged(); - } else { - identifyingFieldsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public Builder addIdentifyingFields( - int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (identifyingFieldsBuilder_ == null) { - ensureIdentifyingFieldsIsMutable(); - identifyingFields_.add(index, builderForValue.build()); - onChanged(); - } else { - identifyingFieldsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public Builder addAllIdentifyingFields( - java.lang.Iterable values) { - if (identifyingFieldsBuilder_ == null) { - ensureIdentifyingFieldsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, identifyingFields_); - onChanged(); - } else { - identifyingFieldsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public Builder clearIdentifyingFields() { - if (identifyingFieldsBuilder_ == null) { - identifyingFields_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - identifyingFieldsBuilder_.clear(); - } - return this; - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public Builder removeIdentifyingFields(int index) { - if (identifyingFieldsBuilder_ == null) { - ensureIdentifyingFieldsIsMutable(); - identifyingFields_.remove(index); - onChanged(); - } else { - identifyingFieldsBuilder_.remove(index); - } - return this; - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getIdentifyingFieldsBuilder( - int index) { - return getIdentifyingFieldsFieldBuilder().getBuilder(index); - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getIdentifyingFieldsOrBuilder( - int index) { - if (identifyingFieldsBuilder_ == null) { - return identifyingFields_.get(index); } else { - return identifyingFieldsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public java.util.List - getIdentifyingFieldsOrBuilderList() { - if (identifyingFieldsBuilder_ != null) { - return identifyingFieldsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(identifyingFields_); - } - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder addIdentifyingFieldsBuilder() { - return getIdentifyingFieldsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()); - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder addIdentifyingFieldsBuilder( - int index) { - return getIdentifyingFieldsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()); - } - /** - *
-     * References to fields uniquely identifying rows within the table.
-     * Nested fields in the format, like `person.birthdate.year`, are allowed.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - public java.util.List - getIdentifyingFieldsBuilderList() { - return getIdentifyingFieldsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getIdentifyingFieldsFieldBuilder() { - if (identifyingFieldsBuilder_ == null) { - identifyingFieldsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - identifyingFields_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - identifyingFields_ = null; - } - return identifyingFieldsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.BigQueryOptions) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.BigQueryOptions) - private static final com.google.privacy.dlp.v2beta1.BigQueryOptions DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.BigQueryOptions(); - } - - public static com.google.privacy.dlp.v2beta1.BigQueryOptions getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public BigQueryOptions parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BigQueryOptions(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.BigQueryOptions getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryOptionsOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryOptionsOrBuilder.java deleted file mode 100644 index 6c28561a3c7f..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryOptionsOrBuilder.java +++ /dev/null @@ -1,83 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface BigQueryOptionsOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.BigQueryOptions) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Complete BigQuery table reference.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - boolean hasTableReference(); - /** - *
-   * Complete BigQuery table reference.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - com.google.privacy.dlp.v2beta1.BigQueryTable getTableReference(); - /** - *
-   * Complete BigQuery table reference.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table_reference = 1; - */ - com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getTableReferenceOrBuilder(); - - /** - *
-   * References to fields uniquely identifying rows within the table.
-   * Nested fields in the format, like `person.birthdate.year`, are allowed.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - java.util.List - getIdentifyingFieldsList(); - /** - *
-   * References to fields uniquely identifying rows within the table.
-   * Nested fields in the format, like `person.birthdate.year`, are allowed.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - com.google.privacy.dlp.v2beta1.FieldId getIdentifyingFields(int index); - /** - *
-   * References to fields uniquely identifying rows within the table.
-   * Nested fields in the format, like `person.birthdate.year`, are allowed.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - int getIdentifyingFieldsCount(); - /** - *
-   * References to fields uniquely identifying rows within the table.
-   * Nested fields in the format, like `person.birthdate.year`, are allowed.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - java.util.List - getIdentifyingFieldsOrBuilderList(); - /** - *
-   * References to fields uniquely identifying rows within the table.
-   * Nested fields in the format, like `person.birthdate.year`, are allowed.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId identifying_fields = 2; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getIdentifyingFieldsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryTable.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryTable.java deleted file mode 100644 index e160354df33e..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryTable.java +++ /dev/null @@ -1,877 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Message defining the location of a BigQuery table. A table is uniquely
- * identified  by its project_id, dataset_id, and table_name. Within a query
- * a table is often referenced with a string in the format of:
- * `<project_id>:<dataset_id>.<table_id>` or
- * `<project_id>.<dataset_id>.<table_id>`.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.BigQueryTable} - */ -public final class BigQueryTable extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.BigQueryTable) - BigQueryTableOrBuilder { -private static final long serialVersionUID = 0L; - // Use BigQueryTable.newBuilder() to construct. - private BigQueryTable(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private BigQueryTable() { - projectId_ = ""; - datasetId_ = ""; - tableId_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private BigQueryTable( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - datasetId_ = s; - break; - } - case 26: { - java.lang.String s = input.readStringRequireUtf8(); - - tableId_ = s; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_BigQueryTable_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_BigQueryTable_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.BigQueryTable.class, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder.class); - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - *
-   * The Google Cloud Platform project ID of the project containing the table.
-   * If omitted, project ID is inferred from the API call.
-   * 
- * - * string project_id = 1; - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - *
-   * The Google Cloud Platform project ID of the project containing the table.
-   * If omitted, project ID is inferred from the API call.
-   * 
- * - * string project_id = 1; - */ - public com.google.protobuf.ByteString - getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DATASET_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object datasetId_; - /** - *
-   * Dataset ID of the table.
-   * 
- * - * string dataset_id = 2; - */ - public java.lang.String getDatasetId() { - java.lang.Object ref = datasetId_; - 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(); - datasetId_ = s; - return s; - } - } - /** - *
-   * Dataset ID of the table.
-   * 
- * - * string dataset_id = 2; - */ - public com.google.protobuf.ByteString - getDatasetIdBytes() { - java.lang.Object ref = datasetId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - datasetId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TABLE_ID_FIELD_NUMBER = 3; - private volatile java.lang.Object tableId_; - /** - *
-   * Name of the table.
-   * 
- * - * string table_id = 3; - */ - public java.lang.String getTableId() { - java.lang.Object ref = tableId_; - 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(); - tableId_ = s; - return s; - } - } - /** - *
-   * Name of the table.
-   * 
- * - * string table_id = 3; - */ - public com.google.protobuf.ByteString - getTableIdBytes() { - java.lang.Object ref = tableId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - tableId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getProjectIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (!getDatasetIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, datasetId_); - } - if (!getTableIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, tableId_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getProjectIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (!getDatasetIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, datasetId_); - } - if (!getTableIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, tableId_); - } - 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.privacy.dlp.v2beta1.BigQueryTable)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.BigQueryTable other = (com.google.privacy.dlp.v2beta1.BigQueryTable) obj; - - boolean result = true; - result = result && getProjectId() - .equals(other.getProjectId()); - result = result && getDatasetId() - .equals(other.getDatasetId()); - result = result && getTableId() - .equals(other.getTableId()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + DATASET_ID_FIELD_NUMBER; - hash = (53 * hash) + getDatasetId().hashCode(); - hash = (37 * hash) + TABLE_ID_FIELD_NUMBER; - hash = (53 * hash) + getTableId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.BigQueryTable parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BigQueryTable parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.BigQueryTable parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BigQueryTable 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.privacy.dlp.v2beta1.BigQueryTable parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BigQueryTable parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.BigQueryTable parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BigQueryTable 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.privacy.dlp.v2beta1.BigQueryTable parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BigQueryTable 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.privacy.dlp.v2beta1.BigQueryTable parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BigQueryTable parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.BigQueryTable prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Message defining the location of a BigQuery table. A table is uniquely
-   * identified  by its project_id, dataset_id, and table_name. Within a query
-   * a table is often referenced with a string in the format of:
-   * `<project_id>:<dataset_id>.<table_id>` or
-   * `<project_id>.<dataset_id>.<table_id>`.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.BigQueryTable} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.BigQueryTable) - com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_BigQueryTable_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_BigQueryTable_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.BigQueryTable.class, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.BigQueryTable.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - projectId_ = ""; - - datasetId_ = ""; - - tableId_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_BigQueryTable_descriptor; - } - - public com.google.privacy.dlp.v2beta1.BigQueryTable getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.BigQueryTable build() { - com.google.privacy.dlp.v2beta1.BigQueryTable result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.BigQueryTable buildPartial() { - com.google.privacy.dlp.v2beta1.BigQueryTable result = new com.google.privacy.dlp.v2beta1.BigQueryTable(this); - result.projectId_ = projectId_; - result.datasetId_ = datasetId_; - result.tableId_ = tableId_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.BigQueryTable) { - return mergeFrom((com.google.privacy.dlp.v2beta1.BigQueryTable)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.BigQueryTable other) { - if (other == com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance()) return this; - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getDatasetId().isEmpty()) { - datasetId_ = other.datasetId_; - onChanged(); - } - if (!other.getTableId().isEmpty()) { - tableId_ = other.tableId_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.BigQueryTable parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.BigQueryTable) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object projectId_ = ""; - /** - *
-     * The Google Cloud Platform project ID of the project containing the table.
-     * If omitted, project ID is inferred from the API call.
-     * 
- * - * string project_id = 1; - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * The Google Cloud Platform project ID of the project containing the table.
-     * If omitted, project ID is inferred from the API call.
-     * 
- * - * string project_id = 1; - */ - public com.google.protobuf.ByteString - getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * The Google Cloud Platform project ID of the project containing the table.
-     * If omitted, project ID is inferred from the API call.
-     * 
- * - * string project_id = 1; - */ - public Builder setProjectId( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - *
-     * The Google Cloud Platform project ID of the project containing the table.
-     * If omitted, project ID is inferred from the API call.
-     * 
- * - * string project_id = 1; - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - *
-     * The Google Cloud Platform project ID of the project containing the table.
-     * If omitted, project ID is inferred from the API call.
-     * 
- * - * string project_id = 1; - */ - public Builder setProjectIdBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object datasetId_ = ""; - /** - *
-     * Dataset ID of the table.
-     * 
- * - * string dataset_id = 2; - */ - public java.lang.String getDatasetId() { - java.lang.Object ref = datasetId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - datasetId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * Dataset ID of the table.
-     * 
- * - * string dataset_id = 2; - */ - public com.google.protobuf.ByteString - getDatasetIdBytes() { - java.lang.Object ref = datasetId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - datasetId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * Dataset ID of the table.
-     * 
- * - * string dataset_id = 2; - */ - public Builder setDatasetId( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - datasetId_ = value; - onChanged(); - return this; - } - /** - *
-     * Dataset ID of the table.
-     * 
- * - * string dataset_id = 2; - */ - public Builder clearDatasetId() { - - datasetId_ = getDefaultInstance().getDatasetId(); - onChanged(); - return this; - } - /** - *
-     * Dataset ID of the table.
-     * 
- * - * string dataset_id = 2; - */ - public Builder setDatasetIdBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - datasetId_ = value; - onChanged(); - return this; - } - - private java.lang.Object tableId_ = ""; - /** - *
-     * Name of the table.
-     * 
- * - * string table_id = 3; - */ - public java.lang.String getTableId() { - java.lang.Object ref = tableId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - tableId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * Name of the table.
-     * 
- * - * string table_id = 3; - */ - public com.google.protobuf.ByteString - getTableIdBytes() { - java.lang.Object ref = tableId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - tableId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * Name of the table.
-     * 
- * - * string table_id = 3; - */ - public Builder setTableId( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - tableId_ = value; - onChanged(); - return this; - } - /** - *
-     * Name of the table.
-     * 
- * - * string table_id = 3; - */ - public Builder clearTableId() { - - tableId_ = getDefaultInstance().getTableId(); - onChanged(); - return this; - } - /** - *
-     * Name of the table.
-     * 
- * - * string table_id = 3; - */ - public Builder setTableIdBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - tableId_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.BigQueryTable) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.BigQueryTable) - private static final com.google.privacy.dlp.v2beta1.BigQueryTable DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.BigQueryTable(); - } - - public static com.google.privacy.dlp.v2beta1.BigQueryTable getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public BigQueryTable parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BigQueryTable(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.BigQueryTable getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryTableOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryTableOrBuilder.java deleted file mode 100644 index fe2e1bb954f8..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BigQueryTableOrBuilder.java +++ /dev/null @@ -1,65 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface BigQueryTableOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.BigQueryTable) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The Google Cloud Platform project ID of the project containing the table.
-   * If omitted, project ID is inferred from the API call.
-   * 
- * - * string project_id = 1; - */ - java.lang.String getProjectId(); - /** - *
-   * The Google Cloud Platform project ID of the project containing the table.
-   * If omitted, project ID is inferred from the API call.
-   * 
- * - * string project_id = 1; - */ - com.google.protobuf.ByteString - getProjectIdBytes(); - - /** - *
-   * Dataset ID of the table.
-   * 
- * - * string dataset_id = 2; - */ - java.lang.String getDatasetId(); - /** - *
-   * Dataset ID of the table.
-   * 
- * - * string dataset_id = 2; - */ - com.google.protobuf.ByteString - getDatasetIdBytes(); - - /** - *
-   * Name of the table.
-   * 
- * - * string table_id = 3; - */ - java.lang.String getTableId(); - /** - *
-   * Name of the table.
-   * 
- * - * string table_id = 3; - */ - com.google.protobuf.ByteString - getTableIdBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BucketingConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BucketingConfig.java deleted file mode 100644 index d4a5b793fbac..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BucketingConfig.java +++ /dev/null @@ -1,1946 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Generalization function that buckets values based on ranges. The ranges and
- * replacement values are dynamically provided by the user for custom behavior,
- * such as 1-30 -> LOW 31-65 -> MEDIUM 66-100 -> HIGH
- * This can be used on
- * data of type: number, long, string, timestamp.
- * If the bound `Value` type differs from the type of data being transformed, we
- * will first attempt converting the type of the data to be transformed to match
- * the type of the bound before comparing.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.BucketingConfig} - */ -public final class BucketingConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.BucketingConfig) - BucketingConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use BucketingConfig.newBuilder() to construct. - private BucketingConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private BucketingConfig() { - buckets_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private BucketingConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - buckets_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - buckets_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.parser(), extensionRegistry)); - 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) == 0x00000001)) { - buckets_ = java.util.Collections.unmodifiableList(buckets_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_BucketingConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_BucketingConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.BucketingConfig.class, com.google.privacy.dlp.v2beta1.BucketingConfig.Builder.class); - } - - public interface BucketOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.BucketingConfig.Bucket) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Lower bound of the range, inclusive. Type should be the same as max if
-     * used.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - boolean hasMin(); - /** - *
-     * Lower bound of the range, inclusive. Type should be the same as max if
-     * used.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - com.google.privacy.dlp.v2beta1.Value getMin(); - /** - *
-     * Lower bound of the range, inclusive. Type should be the same as max if
-     * used.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getMinOrBuilder(); - - /** - *
-     * Upper bound of the range, exclusive; type must match min.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - boolean hasMax(); - /** - *
-     * Upper bound of the range, exclusive; type must match min.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - com.google.privacy.dlp.v2beta1.Value getMax(); - /** - *
-     * Upper bound of the range, exclusive; type must match min.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getMaxOrBuilder(); - - /** - *
-     * Replacement value for this bucket. If not provided
-     * the default behavior will be to hyphenate the min-max range.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - boolean hasReplacementValue(); - /** - *
-     * Replacement value for this bucket. If not provided
-     * the default behavior will be to hyphenate the min-max range.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - com.google.privacy.dlp.v2beta1.Value getReplacementValue(); - /** - *
-     * Replacement value for this bucket. If not provided
-     * the default behavior will be to hyphenate the min-max range.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getReplacementValueOrBuilder(); - } - /** - *
-   * Buckets represented as ranges, along with replacement values. Ranges must
-   * be non-overlapping.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.BucketingConfig.Bucket} - */ - public static final class Bucket extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.BucketingConfig.Bucket) - BucketOrBuilder { - private static final long serialVersionUID = 0L; - // Use Bucket.newBuilder() to construct. - private Bucket(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Bucket() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Bucket( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.Value.Builder subBuilder = null; - if (min_ != null) { - subBuilder = min_.toBuilder(); - } - min_ = input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(min_); - min_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.Value.Builder subBuilder = null; - if (max_ != null) { - subBuilder = max_.toBuilder(); - } - max_ = input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(max_); - max_ = subBuilder.buildPartial(); - } - - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.Value.Builder subBuilder = null; - if (replacementValue_ != null) { - subBuilder = replacementValue_.toBuilder(); - } - replacementValue_ = input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(replacementValue_); - replacementValue_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_BucketingConfig_Bucket_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_BucketingConfig_Bucket_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.class, com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder.class); - } - - public static final int MIN_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.Value min_; - /** - *
-     * Lower bound of the range, inclusive. Type should be the same as max if
-     * used.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public boolean hasMin() { - return min_ != null; - } - /** - *
-     * Lower bound of the range, inclusive. Type should be the same as max if
-     * used.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getMin() { - return min_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : min_; - } - /** - *
-     * Lower bound of the range, inclusive. Type should be the same as max if
-     * used.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getMinOrBuilder() { - return getMin(); - } - - public static final int MAX_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.Value max_; - /** - *
-     * Upper bound of the range, exclusive; type must match min.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public boolean hasMax() { - return max_ != null; - } - /** - *
-     * Upper bound of the range, exclusive; type must match min.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public com.google.privacy.dlp.v2beta1.Value getMax() { - return max_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : max_; - } - /** - *
-     * Upper bound of the range, exclusive; type must match min.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getMaxOrBuilder() { - return getMax(); - } - - public static final int REPLACEMENT_VALUE_FIELD_NUMBER = 3; - private com.google.privacy.dlp.v2beta1.Value replacementValue_; - /** - *
-     * Replacement value for this bucket. If not provided
-     * the default behavior will be to hyphenate the min-max range.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public boolean hasReplacementValue() { - return replacementValue_ != null; - } - /** - *
-     * Replacement value for this bucket. If not provided
-     * the default behavior will be to hyphenate the min-max range.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public com.google.privacy.dlp.v2beta1.Value getReplacementValue() { - return replacementValue_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : replacementValue_; - } - /** - *
-     * Replacement value for this bucket. If not provided
-     * the default behavior will be to hyphenate the min-max range.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getReplacementValueOrBuilder() { - return getReplacementValue(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (min_ != null) { - output.writeMessage(1, getMin()); - } - if (max_ != null) { - output.writeMessage(2, getMax()); - } - if (replacementValue_ != null) { - output.writeMessage(3, getReplacementValue()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (min_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getMin()); - } - if (max_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getMax()); - } - if (replacementValue_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, getReplacementValue()); - } - 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.privacy.dlp.v2beta1.BucketingConfig.Bucket)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket other = (com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket) obj; - - boolean result = true; - result = result && (hasMin() == other.hasMin()); - if (hasMin()) { - result = result && getMin() - .equals(other.getMin()); - } - result = result && (hasMax() == other.hasMax()); - if (hasMax()) { - result = result && getMax() - .equals(other.getMax()); - } - result = result && (hasReplacementValue() == other.hasReplacementValue()); - if (hasReplacementValue()) { - result = result && getReplacementValue() - .equals(other.getReplacementValue()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasMin()) { - hash = (37 * hash) + MIN_FIELD_NUMBER; - hash = (53 * hash) + getMin().hashCode(); - } - if (hasMax()) { - hash = (37 * hash) + MAX_FIELD_NUMBER; - hash = (53 * hash) + getMax().hashCode(); - } - if (hasReplacementValue()) { - hash = (37 * hash) + REPLACEMENT_VALUE_FIELD_NUMBER; - hash = (53 * hash) + getReplacementValue().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket 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.privacy.dlp.v2beta1.BucketingConfig.Bucket parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket 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.privacy.dlp.v2beta1.BucketingConfig.Bucket parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket 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.privacy.dlp.v2beta1.BucketingConfig.Bucket parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * Buckets represented as ranges, along with replacement values. Ranges must
-     * be non-overlapping.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.BucketingConfig.Bucket} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.BucketingConfig.Bucket) - com.google.privacy.dlp.v2beta1.BucketingConfig.BucketOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_BucketingConfig_Bucket_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_BucketingConfig_Bucket_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.class, com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (minBuilder_ == null) { - min_ = null; - } else { - min_ = null; - minBuilder_ = null; - } - if (maxBuilder_ == null) { - max_ = null; - } else { - max_ = null; - maxBuilder_ = null; - } - if (replacementValueBuilder_ == null) { - replacementValue_ = null; - } else { - replacementValue_ = null; - replacementValueBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_BucketingConfig_Bucket_descriptor; - } - - public com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket build() { - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket buildPartial() { - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket result = new com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket(this); - if (minBuilder_ == null) { - result.min_ = min_; - } else { - result.min_ = minBuilder_.build(); - } - if (maxBuilder_ == null) { - result.max_ = max_; - } else { - result.max_ = maxBuilder_.build(); - } - if (replacementValueBuilder_ == null) { - result.replacementValue_ = replacementValue_; - } else { - result.replacementValue_ = replacementValueBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket) { - return mergeFrom((com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket other) { - if (other == com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.getDefaultInstance()) return this; - if (other.hasMin()) { - mergeMin(other.getMin()); - } - if (other.hasMax()) { - mergeMax(other.getMax()); - } - if (other.hasReplacementValue()) { - mergeReplacementValue(other.getReplacementValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.Value min_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> minBuilder_; - /** - *
-       * Lower bound of the range, inclusive. Type should be the same as max if
-       * used.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public boolean hasMin() { - return minBuilder_ != null || min_ != null; - } - /** - *
-       * Lower bound of the range, inclusive. Type should be the same as max if
-       * used.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getMin() { - if (minBuilder_ == null) { - return min_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : min_; - } else { - return minBuilder_.getMessage(); - } - } - /** - *
-       * Lower bound of the range, inclusive. Type should be the same as max if
-       * used.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public Builder setMin(com.google.privacy.dlp.v2beta1.Value value) { - if (minBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - min_ = value; - onChanged(); - } else { - minBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Lower bound of the range, inclusive. Type should be the same as max if
-       * used.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public Builder setMin( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (minBuilder_ == null) { - min_ = builderForValue.build(); - onChanged(); - } else { - minBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Lower bound of the range, inclusive. Type should be the same as max if
-       * used.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public Builder mergeMin(com.google.privacy.dlp.v2beta1.Value value) { - if (minBuilder_ == null) { - if (min_ != null) { - min_ = - com.google.privacy.dlp.v2beta1.Value.newBuilder(min_).mergeFrom(value).buildPartial(); - } else { - min_ = value; - } - onChanged(); - } else { - minBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Lower bound of the range, inclusive. Type should be the same as max if
-       * used.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public Builder clearMin() { - if (minBuilder_ == null) { - min_ = null; - onChanged(); - } else { - min_ = null; - minBuilder_ = null; - } - - return this; - } - /** - *
-       * Lower bound of the range, inclusive. Type should be the same as max if
-       * used.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getMinBuilder() { - - onChanged(); - return getMinFieldBuilder().getBuilder(); - } - /** - *
-       * Lower bound of the range, inclusive. Type should be the same as max if
-       * used.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getMinOrBuilder() { - if (minBuilder_ != null) { - return minBuilder_.getMessageOrBuilder(); - } else { - return min_ == null ? - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : min_; - } - } - /** - *
-       * Lower bound of the range, inclusive. Type should be the same as max if
-       * used.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getMinFieldBuilder() { - if (minBuilder_ == null) { - minBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - getMin(), - getParentForChildren(), - isClean()); - min_ = null; - } - return minBuilder_; - } - - private com.google.privacy.dlp.v2beta1.Value max_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> maxBuilder_; - /** - *
-       * Upper bound of the range, exclusive; type must match min.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public boolean hasMax() { - return maxBuilder_ != null || max_ != null; - } - /** - *
-       * Upper bound of the range, exclusive; type must match min.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public com.google.privacy.dlp.v2beta1.Value getMax() { - if (maxBuilder_ == null) { - return max_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : max_; - } else { - return maxBuilder_.getMessage(); - } - } - /** - *
-       * Upper bound of the range, exclusive; type must match min.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public Builder setMax(com.google.privacy.dlp.v2beta1.Value value) { - if (maxBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - max_ = value; - onChanged(); - } else { - maxBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Upper bound of the range, exclusive; type must match min.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public Builder setMax( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (maxBuilder_ == null) { - max_ = builderForValue.build(); - onChanged(); - } else { - maxBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Upper bound of the range, exclusive; type must match min.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public Builder mergeMax(com.google.privacy.dlp.v2beta1.Value value) { - if (maxBuilder_ == null) { - if (max_ != null) { - max_ = - com.google.privacy.dlp.v2beta1.Value.newBuilder(max_).mergeFrom(value).buildPartial(); - } else { - max_ = value; - } - onChanged(); - } else { - maxBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Upper bound of the range, exclusive; type must match min.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public Builder clearMax() { - if (maxBuilder_ == null) { - max_ = null; - onChanged(); - } else { - max_ = null; - maxBuilder_ = null; - } - - return this; - } - /** - *
-       * Upper bound of the range, exclusive; type must match min.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getMaxBuilder() { - - onChanged(); - return getMaxFieldBuilder().getBuilder(); - } - /** - *
-       * Upper bound of the range, exclusive; type must match min.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getMaxOrBuilder() { - if (maxBuilder_ != null) { - return maxBuilder_.getMessageOrBuilder(); - } else { - return max_ == null ? - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : max_; - } - } - /** - *
-       * Upper bound of the range, exclusive; type must match min.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getMaxFieldBuilder() { - if (maxBuilder_ == null) { - maxBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - getMax(), - getParentForChildren(), - isClean()); - max_ = null; - } - return maxBuilder_; - } - - private com.google.privacy.dlp.v2beta1.Value replacementValue_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> replacementValueBuilder_; - /** - *
-       * Replacement value for this bucket. If not provided
-       * the default behavior will be to hyphenate the min-max range.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public boolean hasReplacementValue() { - return replacementValueBuilder_ != null || replacementValue_ != null; - } - /** - *
-       * Replacement value for this bucket. If not provided
-       * the default behavior will be to hyphenate the min-max range.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public com.google.privacy.dlp.v2beta1.Value getReplacementValue() { - if (replacementValueBuilder_ == null) { - return replacementValue_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : replacementValue_; - } else { - return replacementValueBuilder_.getMessage(); - } - } - /** - *
-       * Replacement value for this bucket. If not provided
-       * the default behavior will be to hyphenate the min-max range.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public Builder setReplacementValue(com.google.privacy.dlp.v2beta1.Value value) { - if (replacementValueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - replacementValue_ = value; - onChanged(); - } else { - replacementValueBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Replacement value for this bucket. If not provided
-       * the default behavior will be to hyphenate the min-max range.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public Builder setReplacementValue( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (replacementValueBuilder_ == null) { - replacementValue_ = builderForValue.build(); - onChanged(); - } else { - replacementValueBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Replacement value for this bucket. If not provided
-       * the default behavior will be to hyphenate the min-max range.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public Builder mergeReplacementValue(com.google.privacy.dlp.v2beta1.Value value) { - if (replacementValueBuilder_ == null) { - if (replacementValue_ != null) { - replacementValue_ = - com.google.privacy.dlp.v2beta1.Value.newBuilder(replacementValue_).mergeFrom(value).buildPartial(); - } else { - replacementValue_ = value; - } - onChanged(); - } else { - replacementValueBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Replacement value for this bucket. If not provided
-       * the default behavior will be to hyphenate the min-max range.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public Builder clearReplacementValue() { - if (replacementValueBuilder_ == null) { - replacementValue_ = null; - onChanged(); - } else { - replacementValue_ = null; - replacementValueBuilder_ = null; - } - - return this; - } - /** - *
-       * Replacement value for this bucket. If not provided
-       * the default behavior will be to hyphenate the min-max range.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getReplacementValueBuilder() { - - onChanged(); - return getReplacementValueFieldBuilder().getBuilder(); - } - /** - *
-       * Replacement value for this bucket. If not provided
-       * the default behavior will be to hyphenate the min-max range.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getReplacementValueOrBuilder() { - if (replacementValueBuilder_ != null) { - return replacementValueBuilder_.getMessageOrBuilder(); - } else { - return replacementValue_ == null ? - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : replacementValue_; - } - } - /** - *
-       * Replacement value for this bucket. If not provided
-       * the default behavior will be to hyphenate the min-max range.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value replacement_value = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getReplacementValueFieldBuilder() { - if (replacementValueBuilder_ == null) { - replacementValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - getReplacementValue(), - getParentForChildren(), - isClean()); - replacementValue_ = null; - } - return replacementValueBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.BucketingConfig.Bucket) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.BucketingConfig.Bucket) - private static final com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket(); - } - - public static com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Bucket parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Bucket(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public static final int BUCKETS_FIELD_NUMBER = 1; - private java.util.List buckets_; - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public java.util.List getBucketsList() { - return buckets_; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public java.util.List - getBucketsOrBuilderList() { - return buckets_; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public int getBucketsCount() { - return buckets_.size(); - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket getBuckets(int index) { - return buckets_.get(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfig.BucketOrBuilder getBucketsOrBuilder( - int index) { - return buckets_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < buckets_.size(); i++) { - output.writeMessage(1, buckets_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < buckets_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, buckets_.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.privacy.dlp.v2beta1.BucketingConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.BucketingConfig other = (com.google.privacy.dlp.v2beta1.BucketingConfig) obj; - - boolean result = true; - result = result && getBucketsList() - .equals(other.getBucketsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getBucketsCount() > 0) { - hash = (37 * hash) + BUCKETS_FIELD_NUMBER; - hash = (53 * hash) + getBucketsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.BucketingConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig 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.privacy.dlp.v2beta1.BucketingConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig 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.privacy.dlp.v2beta1.BucketingConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig 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.privacy.dlp.v2beta1.BucketingConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.BucketingConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.BucketingConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Generalization function that buckets values based on ranges. The ranges and
-   * replacement values are dynamically provided by the user for custom behavior,
-   * such as 1-30 -> LOW 31-65 -> MEDIUM 66-100 -> HIGH
-   * This can be used on
-   * data of type: number, long, string, timestamp.
-   * If the bound `Value` type differs from the type of data being transformed, we
-   * will first attempt converting the type of the data to be transformed to match
-   * the type of the bound before comparing.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.BucketingConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.BucketingConfig) - com.google.privacy.dlp.v2beta1.BucketingConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_BucketingConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_BucketingConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.BucketingConfig.class, com.google.privacy.dlp.v2beta1.BucketingConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.BucketingConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getBucketsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (bucketsBuilder_ == null) { - buckets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - bucketsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_BucketingConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.BucketingConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.BucketingConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.BucketingConfig build() { - com.google.privacy.dlp.v2beta1.BucketingConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.BucketingConfig buildPartial() { - com.google.privacy.dlp.v2beta1.BucketingConfig result = new com.google.privacy.dlp.v2beta1.BucketingConfig(this); - int from_bitField0_ = bitField0_; - if (bucketsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - buckets_ = java.util.Collections.unmodifiableList(buckets_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.buckets_ = buckets_; - } else { - result.buckets_ = bucketsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.BucketingConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.BucketingConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.BucketingConfig other) { - if (other == com.google.privacy.dlp.v2beta1.BucketingConfig.getDefaultInstance()) return this; - if (bucketsBuilder_ == null) { - if (!other.buckets_.isEmpty()) { - if (buckets_.isEmpty()) { - buckets_ = other.buckets_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureBucketsIsMutable(); - buckets_.addAll(other.buckets_); - } - onChanged(); - } - } else { - if (!other.buckets_.isEmpty()) { - if (bucketsBuilder_.isEmpty()) { - bucketsBuilder_.dispose(); - bucketsBuilder_ = null; - buckets_ = other.buckets_; - bitField0_ = (bitField0_ & ~0x00000001); - bucketsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getBucketsFieldBuilder() : null; - } else { - bucketsBuilder_.addAllMessages(other.buckets_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.BucketingConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.BucketingConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List buckets_ = - java.util.Collections.emptyList(); - private void ensureBucketsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - buckets_ = new java.util.ArrayList(buckets_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket, com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder, com.google.privacy.dlp.v2beta1.BucketingConfig.BucketOrBuilder> bucketsBuilder_; - - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public java.util.List getBucketsList() { - if (bucketsBuilder_ == null) { - return java.util.Collections.unmodifiableList(buckets_); - } else { - return bucketsBuilder_.getMessageList(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public int getBucketsCount() { - if (bucketsBuilder_ == null) { - return buckets_.size(); - } else { - return bucketsBuilder_.getCount(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket getBuckets(int index) { - if (bucketsBuilder_ == null) { - return buckets_.get(index); - } else { - return bucketsBuilder_.getMessage(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public Builder setBuckets( - int index, com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket value) { - if (bucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketsIsMutable(); - buckets_.set(index, value); - onChanged(); - } else { - bucketsBuilder_.setMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public Builder setBuckets( - int index, com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder builderForValue) { - if (bucketsBuilder_ == null) { - ensureBucketsIsMutable(); - buckets_.set(index, builderForValue.build()); - onChanged(); - } else { - bucketsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public Builder addBuckets(com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket value) { - if (bucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketsIsMutable(); - buckets_.add(value); - onChanged(); - } else { - bucketsBuilder_.addMessage(value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public Builder addBuckets( - int index, com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket value) { - if (bucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketsIsMutable(); - buckets_.add(index, value); - onChanged(); - } else { - bucketsBuilder_.addMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public Builder addBuckets( - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder builderForValue) { - if (bucketsBuilder_ == null) { - ensureBucketsIsMutable(); - buckets_.add(builderForValue.build()); - onChanged(); - } else { - bucketsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public Builder addBuckets( - int index, com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder builderForValue) { - if (bucketsBuilder_ == null) { - ensureBucketsIsMutable(); - buckets_.add(index, builderForValue.build()); - onChanged(); - } else { - bucketsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public Builder addAllBuckets( - java.lang.Iterable values) { - if (bucketsBuilder_ == null) { - ensureBucketsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, buckets_); - onChanged(); - } else { - bucketsBuilder_.addAllMessages(values); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public Builder clearBuckets() { - if (bucketsBuilder_ == null) { - buckets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - bucketsBuilder_.clear(); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public Builder removeBuckets(int index) { - if (bucketsBuilder_ == null) { - ensureBucketsIsMutable(); - buckets_.remove(index); - onChanged(); - } else { - bucketsBuilder_.remove(index); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder getBucketsBuilder( - int index) { - return getBucketsFieldBuilder().getBuilder(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfig.BucketOrBuilder getBucketsOrBuilder( - int index) { - if (bucketsBuilder_ == null) { - return buckets_.get(index); } else { - return bucketsBuilder_.getMessageOrBuilder(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public java.util.List - getBucketsOrBuilderList() { - if (bucketsBuilder_ != null) { - return bucketsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(buckets_); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder addBucketsBuilder() { - return getBucketsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder addBucketsBuilder( - int index) { - return getBucketsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - public java.util.List - getBucketsBuilderList() { - return getBucketsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket, com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder, com.google.privacy.dlp.v2beta1.BucketingConfig.BucketOrBuilder> - getBucketsFieldBuilder() { - if (bucketsBuilder_ == null) { - bucketsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket, com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket.Builder, com.google.privacy.dlp.v2beta1.BucketingConfig.BucketOrBuilder>( - buckets_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - buckets_ = null; - } - return bucketsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.BucketingConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.BucketingConfig) - private static final com.google.privacy.dlp.v2beta1.BucketingConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.BucketingConfig(); - } - - public static com.google.privacy.dlp.v2beta1.BucketingConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public BucketingConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BucketingConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.BucketingConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BucketingConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BucketingConfigOrBuilder.java deleted file mode 100644 index eac243bb490e..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/BucketingConfigOrBuilder.java +++ /dev/null @@ -1,33 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface BucketingConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.BucketingConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - java.util.List - getBucketsList(); - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - com.google.privacy.dlp.v2beta1.BucketingConfig.Bucket getBuckets(int index); - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - int getBucketsCount(); - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - java.util.List - getBucketsOrBuilderList(); - /** - * repeated .google.privacy.dlp.v2beta1.BucketingConfig.Bucket buckets = 1; - */ - com.google.privacy.dlp.v2beta1.BucketingConfig.BucketOrBuilder getBucketsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CategoryDescription.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CategoryDescription.java deleted file mode 100644 index cc4060d1c136..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CategoryDescription.java +++ /dev/null @@ -1,707 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Info Type Category description.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CategoryDescription} - */ -public final class CategoryDescription extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CategoryDescription) - CategoryDescriptionOrBuilder { -private static final long serialVersionUID = 0L; - // Use CategoryDescription.newBuilder() to construct. - private CategoryDescription(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CategoryDescription() { - name_ = ""; - displayName_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CategoryDescription( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - displayName_ = s; - break; - } - } - } - } 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CategoryDescription_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CategoryDescription_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CategoryDescription.class, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - *
-   * Internal name of the category.
-   * 
- * - * string name = 1; - */ - 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; - } - } - /** - *
-   * Internal name of the category.
-   * 
- * - * string name = 1; - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DISPLAY_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object displayName_; - /** - *
-   * Human readable form of the category name.
-   * 
- * - * string display_name = 2; - */ - public java.lang.String getDisplayName() { - java.lang.Object ref = displayName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - displayName_ = s; - return s; - } - } - /** - *
-   * Human readable form of the category name.
-   * 
- * - * string display_name = 2; - */ - public com.google.protobuf.ByteString - getDisplayNameBytes() { - java.lang.Object ref = displayName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - displayName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (!getDisplayNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, displayName_); - } - unknownFields.writeTo(output); - } - - 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 (!getDisplayNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, displayName_); - } - 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.privacy.dlp.v2beta1.CategoryDescription)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CategoryDescription other = (com.google.privacy.dlp.v2beta1.CategoryDescription) obj; - - boolean result = true; - result = result && getName() - .equals(other.getName()); - result = result && getDisplayName() - .equals(other.getDisplayName()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; - hash = (53 * hash) + getDisplayName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CategoryDescription parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CategoryDescription parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CategoryDescription parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CategoryDescription 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.privacy.dlp.v2beta1.CategoryDescription parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CategoryDescription parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CategoryDescription parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CategoryDescription 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.privacy.dlp.v2beta1.CategoryDescription parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CategoryDescription 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.privacy.dlp.v2beta1.CategoryDescription parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CategoryDescription parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CategoryDescription prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Info Type Category description.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CategoryDescription} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CategoryDescription) - com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CategoryDescription_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CategoryDescription_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CategoryDescription.class, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CategoryDescription.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - name_ = ""; - - displayName_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CategoryDescription_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CategoryDescription getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CategoryDescription.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CategoryDescription build() { - com.google.privacy.dlp.v2beta1.CategoryDescription result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CategoryDescription buildPartial() { - com.google.privacy.dlp.v2beta1.CategoryDescription result = new com.google.privacy.dlp.v2beta1.CategoryDescription(this); - result.name_ = name_; - result.displayName_ = displayName_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CategoryDescription) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CategoryDescription)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CategoryDescription other) { - if (other == com.google.privacy.dlp.v2beta1.CategoryDescription.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getDisplayName().isEmpty()) { - displayName_ = other.displayName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CategoryDescription parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CategoryDescription) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - *
-     * Internal name of the category.
-     * 
- * - * string name = 1; - */ - 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; - } - } - /** - *
-     * Internal name of the category.
-     * 
- * - * string name = 1; - */ - 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; - } - } - /** - *
-     * Internal name of the category.
-     * 
- * - * string name = 1; - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - *
-     * Internal name of the category.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - *
-     * Internal name of the category.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object displayName_ = ""; - /** - *
-     * Human readable form of the category name.
-     * 
- * - * string display_name = 2; - */ - public java.lang.String getDisplayName() { - java.lang.Object ref = displayName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - displayName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * Human readable form of the category name.
-     * 
- * - * string display_name = 2; - */ - public com.google.protobuf.ByteString - getDisplayNameBytes() { - java.lang.Object ref = displayName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - displayName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * Human readable form of the category name.
-     * 
- * - * string display_name = 2; - */ - public Builder setDisplayName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - displayName_ = value; - onChanged(); - return this; - } - /** - *
-     * Human readable form of the category name.
-     * 
- * - * string display_name = 2; - */ - public Builder clearDisplayName() { - - displayName_ = getDefaultInstance().getDisplayName(); - onChanged(); - return this; - } - /** - *
-     * Human readable form of the category name.
-     * 
- * - * string display_name = 2; - */ - public Builder setDisplayNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - displayName_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CategoryDescription) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CategoryDescription) - private static final com.google.privacy.dlp.v2beta1.CategoryDescription DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CategoryDescription(); - } - - public static com.google.privacy.dlp.v2beta1.CategoryDescription getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CategoryDescription parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CategoryDescription(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CategoryDescription getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CategoryDescriptionOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CategoryDescriptionOrBuilder.java deleted file mode 100644 index f4245e72dc48..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CategoryDescriptionOrBuilder.java +++ /dev/null @@ -1,45 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CategoryDescriptionOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CategoryDescription) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Internal name of the category.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - *
-   * Internal name of the category.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString - getNameBytes(); - - /** - *
-   * Human readable form of the category name.
-   * 
- * - * string display_name = 2; - */ - java.lang.String getDisplayName(); - /** - *
-   * Human readable form of the category name.
-   * 
- * - * string display_name = 2; - */ - com.google.protobuf.ByteString - getDisplayNameBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharacterMaskConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharacterMaskConfig.java deleted file mode 100644 index fe7578ab9c63..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharacterMaskConfig.java +++ /dev/null @@ -1,1238 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Partially mask a string by replacing a given number of characters with a
- * fixed character. Masking can start from the beginning or end of the string.
- * This can be used on data of any type (numbers, longs, and so on) and when
- * de-identifying structured data we'll attempt to preserve the original data's
- * type. (This allows you to take a long like 123 and modify it to a string like
- * **3.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CharacterMaskConfig} - */ -public final class CharacterMaskConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CharacterMaskConfig) - CharacterMaskConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use CharacterMaskConfig.newBuilder() to construct. - private CharacterMaskConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CharacterMaskConfig() { - maskingCharacter_ = ""; - numberToMask_ = 0; - reverseOrder_ = false; - charactersToIgnore_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CharacterMaskConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - maskingCharacter_ = s; - break; - } - case 16: { - - numberToMask_ = input.readInt32(); - break; - } - case 24: { - - reverseOrder_ = input.readBool(); - break; - } - case 34: { - if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - charactersToIgnore_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - charactersToIgnore_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.CharsToIgnore.parser(), extensionRegistry)); - 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_ & 0x00000008) == 0x00000008)) { - charactersToIgnore_ = java.util.Collections.unmodifiableList(charactersToIgnore_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CharacterMaskConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CharacterMaskConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CharacterMaskConfig.class, com.google.privacy.dlp.v2beta1.CharacterMaskConfig.Builder.class); - } - - private int bitField0_; - public static final int MASKING_CHARACTER_FIELD_NUMBER = 1; - private volatile java.lang.Object maskingCharacter_; - /** - *
-   * Character to mask the sensitive values&mdash;for example, "*" for an
-   * alphabetic string such as name, or "0" for a numeric string such as ZIP
-   * code or credit card number. String must have length 1. If not supplied, we
-   * will default to "*" for strings, 0 for digits.
-   * 
- * - * string masking_character = 1; - */ - public java.lang.String getMaskingCharacter() { - java.lang.Object ref = maskingCharacter_; - 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(); - maskingCharacter_ = s; - return s; - } - } - /** - *
-   * Character to mask the sensitive values&mdash;for example, "*" for an
-   * alphabetic string such as name, or "0" for a numeric string such as ZIP
-   * code or credit card number. String must have length 1. If not supplied, we
-   * will default to "*" for strings, 0 for digits.
-   * 
- * - * string masking_character = 1; - */ - public com.google.protobuf.ByteString - getMaskingCharacterBytes() { - java.lang.Object ref = maskingCharacter_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - maskingCharacter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int NUMBER_TO_MASK_FIELD_NUMBER = 2; - private int numberToMask_; - /** - *
-   * Number of characters to mask. If not set, all matching chars will be
-   * masked. Skipped characters do not count towards this tally.
-   * 
- * - * int32 number_to_mask = 2; - */ - public int getNumberToMask() { - return numberToMask_; - } - - public static final int REVERSE_ORDER_FIELD_NUMBER = 3; - private boolean reverseOrder_; - /** - *
-   * Mask characters in reverse order. For example, if `masking_character` is
-   * '0', number_to_mask is 14, and `reverse_order` is false, then
-   * 1234-5678-9012-3456 -> 00000000000000-3456
-   * If `masking_character` is '*', `number_to_mask` is 3, and `reverse_order`
-   * is true, then 12345 -> 12***
-   * 
- * - * bool reverse_order = 3; - */ - public boolean getReverseOrder() { - return reverseOrder_; - } - - public static final int CHARACTERS_TO_IGNORE_FIELD_NUMBER = 4; - private java.util.List charactersToIgnore_; - /** - *
-   * When masking a string, items in this list will be skipped when replacing.
-   * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-   * mask 5 chars with * we would produce ***-*55-5555.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public java.util.List getCharactersToIgnoreList() { - return charactersToIgnore_; - } - /** - *
-   * When masking a string, items in this list will be skipped when replacing.
-   * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-   * mask 5 chars with * we would produce ***-*55-5555.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public java.util.List - getCharactersToIgnoreOrBuilderList() { - return charactersToIgnore_; - } - /** - *
-   * When masking a string, items in this list will be skipped when replacing.
-   * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-   * mask 5 chars with * we would produce ***-*55-5555.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public int getCharactersToIgnoreCount() { - return charactersToIgnore_.size(); - } - /** - *
-   * When masking a string, items in this list will be skipped when replacing.
-   * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-   * mask 5 chars with * we would produce ***-*55-5555.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public com.google.privacy.dlp.v2beta1.CharsToIgnore getCharactersToIgnore(int index) { - return charactersToIgnore_.get(index); - } - /** - *
-   * When masking a string, items in this list will be skipped when replacing.
-   * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-   * mask 5 chars with * we would produce ***-*55-5555.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public com.google.privacy.dlp.v2beta1.CharsToIgnoreOrBuilder getCharactersToIgnoreOrBuilder( - int index) { - return charactersToIgnore_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getMaskingCharacterBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, maskingCharacter_); - } - if (numberToMask_ != 0) { - output.writeInt32(2, numberToMask_); - } - if (reverseOrder_ != false) { - output.writeBool(3, reverseOrder_); - } - for (int i = 0; i < charactersToIgnore_.size(); i++) { - output.writeMessage(4, charactersToIgnore_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getMaskingCharacterBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, maskingCharacter_); - } - if (numberToMask_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(2, numberToMask_); - } - if (reverseOrder_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(3, reverseOrder_); - } - for (int i = 0; i < charactersToIgnore_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, charactersToIgnore_.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.privacy.dlp.v2beta1.CharacterMaskConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CharacterMaskConfig other = (com.google.privacy.dlp.v2beta1.CharacterMaskConfig) obj; - - boolean result = true; - result = result && getMaskingCharacter() - .equals(other.getMaskingCharacter()); - result = result && (getNumberToMask() - == other.getNumberToMask()); - result = result && (getReverseOrder() - == other.getReverseOrder()); - result = result && getCharactersToIgnoreList() - .equals(other.getCharactersToIgnoreList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + MASKING_CHARACTER_FIELD_NUMBER; - hash = (53 * hash) + getMaskingCharacter().hashCode(); - hash = (37 * hash) + NUMBER_TO_MASK_FIELD_NUMBER; - hash = (53 * hash) + getNumberToMask(); - hash = (37 * hash) + REVERSE_ORDER_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getReverseOrder()); - if (getCharactersToIgnoreCount() > 0) { - hash = (37 * hash) + CHARACTERS_TO_IGNORE_FIELD_NUMBER; - hash = (53 * hash) + getCharactersToIgnoreList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CharacterMaskConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CharacterMaskConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CharacterMaskConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CharacterMaskConfig 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.privacy.dlp.v2beta1.CharacterMaskConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CharacterMaskConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CharacterMaskConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CharacterMaskConfig 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.privacy.dlp.v2beta1.CharacterMaskConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CharacterMaskConfig 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.privacy.dlp.v2beta1.CharacterMaskConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CharacterMaskConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CharacterMaskConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Partially mask a string by replacing a given number of characters with a
-   * fixed character. Masking can start from the beginning or end of the string.
-   * This can be used on data of any type (numbers, longs, and so on) and when
-   * de-identifying structured data we'll attempt to preserve the original data's
-   * type. (This allows you to take a long like 123 and modify it to a string like
-   * **3.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CharacterMaskConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CharacterMaskConfig) - com.google.privacy.dlp.v2beta1.CharacterMaskConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CharacterMaskConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CharacterMaskConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CharacterMaskConfig.class, com.google.privacy.dlp.v2beta1.CharacterMaskConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CharacterMaskConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getCharactersToIgnoreFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - maskingCharacter_ = ""; - - numberToMask_ = 0; - - reverseOrder_ = false; - - if (charactersToIgnoreBuilder_ == null) { - charactersToIgnore_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - charactersToIgnoreBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CharacterMaskConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CharacterMaskConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CharacterMaskConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CharacterMaskConfig build() { - com.google.privacy.dlp.v2beta1.CharacterMaskConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CharacterMaskConfig buildPartial() { - com.google.privacy.dlp.v2beta1.CharacterMaskConfig result = new com.google.privacy.dlp.v2beta1.CharacterMaskConfig(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.maskingCharacter_ = maskingCharacter_; - result.numberToMask_ = numberToMask_; - result.reverseOrder_ = reverseOrder_; - if (charactersToIgnoreBuilder_ == null) { - if (((bitField0_ & 0x00000008) == 0x00000008)) { - charactersToIgnore_ = java.util.Collections.unmodifiableList(charactersToIgnore_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.charactersToIgnore_ = charactersToIgnore_; - } else { - result.charactersToIgnore_ = charactersToIgnoreBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CharacterMaskConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CharacterMaskConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CharacterMaskConfig other) { - if (other == com.google.privacy.dlp.v2beta1.CharacterMaskConfig.getDefaultInstance()) return this; - if (!other.getMaskingCharacter().isEmpty()) { - maskingCharacter_ = other.maskingCharacter_; - onChanged(); - } - if (other.getNumberToMask() != 0) { - setNumberToMask(other.getNumberToMask()); - } - if (other.getReverseOrder() != false) { - setReverseOrder(other.getReverseOrder()); - } - if (charactersToIgnoreBuilder_ == null) { - if (!other.charactersToIgnore_.isEmpty()) { - if (charactersToIgnore_.isEmpty()) { - charactersToIgnore_ = other.charactersToIgnore_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureCharactersToIgnoreIsMutable(); - charactersToIgnore_.addAll(other.charactersToIgnore_); - } - onChanged(); - } - } else { - if (!other.charactersToIgnore_.isEmpty()) { - if (charactersToIgnoreBuilder_.isEmpty()) { - charactersToIgnoreBuilder_.dispose(); - charactersToIgnoreBuilder_ = null; - charactersToIgnore_ = other.charactersToIgnore_; - bitField0_ = (bitField0_ & ~0x00000008); - charactersToIgnoreBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getCharactersToIgnoreFieldBuilder() : null; - } else { - charactersToIgnoreBuilder_.addAllMessages(other.charactersToIgnore_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CharacterMaskConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CharacterMaskConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.lang.Object maskingCharacter_ = ""; - /** - *
-     * Character to mask the sensitive values&mdash;for example, "*" for an
-     * alphabetic string such as name, or "0" for a numeric string such as ZIP
-     * code or credit card number. String must have length 1. If not supplied, we
-     * will default to "*" for strings, 0 for digits.
-     * 
- * - * string masking_character = 1; - */ - public java.lang.String getMaskingCharacter() { - java.lang.Object ref = maskingCharacter_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - maskingCharacter_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * Character to mask the sensitive values&mdash;for example, "*" for an
-     * alphabetic string such as name, or "0" for a numeric string such as ZIP
-     * code or credit card number. String must have length 1. If not supplied, we
-     * will default to "*" for strings, 0 for digits.
-     * 
- * - * string masking_character = 1; - */ - public com.google.protobuf.ByteString - getMaskingCharacterBytes() { - java.lang.Object ref = maskingCharacter_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - maskingCharacter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * Character to mask the sensitive values&mdash;for example, "*" for an
-     * alphabetic string such as name, or "0" for a numeric string such as ZIP
-     * code or credit card number. String must have length 1. If not supplied, we
-     * will default to "*" for strings, 0 for digits.
-     * 
- * - * string masking_character = 1; - */ - public Builder setMaskingCharacter( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - maskingCharacter_ = value; - onChanged(); - return this; - } - /** - *
-     * Character to mask the sensitive values&mdash;for example, "*" for an
-     * alphabetic string such as name, or "0" for a numeric string such as ZIP
-     * code or credit card number. String must have length 1. If not supplied, we
-     * will default to "*" for strings, 0 for digits.
-     * 
- * - * string masking_character = 1; - */ - public Builder clearMaskingCharacter() { - - maskingCharacter_ = getDefaultInstance().getMaskingCharacter(); - onChanged(); - return this; - } - /** - *
-     * Character to mask the sensitive values&mdash;for example, "*" for an
-     * alphabetic string such as name, or "0" for a numeric string such as ZIP
-     * code or credit card number. String must have length 1. If not supplied, we
-     * will default to "*" for strings, 0 for digits.
-     * 
- * - * string masking_character = 1; - */ - public Builder setMaskingCharacterBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - maskingCharacter_ = value; - onChanged(); - return this; - } - - private int numberToMask_ ; - /** - *
-     * Number of characters to mask. If not set, all matching chars will be
-     * masked. Skipped characters do not count towards this tally.
-     * 
- * - * int32 number_to_mask = 2; - */ - public int getNumberToMask() { - return numberToMask_; - } - /** - *
-     * Number of characters to mask. If not set, all matching chars will be
-     * masked. Skipped characters do not count towards this tally.
-     * 
- * - * int32 number_to_mask = 2; - */ - public Builder setNumberToMask(int value) { - - numberToMask_ = value; - onChanged(); - return this; - } - /** - *
-     * Number of characters to mask. If not set, all matching chars will be
-     * masked. Skipped characters do not count towards this tally.
-     * 
- * - * int32 number_to_mask = 2; - */ - public Builder clearNumberToMask() { - - numberToMask_ = 0; - onChanged(); - return this; - } - - private boolean reverseOrder_ ; - /** - *
-     * Mask characters in reverse order. For example, if `masking_character` is
-     * '0', number_to_mask is 14, and `reverse_order` is false, then
-     * 1234-5678-9012-3456 -> 00000000000000-3456
-     * If `masking_character` is '*', `number_to_mask` is 3, and `reverse_order`
-     * is true, then 12345 -> 12***
-     * 
- * - * bool reverse_order = 3; - */ - public boolean getReverseOrder() { - return reverseOrder_; - } - /** - *
-     * Mask characters in reverse order. For example, if `masking_character` is
-     * '0', number_to_mask is 14, and `reverse_order` is false, then
-     * 1234-5678-9012-3456 -> 00000000000000-3456
-     * If `masking_character` is '*', `number_to_mask` is 3, and `reverse_order`
-     * is true, then 12345 -> 12***
-     * 
- * - * bool reverse_order = 3; - */ - public Builder setReverseOrder(boolean value) { - - reverseOrder_ = value; - onChanged(); - return this; - } - /** - *
-     * Mask characters in reverse order. For example, if `masking_character` is
-     * '0', number_to_mask is 14, and `reverse_order` is false, then
-     * 1234-5678-9012-3456 -> 00000000000000-3456
-     * If `masking_character` is '*', `number_to_mask` is 3, and `reverse_order`
-     * is true, then 12345 -> 12***
-     * 
- * - * bool reverse_order = 3; - */ - public Builder clearReverseOrder() { - - reverseOrder_ = false; - onChanged(); - return this; - } - - private java.util.List charactersToIgnore_ = - java.util.Collections.emptyList(); - private void ensureCharactersToIgnoreIsMutable() { - if (!((bitField0_ & 0x00000008) == 0x00000008)) { - charactersToIgnore_ = new java.util.ArrayList(charactersToIgnore_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CharsToIgnore, com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder, com.google.privacy.dlp.v2beta1.CharsToIgnoreOrBuilder> charactersToIgnoreBuilder_; - - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public java.util.List getCharactersToIgnoreList() { - if (charactersToIgnoreBuilder_ == null) { - return java.util.Collections.unmodifiableList(charactersToIgnore_); - } else { - return charactersToIgnoreBuilder_.getMessageList(); - } - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public int getCharactersToIgnoreCount() { - if (charactersToIgnoreBuilder_ == null) { - return charactersToIgnore_.size(); - } else { - return charactersToIgnoreBuilder_.getCount(); - } - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public com.google.privacy.dlp.v2beta1.CharsToIgnore getCharactersToIgnore(int index) { - if (charactersToIgnoreBuilder_ == null) { - return charactersToIgnore_.get(index); - } else { - return charactersToIgnoreBuilder_.getMessage(index); - } - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public Builder setCharactersToIgnore( - int index, com.google.privacy.dlp.v2beta1.CharsToIgnore value) { - if (charactersToIgnoreBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCharactersToIgnoreIsMutable(); - charactersToIgnore_.set(index, value); - onChanged(); - } else { - charactersToIgnoreBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public Builder setCharactersToIgnore( - int index, com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder builderForValue) { - if (charactersToIgnoreBuilder_ == null) { - ensureCharactersToIgnoreIsMutable(); - charactersToIgnore_.set(index, builderForValue.build()); - onChanged(); - } else { - charactersToIgnoreBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public Builder addCharactersToIgnore(com.google.privacy.dlp.v2beta1.CharsToIgnore value) { - if (charactersToIgnoreBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCharactersToIgnoreIsMutable(); - charactersToIgnore_.add(value); - onChanged(); - } else { - charactersToIgnoreBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public Builder addCharactersToIgnore( - int index, com.google.privacy.dlp.v2beta1.CharsToIgnore value) { - if (charactersToIgnoreBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCharactersToIgnoreIsMutable(); - charactersToIgnore_.add(index, value); - onChanged(); - } else { - charactersToIgnoreBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public Builder addCharactersToIgnore( - com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder builderForValue) { - if (charactersToIgnoreBuilder_ == null) { - ensureCharactersToIgnoreIsMutable(); - charactersToIgnore_.add(builderForValue.build()); - onChanged(); - } else { - charactersToIgnoreBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public Builder addCharactersToIgnore( - int index, com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder builderForValue) { - if (charactersToIgnoreBuilder_ == null) { - ensureCharactersToIgnoreIsMutable(); - charactersToIgnore_.add(index, builderForValue.build()); - onChanged(); - } else { - charactersToIgnoreBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public Builder addAllCharactersToIgnore( - java.lang.Iterable values) { - if (charactersToIgnoreBuilder_ == null) { - ensureCharactersToIgnoreIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, charactersToIgnore_); - onChanged(); - } else { - charactersToIgnoreBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public Builder clearCharactersToIgnore() { - if (charactersToIgnoreBuilder_ == null) { - charactersToIgnore_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - charactersToIgnoreBuilder_.clear(); - } - return this; - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public Builder removeCharactersToIgnore(int index) { - if (charactersToIgnoreBuilder_ == null) { - ensureCharactersToIgnoreIsMutable(); - charactersToIgnore_.remove(index); - onChanged(); - } else { - charactersToIgnoreBuilder_.remove(index); - } - return this; - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder getCharactersToIgnoreBuilder( - int index) { - return getCharactersToIgnoreFieldBuilder().getBuilder(index); - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public com.google.privacy.dlp.v2beta1.CharsToIgnoreOrBuilder getCharactersToIgnoreOrBuilder( - int index) { - if (charactersToIgnoreBuilder_ == null) { - return charactersToIgnore_.get(index); } else { - return charactersToIgnoreBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public java.util.List - getCharactersToIgnoreOrBuilderList() { - if (charactersToIgnoreBuilder_ != null) { - return charactersToIgnoreBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(charactersToIgnore_); - } - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder addCharactersToIgnoreBuilder() { - return getCharactersToIgnoreFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.CharsToIgnore.getDefaultInstance()); - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder addCharactersToIgnoreBuilder( - int index) { - return getCharactersToIgnoreFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.CharsToIgnore.getDefaultInstance()); - } - /** - *
-     * When masking a string, items in this list will be skipped when replacing.
-     * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-     * mask 5 chars with * we would produce ***-*55-5555.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - public java.util.List - getCharactersToIgnoreBuilderList() { - return getCharactersToIgnoreFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CharsToIgnore, com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder, com.google.privacy.dlp.v2beta1.CharsToIgnoreOrBuilder> - getCharactersToIgnoreFieldBuilder() { - if (charactersToIgnoreBuilder_ == null) { - charactersToIgnoreBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CharsToIgnore, com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder, com.google.privacy.dlp.v2beta1.CharsToIgnoreOrBuilder>( - charactersToIgnore_, - ((bitField0_ & 0x00000008) == 0x00000008), - getParentForChildren(), - isClean()); - charactersToIgnore_ = null; - } - return charactersToIgnoreBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CharacterMaskConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CharacterMaskConfig) - private static final com.google.privacy.dlp.v2beta1.CharacterMaskConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CharacterMaskConfig(); - } - - public static com.google.privacy.dlp.v2beta1.CharacterMaskConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CharacterMaskConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CharacterMaskConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CharacterMaskConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharacterMaskConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharacterMaskConfigOrBuilder.java deleted file mode 100644 index 263da697c011..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharacterMaskConfigOrBuilder.java +++ /dev/null @@ -1,110 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CharacterMaskConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CharacterMaskConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Character to mask the sensitive values&mdash;for example, "*" for an
-   * alphabetic string such as name, or "0" for a numeric string such as ZIP
-   * code or credit card number. String must have length 1. If not supplied, we
-   * will default to "*" for strings, 0 for digits.
-   * 
- * - * string masking_character = 1; - */ - java.lang.String getMaskingCharacter(); - /** - *
-   * Character to mask the sensitive values&mdash;for example, "*" for an
-   * alphabetic string such as name, or "0" for a numeric string such as ZIP
-   * code or credit card number. String must have length 1. If not supplied, we
-   * will default to "*" for strings, 0 for digits.
-   * 
- * - * string masking_character = 1; - */ - com.google.protobuf.ByteString - getMaskingCharacterBytes(); - - /** - *
-   * Number of characters to mask. If not set, all matching chars will be
-   * masked. Skipped characters do not count towards this tally.
-   * 
- * - * int32 number_to_mask = 2; - */ - int getNumberToMask(); - - /** - *
-   * Mask characters in reverse order. For example, if `masking_character` is
-   * '0', number_to_mask is 14, and `reverse_order` is false, then
-   * 1234-5678-9012-3456 -> 00000000000000-3456
-   * If `masking_character` is '*', `number_to_mask` is 3, and `reverse_order`
-   * is true, then 12345 -> 12***
-   * 
- * - * bool reverse_order = 3; - */ - boolean getReverseOrder(); - - /** - *
-   * When masking a string, items in this list will be skipped when replacing.
-   * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-   * mask 5 chars with * we would produce ***-*55-5555.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - java.util.List - getCharactersToIgnoreList(); - /** - *
-   * When masking a string, items in this list will be skipped when replacing.
-   * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-   * mask 5 chars with * we would produce ***-*55-5555.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - com.google.privacy.dlp.v2beta1.CharsToIgnore getCharactersToIgnore(int index); - /** - *
-   * When masking a string, items in this list will be skipped when replacing.
-   * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-   * mask 5 chars with * we would produce ***-*55-5555.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - int getCharactersToIgnoreCount(); - /** - *
-   * When masking a string, items in this list will be skipped when replacing.
-   * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-   * mask 5 chars with * we would produce ***-*55-5555.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - java.util.List - getCharactersToIgnoreOrBuilderList(); - /** - *
-   * When masking a string, items in this list will be skipped when replacing.
-   * For example, if your string is 555-555-5555 and you ask us to skip `-` and
-   * mask 5 chars with * we would produce ***-*55-5555.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CharsToIgnore characters_to_ignore = 4; - */ - com.google.privacy.dlp.v2beta1.CharsToIgnoreOrBuilder getCharactersToIgnoreOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharsToIgnore.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharsToIgnore.java deleted file mode 100644 index 7b2472f28ebe..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharsToIgnore.java +++ /dev/null @@ -1,900 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Characters to skip when doing deidentification of a value. These will be left
- * alone and skipped.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CharsToIgnore} - */ -public final class CharsToIgnore extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CharsToIgnore) - CharsToIgnoreOrBuilder { -private static final long serialVersionUID = 0L; - // Use CharsToIgnore.newBuilder() to construct. - private CharsToIgnore(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CharsToIgnore() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CharsToIgnore( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - charactersCase_ = 1; - characters_ = s; - break; - } - case 16: { - int rawValue = input.readEnum(); - charactersCase_ = 2; - characters_ = rawValue; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CharsToIgnore_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CharsToIgnore_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CharsToIgnore.class, com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder.class); - } - - /** - * Protobuf enum {@code google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup} - */ - public enum CharacterGroup - implements com.google.protobuf.ProtocolMessageEnum { - /** - * CHARACTER_GROUP_UNSPECIFIED = 0; - */ - CHARACTER_GROUP_UNSPECIFIED(0), - /** - *
-     * 0-9
-     * 
- * - * NUMERIC = 1; - */ - NUMERIC(1), - /** - *
-     * A-Z
-     * 
- * - * ALPHA_UPPER_CASE = 2; - */ - ALPHA_UPPER_CASE(2), - /** - *
-     * a-z
-     * 
- * - * ALPHA_LOWER_CASE = 3; - */ - ALPHA_LOWER_CASE(3), - /** - *
-     * US Punctuation, one of !"#$%&'()*+,-./:;<=>?@[\]^_`{|}~
-     * 
- * - * PUNCTUATION = 4; - */ - PUNCTUATION(4), - /** - *
-     * Whitespace character, one of [ \t\n\x0B\f\r]
-     * 
- * - * WHITESPACE = 5; - */ - WHITESPACE(5), - UNRECOGNIZED(-1), - ; - - /** - * CHARACTER_GROUP_UNSPECIFIED = 0; - */ - public static final int CHARACTER_GROUP_UNSPECIFIED_VALUE = 0; - /** - *
-     * 0-9
-     * 
- * - * NUMERIC = 1; - */ - public static final int NUMERIC_VALUE = 1; - /** - *
-     * A-Z
-     * 
- * - * ALPHA_UPPER_CASE = 2; - */ - public static final int ALPHA_UPPER_CASE_VALUE = 2; - /** - *
-     * a-z
-     * 
- * - * ALPHA_LOWER_CASE = 3; - */ - public static final int ALPHA_LOWER_CASE_VALUE = 3; - /** - *
-     * US Punctuation, one of !"#$%&'()*+,-./:;<=>?@[\]^_`{|}~
-     * 
- * - * PUNCTUATION = 4; - */ - public static final int PUNCTUATION_VALUE = 4; - /** - *
-     * Whitespace character, one of [ \t\n\x0B\f\r]
-     * 
- * - * WHITESPACE = 5; - */ - public static final int WHITESPACE_VALUE = 5; - - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static CharacterGroup valueOf(int value) { - return forNumber(value); - } - - public static CharacterGroup forNumber(int value) { - switch (value) { - case 0: return CHARACTER_GROUP_UNSPECIFIED; - case 1: return NUMERIC; - case 2: return ALPHA_UPPER_CASE; - case 3: return ALPHA_LOWER_CASE; - case 4: return PUNCTUATION; - case 5: return WHITESPACE; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - private static final com.google.protobuf.Internal.EnumLiteMap< - CharacterGroup> internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public CharacterGroup findValueByNumber(int number) { - return CharacterGroup.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - 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.privacy.dlp.v2beta1.CharsToIgnore.getDescriptor().getEnumTypes().get(0); - } - - private static final CharacterGroup[] VALUES = values(); - - public static CharacterGroup 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 CharacterGroup(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup) - } - - private int charactersCase_ = 0; - private java.lang.Object characters_; - public enum CharactersCase - implements com.google.protobuf.Internal.EnumLite { - CHARACTERS_TO_SKIP(1), - COMMON_CHARACTERS_TO_IGNORE(2), - CHARACTERS_NOT_SET(0); - private final int value; - private CharactersCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static CharactersCase valueOf(int value) { - return forNumber(value); - } - - public static CharactersCase forNumber(int value) { - switch (value) { - case 1: return CHARACTERS_TO_SKIP; - case 2: return COMMON_CHARACTERS_TO_IGNORE; - case 0: return CHARACTERS_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public CharactersCase - getCharactersCase() { - return CharactersCase.forNumber( - charactersCase_); - } - - public static final int CHARACTERS_TO_SKIP_FIELD_NUMBER = 1; - /** - * string characters_to_skip = 1; - */ - public java.lang.String getCharactersToSkip() { - java.lang.Object ref = ""; - if (charactersCase_ == 1) { - ref = characters_; - } - 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 (charactersCase_ == 1) { - characters_ = s; - } - return s; - } - } - /** - * string characters_to_skip = 1; - */ - public com.google.protobuf.ByteString - getCharactersToSkipBytes() { - java.lang.Object ref = ""; - if (charactersCase_ == 1) { - ref = characters_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - if (charactersCase_ == 1) { - characters_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int COMMON_CHARACTERS_TO_IGNORE_FIELD_NUMBER = 2; - /** - * .google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup common_characters_to_ignore = 2; - */ - public int getCommonCharactersToIgnoreValue() { - if (charactersCase_ == 2) { - return (java.lang.Integer) characters_; - } - return 0; - } - /** - * .google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup common_characters_to_ignore = 2; - */ - public com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup getCommonCharactersToIgnore() { - if (charactersCase_ == 2) { - com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup result = com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup.valueOf( - (java.lang.Integer) characters_); - return result == null ? com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup.UNRECOGNIZED : result; - } - return com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup.CHARACTER_GROUP_UNSPECIFIED; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (charactersCase_ == 1) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, characters_); - } - if (charactersCase_ == 2) { - output.writeEnum(2, ((java.lang.Integer) characters_)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (charactersCase_ == 1) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, characters_); - } - if (charactersCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(2, ((java.lang.Integer) characters_)); - } - 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.privacy.dlp.v2beta1.CharsToIgnore)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CharsToIgnore other = (com.google.privacy.dlp.v2beta1.CharsToIgnore) obj; - - boolean result = true; - result = result && getCharactersCase().equals( - other.getCharactersCase()); - if (!result) return false; - switch (charactersCase_) { - case 1: - result = result && getCharactersToSkip() - .equals(other.getCharactersToSkip()); - break; - case 2: - result = result && getCommonCharactersToIgnoreValue() - == other.getCommonCharactersToIgnoreValue(); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (charactersCase_) { - case 1: - hash = (37 * hash) + CHARACTERS_TO_SKIP_FIELD_NUMBER; - hash = (53 * hash) + getCharactersToSkip().hashCode(); - break; - case 2: - hash = (37 * hash) + COMMON_CHARACTERS_TO_IGNORE_FIELD_NUMBER; - hash = (53 * hash) + getCommonCharactersToIgnoreValue(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CharsToIgnore parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CharsToIgnore parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CharsToIgnore parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CharsToIgnore 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.privacy.dlp.v2beta1.CharsToIgnore parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CharsToIgnore parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CharsToIgnore parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CharsToIgnore 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.privacy.dlp.v2beta1.CharsToIgnore parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CharsToIgnore 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.privacy.dlp.v2beta1.CharsToIgnore parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CharsToIgnore parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CharsToIgnore prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Characters to skip when doing deidentification of a value. These will be left
-   * alone and skipped.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CharsToIgnore} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CharsToIgnore) - com.google.privacy.dlp.v2beta1.CharsToIgnoreOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CharsToIgnore_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CharsToIgnore_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CharsToIgnore.class, com.google.privacy.dlp.v2beta1.CharsToIgnore.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CharsToIgnore.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - charactersCase_ = 0; - characters_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CharsToIgnore_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CharsToIgnore getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CharsToIgnore.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CharsToIgnore build() { - com.google.privacy.dlp.v2beta1.CharsToIgnore result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CharsToIgnore buildPartial() { - com.google.privacy.dlp.v2beta1.CharsToIgnore result = new com.google.privacy.dlp.v2beta1.CharsToIgnore(this); - if (charactersCase_ == 1) { - result.characters_ = characters_; - } - if (charactersCase_ == 2) { - result.characters_ = characters_; - } - result.charactersCase_ = charactersCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CharsToIgnore) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CharsToIgnore)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CharsToIgnore other) { - if (other == com.google.privacy.dlp.v2beta1.CharsToIgnore.getDefaultInstance()) return this; - switch (other.getCharactersCase()) { - case CHARACTERS_TO_SKIP: { - charactersCase_ = 1; - characters_ = other.characters_; - onChanged(); - break; - } - case COMMON_CHARACTERS_TO_IGNORE: { - setCommonCharactersToIgnoreValue(other.getCommonCharactersToIgnoreValue()); - break; - } - case CHARACTERS_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CharsToIgnore parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CharsToIgnore) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int charactersCase_ = 0; - private java.lang.Object characters_; - public CharactersCase - getCharactersCase() { - return CharactersCase.forNumber( - charactersCase_); - } - - public Builder clearCharacters() { - charactersCase_ = 0; - characters_ = null; - onChanged(); - return this; - } - - - /** - * string characters_to_skip = 1; - */ - public java.lang.String getCharactersToSkip() { - java.lang.Object ref = ""; - if (charactersCase_ == 1) { - ref = characters_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (charactersCase_ == 1) { - characters_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * string characters_to_skip = 1; - */ - public com.google.protobuf.ByteString - getCharactersToSkipBytes() { - java.lang.Object ref = ""; - if (charactersCase_ == 1) { - ref = characters_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - if (charactersCase_ == 1) { - characters_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * string characters_to_skip = 1; - */ - public Builder setCharactersToSkip( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - charactersCase_ = 1; - characters_ = value; - onChanged(); - return this; - } - /** - * string characters_to_skip = 1; - */ - public Builder clearCharactersToSkip() { - if (charactersCase_ == 1) { - charactersCase_ = 0; - characters_ = null; - onChanged(); - } - return this; - } - /** - * string characters_to_skip = 1; - */ - public Builder setCharactersToSkipBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - charactersCase_ = 1; - characters_ = value; - onChanged(); - return this; - } - - /** - * .google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup common_characters_to_ignore = 2; - */ - public int getCommonCharactersToIgnoreValue() { - if (charactersCase_ == 2) { - return ((java.lang.Integer) characters_).intValue(); - } - return 0; - } - /** - * .google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup common_characters_to_ignore = 2; - */ - public Builder setCommonCharactersToIgnoreValue(int value) { - charactersCase_ = 2; - characters_ = value; - onChanged(); - return this; - } - /** - * .google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup common_characters_to_ignore = 2; - */ - public com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup getCommonCharactersToIgnore() { - if (charactersCase_ == 2) { - com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup result = com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup.valueOf( - (java.lang.Integer) characters_); - return result == null ? com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup.UNRECOGNIZED : result; - } - return com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup.CHARACTER_GROUP_UNSPECIFIED; - } - /** - * .google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup common_characters_to_ignore = 2; - */ - public Builder setCommonCharactersToIgnore(com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup value) { - if (value == null) { - throw new NullPointerException(); - } - charactersCase_ = 2; - characters_ = value.getNumber(); - onChanged(); - return this; - } - /** - * .google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup common_characters_to_ignore = 2; - */ - public Builder clearCommonCharactersToIgnore() { - if (charactersCase_ == 2) { - charactersCase_ = 0; - characters_ = null; - onChanged(); - } - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CharsToIgnore) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CharsToIgnore) - private static final com.google.privacy.dlp.v2beta1.CharsToIgnore DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CharsToIgnore(); - } - - public static com.google.privacy.dlp.v2beta1.CharsToIgnore getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CharsToIgnore parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CharsToIgnore(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CharsToIgnore getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharsToIgnoreOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharsToIgnoreOrBuilder.java deleted file mode 100644 index f1cffae2daf2..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CharsToIgnoreOrBuilder.java +++ /dev/null @@ -1,30 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CharsToIgnoreOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CharsToIgnore) - com.google.protobuf.MessageOrBuilder { - - /** - * string characters_to_skip = 1; - */ - java.lang.String getCharactersToSkip(); - /** - * string characters_to_skip = 1; - */ - com.google.protobuf.ByteString - getCharactersToSkipBytes(); - - /** - * .google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup common_characters_to_ignore = 2; - */ - int getCommonCharactersToIgnoreValue(); - /** - * .google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup common_characters_to_ignore = 2; - */ - com.google.privacy.dlp.v2beta1.CharsToIgnore.CharacterGroup getCommonCharactersToIgnore(); - - public com.google.privacy.dlp.v2beta1.CharsToIgnore.CharactersCase getCharactersCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStorageKeyOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStorageKeyOrBuilder.java deleted file mode 100644 index 21d3ae3f8f26..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStorageKeyOrBuilder.java +++ /dev/null @@ -1,36 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CloudStorageKeyOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CloudStorageKey) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Path to the file.
-   * 
- * - * string file_path = 1; - */ - java.lang.String getFilePath(); - /** - *
-   * Path to the file.
-   * 
- * - * string file_path = 1; - */ - com.google.protobuf.ByteString - getFilePathBytes(); - - /** - *
-   * Byte offset of the referenced data in the file.
-   * 
- * - * int64 start_offset = 2; - */ - long getStartOffset(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStorageOptions.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStorageOptions.java deleted file mode 100644 index 4f79576f82d8..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStorageOptions.java +++ /dev/null @@ -1,1158 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Options defining a file or a set of files (path ending with *) within
- * a Google Cloud Storage bucket.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CloudStorageOptions} - */ -public final class CloudStorageOptions extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CloudStorageOptions) - CloudStorageOptionsOrBuilder { -private static final long serialVersionUID = 0L; - // Use CloudStorageOptions.newBuilder() to construct. - private CloudStorageOptions(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CloudStorageOptions() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CloudStorageOptions( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.Builder subBuilder = null; - if (fileSet_ != null) { - subBuilder = fileSet_.toBuilder(); - } - fileSet_ = input.readMessage(com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(fileSet_); - fileSet_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CloudStorageOptions.class, com.google.privacy.dlp.v2beta1.CloudStorageOptions.Builder.class); - } - - public interface FileSetOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * The url, in the format `gs://<bucket>/<path>`. Trailing wildcard in the
-     * path is allowed.
-     * 
- * - * string url = 1; - */ - java.lang.String getUrl(); - /** - *
-     * The url, in the format `gs://<bucket>/<path>`. Trailing wildcard in the
-     * path is allowed.
-     * 
- * - * string url = 1; - */ - com.google.protobuf.ByteString - getUrlBytes(); - } - /** - *
-   * Set of files to scan.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet} - */ - public static final class FileSet extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet) - FileSetOrBuilder { - private static final long serialVersionUID = 0L; - // Use FileSet.newBuilder() to construct. - private FileSet(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private FileSet() { - url_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private FileSet( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - url_ = s; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_FileSet_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_FileSet_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.class, com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.Builder.class); - } - - public static final int URL_FIELD_NUMBER = 1; - private volatile java.lang.Object url_; - /** - *
-     * The url, in the format `gs://<bucket>/<path>`. Trailing wildcard in the
-     * path is allowed.
-     * 
- * - * string url = 1; - */ - public java.lang.String getUrl() { - java.lang.Object ref = url_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - url_ = s; - return s; - } - } - /** - *
-     * The url, in the format `gs://<bucket>/<path>`. Trailing wildcard in the
-     * path is allowed.
-     * 
- * - * string url = 1; - */ - public com.google.protobuf.ByteString - getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getUrlBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, url_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getUrlBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, url_); - } - 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.privacy.dlp.v2beta1.CloudStorageOptions.FileSet)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet other = (com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet) obj; - - boolean result = true; - result = result && getUrl() - .equals(other.getUrl()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + URL_FIELD_NUMBER; - hash = (53 * hash) + getUrl().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet 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.privacy.dlp.v2beta1.CloudStorageOptions.FileSet parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet 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.privacy.dlp.v2beta1.CloudStorageOptions.FileSet parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet 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.privacy.dlp.v2beta1.CloudStorageOptions.FileSet parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * Set of files to scan.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet) - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSetOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_FileSet_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_FileSet_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.class, com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - url_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_FileSet_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet build() { - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet buildPartial() { - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet result = new com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet(this); - result.url_ = url_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet other) { - if (other == com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.getDefaultInstance()) return this; - if (!other.getUrl().isEmpty()) { - url_ = other.url_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object url_ = ""; - /** - *
-       * The url, in the format `gs://<bucket>/<path>`. Trailing wildcard in the
-       * path is allowed.
-       * 
- * - * string url = 1; - */ - public java.lang.String getUrl() { - java.lang.Object ref = url_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - url_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-       * The url, in the format `gs://<bucket>/<path>`. Trailing wildcard in the
-       * path is allowed.
-       * 
- * - * string url = 1; - */ - public com.google.protobuf.ByteString - getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-       * The url, in the format `gs://<bucket>/<path>`. Trailing wildcard in the
-       * path is allowed.
-       * 
- * - * string url = 1; - */ - public Builder setUrl( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - url_ = value; - onChanged(); - return this; - } - /** - *
-       * The url, in the format `gs://<bucket>/<path>`. Trailing wildcard in the
-       * path is allowed.
-       * 
- * - * string url = 1; - */ - public Builder clearUrl() { - - url_ = getDefaultInstance().getUrl(); - onChanged(); - return this; - } - /** - *
-       * The url, in the format `gs://<bucket>/<path>`. Trailing wildcard in the
-       * path is allowed.
-       * 
- * - * string url = 1; - */ - public Builder setUrlBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - url_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet) - private static final com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet(); - } - - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public FileSet parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new FileSet(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public static final int FILE_SET_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet fileSet_; - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public boolean hasFileSet() { - return fileSet_ != null; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet getFileSet() { - return fileSet_ == null ? com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.getDefaultInstance() : fileSet_; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSetOrBuilder getFileSetOrBuilder() { - return getFileSet(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (fileSet_ != null) { - output.writeMessage(1, getFileSet()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (fileSet_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getFileSet()); - } - 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.privacy.dlp.v2beta1.CloudStorageOptions)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CloudStorageOptions other = (com.google.privacy.dlp.v2beta1.CloudStorageOptions) obj; - - boolean result = true; - result = result && (hasFileSet() == other.hasFileSet()); - if (hasFileSet()) { - result = result && getFileSet() - .equals(other.getFileSet()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasFileSet()) { - hash = (37 * hash) + FILE_SET_FIELD_NUMBER; - hash = (53 * hash) + getFileSet().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions 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.privacy.dlp.v2beta1.CloudStorageOptions parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions 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.privacy.dlp.v2beta1.CloudStorageOptions parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions 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.privacy.dlp.v2beta1.CloudStorageOptions parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CloudStorageOptions prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Options defining a file or a set of files (path ending with *) within
-   * a Google Cloud Storage bucket.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CloudStorageOptions} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CloudStorageOptions) - com.google.privacy.dlp.v2beta1.CloudStorageOptionsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CloudStorageOptions.class, com.google.privacy.dlp.v2beta1.CloudStorageOptions.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CloudStorageOptions.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (fileSetBuilder_ == null) { - fileSet_ = null; - } else { - fileSet_ = null; - fileSetBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CloudStorageOptions getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CloudStorageOptions.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CloudStorageOptions build() { - com.google.privacy.dlp.v2beta1.CloudStorageOptions result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CloudStorageOptions buildPartial() { - com.google.privacy.dlp.v2beta1.CloudStorageOptions result = new com.google.privacy.dlp.v2beta1.CloudStorageOptions(this); - if (fileSetBuilder_ == null) { - result.fileSet_ = fileSet_; - } else { - result.fileSet_ = fileSetBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CloudStorageOptions) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CloudStorageOptions)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CloudStorageOptions other) { - if (other == com.google.privacy.dlp.v2beta1.CloudStorageOptions.getDefaultInstance()) return this; - if (other.hasFileSet()) { - mergeFileSet(other.getFileSet()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CloudStorageOptions parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CloudStorageOptions) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet fileSet_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet, com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.Builder, com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSetOrBuilder> fileSetBuilder_; - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public boolean hasFileSet() { - return fileSetBuilder_ != null || fileSet_ != null; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet getFileSet() { - if (fileSetBuilder_ == null) { - return fileSet_ == null ? com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.getDefaultInstance() : fileSet_; - } else { - return fileSetBuilder_.getMessage(); - } - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public Builder setFileSet(com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet value) { - if (fileSetBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - fileSet_ = value; - onChanged(); - } else { - fileSetBuilder_.setMessage(value); - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public Builder setFileSet( - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.Builder builderForValue) { - if (fileSetBuilder_ == null) { - fileSet_ = builderForValue.build(); - onChanged(); - } else { - fileSetBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public Builder mergeFileSet(com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet value) { - if (fileSetBuilder_ == null) { - if (fileSet_ != null) { - fileSet_ = - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.newBuilder(fileSet_).mergeFrom(value).buildPartial(); - } else { - fileSet_ = value; - } - onChanged(); - } else { - fileSetBuilder_.mergeFrom(value); - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public Builder clearFileSet() { - if (fileSetBuilder_ == null) { - fileSet_ = null; - onChanged(); - } else { - fileSet_ = null; - fileSetBuilder_ = null; - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.Builder getFileSetBuilder() { - - onChanged(); - return getFileSetFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSetOrBuilder getFileSetOrBuilder() { - if (fileSetBuilder_ != null) { - return fileSetBuilder_.getMessageOrBuilder(); - } else { - return fileSet_ == null ? - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.getDefaultInstance() : fileSet_; - } - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet, com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.Builder, com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSetOrBuilder> - getFileSetFieldBuilder() { - if (fileSetBuilder_ == null) { - fileSetBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet, com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet.Builder, com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSetOrBuilder>( - getFileSet(), - getParentForChildren(), - isClean()); - fileSet_ = null; - } - return fileSetBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CloudStorageOptions) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CloudStorageOptions) - private static final com.google.privacy.dlp.v2beta1.CloudStorageOptions DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CloudStorageOptions(); - } - - public static com.google.privacy.dlp.v2beta1.CloudStorageOptions getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CloudStorageOptions parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CloudStorageOptions(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CloudStorageOptions getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStorageOptionsOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStorageOptionsOrBuilder.java deleted file mode 100644 index e0d893925e67..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStorageOptionsOrBuilder.java +++ /dev/null @@ -1,22 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CloudStorageOptionsOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CloudStorageOptions) - com.google.protobuf.MessageOrBuilder { - - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - boolean hasFileSet(); - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet getFileSet(); - /** - * .google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet file_set = 1; - */ - com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSetOrBuilder getFileSetOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStoragePath.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStoragePath.java deleted file mode 100644 index c03e01ecae3d..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStoragePath.java +++ /dev/null @@ -1,552 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * A location in Cloud Storage.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CloudStoragePath} - */ -public final class CloudStoragePath extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CloudStoragePath) - CloudStoragePathOrBuilder { -private static final long serialVersionUID = 0L; - // Use CloudStoragePath.newBuilder() to construct. - private CloudStoragePath(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CloudStoragePath() { - path_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CloudStoragePath( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - path_ = s; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStoragePath_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStoragePath_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CloudStoragePath.class, com.google.privacy.dlp.v2beta1.CloudStoragePath.Builder.class); - } - - public static final int PATH_FIELD_NUMBER = 1; - private volatile java.lang.Object path_; - /** - *
-   * The url, in the format of `gs://bucket/<path>`.
-   * 
- * - * string path = 1; - */ - public java.lang.String getPath() { - java.lang.Object ref = path_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - path_ = s; - return s; - } - } - /** - *
-   * The url, in the format of `gs://bucket/<path>`.
-   * 
- * - * string path = 1; - */ - public com.google.protobuf.ByteString - getPathBytes() { - java.lang.Object ref = path_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - path_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getPathBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, path_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getPathBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, path_); - } - 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.privacy.dlp.v2beta1.CloudStoragePath)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CloudStoragePath other = (com.google.privacy.dlp.v2beta1.CloudStoragePath) obj; - - boolean result = true; - result = result && getPath() - .equals(other.getPath()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PATH_FIELD_NUMBER; - hash = (53 * hash) + getPath().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CloudStoragePath parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CloudStoragePath parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CloudStoragePath parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CloudStoragePath 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.privacy.dlp.v2beta1.CloudStoragePath parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CloudStoragePath parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CloudStoragePath parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CloudStoragePath 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.privacy.dlp.v2beta1.CloudStoragePath parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CloudStoragePath 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.privacy.dlp.v2beta1.CloudStoragePath parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CloudStoragePath parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CloudStoragePath prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * A location in Cloud Storage.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CloudStoragePath} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CloudStoragePath) - com.google.privacy.dlp.v2beta1.CloudStoragePathOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStoragePath_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStoragePath_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CloudStoragePath.class, com.google.privacy.dlp.v2beta1.CloudStoragePath.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CloudStoragePath.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - path_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStoragePath_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CloudStoragePath getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CloudStoragePath.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CloudStoragePath build() { - com.google.privacy.dlp.v2beta1.CloudStoragePath result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CloudStoragePath buildPartial() { - com.google.privacy.dlp.v2beta1.CloudStoragePath result = new com.google.privacy.dlp.v2beta1.CloudStoragePath(this); - result.path_ = path_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CloudStoragePath) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CloudStoragePath)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CloudStoragePath other) { - if (other == com.google.privacy.dlp.v2beta1.CloudStoragePath.getDefaultInstance()) return this; - if (!other.getPath().isEmpty()) { - path_ = other.path_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CloudStoragePath parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CloudStoragePath) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object path_ = ""; - /** - *
-     * The url, in the format of `gs://bucket/<path>`.
-     * 
- * - * string path = 1; - */ - public java.lang.String getPath() { - java.lang.Object ref = path_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - path_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * The url, in the format of `gs://bucket/<path>`.
-     * 
- * - * string path = 1; - */ - public com.google.protobuf.ByteString - getPathBytes() { - java.lang.Object ref = path_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - path_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * The url, in the format of `gs://bucket/<path>`.
-     * 
- * - * string path = 1; - */ - public Builder setPath( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - path_ = value; - onChanged(); - return this; - } - /** - *
-     * The url, in the format of `gs://bucket/<path>`.
-     * 
- * - * string path = 1; - */ - public Builder clearPath() { - - path_ = getDefaultInstance().getPath(); - onChanged(); - return this; - } - /** - *
-     * The url, in the format of `gs://bucket/<path>`.
-     * 
- * - * string path = 1; - */ - public Builder setPathBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - path_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CloudStoragePath) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CloudStoragePath) - private static final com.google.privacy.dlp.v2beta1.CloudStoragePath DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CloudStoragePath(); - } - - public static com.google.privacy.dlp.v2beta1.CloudStoragePath getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CloudStoragePath parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CloudStoragePath(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CloudStoragePath getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStoragePathOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStoragePathOrBuilder.java deleted file mode 100644 index 6217a87da394..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CloudStoragePathOrBuilder.java +++ /dev/null @@ -1,27 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CloudStoragePathOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CloudStoragePath) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The url, in the format of `gs://bucket/<path>`.
-   * 
- * - * string path = 1; - */ - java.lang.String getPath(); - /** - *
-   * The url, in the format of `gs://bucket/<path>`.
-   * 
- * - * string path = 1; - */ - com.google.protobuf.ByteString - getPathBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Color.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Color.java deleted file mode 100644 index 8d7836712f1c..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Color.java +++ /dev/null @@ -1,628 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Represents a color in the RGB color space.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Color} - */ -public final class Color extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.Color) - ColorOrBuilder { -private static final long serialVersionUID = 0L; - // Use Color.newBuilder() to construct. - private Color(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Color() { - red_ = 0F; - green_ = 0F; - blue_ = 0F; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Color( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 13: { - - red_ = input.readFloat(); - break; - } - case 21: { - - green_ = input.readFloat(); - break; - } - case 29: { - - blue_ = input.readFloat(); - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Color_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Color_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Color.class, com.google.privacy.dlp.v2beta1.Color.Builder.class); - } - - public static final int RED_FIELD_NUMBER = 1; - private float red_; - /** - *
-   * The amount of red in the color as a value in the interval [0, 1].
-   * 
- * - * float red = 1; - */ - public float getRed() { - return red_; - } - - public static final int GREEN_FIELD_NUMBER = 2; - private float green_; - /** - *
-   * The amount of green in the color as a value in the interval [0, 1].
-   * 
- * - * float green = 2; - */ - public float getGreen() { - return green_; - } - - public static final int BLUE_FIELD_NUMBER = 3; - private float blue_; - /** - *
-   * The amount of blue in the color as a value in the interval [0, 1].
-   * 
- * - * float blue = 3; - */ - public float getBlue() { - return blue_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (red_ != 0F) { - output.writeFloat(1, red_); - } - if (green_ != 0F) { - output.writeFloat(2, green_); - } - if (blue_ != 0F) { - output.writeFloat(3, blue_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (red_ != 0F) { - size += com.google.protobuf.CodedOutputStream - .computeFloatSize(1, red_); - } - if (green_ != 0F) { - size += com.google.protobuf.CodedOutputStream - .computeFloatSize(2, green_); - } - if (blue_ != 0F) { - size += com.google.protobuf.CodedOutputStream - .computeFloatSize(3, blue_); - } - 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.privacy.dlp.v2beta1.Color)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.Color other = (com.google.privacy.dlp.v2beta1.Color) obj; - - boolean result = true; - result = result && ( - java.lang.Float.floatToIntBits(getRed()) - == java.lang.Float.floatToIntBits( - other.getRed())); - result = result && ( - java.lang.Float.floatToIntBits(getGreen()) - == java.lang.Float.floatToIntBits( - other.getGreen())); - result = result && ( - java.lang.Float.floatToIntBits(getBlue()) - == java.lang.Float.floatToIntBits( - other.getBlue())); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + RED_FIELD_NUMBER; - hash = (53 * hash) + java.lang.Float.floatToIntBits( - getRed()); - hash = (37 * hash) + GREEN_FIELD_NUMBER; - hash = (53 * hash) + java.lang.Float.floatToIntBits( - getGreen()); - hash = (37 * hash) + BLUE_FIELD_NUMBER; - hash = (53 * hash) + java.lang.Float.floatToIntBits( - getBlue()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.Color parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Color parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Color parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Color 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.privacy.dlp.v2beta1.Color parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Color parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Color parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Color 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.privacy.dlp.v2beta1.Color parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Color 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.privacy.dlp.v2beta1.Color parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Color parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.Color prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Represents a color in the RGB color space.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Color} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.Color) - com.google.privacy.dlp.v2beta1.ColorOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Color_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Color_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Color.class, com.google.privacy.dlp.v2beta1.Color.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.Color.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - red_ = 0F; - - green_ = 0F; - - blue_ = 0F; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Color_descriptor; - } - - public com.google.privacy.dlp.v2beta1.Color getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.Color.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.Color build() { - com.google.privacy.dlp.v2beta1.Color result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.Color buildPartial() { - com.google.privacy.dlp.v2beta1.Color result = new com.google.privacy.dlp.v2beta1.Color(this); - result.red_ = red_; - result.green_ = green_; - result.blue_ = blue_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.Color) { - return mergeFrom((com.google.privacy.dlp.v2beta1.Color)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.Color other) { - if (other == com.google.privacy.dlp.v2beta1.Color.getDefaultInstance()) return this; - if (other.getRed() != 0F) { - setRed(other.getRed()); - } - if (other.getGreen() != 0F) { - setGreen(other.getGreen()); - } - if (other.getBlue() != 0F) { - setBlue(other.getBlue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.Color parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.Color) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private float red_ ; - /** - *
-     * The amount of red in the color as a value in the interval [0, 1].
-     * 
- * - * float red = 1; - */ - public float getRed() { - return red_; - } - /** - *
-     * The amount of red in the color as a value in the interval [0, 1].
-     * 
- * - * float red = 1; - */ - public Builder setRed(float value) { - - red_ = value; - onChanged(); - return this; - } - /** - *
-     * The amount of red in the color as a value in the interval [0, 1].
-     * 
- * - * float red = 1; - */ - public Builder clearRed() { - - red_ = 0F; - onChanged(); - return this; - } - - private float green_ ; - /** - *
-     * The amount of green in the color as a value in the interval [0, 1].
-     * 
- * - * float green = 2; - */ - public float getGreen() { - return green_; - } - /** - *
-     * The amount of green in the color as a value in the interval [0, 1].
-     * 
- * - * float green = 2; - */ - public Builder setGreen(float value) { - - green_ = value; - onChanged(); - return this; - } - /** - *
-     * The amount of green in the color as a value in the interval [0, 1].
-     * 
- * - * float green = 2; - */ - public Builder clearGreen() { - - green_ = 0F; - onChanged(); - return this; - } - - private float blue_ ; - /** - *
-     * The amount of blue in the color as a value in the interval [0, 1].
-     * 
- * - * float blue = 3; - */ - public float getBlue() { - return blue_; - } - /** - *
-     * The amount of blue in the color as a value in the interval [0, 1].
-     * 
- * - * float blue = 3; - */ - public Builder setBlue(float value) { - - blue_ = value; - onChanged(); - return this; - } - /** - *
-     * The amount of blue in the color as a value in the interval [0, 1].
-     * 
- * - * float blue = 3; - */ - public Builder clearBlue() { - - blue_ = 0F; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.Color) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.Color) - private static final com.google.privacy.dlp.v2beta1.Color DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.Color(); - } - - public static com.google.privacy.dlp.v2beta1.Color getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Color parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Color(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.Color getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ColorOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ColorOrBuilder.java deleted file mode 100644 index 94c856a417ff..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ColorOrBuilder.java +++ /dev/null @@ -1,36 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ColorOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.Color) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The amount of red in the color as a value in the interval [0, 1].
-   * 
- * - * float red = 1; - */ - float getRed(); - - /** - *
-   * The amount of green in the color as a value in the interval [0, 1].
-   * 
- * - * float green = 2; - */ - float getGreen(); - - /** - *
-   * The amount of blue in the color as a value in the interval [0, 1].
-   * 
- * - * float blue = 3; - */ - float getBlue(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ContentItem.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ContentItem.java deleted file mode 100644 index 7fd2012b8806..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ContentItem.java +++ /dev/null @@ -1,1159 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Container structure for the content to inspect.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ContentItem} - */ -public final class ContentItem extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ContentItem) - ContentItemOrBuilder { -private static final long serialVersionUID = 0L; - // Use ContentItem.newBuilder() to construct. - private ContentItem(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ContentItem() { - type_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ContentItem( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - type_ = s; - break; - } - case 18: { - dataItemCase_ = 2; - dataItem_ = input.readBytes(); - break; - } - case 26: { - java.lang.String s = input.readStringRequireUtf8(); - dataItemCase_ = 3; - dataItem_ = s; - break; - } - case 34: { - com.google.privacy.dlp.v2beta1.Table.Builder subBuilder = null; - if (dataItemCase_ == 4) { - subBuilder = ((com.google.privacy.dlp.v2beta1.Table) dataItem_).toBuilder(); - } - dataItem_ = - input.readMessage(com.google.privacy.dlp.v2beta1.Table.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.Table) dataItem_); - dataItem_ = subBuilder.buildPartial(); - } - dataItemCase_ = 4; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ContentItem_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ContentItem_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ContentItem.class, com.google.privacy.dlp.v2beta1.ContentItem.Builder.class); - } - - private int dataItemCase_ = 0; - private java.lang.Object dataItem_; - public enum DataItemCase - implements com.google.protobuf.Internal.EnumLite { - DATA(2), - VALUE(3), - TABLE(4), - DATAITEM_NOT_SET(0); - private final int value; - private DataItemCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static DataItemCase valueOf(int value) { - return forNumber(value); - } - - public static DataItemCase forNumber(int value) { - switch (value) { - case 2: return DATA; - case 3: return VALUE; - case 4: return TABLE; - case 0: return DATAITEM_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public DataItemCase - getDataItemCase() { - return DataItemCase.forNumber( - dataItemCase_); - } - - public static final int TYPE_FIELD_NUMBER = 1; - private volatile java.lang.Object type_; - /** - *
-   * Type of the content, as defined in Content-Type HTTP header.
-   * Supported types are: all "text" types, octet streams, PNG images,
-   * JPEG images.
-   * 
- * - * string type = 1; - */ - public java.lang.String getType() { - java.lang.Object ref = type_; - 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(); - type_ = s; - return s; - } - } - /** - *
-   * Type of the content, as defined in Content-Type HTTP header.
-   * Supported types are: all "text" types, octet streams, PNG images,
-   * JPEG images.
-   * 
- * - * string type = 1; - */ - public com.google.protobuf.ByteString - getTypeBytes() { - java.lang.Object ref = type_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - type_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DATA_FIELD_NUMBER = 2; - /** - *
-   * Content data to inspect or redact.
-   * 
- * - * bytes data = 2; - */ - public com.google.protobuf.ByteString getData() { - if (dataItemCase_ == 2) { - return (com.google.protobuf.ByteString) dataItem_; - } - return com.google.protobuf.ByteString.EMPTY; - } - - public static final int VALUE_FIELD_NUMBER = 3; - /** - *
-   * String data to inspect or redact.
-   * 
- * - * string value = 3; - */ - public java.lang.String getValue() { - java.lang.Object ref = ""; - if (dataItemCase_ == 3) { - ref = dataItem_; - } - 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 (dataItemCase_ == 3) { - dataItem_ = s; - } - return s; - } - } - /** - *
-   * String data to inspect or redact.
-   * 
- * - * string value = 3; - */ - public com.google.protobuf.ByteString - getValueBytes() { - java.lang.Object ref = ""; - if (dataItemCase_ == 3) { - ref = dataItem_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - if (dataItemCase_ == 3) { - dataItem_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TABLE_FIELD_NUMBER = 4; - /** - *
-   * Structured content for inspection.
-   * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public boolean hasTable() { - return dataItemCase_ == 4; - } - /** - *
-   * Structured content for inspection.
-   * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public com.google.privacy.dlp.v2beta1.Table getTable() { - if (dataItemCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.Table) dataItem_; - } - return com.google.privacy.dlp.v2beta1.Table.getDefaultInstance(); - } - /** - *
-   * Structured content for inspection.
-   * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public com.google.privacy.dlp.v2beta1.TableOrBuilder getTableOrBuilder() { - if (dataItemCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.Table) dataItem_; - } - return com.google.privacy.dlp.v2beta1.Table.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getTypeBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, type_); - } - if (dataItemCase_ == 2) { - output.writeBytes( - 2, (com.google.protobuf.ByteString) dataItem_); - } - if (dataItemCase_ == 3) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, dataItem_); - } - if (dataItemCase_ == 4) { - output.writeMessage(4, (com.google.privacy.dlp.v2beta1.Table) dataItem_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getTypeBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, type_); - } - if (dataItemCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize( - 2, (com.google.protobuf.ByteString) dataItem_); - } - if (dataItemCase_ == 3) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, dataItem_); - } - if (dataItemCase_ == 4) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, (com.google.privacy.dlp.v2beta1.Table) dataItem_); - } - 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.privacy.dlp.v2beta1.ContentItem)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ContentItem other = (com.google.privacy.dlp.v2beta1.ContentItem) obj; - - boolean result = true; - result = result && getType() - .equals(other.getType()); - result = result && getDataItemCase().equals( - other.getDataItemCase()); - if (!result) return false; - switch (dataItemCase_) { - case 2: - result = result && getData() - .equals(other.getData()); - break; - case 3: - result = result && getValue() - .equals(other.getValue()); - break; - case 4: - result = result && getTable() - .equals(other.getTable()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @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) + getType().hashCode(); - switch (dataItemCase_) { - case 2: - hash = (37 * hash) + DATA_FIELD_NUMBER; - hash = (53 * hash) + getData().hashCode(); - break; - case 3: - hash = (37 * hash) + VALUE_FIELD_NUMBER; - hash = (53 * hash) + getValue().hashCode(); - break; - case 4: - hash = (37 * hash) + TABLE_FIELD_NUMBER; - hash = (53 * hash) + getTable().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.ContentItem parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ContentItem parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ContentItem parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ContentItem 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.privacy.dlp.v2beta1.ContentItem parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ContentItem parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ContentItem parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ContentItem 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.privacy.dlp.v2beta1.ContentItem parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ContentItem 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.privacy.dlp.v2beta1.ContentItem parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ContentItem parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ContentItem prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Container structure for the content to inspect.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ContentItem} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ContentItem) - com.google.privacy.dlp.v2beta1.ContentItemOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ContentItem_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ContentItem_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ContentItem.class, com.google.privacy.dlp.v2beta1.ContentItem.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ContentItem.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - type_ = ""; - - dataItemCase_ = 0; - dataItem_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ContentItem_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ContentItem getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ContentItem build() { - com.google.privacy.dlp.v2beta1.ContentItem result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ContentItem buildPartial() { - com.google.privacy.dlp.v2beta1.ContentItem result = new com.google.privacy.dlp.v2beta1.ContentItem(this); - result.type_ = type_; - if (dataItemCase_ == 2) { - result.dataItem_ = dataItem_; - } - if (dataItemCase_ == 3) { - result.dataItem_ = dataItem_; - } - if (dataItemCase_ == 4) { - if (tableBuilder_ == null) { - result.dataItem_ = dataItem_; - } else { - result.dataItem_ = tableBuilder_.build(); - } - } - result.dataItemCase_ = dataItemCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ContentItem) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ContentItem)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ContentItem other) { - if (other == com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()) return this; - if (!other.getType().isEmpty()) { - type_ = other.type_; - onChanged(); - } - switch (other.getDataItemCase()) { - case DATA: { - setData(other.getData()); - break; - } - case VALUE: { - dataItemCase_ = 3; - dataItem_ = other.dataItem_; - onChanged(); - break; - } - case TABLE: { - mergeTable(other.getTable()); - break; - } - case DATAITEM_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ContentItem parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ContentItem) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int dataItemCase_ = 0; - private java.lang.Object dataItem_; - public DataItemCase - getDataItemCase() { - return DataItemCase.forNumber( - dataItemCase_); - } - - public Builder clearDataItem() { - dataItemCase_ = 0; - dataItem_ = null; - onChanged(); - return this; - } - - - private java.lang.Object type_ = ""; - /** - *
-     * Type of the content, as defined in Content-Type HTTP header.
-     * Supported types are: all "text" types, octet streams, PNG images,
-     * JPEG images.
-     * 
- * - * string type = 1; - */ - public java.lang.String getType() { - java.lang.Object ref = type_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - type_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * Type of the content, as defined in Content-Type HTTP header.
-     * Supported types are: all "text" types, octet streams, PNG images,
-     * JPEG images.
-     * 
- * - * string type = 1; - */ - public com.google.protobuf.ByteString - getTypeBytes() { - java.lang.Object ref = type_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - type_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * Type of the content, as defined in Content-Type HTTP header.
-     * Supported types are: all "text" types, octet streams, PNG images,
-     * JPEG images.
-     * 
- * - * string type = 1; - */ - public Builder setType( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - type_ = value; - onChanged(); - return this; - } - /** - *
-     * Type of the content, as defined in Content-Type HTTP header.
-     * Supported types are: all "text" types, octet streams, PNG images,
-     * JPEG images.
-     * 
- * - * string type = 1; - */ - public Builder clearType() { - - type_ = getDefaultInstance().getType(); - onChanged(); - return this; - } - /** - *
-     * Type of the content, as defined in Content-Type HTTP header.
-     * Supported types are: all "text" types, octet streams, PNG images,
-     * JPEG images.
-     * 
- * - * string type = 1; - */ - public Builder setTypeBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - type_ = value; - onChanged(); - return this; - } - - /** - *
-     * Content data to inspect or redact.
-     * 
- * - * bytes data = 2; - */ - public com.google.protobuf.ByteString getData() { - if (dataItemCase_ == 2) { - return (com.google.protobuf.ByteString) dataItem_; - } - return com.google.protobuf.ByteString.EMPTY; - } - /** - *
-     * Content data to inspect or redact.
-     * 
- * - * bytes data = 2; - */ - public Builder setData(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - dataItemCase_ = 2; - dataItem_ = value; - onChanged(); - return this; - } - /** - *
-     * Content data to inspect or redact.
-     * 
- * - * bytes data = 2; - */ - public Builder clearData() { - if (dataItemCase_ == 2) { - dataItemCase_ = 0; - dataItem_ = null; - onChanged(); - } - return this; - } - - /** - *
-     * String data to inspect or redact.
-     * 
- * - * string value = 3; - */ - public java.lang.String getValue() { - java.lang.Object ref = ""; - if (dataItemCase_ == 3) { - ref = dataItem_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (dataItemCase_ == 3) { - dataItem_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * String data to inspect or redact.
-     * 
- * - * string value = 3; - */ - public com.google.protobuf.ByteString - getValueBytes() { - java.lang.Object ref = ""; - if (dataItemCase_ == 3) { - ref = dataItem_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - if (dataItemCase_ == 3) { - dataItem_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * String data to inspect or redact.
-     * 
- * - * string value = 3; - */ - public Builder setValue( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - dataItemCase_ = 3; - dataItem_ = value; - onChanged(); - return this; - } - /** - *
-     * String data to inspect or redact.
-     * 
- * - * string value = 3; - */ - public Builder clearValue() { - if (dataItemCase_ == 3) { - dataItemCase_ = 0; - dataItem_ = null; - onChanged(); - } - return this; - } - /** - *
-     * String data to inspect or redact.
-     * 
- * - * string value = 3; - */ - public Builder setValueBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - dataItemCase_ = 3; - dataItem_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Table, com.google.privacy.dlp.v2beta1.Table.Builder, com.google.privacy.dlp.v2beta1.TableOrBuilder> tableBuilder_; - /** - *
-     * Structured content for inspection.
-     * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public boolean hasTable() { - return dataItemCase_ == 4; - } - /** - *
-     * Structured content for inspection.
-     * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public com.google.privacy.dlp.v2beta1.Table getTable() { - if (tableBuilder_ == null) { - if (dataItemCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.Table) dataItem_; - } - return com.google.privacy.dlp.v2beta1.Table.getDefaultInstance(); - } else { - if (dataItemCase_ == 4) { - return tableBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.Table.getDefaultInstance(); - } - } - /** - *
-     * Structured content for inspection.
-     * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public Builder setTable(com.google.privacy.dlp.v2beta1.Table value) { - if (tableBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - dataItem_ = value; - onChanged(); - } else { - tableBuilder_.setMessage(value); - } - dataItemCase_ = 4; - return this; - } - /** - *
-     * Structured content for inspection.
-     * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public Builder setTable( - com.google.privacy.dlp.v2beta1.Table.Builder builderForValue) { - if (tableBuilder_ == null) { - dataItem_ = builderForValue.build(); - onChanged(); - } else { - tableBuilder_.setMessage(builderForValue.build()); - } - dataItemCase_ = 4; - return this; - } - /** - *
-     * Structured content for inspection.
-     * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public Builder mergeTable(com.google.privacy.dlp.v2beta1.Table value) { - if (tableBuilder_ == null) { - if (dataItemCase_ == 4 && - dataItem_ != com.google.privacy.dlp.v2beta1.Table.getDefaultInstance()) { - dataItem_ = com.google.privacy.dlp.v2beta1.Table.newBuilder((com.google.privacy.dlp.v2beta1.Table) dataItem_) - .mergeFrom(value).buildPartial(); - } else { - dataItem_ = value; - } - onChanged(); - } else { - if (dataItemCase_ == 4) { - tableBuilder_.mergeFrom(value); - } - tableBuilder_.setMessage(value); - } - dataItemCase_ = 4; - return this; - } - /** - *
-     * Structured content for inspection.
-     * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public Builder clearTable() { - if (tableBuilder_ == null) { - if (dataItemCase_ == 4) { - dataItemCase_ = 0; - dataItem_ = null; - onChanged(); - } - } else { - if (dataItemCase_ == 4) { - dataItemCase_ = 0; - dataItem_ = null; - } - tableBuilder_.clear(); - } - return this; - } - /** - *
-     * Structured content for inspection.
-     * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public com.google.privacy.dlp.v2beta1.Table.Builder getTableBuilder() { - return getTableFieldBuilder().getBuilder(); - } - /** - *
-     * Structured content for inspection.
-     * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - public com.google.privacy.dlp.v2beta1.TableOrBuilder getTableOrBuilder() { - if ((dataItemCase_ == 4) && (tableBuilder_ != null)) { - return tableBuilder_.getMessageOrBuilder(); - } else { - if (dataItemCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.Table) dataItem_; - } - return com.google.privacy.dlp.v2beta1.Table.getDefaultInstance(); - } - } - /** - *
-     * Structured content for inspection.
-     * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Table, com.google.privacy.dlp.v2beta1.Table.Builder, com.google.privacy.dlp.v2beta1.TableOrBuilder> - getTableFieldBuilder() { - if (tableBuilder_ == null) { - if (!(dataItemCase_ == 4)) { - dataItem_ = com.google.privacy.dlp.v2beta1.Table.getDefaultInstance(); - } - tableBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Table, com.google.privacy.dlp.v2beta1.Table.Builder, com.google.privacy.dlp.v2beta1.TableOrBuilder>( - (com.google.privacy.dlp.v2beta1.Table) dataItem_, - getParentForChildren(), - isClean()); - dataItem_ = null; - } - dataItemCase_ = 4; - onChanged();; - return tableBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ContentItem) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ContentItem) - private static final com.google.privacy.dlp.v2beta1.ContentItem DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ContentItem(); - } - - public static com.google.privacy.dlp.v2beta1.ContentItem getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ContentItem parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ContentItem(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ContentItem getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ContentItemOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ContentItemOrBuilder.java deleted file mode 100644 index 19942f13f610..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ContentItemOrBuilder.java +++ /dev/null @@ -1,85 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ContentItemOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ContentItem) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Type of the content, as defined in Content-Type HTTP header.
-   * Supported types are: all "text" types, octet streams, PNG images,
-   * JPEG images.
-   * 
- * - * string type = 1; - */ - java.lang.String getType(); - /** - *
-   * Type of the content, as defined in Content-Type HTTP header.
-   * Supported types are: all "text" types, octet streams, PNG images,
-   * JPEG images.
-   * 
- * - * string type = 1; - */ - com.google.protobuf.ByteString - getTypeBytes(); - - /** - *
-   * Content data to inspect or redact.
-   * 
- * - * bytes data = 2; - */ - com.google.protobuf.ByteString getData(); - - /** - *
-   * String data to inspect or redact.
-   * 
- * - * string value = 3; - */ - java.lang.String getValue(); - /** - *
-   * String data to inspect or redact.
-   * 
- * - * string value = 3; - */ - com.google.protobuf.ByteString - getValueBytes(); - - /** - *
-   * Structured content for inspection.
-   * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - boolean hasTable(); - /** - *
-   * Structured content for inspection.
-   * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - com.google.privacy.dlp.v2beta1.Table getTable(); - /** - *
-   * Structured content for inspection.
-   * 
- * - * .google.privacy.dlp.v2beta1.Table table = 4; - */ - com.google.privacy.dlp.v2beta1.TableOrBuilder getTableOrBuilder(); - - public com.google.privacy.dlp.v2beta1.ContentItem.DataItemCase getDataItemCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CreateInspectOperationRequest.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CreateInspectOperationRequest.java deleted file mode 100644 index 1b9f3c826f40..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CreateInspectOperationRequest.java +++ /dev/null @@ -1,1315 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Request for scheduling a scan of a data subset from a Google Platform data
- * repository.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CreateInspectOperationRequest} - */ -public final class CreateInspectOperationRequest extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CreateInspectOperationRequest) - CreateInspectOperationRequestOrBuilder { -private static final long serialVersionUID = 0L; - // Use CreateInspectOperationRequest.newBuilder() to construct. - private CreateInspectOperationRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CreateInspectOperationRequest() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CreateInspectOperationRequest( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InspectConfig.Builder subBuilder = null; - if (inspectConfig_ != null) { - subBuilder = inspectConfig_.toBuilder(); - } - inspectConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.InspectConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(inspectConfig_); - inspectConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.StorageConfig.Builder subBuilder = null; - if (storageConfig_ != null) { - subBuilder = storageConfig_.toBuilder(); - } - storageConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.StorageConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(storageConfig_); - storageConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder subBuilder = null; - if (outputConfig_ != null) { - subBuilder = outputConfig_.toBuilder(); - } - outputConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.OutputStorageConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(outputConfig_); - outputConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 42: { - com.google.privacy.dlp.v2beta1.OperationConfig.Builder subBuilder = null; - if (operationConfig_ != null) { - subBuilder = operationConfig_.toBuilder(); - } - operationConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.OperationConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(operationConfig_); - operationConfig_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CreateInspectOperationRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CreateInspectOperationRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest.class, com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest.Builder.class); - } - - public static final int INSPECT_CONFIG_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.InspectConfig inspectConfig_; - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public boolean hasInspectConfig() { - return inspectConfig_ != null; - } - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig() { - return inspectConfig_ == null ? com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder() { - return getInspectConfig(); - } - - public static final int STORAGE_CONFIG_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.StorageConfig storageConfig_; - /** - *
-   * Specification of the data set to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public boolean hasStorageConfig() { - return storageConfig_ != null; - } - /** - *
-   * Specification of the data set to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public com.google.privacy.dlp.v2beta1.StorageConfig getStorageConfig() { - return storageConfig_ == null ? com.google.privacy.dlp.v2beta1.StorageConfig.getDefaultInstance() : storageConfig_; - } - /** - *
-   * Specification of the data set to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder getStorageConfigOrBuilder() { - return getStorageConfig(); - } - - public static final int OUTPUT_CONFIG_FIELD_NUMBER = 3; - private com.google.privacy.dlp.v2beta1.OutputStorageConfig outputConfig_; - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public boolean hasOutputConfig() { - return outputConfig_ != null; - } - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public com.google.privacy.dlp.v2beta1.OutputStorageConfig getOutputConfig() { - return outputConfig_ == null ? com.google.privacy.dlp.v2beta1.OutputStorageConfig.getDefaultInstance() : outputConfig_; - } - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder getOutputConfigOrBuilder() { - return getOutputConfig(); - } - - public static final int OPERATION_CONFIG_FIELD_NUMBER = 5; - private com.google.privacy.dlp.v2beta1.OperationConfig operationConfig_; - /** - *
-   * Additional configuration settings for long running operations.
-   * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public boolean hasOperationConfig() { - return operationConfig_ != null; - } - /** - *
-   * Additional configuration settings for long running operations.
-   * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public com.google.privacy.dlp.v2beta1.OperationConfig getOperationConfig() { - return operationConfig_ == null ? com.google.privacy.dlp.v2beta1.OperationConfig.getDefaultInstance() : operationConfig_; - } - /** - *
-   * Additional configuration settings for long running operations.
-   * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public com.google.privacy.dlp.v2beta1.OperationConfigOrBuilder getOperationConfigOrBuilder() { - return getOperationConfig(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (inspectConfig_ != null) { - output.writeMessage(1, getInspectConfig()); - } - if (storageConfig_ != null) { - output.writeMessage(2, getStorageConfig()); - } - if (outputConfig_ != null) { - output.writeMessage(3, getOutputConfig()); - } - if (operationConfig_ != null) { - output.writeMessage(5, getOperationConfig()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (inspectConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getInspectConfig()); - } - if (storageConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getStorageConfig()); - } - if (outputConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, getOutputConfig()); - } - if (operationConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, getOperationConfig()); - } - 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.privacy.dlp.v2beta1.CreateInspectOperationRequest)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest other = (com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest) obj; - - boolean result = true; - result = result && (hasInspectConfig() == other.hasInspectConfig()); - if (hasInspectConfig()) { - result = result && getInspectConfig() - .equals(other.getInspectConfig()); - } - result = result && (hasStorageConfig() == other.hasStorageConfig()); - if (hasStorageConfig()) { - result = result && getStorageConfig() - .equals(other.getStorageConfig()); - } - result = result && (hasOutputConfig() == other.hasOutputConfig()); - if (hasOutputConfig()) { - result = result && getOutputConfig() - .equals(other.getOutputConfig()); - } - result = result && (hasOperationConfig() == other.hasOperationConfig()); - if (hasOperationConfig()) { - result = result && getOperationConfig() - .equals(other.getOperationConfig()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasInspectConfig()) { - hash = (37 * hash) + INSPECT_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getInspectConfig().hashCode(); - } - if (hasStorageConfig()) { - hash = (37 * hash) + STORAGE_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getStorageConfig().hashCode(); - } - if (hasOutputConfig()) { - hash = (37 * hash) + OUTPUT_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getOutputConfig().hashCode(); - } - if (hasOperationConfig()) { - hash = (37 * hash) + OPERATION_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getOperationConfig().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest 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.privacy.dlp.v2beta1.CreateInspectOperationRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest 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.privacy.dlp.v2beta1.CreateInspectOperationRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest 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.privacy.dlp.v2beta1.CreateInspectOperationRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Request for scheduling a scan of a data subset from a Google Platform data
-   * repository.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CreateInspectOperationRequest} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CreateInspectOperationRequest) - com.google.privacy.dlp.v2beta1.CreateInspectOperationRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CreateInspectOperationRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CreateInspectOperationRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest.class, com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (inspectConfigBuilder_ == null) { - inspectConfig_ = null; - } else { - inspectConfig_ = null; - inspectConfigBuilder_ = null; - } - if (storageConfigBuilder_ == null) { - storageConfig_ = null; - } else { - storageConfig_ = null; - storageConfigBuilder_ = null; - } - if (outputConfigBuilder_ == null) { - outputConfig_ = null; - } else { - outputConfig_ = null; - outputConfigBuilder_ = null; - } - if (operationConfigBuilder_ == null) { - operationConfig_ = null; - } else { - operationConfig_ = null; - operationConfigBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CreateInspectOperationRequest_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest build() { - com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest buildPartial() { - com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest result = new com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest(this); - if (inspectConfigBuilder_ == null) { - result.inspectConfig_ = inspectConfig_; - } else { - result.inspectConfig_ = inspectConfigBuilder_.build(); - } - if (storageConfigBuilder_ == null) { - result.storageConfig_ = storageConfig_; - } else { - result.storageConfig_ = storageConfigBuilder_.build(); - } - if (outputConfigBuilder_ == null) { - result.outputConfig_ = outputConfig_; - } else { - result.outputConfig_ = outputConfigBuilder_.build(); - } - if (operationConfigBuilder_ == null) { - result.operationConfig_ = operationConfig_; - } else { - result.operationConfig_ = operationConfigBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest other) { - if (other == com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest.getDefaultInstance()) return this; - if (other.hasInspectConfig()) { - mergeInspectConfig(other.getInspectConfig()); - } - if (other.hasStorageConfig()) { - mergeStorageConfig(other.getStorageConfig()); - } - if (other.hasOutputConfig()) { - mergeOutputConfig(other.getOutputConfig()); - } - if (other.hasOperationConfig()) { - mergeOperationConfig(other.getOperationConfig()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.InspectConfig inspectConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder> inspectConfigBuilder_; - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public boolean hasInspectConfig() { - return inspectConfigBuilder_ != null || inspectConfig_ != null; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig() { - if (inspectConfigBuilder_ == null) { - return inspectConfig_ == null ? com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } else { - return inspectConfigBuilder_.getMessage(); - } - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder setInspectConfig(com.google.privacy.dlp.v2beta1.InspectConfig value) { - if (inspectConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - inspectConfig_ = value; - onChanged(); - } else { - inspectConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder setInspectConfig( - com.google.privacy.dlp.v2beta1.InspectConfig.Builder builderForValue) { - if (inspectConfigBuilder_ == null) { - inspectConfig_ = builderForValue.build(); - onChanged(); - } else { - inspectConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder mergeInspectConfig(com.google.privacy.dlp.v2beta1.InspectConfig value) { - if (inspectConfigBuilder_ == null) { - if (inspectConfig_ != null) { - inspectConfig_ = - com.google.privacy.dlp.v2beta1.InspectConfig.newBuilder(inspectConfig_).mergeFrom(value).buildPartial(); - } else { - inspectConfig_ = value; - } - onChanged(); - } else { - inspectConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder clearInspectConfig() { - if (inspectConfigBuilder_ == null) { - inspectConfig_ = null; - onChanged(); - } else { - inspectConfig_ = null; - inspectConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.Builder getInspectConfigBuilder() { - - onChanged(); - return getInspectConfigFieldBuilder().getBuilder(); - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder() { - if (inspectConfigBuilder_ != null) { - return inspectConfigBuilder_.getMessageOrBuilder(); - } else { - return inspectConfig_ == null ? - com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder> - getInspectConfigFieldBuilder() { - if (inspectConfigBuilder_ == null) { - inspectConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder>( - getInspectConfig(), - getParentForChildren(), - isClean()); - inspectConfig_ = null; - } - return inspectConfigBuilder_; - } - - private com.google.privacy.dlp.v2beta1.StorageConfig storageConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.StorageConfig, com.google.privacy.dlp.v2beta1.StorageConfig.Builder, com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder> storageConfigBuilder_; - /** - *
-     * Specification of the data set to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public boolean hasStorageConfig() { - return storageConfigBuilder_ != null || storageConfig_ != null; - } - /** - *
-     * Specification of the data set to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public com.google.privacy.dlp.v2beta1.StorageConfig getStorageConfig() { - if (storageConfigBuilder_ == null) { - return storageConfig_ == null ? com.google.privacy.dlp.v2beta1.StorageConfig.getDefaultInstance() : storageConfig_; - } else { - return storageConfigBuilder_.getMessage(); - } - } - /** - *
-     * Specification of the data set to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public Builder setStorageConfig(com.google.privacy.dlp.v2beta1.StorageConfig value) { - if (storageConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - storageConfig_ = value; - onChanged(); - } else { - storageConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Specification of the data set to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public Builder setStorageConfig( - com.google.privacy.dlp.v2beta1.StorageConfig.Builder builderForValue) { - if (storageConfigBuilder_ == null) { - storageConfig_ = builderForValue.build(); - onChanged(); - } else { - storageConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Specification of the data set to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public Builder mergeStorageConfig(com.google.privacy.dlp.v2beta1.StorageConfig value) { - if (storageConfigBuilder_ == null) { - if (storageConfig_ != null) { - storageConfig_ = - com.google.privacy.dlp.v2beta1.StorageConfig.newBuilder(storageConfig_).mergeFrom(value).buildPartial(); - } else { - storageConfig_ = value; - } - onChanged(); - } else { - storageConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Specification of the data set to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public Builder clearStorageConfig() { - if (storageConfigBuilder_ == null) { - storageConfig_ = null; - onChanged(); - } else { - storageConfig_ = null; - storageConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * Specification of the data set to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public com.google.privacy.dlp.v2beta1.StorageConfig.Builder getStorageConfigBuilder() { - - onChanged(); - return getStorageConfigFieldBuilder().getBuilder(); - } - /** - *
-     * Specification of the data set to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - public com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder getStorageConfigOrBuilder() { - if (storageConfigBuilder_ != null) { - return storageConfigBuilder_.getMessageOrBuilder(); - } else { - return storageConfig_ == null ? - com.google.privacy.dlp.v2beta1.StorageConfig.getDefaultInstance() : storageConfig_; - } - } - /** - *
-     * Specification of the data set to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.StorageConfig, com.google.privacy.dlp.v2beta1.StorageConfig.Builder, com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder> - getStorageConfigFieldBuilder() { - if (storageConfigBuilder_ == null) { - storageConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.StorageConfig, com.google.privacy.dlp.v2beta1.StorageConfig.Builder, com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder>( - getStorageConfig(), - getParentForChildren(), - isClean()); - storageConfig_ = null; - } - return storageConfigBuilder_; - } - - private com.google.privacy.dlp.v2beta1.OutputStorageConfig outputConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.OutputStorageConfig, com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder, com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder> outputConfigBuilder_; - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public boolean hasOutputConfig() { - return outputConfigBuilder_ != null || outputConfig_ != null; - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public com.google.privacy.dlp.v2beta1.OutputStorageConfig getOutputConfig() { - if (outputConfigBuilder_ == null) { - return outputConfig_ == null ? com.google.privacy.dlp.v2beta1.OutputStorageConfig.getDefaultInstance() : outputConfig_; - } else { - return outputConfigBuilder_.getMessage(); - } - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public Builder setOutputConfig(com.google.privacy.dlp.v2beta1.OutputStorageConfig value) { - if (outputConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - outputConfig_ = value; - onChanged(); - } else { - outputConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public Builder setOutputConfig( - com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder builderForValue) { - if (outputConfigBuilder_ == null) { - outputConfig_ = builderForValue.build(); - onChanged(); - } else { - outputConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public Builder mergeOutputConfig(com.google.privacy.dlp.v2beta1.OutputStorageConfig value) { - if (outputConfigBuilder_ == null) { - if (outputConfig_ != null) { - outputConfig_ = - com.google.privacy.dlp.v2beta1.OutputStorageConfig.newBuilder(outputConfig_).mergeFrom(value).buildPartial(); - } else { - outputConfig_ = value; - } - onChanged(); - } else { - outputConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public Builder clearOutputConfig() { - if (outputConfigBuilder_ == null) { - outputConfig_ = null; - onChanged(); - } else { - outputConfig_ = null; - outputConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder getOutputConfigBuilder() { - - onChanged(); - return getOutputConfigFieldBuilder().getBuilder(); - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - public com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder getOutputConfigOrBuilder() { - if (outputConfigBuilder_ != null) { - return outputConfigBuilder_.getMessageOrBuilder(); - } else { - return outputConfig_ == null ? - com.google.privacy.dlp.v2beta1.OutputStorageConfig.getDefaultInstance() : outputConfig_; - } - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.OutputStorageConfig, com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder, com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder> - getOutputConfigFieldBuilder() { - if (outputConfigBuilder_ == null) { - outputConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.OutputStorageConfig, com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder, com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder>( - getOutputConfig(), - getParentForChildren(), - isClean()); - outputConfig_ = null; - } - return outputConfigBuilder_; - } - - private com.google.privacy.dlp.v2beta1.OperationConfig operationConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.OperationConfig, com.google.privacy.dlp.v2beta1.OperationConfig.Builder, com.google.privacy.dlp.v2beta1.OperationConfigOrBuilder> operationConfigBuilder_; - /** - *
-     * Additional configuration settings for long running operations.
-     * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public boolean hasOperationConfig() { - return operationConfigBuilder_ != null || operationConfig_ != null; - } - /** - *
-     * Additional configuration settings for long running operations.
-     * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public com.google.privacy.dlp.v2beta1.OperationConfig getOperationConfig() { - if (operationConfigBuilder_ == null) { - return operationConfig_ == null ? com.google.privacy.dlp.v2beta1.OperationConfig.getDefaultInstance() : operationConfig_; - } else { - return operationConfigBuilder_.getMessage(); - } - } - /** - *
-     * Additional configuration settings for long running operations.
-     * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public Builder setOperationConfig(com.google.privacy.dlp.v2beta1.OperationConfig value) { - if (operationConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - operationConfig_ = value; - onChanged(); - } else { - operationConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Additional configuration settings for long running operations.
-     * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public Builder setOperationConfig( - com.google.privacy.dlp.v2beta1.OperationConfig.Builder builderForValue) { - if (operationConfigBuilder_ == null) { - operationConfig_ = builderForValue.build(); - onChanged(); - } else { - operationConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Additional configuration settings for long running operations.
-     * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public Builder mergeOperationConfig(com.google.privacy.dlp.v2beta1.OperationConfig value) { - if (operationConfigBuilder_ == null) { - if (operationConfig_ != null) { - operationConfig_ = - com.google.privacy.dlp.v2beta1.OperationConfig.newBuilder(operationConfig_).mergeFrom(value).buildPartial(); - } else { - operationConfig_ = value; - } - onChanged(); - } else { - operationConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Additional configuration settings for long running operations.
-     * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public Builder clearOperationConfig() { - if (operationConfigBuilder_ == null) { - operationConfig_ = null; - onChanged(); - } else { - operationConfig_ = null; - operationConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * Additional configuration settings for long running operations.
-     * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public com.google.privacy.dlp.v2beta1.OperationConfig.Builder getOperationConfigBuilder() { - - onChanged(); - return getOperationConfigFieldBuilder().getBuilder(); - } - /** - *
-     * Additional configuration settings for long running operations.
-     * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - public com.google.privacy.dlp.v2beta1.OperationConfigOrBuilder getOperationConfigOrBuilder() { - if (operationConfigBuilder_ != null) { - return operationConfigBuilder_.getMessageOrBuilder(); - } else { - return operationConfig_ == null ? - com.google.privacy.dlp.v2beta1.OperationConfig.getDefaultInstance() : operationConfig_; - } - } - /** - *
-     * Additional configuration settings for long running operations.
-     * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.OperationConfig, com.google.privacy.dlp.v2beta1.OperationConfig.Builder, com.google.privacy.dlp.v2beta1.OperationConfigOrBuilder> - getOperationConfigFieldBuilder() { - if (operationConfigBuilder_ == null) { - operationConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.OperationConfig, com.google.privacy.dlp.v2beta1.OperationConfig.Builder, com.google.privacy.dlp.v2beta1.OperationConfigOrBuilder>( - getOperationConfig(), - getParentForChildren(), - isClean()); - operationConfig_ = null; - } - return operationConfigBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CreateInspectOperationRequest) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CreateInspectOperationRequest) - private static final com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest(); - } - - public static com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CreateInspectOperationRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateInspectOperationRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CreateInspectOperationRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CreateInspectOperationRequestOrBuilder.java deleted file mode 100644 index 983fed9533db..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CreateInspectOperationRequestOrBuilder.java +++ /dev/null @@ -1,109 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CreateInspectOperationRequestOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CreateInspectOperationRequest) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - boolean hasInspectConfig(); - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig(); - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder(); - - /** - *
-   * Specification of the data set to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - boolean hasStorageConfig(); - /** - *
-   * Specification of the data set to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - com.google.privacy.dlp.v2beta1.StorageConfig getStorageConfig(); - /** - *
-   * Specification of the data set to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig storage_config = 2; - */ - com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder getStorageConfigOrBuilder(); - - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - boolean hasOutputConfig(); - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - com.google.privacy.dlp.v2beta1.OutputStorageConfig getOutputConfig(); - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig output_config = 3; - */ - com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder getOutputConfigOrBuilder(); - - /** - *
-   * Additional configuration settings for long running operations.
-   * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - boolean hasOperationConfig(); - /** - *
-   * Additional configuration settings for long running operations.
-   * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - com.google.privacy.dlp.v2beta1.OperationConfig getOperationConfig(); - /** - *
-   * Additional configuration settings for long running operations.
-   * 
- * - * .google.privacy.dlp.v2beta1.OperationConfig operation_config = 5; - */ - com.google.privacy.dlp.v2beta1.OperationConfigOrBuilder getOperationConfigOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoHashConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoHashConfig.java deleted file mode 100644 index 7e3b0ae292ce..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoHashConfig.java +++ /dev/null @@ -1,634 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Pseudonymization method that generates surrogates via cryptographic hashing.
- * Uses SHA-256.
- * Outputs a 32 byte digest as an uppercase hex string
- * (for example, 41D1567F7F99F1DC2A5FAB886DEE5BEE).
- * Currently, only string and integer values can be hashed.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CryptoHashConfig} - */ -public final class CryptoHashConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CryptoHashConfig) - CryptoHashConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use CryptoHashConfig.newBuilder() to construct. - private CryptoHashConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CryptoHashConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CryptoHashConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.CryptoKey.Builder subBuilder = null; - if (cryptoKey_ != null) { - subBuilder = cryptoKey_.toBuilder(); - } - cryptoKey_ = input.readMessage(com.google.privacy.dlp.v2beta1.CryptoKey.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(cryptoKey_); - cryptoKey_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoHashConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoHashConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CryptoHashConfig.class, com.google.privacy.dlp.v2beta1.CryptoHashConfig.Builder.class); - } - - public static final int CRYPTO_KEY_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.CryptoKey cryptoKey_; - /** - *
-   * The key used by the hash function.
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public boolean hasCryptoKey() { - return cryptoKey_ != null; - } - /** - *
-   * The key used by the hash function.
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CryptoKey getCryptoKey() { - return cryptoKey_ == null ? com.google.privacy.dlp.v2beta1.CryptoKey.getDefaultInstance() : cryptoKey_; - } - /** - *
-   * The key used by the hash function.
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder getCryptoKeyOrBuilder() { - return getCryptoKey(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (cryptoKey_ != null) { - output.writeMessage(1, getCryptoKey()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (cryptoKey_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getCryptoKey()); - } - 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.privacy.dlp.v2beta1.CryptoHashConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CryptoHashConfig other = (com.google.privacy.dlp.v2beta1.CryptoHashConfig) obj; - - boolean result = true; - result = result && (hasCryptoKey() == other.hasCryptoKey()); - if (hasCryptoKey()) { - result = result && getCryptoKey() - .equals(other.getCryptoKey()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasCryptoKey()) { - hash = (37 * hash) + CRYPTO_KEY_FIELD_NUMBER; - hash = (53 * hash) + getCryptoKey().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CryptoHashConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CryptoHashConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CryptoHashConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CryptoHashConfig 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.privacy.dlp.v2beta1.CryptoHashConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CryptoHashConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CryptoHashConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CryptoHashConfig 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.privacy.dlp.v2beta1.CryptoHashConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CryptoHashConfig 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.privacy.dlp.v2beta1.CryptoHashConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CryptoHashConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CryptoHashConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Pseudonymization method that generates surrogates via cryptographic hashing.
-   * Uses SHA-256.
-   * Outputs a 32 byte digest as an uppercase hex string
-   * (for example, 41D1567F7F99F1DC2A5FAB886DEE5BEE).
-   * Currently, only string and integer values can be hashed.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CryptoHashConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CryptoHashConfig) - com.google.privacy.dlp.v2beta1.CryptoHashConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoHashConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoHashConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CryptoHashConfig.class, com.google.privacy.dlp.v2beta1.CryptoHashConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CryptoHashConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (cryptoKeyBuilder_ == null) { - cryptoKey_ = null; - } else { - cryptoKey_ = null; - cryptoKeyBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoHashConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CryptoHashConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CryptoHashConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CryptoHashConfig build() { - com.google.privacy.dlp.v2beta1.CryptoHashConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CryptoHashConfig buildPartial() { - com.google.privacy.dlp.v2beta1.CryptoHashConfig result = new com.google.privacy.dlp.v2beta1.CryptoHashConfig(this); - if (cryptoKeyBuilder_ == null) { - result.cryptoKey_ = cryptoKey_; - } else { - result.cryptoKey_ = cryptoKeyBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CryptoHashConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CryptoHashConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CryptoHashConfig other) { - if (other == com.google.privacy.dlp.v2beta1.CryptoHashConfig.getDefaultInstance()) return this; - if (other.hasCryptoKey()) { - mergeCryptoKey(other.getCryptoKey()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CryptoHashConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CryptoHashConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.CryptoKey cryptoKey_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoKey, com.google.privacy.dlp.v2beta1.CryptoKey.Builder, com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder> cryptoKeyBuilder_; - /** - *
-     * The key used by the hash function.
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public boolean hasCryptoKey() { - return cryptoKeyBuilder_ != null || cryptoKey_ != null; - } - /** - *
-     * The key used by the hash function.
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CryptoKey getCryptoKey() { - if (cryptoKeyBuilder_ == null) { - return cryptoKey_ == null ? com.google.privacy.dlp.v2beta1.CryptoKey.getDefaultInstance() : cryptoKey_; - } else { - return cryptoKeyBuilder_.getMessage(); - } - } - /** - *
-     * The key used by the hash function.
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public Builder setCryptoKey(com.google.privacy.dlp.v2beta1.CryptoKey value) { - if (cryptoKeyBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - cryptoKey_ = value; - onChanged(); - } else { - cryptoKeyBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The key used by the hash function.
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public Builder setCryptoKey( - com.google.privacy.dlp.v2beta1.CryptoKey.Builder builderForValue) { - if (cryptoKeyBuilder_ == null) { - cryptoKey_ = builderForValue.build(); - onChanged(); - } else { - cryptoKeyBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The key used by the hash function.
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public Builder mergeCryptoKey(com.google.privacy.dlp.v2beta1.CryptoKey value) { - if (cryptoKeyBuilder_ == null) { - if (cryptoKey_ != null) { - cryptoKey_ = - com.google.privacy.dlp.v2beta1.CryptoKey.newBuilder(cryptoKey_).mergeFrom(value).buildPartial(); - } else { - cryptoKey_ = value; - } - onChanged(); - } else { - cryptoKeyBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The key used by the hash function.
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public Builder clearCryptoKey() { - if (cryptoKeyBuilder_ == null) { - cryptoKey_ = null; - onChanged(); - } else { - cryptoKey_ = null; - cryptoKeyBuilder_ = null; - } - - return this; - } - /** - *
-     * The key used by the hash function.
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CryptoKey.Builder getCryptoKeyBuilder() { - - onChanged(); - return getCryptoKeyFieldBuilder().getBuilder(); - } - /** - *
-     * The key used by the hash function.
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder getCryptoKeyOrBuilder() { - if (cryptoKeyBuilder_ != null) { - return cryptoKeyBuilder_.getMessageOrBuilder(); - } else { - return cryptoKey_ == null ? - com.google.privacy.dlp.v2beta1.CryptoKey.getDefaultInstance() : cryptoKey_; - } - } - /** - *
-     * The key used by the hash function.
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoKey, com.google.privacy.dlp.v2beta1.CryptoKey.Builder, com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder> - getCryptoKeyFieldBuilder() { - if (cryptoKeyBuilder_ == null) { - cryptoKeyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoKey, com.google.privacy.dlp.v2beta1.CryptoKey.Builder, com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder>( - getCryptoKey(), - getParentForChildren(), - isClean()); - cryptoKey_ = null; - } - return cryptoKeyBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CryptoHashConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CryptoHashConfig) - private static final com.google.privacy.dlp.v2beta1.CryptoHashConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CryptoHashConfig(); - } - - public static com.google.privacy.dlp.v2beta1.CryptoHashConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CryptoHashConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CryptoHashConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CryptoHashConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoHashConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoHashConfigOrBuilder.java deleted file mode 100644 index 77d2ee083d19..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoHashConfigOrBuilder.java +++ /dev/null @@ -1,34 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CryptoHashConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CryptoHashConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The key used by the hash function.
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - boolean hasCryptoKey(); - /** - *
-   * The key used by the hash function.
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - com.google.privacy.dlp.v2beta1.CryptoKey getCryptoKey(); - /** - *
-   * The key used by the hash function.
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder getCryptoKeyOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoKey.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoKey.java deleted file mode 100644 index 5b42dfdfb54f..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoKey.java +++ /dev/null @@ -1,1085 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * This is a data encryption key (DEK) (as opposed to
- * a key encryption key (KEK) stored by KMS).
- * When using KMS to wrap/unwrap DEKs, be sure to set an appropriate
- * IAM policy on the KMS CryptoKey (KEK) to ensure an attacker cannot
- * unwrap the data crypto key.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CryptoKey} - */ -public final class CryptoKey extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CryptoKey) - CryptoKeyOrBuilder { -private static final long serialVersionUID = 0L; - // Use CryptoKey.newBuilder() to construct. - private CryptoKey(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CryptoKey() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CryptoKey( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.TransientCryptoKey.Builder subBuilder = null; - if (sourceCase_ == 1) { - subBuilder = ((com.google.privacy.dlp.v2beta1.TransientCryptoKey) source_).toBuilder(); - } - source_ = - input.readMessage(com.google.privacy.dlp.v2beta1.TransientCryptoKey.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.TransientCryptoKey) source_); - source_ = subBuilder.buildPartial(); - } - sourceCase_ = 1; - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.Builder subBuilder = null; - if (sourceCase_ == 2) { - subBuilder = ((com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) source_).toBuilder(); - } - source_ = - input.readMessage(com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) source_); - source_ = subBuilder.buildPartial(); - } - sourceCase_ = 2; - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.Builder subBuilder = null; - if (sourceCase_ == 3) { - subBuilder = ((com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) source_).toBuilder(); - } - source_ = - input.readMessage(com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) source_); - source_ = subBuilder.buildPartial(); - } - sourceCase_ = 3; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CryptoKey.class, com.google.privacy.dlp.v2beta1.CryptoKey.Builder.class); - } - - private int sourceCase_ = 0; - private java.lang.Object source_; - public enum SourceCase - implements com.google.protobuf.Internal.EnumLite { - TRANSIENT(1), - UNWRAPPED(2), - KMS_WRAPPED(3), - SOURCE_NOT_SET(0); - private final int value; - private SourceCase(int value) { - this.value = value; - } - /** - * @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 1: return TRANSIENT; - case 2: return UNWRAPPED; - case 3: return KMS_WRAPPED; - 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 TRANSIENT_FIELD_NUMBER = 1; - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public boolean hasTransient() { - return sourceCase_ == 1; - } - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public com.google.privacy.dlp.v2beta1.TransientCryptoKey getTransient() { - if (sourceCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.TransientCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.TransientCryptoKey.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public com.google.privacy.dlp.v2beta1.TransientCryptoKeyOrBuilder getTransientOrBuilder() { - if (sourceCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.TransientCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.TransientCryptoKey.getDefaultInstance(); - } - - public static final int UNWRAPPED_FIELD_NUMBER = 2; - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public boolean hasUnwrapped() { - return sourceCase_ == 2; - } - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey getUnwrapped() { - if (sourceCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public com.google.privacy.dlp.v2beta1.UnwrappedCryptoKeyOrBuilder getUnwrappedOrBuilder() { - if (sourceCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.getDefaultInstance(); - } - - public static final int KMS_WRAPPED_FIELD_NUMBER = 3; - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public boolean hasKmsWrapped() { - return sourceCase_ == 3; - } - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey getKmsWrapped() { - if (sourceCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKeyOrBuilder getKmsWrappedOrBuilder() { - if (sourceCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (sourceCase_ == 1) { - output.writeMessage(1, (com.google.privacy.dlp.v2beta1.TransientCryptoKey) source_); - } - if (sourceCase_ == 2) { - output.writeMessage(2, (com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) source_); - } - if (sourceCase_ == 3) { - output.writeMessage(3, (com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) source_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (sourceCase_ == 1) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, (com.google.privacy.dlp.v2beta1.TransientCryptoKey) source_); - } - if (sourceCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, (com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) source_); - } - if (sourceCase_ == 3) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, (com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) 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.privacy.dlp.v2beta1.CryptoKey)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CryptoKey other = (com.google.privacy.dlp.v2beta1.CryptoKey) obj; - - boolean result = true; - result = result && getSourceCase().equals( - other.getSourceCase()); - if (!result) return false; - switch (sourceCase_) { - case 1: - result = result && getTransient() - .equals(other.getTransient()); - break; - case 2: - result = result && getUnwrapped() - .equals(other.getUnwrapped()); - break; - case 3: - result = result && getKmsWrapped() - .equals(other.getKmsWrapped()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (sourceCase_) { - case 1: - hash = (37 * hash) + TRANSIENT_FIELD_NUMBER; - hash = (53 * hash) + getTransient().hashCode(); - break; - case 2: - hash = (37 * hash) + UNWRAPPED_FIELD_NUMBER; - hash = (53 * hash) + getUnwrapped().hashCode(); - break; - case 3: - hash = (37 * hash) + KMS_WRAPPED_FIELD_NUMBER; - hash = (53 * hash) + getKmsWrapped().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CryptoKey parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CryptoKey parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CryptoKey parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CryptoKey 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.privacy.dlp.v2beta1.CryptoKey parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CryptoKey parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CryptoKey parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CryptoKey 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.privacy.dlp.v2beta1.CryptoKey parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CryptoKey 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.privacy.dlp.v2beta1.CryptoKey parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CryptoKey parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CryptoKey prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * This is a data encryption key (DEK) (as opposed to
-   * a key encryption key (KEK) stored by KMS).
-   * When using KMS to wrap/unwrap DEKs, be sure to set an appropriate
-   * IAM policy on the KMS CryptoKey (KEK) to ensure an attacker cannot
-   * unwrap the data crypto key.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CryptoKey} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CryptoKey) - com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CryptoKey.class, com.google.privacy.dlp.v2beta1.CryptoKey.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CryptoKey.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - sourceCase_ = 0; - source_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoKey_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CryptoKey getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CryptoKey.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CryptoKey build() { - com.google.privacy.dlp.v2beta1.CryptoKey result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CryptoKey buildPartial() { - com.google.privacy.dlp.v2beta1.CryptoKey result = new com.google.privacy.dlp.v2beta1.CryptoKey(this); - if (sourceCase_ == 1) { - if (transientBuilder_ == null) { - result.source_ = source_; - } else { - result.source_ = transientBuilder_.build(); - } - } - if (sourceCase_ == 2) { - if (unwrappedBuilder_ == null) { - result.source_ = source_; - } else { - result.source_ = unwrappedBuilder_.build(); - } - } - if (sourceCase_ == 3) { - if (kmsWrappedBuilder_ == null) { - result.source_ = source_; - } else { - result.source_ = kmsWrappedBuilder_.build(); - } - } - result.sourceCase_ = sourceCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CryptoKey) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CryptoKey)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CryptoKey other) { - if (other == com.google.privacy.dlp.v2beta1.CryptoKey.getDefaultInstance()) return this; - switch (other.getSourceCase()) { - case TRANSIENT: { - mergeTransient(other.getTransient()); - break; - } - case UNWRAPPED: { - mergeUnwrapped(other.getUnwrapped()); - break; - } - case KMS_WRAPPED: { - mergeKmsWrapped(other.getKmsWrapped()); - break; - } - case SOURCE_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CryptoKey parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CryptoKey) 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 com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TransientCryptoKey, com.google.privacy.dlp.v2beta1.TransientCryptoKey.Builder, com.google.privacy.dlp.v2beta1.TransientCryptoKeyOrBuilder> transientBuilder_; - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public boolean hasTransient() { - return sourceCase_ == 1; - } - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public com.google.privacy.dlp.v2beta1.TransientCryptoKey getTransient() { - if (transientBuilder_ == null) { - if (sourceCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.TransientCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.TransientCryptoKey.getDefaultInstance(); - } else { - if (sourceCase_ == 1) { - return transientBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.TransientCryptoKey.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public Builder setTransient(com.google.privacy.dlp.v2beta1.TransientCryptoKey value) { - if (transientBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - source_ = value; - onChanged(); - } else { - transientBuilder_.setMessage(value); - } - sourceCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public Builder setTransient( - com.google.privacy.dlp.v2beta1.TransientCryptoKey.Builder builderForValue) { - if (transientBuilder_ == null) { - source_ = builderForValue.build(); - onChanged(); - } else { - transientBuilder_.setMessage(builderForValue.build()); - } - sourceCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public Builder mergeTransient(com.google.privacy.dlp.v2beta1.TransientCryptoKey value) { - if (transientBuilder_ == null) { - if (sourceCase_ == 1 && - source_ != com.google.privacy.dlp.v2beta1.TransientCryptoKey.getDefaultInstance()) { - source_ = com.google.privacy.dlp.v2beta1.TransientCryptoKey.newBuilder((com.google.privacy.dlp.v2beta1.TransientCryptoKey) source_) - .mergeFrom(value).buildPartial(); - } else { - source_ = value; - } - onChanged(); - } else { - if (sourceCase_ == 1) { - transientBuilder_.mergeFrom(value); - } - transientBuilder_.setMessage(value); - } - sourceCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public Builder clearTransient() { - if (transientBuilder_ == null) { - if (sourceCase_ == 1) { - sourceCase_ = 0; - source_ = null; - onChanged(); - } - } else { - if (sourceCase_ == 1) { - sourceCase_ = 0; - source_ = null; - } - transientBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public com.google.privacy.dlp.v2beta1.TransientCryptoKey.Builder getTransientBuilder() { - return getTransientFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - public com.google.privacy.dlp.v2beta1.TransientCryptoKeyOrBuilder getTransientOrBuilder() { - if ((sourceCase_ == 1) && (transientBuilder_ != null)) { - return transientBuilder_.getMessageOrBuilder(); - } else { - if (sourceCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.TransientCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.TransientCryptoKey.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TransientCryptoKey, com.google.privacy.dlp.v2beta1.TransientCryptoKey.Builder, com.google.privacy.dlp.v2beta1.TransientCryptoKeyOrBuilder> - getTransientFieldBuilder() { - if (transientBuilder_ == null) { - if (!(sourceCase_ == 1)) { - source_ = com.google.privacy.dlp.v2beta1.TransientCryptoKey.getDefaultInstance(); - } - transientBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TransientCryptoKey, com.google.privacy.dlp.v2beta1.TransientCryptoKey.Builder, com.google.privacy.dlp.v2beta1.TransientCryptoKeyOrBuilder>( - (com.google.privacy.dlp.v2beta1.TransientCryptoKey) source_, - getParentForChildren(), - isClean()); - source_ = null; - } - sourceCase_ = 1; - onChanged();; - return transientBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey, com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.Builder, com.google.privacy.dlp.v2beta1.UnwrappedCryptoKeyOrBuilder> unwrappedBuilder_; - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public boolean hasUnwrapped() { - return sourceCase_ == 2; - } - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey getUnwrapped() { - if (unwrappedBuilder_ == null) { - if (sourceCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.getDefaultInstance(); - } else { - if (sourceCase_ == 2) { - return unwrappedBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public Builder setUnwrapped(com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey value) { - if (unwrappedBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - source_ = value; - onChanged(); - } else { - unwrappedBuilder_.setMessage(value); - } - sourceCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public Builder setUnwrapped( - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.Builder builderForValue) { - if (unwrappedBuilder_ == null) { - source_ = builderForValue.build(); - onChanged(); - } else { - unwrappedBuilder_.setMessage(builderForValue.build()); - } - sourceCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public Builder mergeUnwrapped(com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey value) { - if (unwrappedBuilder_ == null) { - if (sourceCase_ == 2 && - source_ != com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.getDefaultInstance()) { - source_ = com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.newBuilder((com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) source_) - .mergeFrom(value).buildPartial(); - } else { - source_ = value; - } - onChanged(); - } else { - if (sourceCase_ == 2) { - unwrappedBuilder_.mergeFrom(value); - } - unwrappedBuilder_.setMessage(value); - } - sourceCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public Builder clearUnwrapped() { - if (unwrappedBuilder_ == null) { - if (sourceCase_ == 2) { - sourceCase_ = 0; - source_ = null; - onChanged(); - } - } else { - if (sourceCase_ == 2) { - sourceCase_ = 0; - source_ = null; - } - unwrappedBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.Builder getUnwrappedBuilder() { - return getUnwrappedFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - public com.google.privacy.dlp.v2beta1.UnwrappedCryptoKeyOrBuilder getUnwrappedOrBuilder() { - if ((sourceCase_ == 2) && (unwrappedBuilder_ != null)) { - return unwrappedBuilder_.getMessageOrBuilder(); - } else { - if (sourceCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey, com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.Builder, com.google.privacy.dlp.v2beta1.UnwrappedCryptoKeyOrBuilder> - getUnwrappedFieldBuilder() { - if (unwrappedBuilder_ == null) { - if (!(sourceCase_ == 2)) { - source_ = com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.getDefaultInstance(); - } - unwrappedBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey, com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.Builder, com.google.privacy.dlp.v2beta1.UnwrappedCryptoKeyOrBuilder>( - (com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) source_, - getParentForChildren(), - isClean()); - source_ = null; - } - sourceCase_ = 2; - onChanged();; - return unwrappedBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey, com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.Builder, com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKeyOrBuilder> kmsWrappedBuilder_; - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public boolean hasKmsWrapped() { - return sourceCase_ == 3; - } - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey getKmsWrapped() { - if (kmsWrappedBuilder_ == null) { - if (sourceCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.getDefaultInstance(); - } else { - if (sourceCase_ == 3) { - return kmsWrappedBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public Builder setKmsWrapped(com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey value) { - if (kmsWrappedBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - source_ = value; - onChanged(); - } else { - kmsWrappedBuilder_.setMessage(value); - } - sourceCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public Builder setKmsWrapped( - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.Builder builderForValue) { - if (kmsWrappedBuilder_ == null) { - source_ = builderForValue.build(); - onChanged(); - } else { - kmsWrappedBuilder_.setMessage(builderForValue.build()); - } - sourceCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public Builder mergeKmsWrapped(com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey value) { - if (kmsWrappedBuilder_ == null) { - if (sourceCase_ == 3 && - source_ != com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.getDefaultInstance()) { - source_ = com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.newBuilder((com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) source_) - .mergeFrom(value).buildPartial(); - } else { - source_ = value; - } - onChanged(); - } else { - if (sourceCase_ == 3) { - kmsWrappedBuilder_.mergeFrom(value); - } - kmsWrappedBuilder_.setMessage(value); - } - sourceCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public Builder clearKmsWrapped() { - if (kmsWrappedBuilder_ == null) { - if (sourceCase_ == 3) { - sourceCase_ = 0; - source_ = null; - onChanged(); - } - } else { - if (sourceCase_ == 3) { - sourceCase_ = 0; - source_ = null; - } - kmsWrappedBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.Builder getKmsWrappedBuilder() { - return getKmsWrappedFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - public com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKeyOrBuilder getKmsWrappedOrBuilder() { - if ((sourceCase_ == 3) && (kmsWrappedBuilder_ != null)) { - return kmsWrappedBuilder_.getMessageOrBuilder(); - } else { - if (sourceCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) source_; - } - return com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey, com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.Builder, com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKeyOrBuilder> - getKmsWrappedFieldBuilder() { - if (kmsWrappedBuilder_ == null) { - if (!(sourceCase_ == 3)) { - source_ = com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.getDefaultInstance(); - } - kmsWrappedBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey, com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.Builder, com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKeyOrBuilder>( - (com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) source_, - getParentForChildren(), - isClean()); - source_ = null; - } - sourceCase_ = 3; - onChanged();; - return kmsWrappedBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CryptoKey) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CryptoKey) - private static final com.google.privacy.dlp.v2beta1.CryptoKey DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CryptoKey(); - } - - public static com.google.privacy.dlp.v2beta1.CryptoKey getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CryptoKey parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CryptoKey(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CryptoKey getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoKeyOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoKeyOrBuilder.java deleted file mode 100644 index 174dbed9cea7..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoKeyOrBuilder.java +++ /dev/null @@ -1,50 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CryptoKeyOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CryptoKey) - com.google.protobuf.MessageOrBuilder { - - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - boolean hasTransient(); - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - com.google.privacy.dlp.v2beta1.TransientCryptoKey getTransient(); - /** - * .google.privacy.dlp.v2beta1.TransientCryptoKey transient = 1; - */ - com.google.privacy.dlp.v2beta1.TransientCryptoKeyOrBuilder getTransientOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - boolean hasUnwrapped(); - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey getUnwrapped(); - /** - * .google.privacy.dlp.v2beta1.UnwrappedCryptoKey unwrapped = 2; - */ - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKeyOrBuilder getUnwrappedOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - boolean hasKmsWrapped(); - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey getKmsWrapped(); - /** - * .google.privacy.dlp.v2beta1.KmsWrappedCryptoKey kms_wrapped = 3; - */ - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKeyOrBuilder getKmsWrappedOrBuilder(); - - public com.google.privacy.dlp.v2beta1.CryptoKey.SourceCase getSourceCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoReplaceFfxFpeConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoReplaceFfxFpeConfig.java deleted file mode 100644 index f788c39a27d1..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoReplaceFfxFpeConfig.java +++ /dev/null @@ -1,1731 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Replaces an identifier with a surrogate using FPE with the FFX
- * mode of operation.
- * The identifier must be representable by the US-ASCII character set.
- * For a given crypto key and context, the same identifier will be
- * replaced with the same surrogate.
- * Identifiers must be at least two characters long.
- * In the case that the identifier is the empty string, it will be skipped.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig} - */ -public final class CryptoReplaceFfxFpeConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) - CryptoReplaceFfxFpeConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use CryptoReplaceFfxFpeConfig.newBuilder() to construct. - private CryptoReplaceFfxFpeConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CryptoReplaceFfxFpeConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CryptoReplaceFfxFpeConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.CryptoKey.Builder subBuilder = null; - if (cryptoKey_ != null) { - subBuilder = cryptoKey_.toBuilder(); - } - cryptoKey_ = input.readMessage(com.google.privacy.dlp.v2beta1.CryptoKey.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(cryptoKey_); - cryptoKey_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null; - if (context_ != null) { - subBuilder = context_.toBuilder(); - } - context_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(context_); - context_ = subBuilder.buildPartial(); - } - - break; - } - case 32: { - int rawValue = input.readEnum(); - alphabetCase_ = 4; - alphabet_ = rawValue; - break; - } - case 42: { - java.lang.String s = input.readStringRequireUtf8(); - alphabetCase_ = 5; - alphabet_ = s; - break; - } - case 48: { - alphabetCase_ = 6; - alphabet_ = input.readInt32(); - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoReplaceFfxFpeConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoReplaceFfxFpeConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.class, com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.Builder.class); - } - - /** - *
-   * These are commonly used subsets of the alphabet that the FFX mode
-   * natively supports. In the algorithm, the alphabet is selected using
-   * the "radix". Therefore each corresponds to particular radix.
-   * 
- * - * Protobuf enum {@code google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet} - */ - public enum FfxCommonNativeAlphabet - implements com.google.protobuf.ProtocolMessageEnum { - /** - * FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED = 0; - */ - FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED(0), - /** - *
-     * [0-9] (radix of 10)
-     * 
- * - * NUMERIC = 1; - */ - NUMERIC(1), - /** - *
-     * [0-9A-F] (radix of 16)
-     * 
- * - * HEXADECIMAL = 2; - */ - HEXADECIMAL(2), - /** - *
-     * [0-9A-Z] (radix of 36)
-     * 
- * - * UPPER_CASE_ALPHA_NUMERIC = 3; - */ - UPPER_CASE_ALPHA_NUMERIC(3), - /** - *
-     * [0-9A-Za-z] (radix of 62)
-     * 
- * - * ALPHA_NUMERIC = 4; - */ - ALPHA_NUMERIC(4), - UNRECOGNIZED(-1), - ; - - /** - * FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED = 0; - */ - public static final int FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED_VALUE = 0; - /** - *
-     * [0-9] (radix of 10)
-     * 
- * - * NUMERIC = 1; - */ - public static final int NUMERIC_VALUE = 1; - /** - *
-     * [0-9A-F] (radix of 16)
-     * 
- * - * HEXADECIMAL = 2; - */ - public static final int HEXADECIMAL_VALUE = 2; - /** - *
-     * [0-9A-Z] (radix of 36)
-     * 
- * - * UPPER_CASE_ALPHA_NUMERIC = 3; - */ - public static final int UPPER_CASE_ALPHA_NUMERIC_VALUE = 3; - /** - *
-     * [0-9A-Za-z] (radix of 62)
-     * 
- * - * ALPHA_NUMERIC = 4; - */ - public static final int ALPHA_NUMERIC_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; - } - - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static FfxCommonNativeAlphabet valueOf(int value) { - return forNumber(value); - } - - public static FfxCommonNativeAlphabet forNumber(int value) { - switch (value) { - case 0: return FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED; - case 1: return NUMERIC; - case 2: return HEXADECIMAL; - case 3: return UPPER_CASE_ALPHA_NUMERIC; - case 4: return ALPHA_NUMERIC; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - private static final com.google.protobuf.Internal.EnumLiteMap< - FfxCommonNativeAlphabet> internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public FfxCommonNativeAlphabet findValueByNumber(int number) { - return FfxCommonNativeAlphabet.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - 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.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.getDescriptor().getEnumTypes().get(0); - } - - private static final FfxCommonNativeAlphabet[] VALUES = values(); - - public static FfxCommonNativeAlphabet 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 FfxCommonNativeAlphabet(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet) - } - - private int alphabetCase_ = 0; - private java.lang.Object alphabet_; - public enum AlphabetCase - implements com.google.protobuf.Internal.EnumLite { - COMMON_ALPHABET(4), - CUSTOM_ALPHABET(5), - RADIX(6), - ALPHABET_NOT_SET(0); - private final int value; - private AlphabetCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static AlphabetCase valueOf(int value) { - return forNumber(value); - } - - public static AlphabetCase forNumber(int value) { - switch (value) { - case 4: return COMMON_ALPHABET; - case 5: return CUSTOM_ALPHABET; - case 6: return RADIX; - case 0: return ALPHABET_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public AlphabetCase - getAlphabetCase() { - return AlphabetCase.forNumber( - alphabetCase_); - } - - public static final int CRYPTO_KEY_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.CryptoKey cryptoKey_; - /** - *
-   * The key used by the encryption algorithm. [required]
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public boolean hasCryptoKey() { - return cryptoKey_ != null; - } - /** - *
-   * The key used by the encryption algorithm. [required]
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CryptoKey getCryptoKey() { - return cryptoKey_ == null ? com.google.privacy.dlp.v2beta1.CryptoKey.getDefaultInstance() : cryptoKey_; - } - /** - *
-   * The key used by the encryption algorithm. [required]
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder getCryptoKeyOrBuilder() { - return getCryptoKey(); - } - - public static final int CONTEXT_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.FieldId context_; - /** - *
-   * A context may be used for higher security since the same
-   * identifier in two different contexts likely will be given a distinct
-   * surrogate. The principle is that the likeliness is inversely related
-   * to the ratio of the number of distinct identifiers per context over the
-   * number of possible surrogates: As long as this ratio is small, the
-   * likehood is large.
-   * If the context is not set, a default tweak will be used.
-   * If the context is set but:
-   * 1. there is no record present when transforming a given value or
-   * 1. the field is not present when transforming a given value,
-   * a default tweak will be used.
-   * Note that case (1) is expected when an `InfoTypeTransformation` is
-   * applied to both structured and non-structured `ContentItem`s.
-   * Currently, the referenced field may be of value type integer or string.
-   * The tweak is constructed as a sequence of bytes in big endian byte order
-   * such that:
-   * - a 64 bit integer is encoded followed by a single byte of value 1
-   * - a string is encoded in UTF-8 format followed by a single byte of value 2
-   * This is also known as the 'tweak', as in tweakable encryption.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public boolean hasContext() { - return context_ != null; - } - /** - *
-   * A context may be used for higher security since the same
-   * identifier in two different contexts likely will be given a distinct
-   * surrogate. The principle is that the likeliness is inversely related
-   * to the ratio of the number of distinct identifiers per context over the
-   * number of possible surrogates: As long as this ratio is small, the
-   * likehood is large.
-   * If the context is not set, a default tweak will be used.
-   * If the context is set but:
-   * 1. there is no record present when transforming a given value or
-   * 1. the field is not present when transforming a given value,
-   * a default tweak will be used.
-   * Note that case (1) is expected when an `InfoTypeTransformation` is
-   * applied to both structured and non-structured `ContentItem`s.
-   * Currently, the referenced field may be of value type integer or string.
-   * The tweak is constructed as a sequence of bytes in big endian byte order
-   * such that:
-   * - a 64 bit integer is encoded followed by a single byte of value 1
-   * - a string is encoded in UTF-8 format followed by a single byte of value 2
-   * This is also known as the 'tweak', as in tweakable encryption.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId getContext() { - return context_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : context_; - } - /** - *
-   * A context may be used for higher security since the same
-   * identifier in two different contexts likely will be given a distinct
-   * surrogate. The principle is that the likeliness is inversely related
-   * to the ratio of the number of distinct identifiers per context over the
-   * number of possible surrogates: As long as this ratio is small, the
-   * likehood is large.
-   * If the context is not set, a default tweak will be used.
-   * If the context is set but:
-   * 1. there is no record present when transforming a given value or
-   * 1. the field is not present when transforming a given value,
-   * a default tweak will be used.
-   * Note that case (1) is expected when an `InfoTypeTransformation` is
-   * applied to both structured and non-structured `ContentItem`s.
-   * Currently, the referenced field may be of value type integer or string.
-   * The tweak is constructed as a sequence of bytes in big endian byte order
-   * such that:
-   * - a 64 bit integer is encoded followed by a single byte of value 1
-   * - a string is encoded in UTF-8 format followed by a single byte of value 2
-   * This is also known as the 'tweak', as in tweakable encryption.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getContextOrBuilder() { - return getContext(); - } - - public static final int COMMON_ALPHABET_FIELD_NUMBER = 4; - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - */ - public int getCommonAlphabetValue() { - if (alphabetCase_ == 4) { - return (java.lang.Integer) alphabet_; - } - return 0; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - */ - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet getCommonAlphabet() { - if (alphabetCase_ == 4) { - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet result = com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet.valueOf( - (java.lang.Integer) alphabet_); - return result == null ? com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet.UNRECOGNIZED : result; - } - return com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet.FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED; - } - - public static final int CUSTOM_ALPHABET_FIELD_NUMBER = 5; - /** - *
-   * This is supported by mapping these to the alphanumeric characters
-   * that the FFX mode natively supports. This happens before/after
-   * encryption/decryption.
-   * Each character listed must appear only once.
-   * Number of characters must be in the range [2, 62].
-   * This must be encoded as ASCII.
-   * The order of characters does not matter.
-   * 
- * - * string custom_alphabet = 5; - */ - public java.lang.String getCustomAlphabet() { - java.lang.Object ref = ""; - if (alphabetCase_ == 5) { - ref = alphabet_; - } - 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 (alphabetCase_ == 5) { - alphabet_ = s; - } - return s; - } - } - /** - *
-   * This is supported by mapping these to the alphanumeric characters
-   * that the FFX mode natively supports. This happens before/after
-   * encryption/decryption.
-   * Each character listed must appear only once.
-   * Number of characters must be in the range [2, 62].
-   * This must be encoded as ASCII.
-   * The order of characters does not matter.
-   * 
- * - * string custom_alphabet = 5; - */ - public com.google.protobuf.ByteString - getCustomAlphabetBytes() { - java.lang.Object ref = ""; - if (alphabetCase_ == 5) { - ref = alphabet_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - if (alphabetCase_ == 5) { - alphabet_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int RADIX_FIELD_NUMBER = 6; - /** - *
-   * The native way to select the alphabet. Must be in the range [2, 62].
-   * 
- * - * int32 radix = 6; - */ - public int getRadix() { - if (alphabetCase_ == 6) { - return (java.lang.Integer) alphabet_; - } - return 0; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (cryptoKey_ != null) { - output.writeMessage(1, getCryptoKey()); - } - if (context_ != null) { - output.writeMessage(2, getContext()); - } - if (alphabetCase_ == 4) { - output.writeEnum(4, ((java.lang.Integer) alphabet_)); - } - if (alphabetCase_ == 5) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, alphabet_); - } - if (alphabetCase_ == 6) { - output.writeInt32( - 6, (int)((java.lang.Integer) alphabet_)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (cryptoKey_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getCryptoKey()); - } - if (context_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getContext()); - } - if (alphabetCase_ == 4) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(4, ((java.lang.Integer) alphabet_)); - } - if (alphabetCase_ == 5) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, alphabet_); - } - if (alphabetCase_ == 6) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size( - 6, (int)((java.lang.Integer) alphabet_)); - } - 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.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig other = (com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) obj; - - boolean result = true; - result = result && (hasCryptoKey() == other.hasCryptoKey()); - if (hasCryptoKey()) { - result = result && getCryptoKey() - .equals(other.getCryptoKey()); - } - result = result && (hasContext() == other.hasContext()); - if (hasContext()) { - result = result && getContext() - .equals(other.getContext()); - } - result = result && getAlphabetCase().equals( - other.getAlphabetCase()); - if (!result) return false; - switch (alphabetCase_) { - case 4: - result = result && getCommonAlphabetValue() - == other.getCommonAlphabetValue(); - break; - case 5: - result = result && getCustomAlphabet() - .equals(other.getCustomAlphabet()); - break; - case 6: - result = result && (getRadix() - == other.getRadix()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasCryptoKey()) { - hash = (37 * hash) + CRYPTO_KEY_FIELD_NUMBER; - hash = (53 * hash) + getCryptoKey().hashCode(); - } - if (hasContext()) { - hash = (37 * hash) + CONTEXT_FIELD_NUMBER; - hash = (53 * hash) + getContext().hashCode(); - } - switch (alphabetCase_) { - case 4: - hash = (37 * hash) + COMMON_ALPHABET_FIELD_NUMBER; - hash = (53 * hash) + getCommonAlphabetValue(); - break; - case 5: - hash = (37 * hash) + CUSTOM_ALPHABET_FIELD_NUMBER; - hash = (53 * hash) + getCustomAlphabet().hashCode(); - break; - case 6: - hash = (37 * hash) + RADIX_FIELD_NUMBER; - hash = (53 * hash) + getRadix(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig 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.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig 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.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig 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.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Replaces an identifier with a surrogate using FPE with the FFX
-   * mode of operation.
-   * The identifier must be representable by the US-ASCII character set.
-   * For a given crypto key and context, the same identifier will be
-   * replaced with the same surrogate.
-   * Identifiers must be at least two characters long.
-   * In the case that the identifier is the empty string, it will be skipped.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoReplaceFfxFpeConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoReplaceFfxFpeConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.class, com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (cryptoKeyBuilder_ == null) { - cryptoKey_ = null; - } else { - cryptoKey_ = null; - cryptoKeyBuilder_ = null; - } - if (contextBuilder_ == null) { - context_ = null; - } else { - context_ = null; - contextBuilder_ = null; - } - alphabetCase_ = 0; - alphabet_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_CryptoReplaceFfxFpeConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig build() { - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig buildPartial() { - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig result = new com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig(this); - if (cryptoKeyBuilder_ == null) { - result.cryptoKey_ = cryptoKey_; - } else { - result.cryptoKey_ = cryptoKeyBuilder_.build(); - } - if (contextBuilder_ == null) { - result.context_ = context_; - } else { - result.context_ = contextBuilder_.build(); - } - if (alphabetCase_ == 4) { - result.alphabet_ = alphabet_; - } - if (alphabetCase_ == 5) { - result.alphabet_ = alphabet_; - } - if (alphabetCase_ == 6) { - result.alphabet_ = alphabet_; - } - result.alphabetCase_ = alphabetCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig other) { - if (other == com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.getDefaultInstance()) return this; - if (other.hasCryptoKey()) { - mergeCryptoKey(other.getCryptoKey()); - } - if (other.hasContext()) { - mergeContext(other.getContext()); - } - switch (other.getAlphabetCase()) { - case COMMON_ALPHABET: { - setCommonAlphabetValue(other.getCommonAlphabetValue()); - break; - } - case CUSTOM_ALPHABET: { - alphabetCase_ = 5; - alphabet_ = other.alphabet_; - onChanged(); - break; - } - case RADIX: { - setRadix(other.getRadix()); - break; - } - case ALPHABET_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int alphabetCase_ = 0; - private java.lang.Object alphabet_; - public AlphabetCase - getAlphabetCase() { - return AlphabetCase.forNumber( - alphabetCase_); - } - - public Builder clearAlphabet() { - alphabetCase_ = 0; - alphabet_ = null; - onChanged(); - return this; - } - - - private com.google.privacy.dlp.v2beta1.CryptoKey cryptoKey_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoKey, com.google.privacy.dlp.v2beta1.CryptoKey.Builder, com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder> cryptoKeyBuilder_; - /** - *
-     * The key used by the encryption algorithm. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public boolean hasCryptoKey() { - return cryptoKeyBuilder_ != null || cryptoKey_ != null; - } - /** - *
-     * The key used by the encryption algorithm. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CryptoKey getCryptoKey() { - if (cryptoKeyBuilder_ == null) { - return cryptoKey_ == null ? com.google.privacy.dlp.v2beta1.CryptoKey.getDefaultInstance() : cryptoKey_; - } else { - return cryptoKeyBuilder_.getMessage(); - } - } - /** - *
-     * The key used by the encryption algorithm. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public Builder setCryptoKey(com.google.privacy.dlp.v2beta1.CryptoKey value) { - if (cryptoKeyBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - cryptoKey_ = value; - onChanged(); - } else { - cryptoKeyBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The key used by the encryption algorithm. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public Builder setCryptoKey( - com.google.privacy.dlp.v2beta1.CryptoKey.Builder builderForValue) { - if (cryptoKeyBuilder_ == null) { - cryptoKey_ = builderForValue.build(); - onChanged(); - } else { - cryptoKeyBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The key used by the encryption algorithm. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public Builder mergeCryptoKey(com.google.privacy.dlp.v2beta1.CryptoKey value) { - if (cryptoKeyBuilder_ == null) { - if (cryptoKey_ != null) { - cryptoKey_ = - com.google.privacy.dlp.v2beta1.CryptoKey.newBuilder(cryptoKey_).mergeFrom(value).buildPartial(); - } else { - cryptoKey_ = value; - } - onChanged(); - } else { - cryptoKeyBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The key used by the encryption algorithm. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public Builder clearCryptoKey() { - if (cryptoKeyBuilder_ == null) { - cryptoKey_ = null; - onChanged(); - } else { - cryptoKey_ = null; - cryptoKeyBuilder_ = null; - } - - return this; - } - /** - *
-     * The key used by the encryption algorithm. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CryptoKey.Builder getCryptoKeyBuilder() { - - onChanged(); - return getCryptoKeyFieldBuilder().getBuilder(); - } - /** - *
-     * The key used by the encryption algorithm. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder getCryptoKeyOrBuilder() { - if (cryptoKeyBuilder_ != null) { - return cryptoKeyBuilder_.getMessageOrBuilder(); - } else { - return cryptoKey_ == null ? - com.google.privacy.dlp.v2beta1.CryptoKey.getDefaultInstance() : cryptoKey_; - } - } - /** - *
-     * The key used by the encryption algorithm. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoKey, com.google.privacy.dlp.v2beta1.CryptoKey.Builder, com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder> - getCryptoKeyFieldBuilder() { - if (cryptoKeyBuilder_ == null) { - cryptoKeyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoKey, com.google.privacy.dlp.v2beta1.CryptoKey.Builder, com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder>( - getCryptoKey(), - getParentForChildren(), - isClean()); - cryptoKey_ = null; - } - return cryptoKeyBuilder_; - } - - private com.google.privacy.dlp.v2beta1.FieldId context_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> contextBuilder_; - /** - *
-     * A context may be used for higher security since the same
-     * identifier in two different contexts likely will be given a distinct
-     * surrogate. The principle is that the likeliness is inversely related
-     * to the ratio of the number of distinct identifiers per context over the
-     * number of possible surrogates: As long as this ratio is small, the
-     * likehood is large.
-     * If the context is not set, a default tweak will be used.
-     * If the context is set but:
-     * 1. there is no record present when transforming a given value or
-     * 1. the field is not present when transforming a given value,
-     * a default tweak will be used.
-     * Note that case (1) is expected when an `InfoTypeTransformation` is
-     * applied to both structured and non-structured `ContentItem`s.
-     * Currently, the referenced field may be of value type integer or string.
-     * The tweak is constructed as a sequence of bytes in big endian byte order
-     * such that:
-     * - a 64 bit integer is encoded followed by a single byte of value 1
-     * - a string is encoded in UTF-8 format followed by a single byte of value 2
-     * This is also known as the 'tweak', as in tweakable encryption.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public boolean hasContext() { - return contextBuilder_ != null || context_ != null; - } - /** - *
-     * A context may be used for higher security since the same
-     * identifier in two different contexts likely will be given a distinct
-     * surrogate. The principle is that the likeliness is inversely related
-     * to the ratio of the number of distinct identifiers per context over the
-     * number of possible surrogates: As long as this ratio is small, the
-     * likehood is large.
-     * If the context is not set, a default tweak will be used.
-     * If the context is set but:
-     * 1. there is no record present when transforming a given value or
-     * 1. the field is not present when transforming a given value,
-     * a default tweak will be used.
-     * Note that case (1) is expected when an `InfoTypeTransformation` is
-     * applied to both structured and non-structured `ContentItem`s.
-     * Currently, the referenced field may be of value type integer or string.
-     * The tweak is constructed as a sequence of bytes in big endian byte order
-     * such that:
-     * - a 64 bit integer is encoded followed by a single byte of value 1
-     * - a string is encoded in UTF-8 format followed by a single byte of value 2
-     * This is also known as the 'tweak', as in tweakable encryption.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId getContext() { - if (contextBuilder_ == null) { - return context_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : context_; - } else { - return contextBuilder_.getMessage(); - } - } - /** - *
-     * A context may be used for higher security since the same
-     * identifier in two different contexts likely will be given a distinct
-     * surrogate. The principle is that the likeliness is inversely related
-     * to the ratio of the number of distinct identifiers per context over the
-     * number of possible surrogates: As long as this ratio is small, the
-     * likehood is large.
-     * If the context is not set, a default tweak will be used.
-     * If the context is set but:
-     * 1. there is no record present when transforming a given value or
-     * 1. the field is not present when transforming a given value,
-     * a default tweak will be used.
-     * Note that case (1) is expected when an `InfoTypeTransformation` is
-     * applied to both structured and non-structured `ContentItem`s.
-     * Currently, the referenced field may be of value type integer or string.
-     * The tweak is constructed as a sequence of bytes in big endian byte order
-     * such that:
-     * - a 64 bit integer is encoded followed by a single byte of value 1
-     * - a string is encoded in UTF-8 format followed by a single byte of value 2
-     * This is also known as the 'tweak', as in tweakable encryption.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public Builder setContext(com.google.privacy.dlp.v2beta1.FieldId value) { - if (contextBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - context_ = value; - onChanged(); - } else { - contextBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * A context may be used for higher security since the same
-     * identifier in two different contexts likely will be given a distinct
-     * surrogate. The principle is that the likeliness is inversely related
-     * to the ratio of the number of distinct identifiers per context over the
-     * number of possible surrogates: As long as this ratio is small, the
-     * likehood is large.
-     * If the context is not set, a default tweak will be used.
-     * If the context is set but:
-     * 1. there is no record present when transforming a given value or
-     * 1. the field is not present when transforming a given value,
-     * a default tweak will be used.
-     * Note that case (1) is expected when an `InfoTypeTransformation` is
-     * applied to both structured and non-structured `ContentItem`s.
-     * Currently, the referenced field may be of value type integer or string.
-     * The tweak is constructed as a sequence of bytes in big endian byte order
-     * such that:
-     * - a 64 bit integer is encoded followed by a single byte of value 1
-     * - a string is encoded in UTF-8 format followed by a single byte of value 2
-     * This is also known as the 'tweak', as in tweakable encryption.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public Builder setContext( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (contextBuilder_ == null) { - context_ = builderForValue.build(); - onChanged(); - } else { - contextBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * A context may be used for higher security since the same
-     * identifier in two different contexts likely will be given a distinct
-     * surrogate. The principle is that the likeliness is inversely related
-     * to the ratio of the number of distinct identifiers per context over the
-     * number of possible surrogates: As long as this ratio is small, the
-     * likehood is large.
-     * If the context is not set, a default tweak will be used.
-     * If the context is set but:
-     * 1. there is no record present when transforming a given value or
-     * 1. the field is not present when transforming a given value,
-     * a default tweak will be used.
-     * Note that case (1) is expected when an `InfoTypeTransformation` is
-     * applied to both structured and non-structured `ContentItem`s.
-     * Currently, the referenced field may be of value type integer or string.
-     * The tweak is constructed as a sequence of bytes in big endian byte order
-     * such that:
-     * - a 64 bit integer is encoded followed by a single byte of value 1
-     * - a string is encoded in UTF-8 format followed by a single byte of value 2
-     * This is also known as the 'tweak', as in tweakable encryption.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public Builder mergeContext(com.google.privacy.dlp.v2beta1.FieldId value) { - if (contextBuilder_ == null) { - if (context_ != null) { - context_ = - com.google.privacy.dlp.v2beta1.FieldId.newBuilder(context_).mergeFrom(value).buildPartial(); - } else { - context_ = value; - } - onChanged(); - } else { - contextBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * A context may be used for higher security since the same
-     * identifier in two different contexts likely will be given a distinct
-     * surrogate. The principle is that the likeliness is inversely related
-     * to the ratio of the number of distinct identifiers per context over the
-     * number of possible surrogates: As long as this ratio is small, the
-     * likehood is large.
-     * If the context is not set, a default tweak will be used.
-     * If the context is set but:
-     * 1. there is no record present when transforming a given value or
-     * 1. the field is not present when transforming a given value,
-     * a default tweak will be used.
-     * Note that case (1) is expected when an `InfoTypeTransformation` is
-     * applied to both structured and non-structured `ContentItem`s.
-     * Currently, the referenced field may be of value type integer or string.
-     * The tweak is constructed as a sequence of bytes in big endian byte order
-     * such that:
-     * - a 64 bit integer is encoded followed by a single byte of value 1
-     * - a string is encoded in UTF-8 format followed by a single byte of value 2
-     * This is also known as the 'tweak', as in tweakable encryption.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public Builder clearContext() { - if (contextBuilder_ == null) { - context_ = null; - onChanged(); - } else { - context_ = null; - contextBuilder_ = null; - } - - return this; - } - /** - *
-     * A context may be used for higher security since the same
-     * identifier in two different contexts likely will be given a distinct
-     * surrogate. The principle is that the likeliness is inversely related
-     * to the ratio of the number of distinct identifiers per context over the
-     * number of possible surrogates: As long as this ratio is small, the
-     * likehood is large.
-     * If the context is not set, a default tweak will be used.
-     * If the context is set but:
-     * 1. there is no record present when transforming a given value or
-     * 1. the field is not present when transforming a given value,
-     * a default tweak will be used.
-     * Note that case (1) is expected when an `InfoTypeTransformation` is
-     * applied to both structured and non-structured `ContentItem`s.
-     * Currently, the referenced field may be of value type integer or string.
-     * The tweak is constructed as a sequence of bytes in big endian byte order
-     * such that:
-     * - a 64 bit integer is encoded followed by a single byte of value 1
-     * - a string is encoded in UTF-8 format followed by a single byte of value 2
-     * This is also known as the 'tweak', as in tweakable encryption.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getContextBuilder() { - - onChanged(); - return getContextFieldBuilder().getBuilder(); - } - /** - *
-     * A context may be used for higher security since the same
-     * identifier in two different contexts likely will be given a distinct
-     * surrogate. The principle is that the likeliness is inversely related
-     * to the ratio of the number of distinct identifiers per context over the
-     * number of possible surrogates: As long as this ratio is small, the
-     * likehood is large.
-     * If the context is not set, a default tweak will be used.
-     * If the context is set but:
-     * 1. there is no record present when transforming a given value or
-     * 1. the field is not present when transforming a given value,
-     * a default tweak will be used.
-     * Note that case (1) is expected when an `InfoTypeTransformation` is
-     * applied to both structured and non-structured `ContentItem`s.
-     * Currently, the referenced field may be of value type integer or string.
-     * The tweak is constructed as a sequence of bytes in big endian byte order
-     * such that:
-     * - a 64 bit integer is encoded followed by a single byte of value 1
-     * - a string is encoded in UTF-8 format followed by a single byte of value 2
-     * This is also known as the 'tweak', as in tweakable encryption.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getContextOrBuilder() { - if (contextBuilder_ != null) { - return contextBuilder_.getMessageOrBuilder(); - } else { - return context_ == null ? - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : context_; - } - } - /** - *
-     * A context may be used for higher security since the same
-     * identifier in two different contexts likely will be given a distinct
-     * surrogate. The principle is that the likeliness is inversely related
-     * to the ratio of the number of distinct identifiers per context over the
-     * number of possible surrogates: As long as this ratio is small, the
-     * likehood is large.
-     * If the context is not set, a default tweak will be used.
-     * If the context is set but:
-     * 1. there is no record present when transforming a given value or
-     * 1. the field is not present when transforming a given value,
-     * a default tweak will be used.
-     * Note that case (1) is expected when an `InfoTypeTransformation` is
-     * applied to both structured and non-structured `ContentItem`s.
-     * Currently, the referenced field may be of value type integer or string.
-     * The tweak is constructed as a sequence of bytes in big endian byte order
-     * such that:
-     * - a 64 bit integer is encoded followed by a single byte of value 1
-     * - a string is encoded in UTF-8 format followed by a single byte of value 2
-     * This is also known as the 'tweak', as in tweakable encryption.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getContextFieldBuilder() { - if (contextBuilder_ == null) { - contextBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - getContext(), - getParentForChildren(), - isClean()); - context_ = null; - } - return contextBuilder_; - } - - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - */ - public int getCommonAlphabetValue() { - if (alphabetCase_ == 4) { - return ((java.lang.Integer) alphabet_).intValue(); - } - return 0; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - */ - public Builder setCommonAlphabetValue(int value) { - alphabetCase_ = 4; - alphabet_ = value; - onChanged(); - return this; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - */ - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet getCommonAlphabet() { - if (alphabetCase_ == 4) { - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet result = com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet.valueOf( - (java.lang.Integer) alphabet_); - return result == null ? com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet.UNRECOGNIZED : result; - } - return com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet.FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - */ - public Builder setCommonAlphabet(com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet value) { - if (value == null) { - throw new NullPointerException(); - } - alphabetCase_ = 4; - alphabet_ = value.getNumber(); - onChanged(); - return this; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - */ - public Builder clearCommonAlphabet() { - if (alphabetCase_ == 4) { - alphabetCase_ = 0; - alphabet_ = null; - onChanged(); - } - return this; - } - - /** - *
-     * This is supported by mapping these to the alphanumeric characters
-     * that the FFX mode natively supports. This happens before/after
-     * encryption/decryption.
-     * Each character listed must appear only once.
-     * Number of characters must be in the range [2, 62].
-     * This must be encoded as ASCII.
-     * The order of characters does not matter.
-     * 
- * - * string custom_alphabet = 5; - */ - public java.lang.String getCustomAlphabet() { - java.lang.Object ref = ""; - if (alphabetCase_ == 5) { - ref = alphabet_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (alphabetCase_ == 5) { - alphabet_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * This is supported by mapping these to the alphanumeric characters
-     * that the FFX mode natively supports. This happens before/after
-     * encryption/decryption.
-     * Each character listed must appear only once.
-     * Number of characters must be in the range [2, 62].
-     * This must be encoded as ASCII.
-     * The order of characters does not matter.
-     * 
- * - * string custom_alphabet = 5; - */ - public com.google.protobuf.ByteString - getCustomAlphabetBytes() { - java.lang.Object ref = ""; - if (alphabetCase_ == 5) { - ref = alphabet_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - if (alphabetCase_ == 5) { - alphabet_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * This is supported by mapping these to the alphanumeric characters
-     * that the FFX mode natively supports. This happens before/after
-     * encryption/decryption.
-     * Each character listed must appear only once.
-     * Number of characters must be in the range [2, 62].
-     * This must be encoded as ASCII.
-     * The order of characters does not matter.
-     * 
- * - * string custom_alphabet = 5; - */ - public Builder setCustomAlphabet( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - alphabetCase_ = 5; - alphabet_ = value; - onChanged(); - return this; - } - /** - *
-     * This is supported by mapping these to the alphanumeric characters
-     * that the FFX mode natively supports. This happens before/after
-     * encryption/decryption.
-     * Each character listed must appear only once.
-     * Number of characters must be in the range [2, 62].
-     * This must be encoded as ASCII.
-     * The order of characters does not matter.
-     * 
- * - * string custom_alphabet = 5; - */ - public Builder clearCustomAlphabet() { - if (alphabetCase_ == 5) { - alphabetCase_ = 0; - alphabet_ = null; - onChanged(); - } - return this; - } - /** - *
-     * This is supported by mapping these to the alphanumeric characters
-     * that the FFX mode natively supports. This happens before/after
-     * encryption/decryption.
-     * Each character listed must appear only once.
-     * Number of characters must be in the range [2, 62].
-     * This must be encoded as ASCII.
-     * The order of characters does not matter.
-     * 
- * - * string custom_alphabet = 5; - */ - public Builder setCustomAlphabetBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - alphabetCase_ = 5; - alphabet_ = value; - onChanged(); - return this; - } - - /** - *
-     * The native way to select the alphabet. Must be in the range [2, 62].
-     * 
- * - * int32 radix = 6; - */ - public int getRadix() { - if (alphabetCase_ == 6) { - return (java.lang.Integer) alphabet_; - } - return 0; - } - /** - *
-     * The native way to select the alphabet. Must be in the range [2, 62].
-     * 
- * - * int32 radix = 6; - */ - public Builder setRadix(int value) { - alphabetCase_ = 6; - alphabet_ = value; - onChanged(); - return this; - } - /** - *
-     * The native way to select the alphabet. Must be in the range [2, 62].
-     * 
- * - * int32 radix = 6; - */ - public Builder clearRadix() { - if (alphabetCase_ == 6) { - alphabetCase_ = 0; - alphabet_ = null; - onChanged(); - } - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) - private static final com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig(); - } - - public static com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CryptoReplaceFfxFpeConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CryptoReplaceFfxFpeConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoReplaceFfxFpeConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoReplaceFfxFpeConfigOrBuilder.java deleted file mode 100644 index 50b3c41d4be9..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CryptoReplaceFfxFpeConfigOrBuilder.java +++ /dev/null @@ -1,163 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CryptoReplaceFfxFpeConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The key used by the encryption algorithm. [required]
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - boolean hasCryptoKey(); - /** - *
-   * The key used by the encryption algorithm. [required]
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - com.google.privacy.dlp.v2beta1.CryptoKey getCryptoKey(); - /** - *
-   * The key used by the encryption algorithm. [required]
-   * 
- * - * .google.privacy.dlp.v2beta1.CryptoKey crypto_key = 1; - */ - com.google.privacy.dlp.v2beta1.CryptoKeyOrBuilder getCryptoKeyOrBuilder(); - - /** - *
-   * A context may be used for higher security since the same
-   * identifier in two different contexts likely will be given a distinct
-   * surrogate. The principle is that the likeliness is inversely related
-   * to the ratio of the number of distinct identifiers per context over the
-   * number of possible surrogates: As long as this ratio is small, the
-   * likehood is large.
-   * If the context is not set, a default tweak will be used.
-   * If the context is set but:
-   * 1. there is no record present when transforming a given value or
-   * 1. the field is not present when transforming a given value,
-   * a default tweak will be used.
-   * Note that case (1) is expected when an `InfoTypeTransformation` is
-   * applied to both structured and non-structured `ContentItem`s.
-   * Currently, the referenced field may be of value type integer or string.
-   * The tweak is constructed as a sequence of bytes in big endian byte order
-   * such that:
-   * - a 64 bit integer is encoded followed by a single byte of value 1
-   * - a string is encoded in UTF-8 format followed by a single byte of value 2
-   * This is also known as the 'tweak', as in tweakable encryption.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - boolean hasContext(); - /** - *
-   * A context may be used for higher security since the same
-   * identifier in two different contexts likely will be given a distinct
-   * surrogate. The principle is that the likeliness is inversely related
-   * to the ratio of the number of distinct identifiers per context over the
-   * number of possible surrogates: As long as this ratio is small, the
-   * likehood is large.
-   * If the context is not set, a default tweak will be used.
-   * If the context is set but:
-   * 1. there is no record present when transforming a given value or
-   * 1. the field is not present when transforming a given value,
-   * a default tweak will be used.
-   * Note that case (1) is expected when an `InfoTypeTransformation` is
-   * applied to both structured and non-structured `ContentItem`s.
-   * Currently, the referenced field may be of value type integer or string.
-   * The tweak is constructed as a sequence of bytes in big endian byte order
-   * such that:
-   * - a 64 bit integer is encoded followed by a single byte of value 1
-   * - a string is encoded in UTF-8 format followed by a single byte of value 2
-   * This is also known as the 'tweak', as in tweakable encryption.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - com.google.privacy.dlp.v2beta1.FieldId getContext(); - /** - *
-   * A context may be used for higher security since the same
-   * identifier in two different contexts likely will be given a distinct
-   * surrogate. The principle is that the likeliness is inversely related
-   * to the ratio of the number of distinct identifiers per context over the
-   * number of possible surrogates: As long as this ratio is small, the
-   * likehood is large.
-   * If the context is not set, a default tweak will be used.
-   * If the context is set but:
-   * 1. there is no record present when transforming a given value or
-   * 1. the field is not present when transforming a given value,
-   * a default tweak will be used.
-   * Note that case (1) is expected when an `InfoTypeTransformation` is
-   * applied to both structured and non-structured `ContentItem`s.
-   * Currently, the referenced field may be of value type integer or string.
-   * The tweak is constructed as a sequence of bytes in big endian byte order
-   * such that:
-   * - a 64 bit integer is encoded followed by a single byte of value 1
-   * - a string is encoded in UTF-8 format followed by a single byte of value 2
-   * This is also known as the 'tweak', as in tweakable encryption.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId context = 2; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getContextOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - */ - int getCommonAlphabetValue(); - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet common_alphabet = 4; - */ - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.FfxCommonNativeAlphabet getCommonAlphabet(); - - /** - *
-   * This is supported by mapping these to the alphanumeric characters
-   * that the FFX mode natively supports. This happens before/after
-   * encryption/decryption.
-   * Each character listed must appear only once.
-   * Number of characters must be in the range [2, 62].
-   * This must be encoded as ASCII.
-   * The order of characters does not matter.
-   * 
- * - * string custom_alphabet = 5; - */ - java.lang.String getCustomAlphabet(); - /** - *
-   * This is supported by mapping these to the alphanumeric characters
-   * that the FFX mode natively supports. This happens before/after
-   * encryption/decryption.
-   * Each character listed must appear only once.
-   * Number of characters must be in the range [2, 62].
-   * This must be encoded as ASCII.
-   * The order of characters does not matter.
-   * 
- * - * string custom_alphabet = 5; - */ - com.google.protobuf.ByteString - getCustomAlphabetBytes(); - - /** - *
-   * The native way to select the alphabet. Must be in the range [2, 62].
-   * 
- * - * int32 radix = 6; - */ - int getRadix(); - - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.AlphabetCase getAlphabetCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CustomInfoType.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CustomInfoType.java deleted file mode 100644 index c59004d71404..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CustomInfoType.java +++ /dev/null @@ -1,2424 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Custom information type provided by the user. Used to find domain-specific
- * sensitive information configurable to the data in question.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CustomInfoType} - */ -public final class CustomInfoType extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CustomInfoType) - CustomInfoTypeOrBuilder { -private static final long serialVersionUID = 0L; - // Use CustomInfoType.newBuilder() to construct. - private CustomInfoType(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CustomInfoType() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CustomInfoType( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InfoType.Builder subBuilder = null; - if (infoType_ != null) { - subBuilder = infoType_.toBuilder(); - } - infoType_ = input.readMessage(com.google.privacy.dlp.v2beta1.InfoType.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(infoType_); - infoType_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.Builder subBuilder = null; - if (typeCase_ == 2) { - subBuilder = ((com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 2; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CustomInfoType.class, com.google.privacy.dlp.v2beta1.CustomInfoType.Builder.class); - } - - public interface DictionaryOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * List of words or phrases to search for.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - boolean hasWordList(); - /** - *
-     * List of words or phrases to search for.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList getWordList(); - /** - *
-     * List of words or phrases to search for.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordListOrBuilder getWordListOrBuilder(); - - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.SourceCase getSourceCase(); - } - /** - *
-   * Custom information type based on a dictionary of words or phrases. This can
-   * be used to match sensitive information specific to the data, such as a list
-   * of employee IDs or job titles.
-   * Dictionary words are case-insensitive and all characters other than letters
-   * and digits in the unicode [Basic Multilingual
-   * Plane](https://en.wikipedia.org/wiki/Plane_%28Unicode%29#Basic_Multilingual_Plane)
-   * will be replaced with whitespace when scanning for matches, so the
-   * dictionary phrase "Sam Johnson" will match all three phrases "sam johnson",
-   * "Sam, Johnson", and "Sam (Johnson)". Additionally, the characters
-   * surrounding any match must be of a different type than the adjacent
-   * characters within the word, so letters must be next to non-letters and
-   * digits next to non-digits. For example, the dictionary word "jen" will
-   * match the first three letters of the text "jen123" but will return no
-   * matches for "jennifer".
-   * Dictionary words containing a large number of characters that are not
-   * letters or digits may result in unexpected findings because such characters
-   * are treated as whitespace.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CustomInfoType.Dictionary} - */ - public static final class Dictionary extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) - DictionaryOrBuilder { - private static final long serialVersionUID = 0L; - // Use Dictionary.newBuilder() to construct. - private Dictionary(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Dictionary() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Dictionary( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.Builder subBuilder = null; - if (sourceCase_ == 1) { - subBuilder = ((com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) source_).toBuilder(); - } - source_ = - input.readMessage(com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) source_); - source_ = subBuilder.buildPartial(); - } - sourceCase_ = 1; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.class, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.Builder.class); - } - - public interface WordListOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) - com.google.protobuf.MessageOrBuilder { - - /** - *
-       * Words or phrases defining the dictionary. The dictionary must contain
-       * at least one phrase and every phrase must contain at least 2 characters
-       * that are letters or digits. [required]
-       * 
- * - * repeated string words = 1; - */ - java.util.List - getWordsList(); - /** - *
-       * Words or phrases defining the dictionary. The dictionary must contain
-       * at least one phrase and every phrase must contain at least 2 characters
-       * that are letters or digits. [required]
-       * 
- * - * repeated string words = 1; - */ - int getWordsCount(); - /** - *
-       * Words or phrases defining the dictionary. The dictionary must contain
-       * at least one phrase and every phrase must contain at least 2 characters
-       * that are letters or digits. [required]
-       * 
- * - * repeated string words = 1; - */ - java.lang.String getWords(int index); - /** - *
-       * Words or phrases defining the dictionary. The dictionary must contain
-       * at least one phrase and every phrase must contain at least 2 characters
-       * that are letters or digits. [required]
-       * 
- * - * repeated string words = 1; - */ - com.google.protobuf.ByteString - getWordsBytes(int index); - } - /** - *
-     * Message defining a list of words or phrases to search for in the data.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList} - */ - public static final class WordList extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) - WordListOrBuilder { - private static final long serialVersionUID = 0L; - // Use WordList.newBuilder() to construct. - private WordList(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private WordList() { - words_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private WordList( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - words_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - words_.add(s); - 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) == 0x00000001)) { - words_ = words_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_WordList_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_WordList_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.class, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.Builder.class); - } - - public static final int WORDS_FIELD_NUMBER = 1; - private com.google.protobuf.LazyStringList words_; - /** - *
-       * Words or phrases defining the dictionary. The dictionary must contain
-       * at least one phrase and every phrase must contain at least 2 characters
-       * that are letters or digits. [required]
-       * 
- * - * repeated string words = 1; - */ - public com.google.protobuf.ProtocolStringList - getWordsList() { - return words_; - } - /** - *
-       * Words or phrases defining the dictionary. The dictionary must contain
-       * at least one phrase and every phrase must contain at least 2 characters
-       * that are letters or digits. [required]
-       * 
- * - * repeated string words = 1; - */ - public int getWordsCount() { - return words_.size(); - } - /** - *
-       * Words or phrases defining the dictionary. The dictionary must contain
-       * at least one phrase and every phrase must contain at least 2 characters
-       * that are letters or digits. [required]
-       * 
- * - * repeated string words = 1; - */ - public java.lang.String getWords(int index) { - return words_.get(index); - } - /** - *
-       * Words or phrases defining the dictionary. The dictionary must contain
-       * at least one phrase and every phrase must contain at least 2 characters
-       * that are letters or digits. [required]
-       * 
- * - * repeated string words = 1; - */ - public com.google.protobuf.ByteString - getWordsBytes(int index) { - return words_.getByteString(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < words_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, words_.getRaw(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - for (int i = 0; i < words_.size(); i++) { - dataSize += computeStringSizeNoTag(words_.getRaw(i)); - } - size += dataSize; - size += 1 * getWordsList().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.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList other = (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) obj; - - boolean result = true; - result = result && getWordsList() - .equals(other.getWordsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getWordsCount() > 0) { - hash = (37 * hash) + WORDS_FIELD_NUMBER; - hash = (53 * hash) + getWordsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList 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.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList 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.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList 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.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-       * Message defining a list of words or phrases to search for in the data.
-       * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordListOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_WordList_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_WordList_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.class, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - words_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_WordList_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList build() { - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList buildPartial() { - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList result = new com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList(this); - int from_bitField0_ = bitField0_; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - words_ = words_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.words_ = words_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList other) { - if (other == com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.getDefaultInstance()) return this; - if (!other.words_.isEmpty()) { - if (words_.isEmpty()) { - words_ = other.words_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureWordsIsMutable(); - words_.addAll(other.words_); - } - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private com.google.protobuf.LazyStringList words_ = com.google.protobuf.LazyStringArrayList.EMPTY; - private void ensureWordsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - words_ = new com.google.protobuf.LazyStringArrayList(words_); - bitField0_ |= 0x00000001; - } - } - /** - *
-         * Words or phrases defining the dictionary. The dictionary must contain
-         * at least one phrase and every phrase must contain at least 2 characters
-         * that are letters or digits. [required]
-         * 
- * - * repeated string words = 1; - */ - public com.google.protobuf.ProtocolStringList - getWordsList() { - return words_.getUnmodifiableView(); - } - /** - *
-         * Words or phrases defining the dictionary. The dictionary must contain
-         * at least one phrase and every phrase must contain at least 2 characters
-         * that are letters or digits. [required]
-         * 
- * - * repeated string words = 1; - */ - public int getWordsCount() { - return words_.size(); - } - /** - *
-         * Words or phrases defining the dictionary. The dictionary must contain
-         * at least one phrase and every phrase must contain at least 2 characters
-         * that are letters or digits. [required]
-         * 
- * - * repeated string words = 1; - */ - public java.lang.String getWords(int index) { - return words_.get(index); - } - /** - *
-         * Words or phrases defining the dictionary. The dictionary must contain
-         * at least one phrase and every phrase must contain at least 2 characters
-         * that are letters or digits. [required]
-         * 
- * - * repeated string words = 1; - */ - public com.google.protobuf.ByteString - getWordsBytes(int index) { - return words_.getByteString(index); - } - /** - *
-         * Words or phrases defining the dictionary. The dictionary must contain
-         * at least one phrase and every phrase must contain at least 2 characters
-         * that are letters or digits. [required]
-         * 
- * - * repeated string words = 1; - */ - public Builder setWords( - int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureWordsIsMutable(); - words_.set(index, value); - onChanged(); - return this; - } - /** - *
-         * Words or phrases defining the dictionary. The dictionary must contain
-         * at least one phrase and every phrase must contain at least 2 characters
-         * that are letters or digits. [required]
-         * 
- * - * repeated string words = 1; - */ - public Builder addWords( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureWordsIsMutable(); - words_.add(value); - onChanged(); - return this; - } - /** - *
-         * Words or phrases defining the dictionary. The dictionary must contain
-         * at least one phrase and every phrase must contain at least 2 characters
-         * that are letters or digits. [required]
-         * 
- * - * repeated string words = 1; - */ - public Builder addAllWords( - java.lang.Iterable values) { - ensureWordsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, words_); - onChanged(); - return this; - } - /** - *
-         * Words or phrases defining the dictionary. The dictionary must contain
-         * at least one phrase and every phrase must contain at least 2 characters
-         * that are letters or digits. [required]
-         * 
- * - * repeated string words = 1; - */ - public Builder clearWords() { - words_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - *
-         * Words or phrases defining the dictionary. The dictionary must contain
-         * at least one phrase and every phrase must contain at least 2 characters
-         * that are letters or digits. [required]
-         * 
- * - * repeated string words = 1; - */ - public Builder addWordsBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureWordsIsMutable(); - words_.add(value); - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) - private static final com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList(); - } - - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public WordList parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new WordList(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int sourceCase_ = 0; - private java.lang.Object source_; - public enum SourceCase - implements com.google.protobuf.Internal.EnumLite { - WORD_LIST(1), - SOURCE_NOT_SET(0); - private final int value; - private SourceCase(int value) { - this.value = value; - } - /** - * @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 1: return WORD_LIST; - 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 WORD_LIST_FIELD_NUMBER = 1; - /** - *
-     * List of words or phrases to search for.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public boolean hasWordList() { - return sourceCase_ == 1; - } - /** - *
-     * List of words or phrases to search for.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList getWordList() { - if (sourceCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) source_; - } - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.getDefaultInstance(); - } - /** - *
-     * List of words or phrases to search for.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordListOrBuilder getWordListOrBuilder() { - if (sourceCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) source_; - } - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (sourceCase_ == 1) { - output.writeMessage(1, (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) source_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (sourceCase_ == 1) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) 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.privacy.dlp.v2beta1.CustomInfoType.Dictionary)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary other = (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) obj; - - boolean result = true; - result = result && getSourceCase().equals( - other.getSourceCase()); - if (!result) return false; - switch (sourceCase_) { - case 1: - result = result && getWordList() - .equals(other.getWordList()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (sourceCase_) { - case 1: - hash = (37 * hash) + WORD_LIST_FIELD_NUMBER; - hash = (53 * hash) + getWordList().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary 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.privacy.dlp.v2beta1.CustomInfoType.Dictionary parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary 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.privacy.dlp.v2beta1.CustomInfoType.Dictionary parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary 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.privacy.dlp.v2beta1.CustomInfoType.Dictionary parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * Custom information type based on a dictionary of words or phrases. This can
-     * be used to match sensitive information specific to the data, such as a list
-     * of employee IDs or job titles.
-     * Dictionary words are case-insensitive and all characters other than letters
-     * and digits in the unicode [Basic Multilingual
-     * Plane](https://en.wikipedia.org/wiki/Plane_%28Unicode%29#Basic_Multilingual_Plane)
-     * will be replaced with whitespace when scanning for matches, so the
-     * dictionary phrase "Sam Johnson" will match all three phrases "sam johnson",
-     * "Sam, Johnson", and "Sam (Johnson)". Additionally, the characters
-     * surrounding any match must be of a different type than the adjacent
-     * characters within the word, so letters must be next to non-letters and
-     * digits next to non-digits. For example, the dictionary word "jen" will
-     * match the first three letters of the text "jen123" but will return no
-     * matches for "jennifer".
-     * Dictionary words containing a large number of characters that are not
-     * letters or digits may result in unexpected findings because such characters
-     * are treated as whitespace.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CustomInfoType.Dictionary} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) - com.google.privacy.dlp.v2beta1.CustomInfoType.DictionaryOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.class, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - sourceCase_ = 0; - source_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary build() { - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary buildPartial() { - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary result = new com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary(this); - if (sourceCase_ == 1) { - if (wordListBuilder_ == null) { - result.source_ = source_; - } else { - result.source_ = wordListBuilder_.build(); - } - } - result.sourceCase_ = sourceCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary other) { - if (other == com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.getDefaultInstance()) return this; - switch (other.getSourceCase()) { - case WORD_LIST: { - mergeWordList(other.getWordList()); - break; - } - case SOURCE_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) 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 com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.Builder, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordListOrBuilder> wordListBuilder_; - /** - *
-       * List of words or phrases to search for.
-       * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public boolean hasWordList() { - return sourceCase_ == 1; - } - /** - *
-       * List of words or phrases to search for.
-       * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList getWordList() { - if (wordListBuilder_ == null) { - if (sourceCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) source_; - } - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.getDefaultInstance(); - } else { - if (sourceCase_ == 1) { - return wordListBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.getDefaultInstance(); - } - } - /** - *
-       * List of words or phrases to search for.
-       * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public Builder setWordList(com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList value) { - if (wordListBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - source_ = value; - onChanged(); - } else { - wordListBuilder_.setMessage(value); - } - sourceCase_ = 1; - return this; - } - /** - *
-       * List of words or phrases to search for.
-       * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public Builder setWordList( - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.Builder builderForValue) { - if (wordListBuilder_ == null) { - source_ = builderForValue.build(); - onChanged(); - } else { - wordListBuilder_.setMessage(builderForValue.build()); - } - sourceCase_ = 1; - return this; - } - /** - *
-       * List of words or phrases to search for.
-       * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public Builder mergeWordList(com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList value) { - if (wordListBuilder_ == null) { - if (sourceCase_ == 1 && - source_ != com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.getDefaultInstance()) { - source_ = com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.newBuilder((com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) source_) - .mergeFrom(value).buildPartial(); - } else { - source_ = value; - } - onChanged(); - } else { - if (sourceCase_ == 1) { - wordListBuilder_.mergeFrom(value); - } - wordListBuilder_.setMessage(value); - } - sourceCase_ = 1; - return this; - } - /** - *
-       * List of words or phrases to search for.
-       * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public Builder clearWordList() { - if (wordListBuilder_ == null) { - if (sourceCase_ == 1) { - sourceCase_ = 0; - source_ = null; - onChanged(); - } - } else { - if (sourceCase_ == 1) { - sourceCase_ = 0; - source_ = null; - } - wordListBuilder_.clear(); - } - return this; - } - /** - *
-       * List of words or phrases to search for.
-       * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.Builder getWordListBuilder() { - return getWordListFieldBuilder().getBuilder(); - } - /** - *
-       * List of words or phrases to search for.
-       * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordListOrBuilder getWordListOrBuilder() { - if ((sourceCase_ == 1) && (wordListBuilder_ != null)) { - return wordListBuilder_.getMessageOrBuilder(); - } else { - if (sourceCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) source_; - } - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.getDefaultInstance(); - } - } - /** - *
-       * List of words or phrases to search for.
-       * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList word_list = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.Builder, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordListOrBuilder> - getWordListFieldBuilder() { - if (wordListBuilder_ == null) { - if (!(sourceCase_ == 1)) { - source_ = com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.getDefaultInstance(); - } - wordListBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList.Builder, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordListOrBuilder>( - (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.WordList) source_, - getParentForChildren(), - isClean()); - source_ = null; - } - sourceCase_ = 1; - onChanged();; - return wordListBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) - private static final com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary(); - } - - public static com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Dictionary parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Dictionary(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int typeCase_ = 0; - private java.lang.Object type_; - public enum TypeCase - implements com.google.protobuf.Internal.EnumLite { - DICTIONARY(2), - TYPE_NOT_SET(0); - private final int value; - private TypeCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TypeCase valueOf(int value) { - return forNumber(value); - } - - public static TypeCase forNumber(int value) { - switch (value) { - case 2: return DICTIONARY; - case 0: return TYPE_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public static final int INFO_TYPE_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.InfoType infoType_; - /** - *
-   * Info type configuration. All custom info types must have configurations
-   * that do not conflict with built-in info types or other custom info types.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return infoType_ != null; - } - /** - *
-   * Info type configuration. All custom info types must have configurations
-   * that do not conflict with built-in info types or other custom info types.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - /** - *
-   * Info type configuration. All custom info types must have configurations
-   * that do not conflict with built-in info types or other custom info types.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - return getInfoType(); - } - - public static final int DICTIONARY_FIELD_NUMBER = 2; - /** - *
-   * Dictionary-based custom info type.
-   * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public boolean hasDictionary() { - return typeCase_ == 2; - } - /** - *
-   * Dictionary-based custom info type.
-   * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary getDictionary() { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) type_; - } - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.getDefaultInstance(); - } - /** - *
-   * Dictionary-based custom info type.
-   * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.DictionaryOrBuilder getDictionaryOrBuilder() { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) type_; - } - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (infoType_ != null) { - output.writeMessage(1, getInfoType()); - } - if (typeCase_ == 2) { - output.writeMessage(2, (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) type_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (infoType_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getInfoType()); - } - if (typeCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) type_); - } - 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.privacy.dlp.v2beta1.CustomInfoType)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.CustomInfoType other = (com.google.privacy.dlp.v2beta1.CustomInfoType) obj; - - boolean result = true; - result = result && (hasInfoType() == other.hasInfoType()); - if (hasInfoType()) { - result = result && getInfoType() - .equals(other.getInfoType()); - } - result = result && getTypeCase().equals( - other.getTypeCase()); - if (!result) return false; - switch (typeCase_) { - case 2: - result = result && getDictionary() - .equals(other.getDictionary()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasInfoType()) { - hash = (37 * hash) + INFO_TYPE_FIELD_NUMBER; - hash = (53 * hash) + getInfoType().hashCode(); - } - switch (typeCase_) { - case 2: - hash = (37 * hash) + DICTIONARY_FIELD_NUMBER; - hash = (53 * hash) + getDictionary().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.CustomInfoType parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType 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.privacy.dlp.v2beta1.CustomInfoType parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType 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.privacy.dlp.v2beta1.CustomInfoType parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType 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.privacy.dlp.v2beta1.CustomInfoType parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.CustomInfoType parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CustomInfoType prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Custom information type provided by the user. Used to find domain-specific
-   * sensitive information configurable to the data in question.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.CustomInfoType} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CustomInfoType) - com.google.privacy.dlp.v2beta1.CustomInfoTypeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CustomInfoType.class, com.google.privacy.dlp.v2beta1.CustomInfoType.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.CustomInfoType.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (infoTypeBuilder_ == null) { - infoType_ = null; - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - typeCase_ = 0; - type_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CustomInfoType_descriptor; - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CustomInfoType.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType build() { - com.google.privacy.dlp.v2beta1.CustomInfoType result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType buildPartial() { - com.google.privacy.dlp.v2beta1.CustomInfoType result = new com.google.privacy.dlp.v2beta1.CustomInfoType(this); - if (infoTypeBuilder_ == null) { - result.infoType_ = infoType_; - } else { - result.infoType_ = infoTypeBuilder_.build(); - } - if (typeCase_ == 2) { - if (dictionaryBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = dictionaryBuilder_.build(); - } - } - result.typeCase_ = typeCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CustomInfoType) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CustomInfoType)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CustomInfoType other) { - if (other == com.google.privacy.dlp.v2beta1.CustomInfoType.getDefaultInstance()) return this; - if (other.hasInfoType()) { - mergeInfoType(other.getInfoType()); - } - switch (other.getTypeCase()) { - case DICTIONARY: { - mergeDictionary(other.getDictionary()); - break; - } - case TYPE_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CustomInfoType parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CustomInfoType) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int typeCase_ = 0; - private java.lang.Object type_; - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public Builder clearType() { - typeCase_ = 0; - type_ = null; - onChanged(); - return this; - } - - - private com.google.privacy.dlp.v2beta1.InfoType infoType_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> infoTypeBuilder_; - /** - *
-     * Info type configuration. All custom info types must have configurations
-     * that do not conflict with built-in info types or other custom info types.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return infoTypeBuilder_ != null || infoType_ != null; - } - /** - *
-     * Info type configuration. All custom info types must have configurations
-     * that do not conflict with built-in info types or other custom info types.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - if (infoTypeBuilder_ == null) { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } else { - return infoTypeBuilder_.getMessage(); - } - } - /** - *
-     * Info type configuration. All custom info types must have configurations
-     * that do not conflict with built-in info types or other custom info types.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - infoType_ = value; - onChanged(); - } else { - infoTypeBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Info type configuration. All custom info types must have configurations
-     * that do not conflict with built-in info types or other custom info types.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType( - com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypeBuilder_ == null) { - infoType_ = builderForValue.build(); - onChanged(); - } else { - infoTypeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Info type configuration. All custom info types must have configurations
-     * that do not conflict with built-in info types or other custom info types.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder mergeInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (infoType_ != null) { - infoType_ = - com.google.privacy.dlp.v2beta1.InfoType.newBuilder(infoType_).mergeFrom(value).buildPartial(); - } else { - infoType_ = value; - } - onChanged(); - } else { - infoTypeBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Info type configuration. All custom info types must have configurations
-     * that do not conflict with built-in info types or other custom info types.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder clearInfoType() { - if (infoTypeBuilder_ == null) { - infoType_ = null; - onChanged(); - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - - return this; - } - /** - *
-     * Info type configuration. All custom info types must have configurations
-     * that do not conflict with built-in info types or other custom info types.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder getInfoTypeBuilder() { - - onChanged(); - return getInfoTypeFieldBuilder().getBuilder(); - } - /** - *
-     * Info type configuration. All custom info types must have configurations
-     * that do not conflict with built-in info types or other custom info types.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - if (infoTypeBuilder_ != null) { - return infoTypeBuilder_.getMessageOrBuilder(); - } else { - return infoType_ == null ? - com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - } - /** - *
-     * Info type configuration. All custom info types must have configurations
-     * that do not conflict with built-in info types or other custom info types.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> - getInfoTypeFieldBuilder() { - if (infoTypeBuilder_ == null) { - infoTypeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder>( - getInfoType(), - getParentForChildren(), - isClean()); - infoType_ = null; - } - return infoTypeBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.Builder, com.google.privacy.dlp.v2beta1.CustomInfoType.DictionaryOrBuilder> dictionaryBuilder_; - /** - *
-     * Dictionary-based custom info type.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public boolean hasDictionary() { - return typeCase_ == 2; - } - /** - *
-     * Dictionary-based custom info type.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary getDictionary() { - if (dictionaryBuilder_ == null) { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) type_; - } - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.getDefaultInstance(); - } else { - if (typeCase_ == 2) { - return dictionaryBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.getDefaultInstance(); - } - } - /** - *
-     * Dictionary-based custom info type.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public Builder setDictionary(com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary value) { - if (dictionaryBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - dictionaryBuilder_.setMessage(value); - } - typeCase_ = 2; - return this; - } - /** - *
-     * Dictionary-based custom info type.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public Builder setDictionary( - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.Builder builderForValue) { - if (dictionaryBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - dictionaryBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 2; - return this; - } - /** - *
-     * Dictionary-based custom info type.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public Builder mergeDictionary(com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary value) { - if (dictionaryBuilder_ == null) { - if (typeCase_ == 2 && - type_ != com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.newBuilder((com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 2) { - dictionaryBuilder_.mergeFrom(value); - } - dictionaryBuilder_.setMessage(value); - } - typeCase_ = 2; - return this; - } - /** - *
-     * Dictionary-based custom info type.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public Builder clearDictionary() { - if (dictionaryBuilder_ == null) { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - } - dictionaryBuilder_.clear(); - } - return this; - } - /** - *
-     * Dictionary-based custom info type.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.Builder getDictionaryBuilder() { - return getDictionaryFieldBuilder().getBuilder(); - } - /** - *
-     * Dictionary-based custom info type.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.DictionaryOrBuilder getDictionaryOrBuilder() { - if ((typeCase_ == 2) && (dictionaryBuilder_ != null)) { - return dictionaryBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) type_; - } - return com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.getDefaultInstance(); - } - } - /** - *
-     * Dictionary-based custom info type.
-     * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.Builder, com.google.privacy.dlp.v2beta1.CustomInfoType.DictionaryOrBuilder> - getDictionaryFieldBuilder() { - if (dictionaryBuilder_ == null) { - if (!(typeCase_ == 2)) { - type_ = com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.getDefaultInstance(); - } - dictionaryBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary, com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary.Builder, com.google.privacy.dlp.v2beta1.CustomInfoType.DictionaryOrBuilder>( - (com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 2; - onChanged();; - return dictionaryBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CustomInfoType) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CustomInfoType) - private static final com.google.privacy.dlp.v2beta1.CustomInfoType DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CustomInfoType(); - } - - public static com.google.privacy.dlp.v2beta1.CustomInfoType getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CustomInfoType parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CustomInfoType(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.CustomInfoType getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CustomInfoTypeOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CustomInfoTypeOrBuilder.java deleted file mode 100644 index a87910151ee3..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/CustomInfoTypeOrBuilder.java +++ /dev/null @@ -1,64 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface CustomInfoTypeOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.CustomInfoType) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Info type configuration. All custom info types must have configurations
-   * that do not conflict with built-in info types or other custom info types.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - boolean hasInfoType(); - /** - *
-   * Info type configuration. All custom info types must have configurations
-   * that do not conflict with built-in info types or other custom info types.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoType getInfoType(); - /** - *
-   * Info type configuration. All custom info types must have configurations
-   * that do not conflict with built-in info types or other custom info types.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder(); - - /** - *
-   * Dictionary-based custom info type.
-   * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - boolean hasDictionary(); - /** - *
-   * Dictionary-based custom info type.
-   * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - com.google.privacy.dlp.v2beta1.CustomInfoType.Dictionary getDictionary(); - /** - *
-   * Dictionary-based custom info type.
-   * 
- * - * .google.privacy.dlp.v2beta1.CustomInfoType.Dictionary dictionary = 2; - */ - com.google.privacy.dlp.v2beta1.CustomInfoType.DictionaryOrBuilder getDictionaryOrBuilder(); - - public com.google.privacy.dlp.v2beta1.CustomInfoType.TypeCase getTypeCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreKey.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreKey.java deleted file mode 100644 index 759a04c54e6f..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreKey.java +++ /dev/null @@ -1,626 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Record key for a finding in Cloud Datastore.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DatastoreKey} - */ -public final class DatastoreKey extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.DatastoreKey) - DatastoreKeyOrBuilder { -private static final long serialVersionUID = 0L; - // Use DatastoreKey.newBuilder() to construct. - private DatastoreKey(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private DatastoreKey() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private DatastoreKey( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.Key.Builder subBuilder = null; - if (entityKey_ != null) { - subBuilder = entityKey_.toBuilder(); - } - entityKey_ = input.readMessage(com.google.privacy.dlp.v2beta1.Key.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(entityKey_); - entityKey_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_DatastoreKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_DatastoreKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DatastoreKey.class, com.google.privacy.dlp.v2beta1.DatastoreKey.Builder.class); - } - - public static final int ENTITY_KEY_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.Key entityKey_; - /** - *
-   * Datastore entity key.
-   * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public boolean hasEntityKey() { - return entityKey_ != null; - } - /** - *
-   * Datastore entity key.
-   * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public com.google.privacy.dlp.v2beta1.Key getEntityKey() { - return entityKey_ == null ? com.google.privacy.dlp.v2beta1.Key.getDefaultInstance() : entityKey_; - } - /** - *
-   * Datastore entity key.
-   * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public com.google.privacy.dlp.v2beta1.KeyOrBuilder getEntityKeyOrBuilder() { - return getEntityKey(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (entityKey_ != null) { - output.writeMessage(1, getEntityKey()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (entityKey_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getEntityKey()); - } - 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.privacy.dlp.v2beta1.DatastoreKey)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.DatastoreKey other = (com.google.privacy.dlp.v2beta1.DatastoreKey) obj; - - boolean result = true; - result = result && (hasEntityKey() == other.hasEntityKey()); - if (hasEntityKey()) { - result = result && getEntityKey() - .equals(other.getEntityKey()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasEntityKey()) { - hash = (37 * hash) + ENTITY_KEY_FIELD_NUMBER; - hash = (53 * hash) + getEntityKey().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.DatastoreKey parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DatastoreKey parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DatastoreKey parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DatastoreKey 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.privacy.dlp.v2beta1.DatastoreKey parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DatastoreKey parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DatastoreKey parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DatastoreKey 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.privacy.dlp.v2beta1.DatastoreKey parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DatastoreKey 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.privacy.dlp.v2beta1.DatastoreKey parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DatastoreKey parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.DatastoreKey prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Record key for a finding in Cloud Datastore.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DatastoreKey} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.DatastoreKey) - com.google.privacy.dlp.v2beta1.DatastoreKeyOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_DatastoreKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_DatastoreKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DatastoreKey.class, com.google.privacy.dlp.v2beta1.DatastoreKey.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.DatastoreKey.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (entityKeyBuilder_ == null) { - entityKey_ = null; - } else { - entityKey_ = null; - entityKeyBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_DatastoreKey_descriptor; - } - - public com.google.privacy.dlp.v2beta1.DatastoreKey getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.DatastoreKey.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.DatastoreKey build() { - com.google.privacy.dlp.v2beta1.DatastoreKey result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.DatastoreKey buildPartial() { - com.google.privacy.dlp.v2beta1.DatastoreKey result = new com.google.privacy.dlp.v2beta1.DatastoreKey(this); - if (entityKeyBuilder_ == null) { - result.entityKey_ = entityKey_; - } else { - result.entityKey_ = entityKeyBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.DatastoreKey) { - return mergeFrom((com.google.privacy.dlp.v2beta1.DatastoreKey)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.DatastoreKey other) { - if (other == com.google.privacy.dlp.v2beta1.DatastoreKey.getDefaultInstance()) return this; - if (other.hasEntityKey()) { - mergeEntityKey(other.getEntityKey()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.DatastoreKey parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.DatastoreKey) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.Key entityKey_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Key, com.google.privacy.dlp.v2beta1.Key.Builder, com.google.privacy.dlp.v2beta1.KeyOrBuilder> entityKeyBuilder_; - /** - *
-     * Datastore entity key.
-     * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public boolean hasEntityKey() { - return entityKeyBuilder_ != null || entityKey_ != null; - } - /** - *
-     * Datastore entity key.
-     * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public com.google.privacy.dlp.v2beta1.Key getEntityKey() { - if (entityKeyBuilder_ == null) { - return entityKey_ == null ? com.google.privacy.dlp.v2beta1.Key.getDefaultInstance() : entityKey_; - } else { - return entityKeyBuilder_.getMessage(); - } - } - /** - *
-     * Datastore entity key.
-     * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public Builder setEntityKey(com.google.privacy.dlp.v2beta1.Key value) { - if (entityKeyBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - entityKey_ = value; - onChanged(); - } else { - entityKeyBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Datastore entity key.
-     * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public Builder setEntityKey( - com.google.privacy.dlp.v2beta1.Key.Builder builderForValue) { - if (entityKeyBuilder_ == null) { - entityKey_ = builderForValue.build(); - onChanged(); - } else { - entityKeyBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Datastore entity key.
-     * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public Builder mergeEntityKey(com.google.privacy.dlp.v2beta1.Key value) { - if (entityKeyBuilder_ == null) { - if (entityKey_ != null) { - entityKey_ = - com.google.privacy.dlp.v2beta1.Key.newBuilder(entityKey_).mergeFrom(value).buildPartial(); - } else { - entityKey_ = value; - } - onChanged(); - } else { - entityKeyBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Datastore entity key.
-     * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public Builder clearEntityKey() { - if (entityKeyBuilder_ == null) { - entityKey_ = null; - onChanged(); - } else { - entityKey_ = null; - entityKeyBuilder_ = null; - } - - return this; - } - /** - *
-     * Datastore entity key.
-     * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public com.google.privacy.dlp.v2beta1.Key.Builder getEntityKeyBuilder() { - - onChanged(); - return getEntityKeyFieldBuilder().getBuilder(); - } - /** - *
-     * Datastore entity key.
-     * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - public com.google.privacy.dlp.v2beta1.KeyOrBuilder getEntityKeyOrBuilder() { - if (entityKeyBuilder_ != null) { - return entityKeyBuilder_.getMessageOrBuilder(); - } else { - return entityKey_ == null ? - com.google.privacy.dlp.v2beta1.Key.getDefaultInstance() : entityKey_; - } - } - /** - *
-     * Datastore entity key.
-     * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Key, com.google.privacy.dlp.v2beta1.Key.Builder, com.google.privacy.dlp.v2beta1.KeyOrBuilder> - getEntityKeyFieldBuilder() { - if (entityKeyBuilder_ == null) { - entityKeyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Key, com.google.privacy.dlp.v2beta1.Key.Builder, com.google.privacy.dlp.v2beta1.KeyOrBuilder>( - getEntityKey(), - getParentForChildren(), - isClean()); - entityKey_ = null; - } - return entityKeyBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.DatastoreKey) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.DatastoreKey) - private static final com.google.privacy.dlp.v2beta1.DatastoreKey DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.DatastoreKey(); - } - - public static com.google.privacy.dlp.v2beta1.DatastoreKey getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public DatastoreKey parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DatastoreKey(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.DatastoreKey getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreKeyOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreKeyOrBuilder.java deleted file mode 100644 index e0b995455e57..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreKeyOrBuilder.java +++ /dev/null @@ -1,34 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface DatastoreKeyOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.DatastoreKey) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Datastore entity key.
-   * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - boolean hasEntityKey(); - /** - *
-   * Datastore entity key.
-   * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - com.google.privacy.dlp.v2beta1.Key getEntityKey(); - /** - *
-   * Datastore entity key.
-   * 
- * - * .google.privacy.dlp.v2beta1.Key entity_key = 1; - */ - com.google.privacy.dlp.v2beta1.KeyOrBuilder getEntityKeyOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreOptions.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreOptions.java deleted file mode 100644 index 3a0abb0148cc..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreOptions.java +++ /dev/null @@ -1,1330 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Options defining a data set within Google Cloud Datastore.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DatastoreOptions} - */ -public final class DatastoreOptions extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.DatastoreOptions) - DatastoreOptionsOrBuilder { -private static final long serialVersionUID = 0L; - // Use DatastoreOptions.newBuilder() to construct. - private DatastoreOptions(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private DatastoreOptions() { - projection_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private DatastoreOptions( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.PartitionId.Builder subBuilder = null; - if (partitionId_ != null) { - subBuilder = partitionId_.toBuilder(); - } - partitionId_ = input.readMessage(com.google.privacy.dlp.v2beta1.PartitionId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(partitionId_); - partitionId_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.KindExpression.Builder subBuilder = null; - if (kind_ != null) { - subBuilder = kind_.toBuilder(); - } - kind_ = input.readMessage(com.google.privacy.dlp.v2beta1.KindExpression.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(kind_); - kind_ = subBuilder.buildPartial(); - } - - break; - } - case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { - projection_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000004; - } - projection_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.Projection.parser(), extensionRegistry)); - 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_ & 0x00000004) == 0x00000004)) { - projection_ = java.util.Collections.unmodifiableList(projection_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_DatastoreOptions_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_DatastoreOptions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DatastoreOptions.class, com.google.privacy.dlp.v2beta1.DatastoreOptions.Builder.class); - } - - private int bitField0_; - public static final int PARTITION_ID_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.PartitionId partitionId_; - /** - *
-   * A partition ID identifies a grouping of entities. The grouping is always
-   * by project and namespace, however the namespace ID may be empty.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public boolean hasPartitionId() { - return partitionId_ != null; - } - /** - *
-   * A partition ID identifies a grouping of entities. The grouping is always
-   * by project and namespace, however the namespace ID may be empty.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public com.google.privacy.dlp.v2beta1.PartitionId getPartitionId() { - return partitionId_ == null ? com.google.privacy.dlp.v2beta1.PartitionId.getDefaultInstance() : partitionId_; - } - /** - *
-   * A partition ID identifies a grouping of entities. The grouping is always
-   * by project and namespace, however the namespace ID may be empty.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder getPartitionIdOrBuilder() { - return getPartitionId(); - } - - public static final int KIND_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.KindExpression kind_; - /** - *
-   * The kind to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public boolean hasKind() { - return kind_ != null; - } - /** - *
-   * The kind to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public com.google.privacy.dlp.v2beta1.KindExpression getKind() { - return kind_ == null ? com.google.privacy.dlp.v2beta1.KindExpression.getDefaultInstance() : kind_; - } - /** - *
-   * The kind to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public com.google.privacy.dlp.v2beta1.KindExpressionOrBuilder getKindOrBuilder() { - return getKind(); - } - - public static final int PROJECTION_FIELD_NUMBER = 3; - private java.util.List projection_; - /** - *
-   * Properties to scan. If none are specified, all properties will be scanned
-   * by default.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public java.util.List getProjectionList() { - return projection_; - } - /** - *
-   * Properties to scan. If none are specified, all properties will be scanned
-   * by default.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public java.util.List - getProjectionOrBuilderList() { - return projection_; - } - /** - *
-   * Properties to scan. If none are specified, all properties will be scanned
-   * by default.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public int getProjectionCount() { - return projection_.size(); - } - /** - *
-   * Properties to scan. If none are specified, all properties will be scanned
-   * by default.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public com.google.privacy.dlp.v2beta1.Projection getProjection(int index) { - return projection_.get(index); - } - /** - *
-   * Properties to scan. If none are specified, all properties will be scanned
-   * by default.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public com.google.privacy.dlp.v2beta1.ProjectionOrBuilder getProjectionOrBuilder( - int index) { - return projection_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (partitionId_ != null) { - output.writeMessage(1, getPartitionId()); - } - if (kind_ != null) { - output.writeMessage(2, getKind()); - } - for (int i = 0; i < projection_.size(); i++) { - output.writeMessage(3, projection_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (partitionId_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getPartitionId()); - } - if (kind_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getKind()); - } - for (int i = 0; i < projection_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, projection_.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.privacy.dlp.v2beta1.DatastoreOptions)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.DatastoreOptions other = (com.google.privacy.dlp.v2beta1.DatastoreOptions) obj; - - boolean result = true; - result = result && (hasPartitionId() == other.hasPartitionId()); - if (hasPartitionId()) { - result = result && getPartitionId() - .equals(other.getPartitionId()); - } - result = result && (hasKind() == other.hasKind()); - if (hasKind()) { - result = result && getKind() - .equals(other.getKind()); - } - result = result && getProjectionList() - .equals(other.getProjectionList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasPartitionId()) { - hash = (37 * hash) + PARTITION_ID_FIELD_NUMBER; - hash = (53 * hash) + getPartitionId().hashCode(); - } - if (hasKind()) { - hash = (37 * hash) + KIND_FIELD_NUMBER; - hash = (53 * hash) + getKind().hashCode(); - } - if (getProjectionCount() > 0) { - hash = (37 * hash) + PROJECTION_FIELD_NUMBER; - hash = (53 * hash) + getProjectionList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.DatastoreOptions parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DatastoreOptions parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DatastoreOptions parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DatastoreOptions 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.privacy.dlp.v2beta1.DatastoreOptions parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DatastoreOptions parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DatastoreOptions parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DatastoreOptions 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.privacy.dlp.v2beta1.DatastoreOptions parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DatastoreOptions 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.privacy.dlp.v2beta1.DatastoreOptions parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DatastoreOptions parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.DatastoreOptions prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Options defining a data set within Google Cloud Datastore.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DatastoreOptions} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.DatastoreOptions) - com.google.privacy.dlp.v2beta1.DatastoreOptionsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_DatastoreOptions_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_DatastoreOptions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DatastoreOptions.class, com.google.privacy.dlp.v2beta1.DatastoreOptions.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.DatastoreOptions.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getProjectionFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (partitionIdBuilder_ == null) { - partitionId_ = null; - } else { - partitionId_ = null; - partitionIdBuilder_ = null; - } - if (kindBuilder_ == null) { - kind_ = null; - } else { - kind_ = null; - kindBuilder_ = null; - } - if (projectionBuilder_ == null) { - projection_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - } else { - projectionBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_DatastoreOptions_descriptor; - } - - public com.google.privacy.dlp.v2beta1.DatastoreOptions getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.DatastoreOptions.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.DatastoreOptions build() { - com.google.privacy.dlp.v2beta1.DatastoreOptions result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.DatastoreOptions buildPartial() { - com.google.privacy.dlp.v2beta1.DatastoreOptions result = new com.google.privacy.dlp.v2beta1.DatastoreOptions(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (partitionIdBuilder_ == null) { - result.partitionId_ = partitionId_; - } else { - result.partitionId_ = partitionIdBuilder_.build(); - } - if (kindBuilder_ == null) { - result.kind_ = kind_; - } else { - result.kind_ = kindBuilder_.build(); - } - if (projectionBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { - projection_ = java.util.Collections.unmodifiableList(projection_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.projection_ = projection_; - } else { - result.projection_ = projectionBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.DatastoreOptions) { - return mergeFrom((com.google.privacy.dlp.v2beta1.DatastoreOptions)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.DatastoreOptions other) { - if (other == com.google.privacy.dlp.v2beta1.DatastoreOptions.getDefaultInstance()) return this; - if (other.hasPartitionId()) { - mergePartitionId(other.getPartitionId()); - } - if (other.hasKind()) { - mergeKind(other.getKind()); - } - if (projectionBuilder_ == null) { - if (!other.projection_.isEmpty()) { - if (projection_.isEmpty()) { - projection_ = other.projection_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureProjectionIsMutable(); - projection_.addAll(other.projection_); - } - onChanged(); - } - } else { - if (!other.projection_.isEmpty()) { - if (projectionBuilder_.isEmpty()) { - projectionBuilder_.dispose(); - projectionBuilder_ = null; - projection_ = other.projection_; - bitField0_ = (bitField0_ & ~0x00000004); - projectionBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getProjectionFieldBuilder() : null; - } else { - projectionBuilder_.addAllMessages(other.projection_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.DatastoreOptions parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.DatastoreOptions) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private com.google.privacy.dlp.v2beta1.PartitionId partitionId_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PartitionId, com.google.privacy.dlp.v2beta1.PartitionId.Builder, com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder> partitionIdBuilder_; - /** - *
-     * A partition ID identifies a grouping of entities. The grouping is always
-     * by project and namespace, however the namespace ID may be empty.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public boolean hasPartitionId() { - return partitionIdBuilder_ != null || partitionId_ != null; - } - /** - *
-     * A partition ID identifies a grouping of entities. The grouping is always
-     * by project and namespace, however the namespace ID may be empty.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public com.google.privacy.dlp.v2beta1.PartitionId getPartitionId() { - if (partitionIdBuilder_ == null) { - return partitionId_ == null ? com.google.privacy.dlp.v2beta1.PartitionId.getDefaultInstance() : partitionId_; - } else { - return partitionIdBuilder_.getMessage(); - } - } - /** - *
-     * A partition ID identifies a grouping of entities. The grouping is always
-     * by project and namespace, however the namespace ID may be empty.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public Builder setPartitionId(com.google.privacy.dlp.v2beta1.PartitionId value) { - if (partitionIdBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - partitionId_ = value; - onChanged(); - } else { - partitionIdBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * A partition ID identifies a grouping of entities. The grouping is always
-     * by project and namespace, however the namespace ID may be empty.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public Builder setPartitionId( - com.google.privacy.dlp.v2beta1.PartitionId.Builder builderForValue) { - if (partitionIdBuilder_ == null) { - partitionId_ = builderForValue.build(); - onChanged(); - } else { - partitionIdBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * A partition ID identifies a grouping of entities. The grouping is always
-     * by project and namespace, however the namespace ID may be empty.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public Builder mergePartitionId(com.google.privacy.dlp.v2beta1.PartitionId value) { - if (partitionIdBuilder_ == null) { - if (partitionId_ != null) { - partitionId_ = - com.google.privacy.dlp.v2beta1.PartitionId.newBuilder(partitionId_).mergeFrom(value).buildPartial(); - } else { - partitionId_ = value; - } - onChanged(); - } else { - partitionIdBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * A partition ID identifies a grouping of entities. The grouping is always
-     * by project and namespace, however the namespace ID may be empty.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public Builder clearPartitionId() { - if (partitionIdBuilder_ == null) { - partitionId_ = null; - onChanged(); - } else { - partitionId_ = null; - partitionIdBuilder_ = null; - } - - return this; - } - /** - *
-     * A partition ID identifies a grouping of entities. The grouping is always
-     * by project and namespace, however the namespace ID may be empty.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public com.google.privacy.dlp.v2beta1.PartitionId.Builder getPartitionIdBuilder() { - - onChanged(); - return getPartitionIdFieldBuilder().getBuilder(); - } - /** - *
-     * A partition ID identifies a grouping of entities. The grouping is always
-     * by project and namespace, however the namespace ID may be empty.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder getPartitionIdOrBuilder() { - if (partitionIdBuilder_ != null) { - return partitionIdBuilder_.getMessageOrBuilder(); - } else { - return partitionId_ == null ? - com.google.privacy.dlp.v2beta1.PartitionId.getDefaultInstance() : partitionId_; - } - } - /** - *
-     * A partition ID identifies a grouping of entities. The grouping is always
-     * by project and namespace, however the namespace ID may be empty.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PartitionId, com.google.privacy.dlp.v2beta1.PartitionId.Builder, com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder> - getPartitionIdFieldBuilder() { - if (partitionIdBuilder_ == null) { - partitionIdBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PartitionId, com.google.privacy.dlp.v2beta1.PartitionId.Builder, com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder>( - getPartitionId(), - getParentForChildren(), - isClean()); - partitionId_ = null; - } - return partitionIdBuilder_; - } - - private com.google.privacy.dlp.v2beta1.KindExpression kind_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.KindExpression, com.google.privacy.dlp.v2beta1.KindExpression.Builder, com.google.privacy.dlp.v2beta1.KindExpressionOrBuilder> kindBuilder_; - /** - *
-     * The kind to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public boolean hasKind() { - return kindBuilder_ != null || kind_ != null; - } - /** - *
-     * The kind to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public com.google.privacy.dlp.v2beta1.KindExpression getKind() { - if (kindBuilder_ == null) { - return kind_ == null ? com.google.privacy.dlp.v2beta1.KindExpression.getDefaultInstance() : kind_; - } else { - return kindBuilder_.getMessage(); - } - } - /** - *
-     * The kind to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public Builder setKind(com.google.privacy.dlp.v2beta1.KindExpression value) { - if (kindBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - kind_ = value; - onChanged(); - } else { - kindBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The kind to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public Builder setKind( - com.google.privacy.dlp.v2beta1.KindExpression.Builder builderForValue) { - if (kindBuilder_ == null) { - kind_ = builderForValue.build(); - onChanged(); - } else { - kindBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The kind to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public Builder mergeKind(com.google.privacy.dlp.v2beta1.KindExpression value) { - if (kindBuilder_ == null) { - if (kind_ != null) { - kind_ = - com.google.privacy.dlp.v2beta1.KindExpression.newBuilder(kind_).mergeFrom(value).buildPartial(); - } else { - kind_ = value; - } - onChanged(); - } else { - kindBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The kind to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public Builder clearKind() { - if (kindBuilder_ == null) { - kind_ = null; - onChanged(); - } else { - kind_ = null; - kindBuilder_ = null; - } - - return this; - } - /** - *
-     * The kind to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public com.google.privacy.dlp.v2beta1.KindExpression.Builder getKindBuilder() { - - onChanged(); - return getKindFieldBuilder().getBuilder(); - } - /** - *
-     * The kind to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - public com.google.privacy.dlp.v2beta1.KindExpressionOrBuilder getKindOrBuilder() { - if (kindBuilder_ != null) { - return kindBuilder_.getMessageOrBuilder(); - } else { - return kind_ == null ? - com.google.privacy.dlp.v2beta1.KindExpression.getDefaultInstance() : kind_; - } - } - /** - *
-     * The kind to process.
-     * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.KindExpression, com.google.privacy.dlp.v2beta1.KindExpression.Builder, com.google.privacy.dlp.v2beta1.KindExpressionOrBuilder> - getKindFieldBuilder() { - if (kindBuilder_ == null) { - kindBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.KindExpression, com.google.privacy.dlp.v2beta1.KindExpression.Builder, com.google.privacy.dlp.v2beta1.KindExpressionOrBuilder>( - getKind(), - getParentForChildren(), - isClean()); - kind_ = null; - } - return kindBuilder_; - } - - private java.util.List projection_ = - java.util.Collections.emptyList(); - private void ensureProjectionIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { - projection_ = new java.util.ArrayList(projection_); - bitField0_ |= 0x00000004; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Projection, com.google.privacy.dlp.v2beta1.Projection.Builder, com.google.privacy.dlp.v2beta1.ProjectionOrBuilder> projectionBuilder_; - - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public java.util.List getProjectionList() { - if (projectionBuilder_ == null) { - return java.util.Collections.unmodifiableList(projection_); - } else { - return projectionBuilder_.getMessageList(); - } - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public int getProjectionCount() { - if (projectionBuilder_ == null) { - return projection_.size(); - } else { - return projectionBuilder_.getCount(); - } - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public com.google.privacy.dlp.v2beta1.Projection getProjection(int index) { - if (projectionBuilder_ == null) { - return projection_.get(index); - } else { - return projectionBuilder_.getMessage(index); - } - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public Builder setProjection( - int index, com.google.privacy.dlp.v2beta1.Projection value) { - if (projectionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureProjectionIsMutable(); - projection_.set(index, value); - onChanged(); - } else { - projectionBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public Builder setProjection( - int index, com.google.privacy.dlp.v2beta1.Projection.Builder builderForValue) { - if (projectionBuilder_ == null) { - ensureProjectionIsMutable(); - projection_.set(index, builderForValue.build()); - onChanged(); - } else { - projectionBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public Builder addProjection(com.google.privacy.dlp.v2beta1.Projection value) { - if (projectionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureProjectionIsMutable(); - projection_.add(value); - onChanged(); - } else { - projectionBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public Builder addProjection( - int index, com.google.privacy.dlp.v2beta1.Projection value) { - if (projectionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureProjectionIsMutable(); - projection_.add(index, value); - onChanged(); - } else { - projectionBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public Builder addProjection( - com.google.privacy.dlp.v2beta1.Projection.Builder builderForValue) { - if (projectionBuilder_ == null) { - ensureProjectionIsMutable(); - projection_.add(builderForValue.build()); - onChanged(); - } else { - projectionBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public Builder addProjection( - int index, com.google.privacy.dlp.v2beta1.Projection.Builder builderForValue) { - if (projectionBuilder_ == null) { - ensureProjectionIsMutable(); - projection_.add(index, builderForValue.build()); - onChanged(); - } else { - projectionBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public Builder addAllProjection( - java.lang.Iterable values) { - if (projectionBuilder_ == null) { - ensureProjectionIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, projection_); - onChanged(); - } else { - projectionBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public Builder clearProjection() { - if (projectionBuilder_ == null) { - projection_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - } else { - projectionBuilder_.clear(); - } - return this; - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public Builder removeProjection(int index) { - if (projectionBuilder_ == null) { - ensureProjectionIsMutable(); - projection_.remove(index); - onChanged(); - } else { - projectionBuilder_.remove(index); - } - return this; - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public com.google.privacy.dlp.v2beta1.Projection.Builder getProjectionBuilder( - int index) { - return getProjectionFieldBuilder().getBuilder(index); - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public com.google.privacy.dlp.v2beta1.ProjectionOrBuilder getProjectionOrBuilder( - int index) { - if (projectionBuilder_ == null) { - return projection_.get(index); } else { - return projectionBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public java.util.List - getProjectionOrBuilderList() { - if (projectionBuilder_ != null) { - return projectionBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(projection_); - } - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public com.google.privacy.dlp.v2beta1.Projection.Builder addProjectionBuilder() { - return getProjectionFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.Projection.getDefaultInstance()); - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public com.google.privacy.dlp.v2beta1.Projection.Builder addProjectionBuilder( - int index) { - return getProjectionFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.Projection.getDefaultInstance()); - } - /** - *
-     * Properties to scan. If none are specified, all properties will be scanned
-     * by default.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - public java.util.List - getProjectionBuilderList() { - return getProjectionFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Projection, com.google.privacy.dlp.v2beta1.Projection.Builder, com.google.privacy.dlp.v2beta1.ProjectionOrBuilder> - getProjectionFieldBuilder() { - if (projectionBuilder_ == null) { - projectionBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Projection, com.google.privacy.dlp.v2beta1.Projection.Builder, com.google.privacy.dlp.v2beta1.ProjectionOrBuilder>( - projection_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); - projection_ = null; - } - return projectionBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.DatastoreOptions) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.DatastoreOptions) - private static final com.google.privacy.dlp.v2beta1.DatastoreOptions DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.DatastoreOptions(); - } - - public static com.google.privacy.dlp.v2beta1.DatastoreOptions getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public DatastoreOptions parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DatastoreOptions(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.DatastoreOptions getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreOptionsOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreOptionsOrBuilder.java deleted file mode 100644 index 399cc66fb7ee..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DatastoreOptionsOrBuilder.java +++ /dev/null @@ -1,111 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface DatastoreOptionsOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.DatastoreOptions) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * A partition ID identifies a grouping of entities. The grouping is always
-   * by project and namespace, however the namespace ID may be empty.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - boolean hasPartitionId(); - /** - *
-   * A partition ID identifies a grouping of entities. The grouping is always
-   * by project and namespace, however the namespace ID may be empty.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - com.google.privacy.dlp.v2beta1.PartitionId getPartitionId(); - /** - *
-   * A partition ID identifies a grouping of entities. The grouping is always
-   * by project and namespace, however the namespace ID may be empty.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder getPartitionIdOrBuilder(); - - /** - *
-   * The kind to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - boolean hasKind(); - /** - *
-   * The kind to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - com.google.privacy.dlp.v2beta1.KindExpression getKind(); - /** - *
-   * The kind to process.
-   * 
- * - * .google.privacy.dlp.v2beta1.KindExpression kind = 2; - */ - com.google.privacy.dlp.v2beta1.KindExpressionOrBuilder getKindOrBuilder(); - - /** - *
-   * Properties to scan. If none are specified, all properties will be scanned
-   * by default.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - java.util.List - getProjectionList(); - /** - *
-   * Properties to scan. If none are specified, all properties will be scanned
-   * by default.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - com.google.privacy.dlp.v2beta1.Projection getProjection(int index); - /** - *
-   * Properties to scan. If none are specified, all properties will be scanned
-   * by default.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - int getProjectionCount(); - /** - *
-   * Properties to scan. If none are specified, all properties will be scanned
-   * by default.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - java.util.List - getProjectionOrBuilderList(); - /** - *
-   * Properties to scan. If none are specified, all properties will be scanned
-   * by default.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Projection projection = 3; - */ - com.google.privacy.dlp.v2beta1.ProjectionOrBuilder getProjectionOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentificationSummary.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentificationSummary.java deleted file mode 100644 index d0c91a61fb52..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentificationSummary.java +++ /dev/null @@ -1,912 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * High level summary of deidentification.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DeidentificationSummary} - */ -public final class DeidentificationSummary extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.DeidentificationSummary) - DeidentificationSummaryOrBuilder { -private static final long serialVersionUID = 0L; - // Use DeidentificationSummary.newBuilder() to construct. - private DeidentificationSummary(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private DeidentificationSummary() { - transformedBytes_ = 0L; - transformationSummaries_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private DeidentificationSummary( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 16: { - - transformedBytes_ = input.readInt64(); - break; - } - case 26: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - transformationSummaries_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - transformationSummaries_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.TransformationSummary.parser(), extensionRegistry)); - 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_ & 0x00000002) == 0x00000002)) { - transformationSummaries_ = java.util.Collections.unmodifiableList(transformationSummaries_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentificationSummary_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentificationSummary_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DeidentificationSummary.class, com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder.class); - } - - private int bitField0_; - public static final int TRANSFORMED_BYTES_FIELD_NUMBER = 2; - private long transformedBytes_; - /** - *
-   * Total size in bytes that were transformed in some way.
-   * 
- * - * int64 transformed_bytes = 2; - */ - public long getTransformedBytes() { - return transformedBytes_; - } - - public static final int TRANSFORMATION_SUMMARIES_FIELD_NUMBER = 3; - private java.util.List transformationSummaries_; - /** - *
-   * Transformations applied to the dataset.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public java.util.List getTransformationSummariesList() { - return transformationSummaries_; - } - /** - *
-   * Transformations applied to the dataset.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public java.util.List - getTransformationSummariesOrBuilderList() { - return transformationSummaries_; - } - /** - *
-   * Transformations applied to the dataset.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public int getTransformationSummariesCount() { - return transformationSummaries_.size(); - } - /** - *
-   * Transformations applied to the dataset.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary getTransformationSummaries(int index) { - return transformationSummaries_.get(index); - } - /** - *
-   * Transformations applied to the dataset.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummaryOrBuilder getTransformationSummariesOrBuilder( - int index) { - return transformationSummaries_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (transformedBytes_ != 0L) { - output.writeInt64(2, transformedBytes_); - } - for (int i = 0; i < transformationSummaries_.size(); i++) { - output.writeMessage(3, transformationSummaries_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (transformedBytes_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(2, transformedBytes_); - } - for (int i = 0; i < transformationSummaries_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, transformationSummaries_.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.privacy.dlp.v2beta1.DeidentificationSummary)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.DeidentificationSummary other = (com.google.privacy.dlp.v2beta1.DeidentificationSummary) obj; - - boolean result = true; - result = result && (getTransformedBytes() - == other.getTransformedBytes()); - result = result && getTransformationSummariesList() - .equals(other.getTransformationSummariesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TRANSFORMED_BYTES_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getTransformedBytes()); - if (getTransformationSummariesCount() > 0) { - hash = (37 * hash) + TRANSFORMATION_SUMMARIES_FIELD_NUMBER; - hash = (53 * hash) + getTransformationSummariesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.DeidentificationSummary parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentificationSummary parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DeidentificationSummary parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentificationSummary 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.privacy.dlp.v2beta1.DeidentificationSummary parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentificationSummary parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DeidentificationSummary parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentificationSummary 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.privacy.dlp.v2beta1.DeidentificationSummary parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentificationSummary 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.privacy.dlp.v2beta1.DeidentificationSummary parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentificationSummary parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.DeidentificationSummary prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * High level summary of deidentification.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DeidentificationSummary} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.DeidentificationSummary) - com.google.privacy.dlp.v2beta1.DeidentificationSummaryOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentificationSummary_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentificationSummary_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DeidentificationSummary.class, com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.DeidentificationSummary.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getTransformationSummariesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - transformedBytes_ = 0L; - - if (transformationSummariesBuilder_ == null) { - transformationSummaries_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - transformationSummariesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentificationSummary_descriptor; - } - - public com.google.privacy.dlp.v2beta1.DeidentificationSummary getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.DeidentificationSummary.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.DeidentificationSummary build() { - com.google.privacy.dlp.v2beta1.DeidentificationSummary result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.DeidentificationSummary buildPartial() { - com.google.privacy.dlp.v2beta1.DeidentificationSummary result = new com.google.privacy.dlp.v2beta1.DeidentificationSummary(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.transformedBytes_ = transformedBytes_; - if (transformationSummariesBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - transformationSummaries_ = java.util.Collections.unmodifiableList(transformationSummaries_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.transformationSummaries_ = transformationSummaries_; - } else { - result.transformationSummaries_ = transformationSummariesBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.DeidentificationSummary) { - return mergeFrom((com.google.privacy.dlp.v2beta1.DeidentificationSummary)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.DeidentificationSummary other) { - if (other == com.google.privacy.dlp.v2beta1.DeidentificationSummary.getDefaultInstance()) return this; - if (other.getTransformedBytes() != 0L) { - setTransformedBytes(other.getTransformedBytes()); - } - if (transformationSummariesBuilder_ == null) { - if (!other.transformationSummaries_.isEmpty()) { - if (transformationSummaries_.isEmpty()) { - transformationSummaries_ = other.transformationSummaries_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureTransformationSummariesIsMutable(); - transformationSummaries_.addAll(other.transformationSummaries_); - } - onChanged(); - } - } else { - if (!other.transformationSummaries_.isEmpty()) { - if (transformationSummariesBuilder_.isEmpty()) { - transformationSummariesBuilder_.dispose(); - transformationSummariesBuilder_ = null; - transformationSummaries_ = other.transformationSummaries_; - bitField0_ = (bitField0_ & ~0x00000002); - transformationSummariesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getTransformationSummariesFieldBuilder() : null; - } else { - transformationSummariesBuilder_.addAllMessages(other.transformationSummaries_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.DeidentificationSummary parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.DeidentificationSummary) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private long transformedBytes_ ; - /** - *
-     * Total size in bytes that were transformed in some way.
-     * 
- * - * int64 transformed_bytes = 2; - */ - public long getTransformedBytes() { - return transformedBytes_; - } - /** - *
-     * Total size in bytes that were transformed in some way.
-     * 
- * - * int64 transformed_bytes = 2; - */ - public Builder setTransformedBytes(long value) { - - transformedBytes_ = value; - onChanged(); - return this; - } - /** - *
-     * Total size in bytes that were transformed in some way.
-     * 
- * - * int64 transformed_bytes = 2; - */ - public Builder clearTransformedBytes() { - - transformedBytes_ = 0L; - onChanged(); - return this; - } - - private java.util.List transformationSummaries_ = - java.util.Collections.emptyList(); - private void ensureTransformationSummariesIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - transformationSummaries_ = new java.util.ArrayList(transformationSummaries_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TransformationSummary, com.google.privacy.dlp.v2beta1.TransformationSummary.Builder, com.google.privacy.dlp.v2beta1.TransformationSummaryOrBuilder> transformationSummariesBuilder_; - - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public java.util.List getTransformationSummariesList() { - if (transformationSummariesBuilder_ == null) { - return java.util.Collections.unmodifiableList(transformationSummaries_); - } else { - return transformationSummariesBuilder_.getMessageList(); - } - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public int getTransformationSummariesCount() { - if (transformationSummariesBuilder_ == null) { - return transformationSummaries_.size(); - } else { - return transformationSummariesBuilder_.getCount(); - } - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary getTransformationSummaries(int index) { - if (transformationSummariesBuilder_ == null) { - return transformationSummaries_.get(index); - } else { - return transformationSummariesBuilder_.getMessage(index); - } - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public Builder setTransformationSummaries( - int index, com.google.privacy.dlp.v2beta1.TransformationSummary value) { - if (transformationSummariesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTransformationSummariesIsMutable(); - transformationSummaries_.set(index, value); - onChanged(); - } else { - transformationSummariesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public Builder setTransformationSummaries( - int index, com.google.privacy.dlp.v2beta1.TransformationSummary.Builder builderForValue) { - if (transformationSummariesBuilder_ == null) { - ensureTransformationSummariesIsMutable(); - transformationSummaries_.set(index, builderForValue.build()); - onChanged(); - } else { - transformationSummariesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public Builder addTransformationSummaries(com.google.privacy.dlp.v2beta1.TransformationSummary value) { - if (transformationSummariesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTransformationSummariesIsMutable(); - transformationSummaries_.add(value); - onChanged(); - } else { - transformationSummariesBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public Builder addTransformationSummaries( - int index, com.google.privacy.dlp.v2beta1.TransformationSummary value) { - if (transformationSummariesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTransformationSummariesIsMutable(); - transformationSummaries_.add(index, value); - onChanged(); - } else { - transformationSummariesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public Builder addTransformationSummaries( - com.google.privacy.dlp.v2beta1.TransformationSummary.Builder builderForValue) { - if (transformationSummariesBuilder_ == null) { - ensureTransformationSummariesIsMutable(); - transformationSummaries_.add(builderForValue.build()); - onChanged(); - } else { - transformationSummariesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public Builder addTransformationSummaries( - int index, com.google.privacy.dlp.v2beta1.TransformationSummary.Builder builderForValue) { - if (transformationSummariesBuilder_ == null) { - ensureTransformationSummariesIsMutable(); - transformationSummaries_.add(index, builderForValue.build()); - onChanged(); - } else { - transformationSummariesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public Builder addAllTransformationSummaries( - java.lang.Iterable values) { - if (transformationSummariesBuilder_ == null) { - ensureTransformationSummariesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, transformationSummaries_); - onChanged(); - } else { - transformationSummariesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public Builder clearTransformationSummaries() { - if (transformationSummariesBuilder_ == null) { - transformationSummaries_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - transformationSummariesBuilder_.clear(); - } - return this; - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public Builder removeTransformationSummaries(int index) { - if (transformationSummariesBuilder_ == null) { - ensureTransformationSummariesIsMutable(); - transformationSummaries_.remove(index); - onChanged(); - } else { - transformationSummariesBuilder_.remove(index); - } - return this; - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.Builder getTransformationSummariesBuilder( - int index) { - return getTransformationSummariesFieldBuilder().getBuilder(index); - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummaryOrBuilder getTransformationSummariesOrBuilder( - int index) { - if (transformationSummariesBuilder_ == null) { - return transformationSummaries_.get(index); } else { - return transformationSummariesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public java.util.List - getTransformationSummariesOrBuilderList() { - if (transformationSummariesBuilder_ != null) { - return transformationSummariesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(transformationSummaries_); - } - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.Builder addTransformationSummariesBuilder() { - return getTransformationSummariesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.TransformationSummary.getDefaultInstance()); - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.Builder addTransformationSummariesBuilder( - int index) { - return getTransformationSummariesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.TransformationSummary.getDefaultInstance()); - } - /** - *
-     * Transformations applied to the dataset.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - public java.util.List - getTransformationSummariesBuilderList() { - return getTransformationSummariesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TransformationSummary, com.google.privacy.dlp.v2beta1.TransformationSummary.Builder, com.google.privacy.dlp.v2beta1.TransformationSummaryOrBuilder> - getTransformationSummariesFieldBuilder() { - if (transformationSummariesBuilder_ == null) { - transformationSummariesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TransformationSummary, com.google.privacy.dlp.v2beta1.TransformationSummary.Builder, com.google.privacy.dlp.v2beta1.TransformationSummaryOrBuilder>( - transformationSummaries_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - transformationSummaries_ = null; - } - return transformationSummariesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.DeidentificationSummary) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.DeidentificationSummary) - private static final com.google.privacy.dlp.v2beta1.DeidentificationSummary DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.DeidentificationSummary(); - } - - public static com.google.privacy.dlp.v2beta1.DeidentificationSummary getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public DeidentificationSummary parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DeidentificationSummary(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.DeidentificationSummary getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentificationSummaryOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentificationSummaryOrBuilder.java deleted file mode 100644 index b05605e9fa68..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentificationSummaryOrBuilder.java +++ /dev/null @@ -1,62 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface DeidentificationSummaryOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.DeidentificationSummary) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Total size in bytes that were transformed in some way.
-   * 
- * - * int64 transformed_bytes = 2; - */ - long getTransformedBytes(); - - /** - *
-   * Transformations applied to the dataset.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - java.util.List - getTransformationSummariesList(); - /** - *
-   * Transformations applied to the dataset.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - com.google.privacy.dlp.v2beta1.TransformationSummary getTransformationSummaries(int index); - /** - *
-   * Transformations applied to the dataset.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - int getTransformationSummariesCount(); - /** - *
-   * Transformations applied to the dataset.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - java.util.List - getTransformationSummariesOrBuilderList(); - /** - *
-   * Transformations applied to the dataset.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.TransformationSummary transformation_summaries = 3; - */ - com.google.privacy.dlp.v2beta1.TransformationSummaryOrBuilder getTransformationSummariesOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyConfig.java deleted file mode 100644 index 1f8d451cb975..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyConfig.java +++ /dev/null @@ -1,1005 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * The configuration that controls how the data will change.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DeidentifyConfig} - */ -public final class DeidentifyConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.DeidentifyConfig) - DeidentifyConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use DeidentifyConfig.newBuilder() to construct. - private DeidentifyConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private DeidentifyConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private DeidentifyConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder subBuilder = null; - if (transformationCase_ == 1) { - subBuilder = ((com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.InfoTypeTransformations.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 1; - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.RecordTransformations.Builder subBuilder = null; - if (transformationCase_ == 2) { - subBuilder = ((com.google.privacy.dlp.v2beta1.RecordTransformations) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.RecordTransformations.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.RecordTransformations) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 2; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DeidentifyConfig.class, com.google.privacy.dlp.v2beta1.DeidentifyConfig.Builder.class); - } - - private int transformationCase_ = 0; - private java.lang.Object transformation_; - public enum TransformationCase - implements com.google.protobuf.Internal.EnumLite { - INFO_TYPE_TRANSFORMATIONS(1), - RECORD_TRANSFORMATIONS(2), - TRANSFORMATION_NOT_SET(0); - private final int value; - private TransformationCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TransformationCase valueOf(int value) { - return forNumber(value); - } - - public static TransformationCase forNumber(int value) { - switch (value) { - case 1: return INFO_TYPE_TRANSFORMATIONS; - case 2: return RECORD_TRANSFORMATIONS; - case 0: return TRANSFORMATION_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TransformationCase - getTransformationCase() { - return TransformationCase.forNumber( - transformationCase_); - } - - public static final int INFO_TYPE_TRANSFORMATIONS_FIELD_NUMBER = 1; - /** - *
-   * Treat the dataset as free-form text and apply the same free text
-   * transformation everywhere.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public boolean hasInfoTypeTransformations() { - return transformationCase_ == 1; - } - /** - *
-   * Treat the dataset as free-form text and apply the same free text
-   * transformation everywhere.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations getInfoTypeTransformations() { - if (transformationCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - /** - *
-   * Treat the dataset as free-form text and apply the same free text
-   * transformation everywhere.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder getInfoTypeTransformationsOrBuilder() { - if (transformationCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - - public static final int RECORD_TRANSFORMATIONS_FIELD_NUMBER = 2; - /** - *
-   * Treat the dataset as structured. Transformations can be applied to
-   * specific locations within structured datasets, such as transforming
-   * a column within a table.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public boolean hasRecordTransformations() { - return transformationCase_ == 2; - } - /** - *
-   * Treat the dataset as structured. Transformations can be applied to
-   * specific locations within structured datasets, such as transforming
-   * a column within a table.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordTransformations getRecordTransformations() { - if (transformationCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.RecordTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.RecordTransformations.getDefaultInstance(); - } - /** - *
-   * Treat the dataset as structured. Transformations can be applied to
-   * specific locations within structured datasets, such as transforming
-   * a column within a table.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordTransformationsOrBuilder getRecordTransformationsOrBuilder() { - if (transformationCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.RecordTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.RecordTransformations.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (transformationCase_ == 1) { - output.writeMessage(1, (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_); - } - if (transformationCase_ == 2) { - output.writeMessage(2, (com.google.privacy.dlp.v2beta1.RecordTransformations) transformation_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (transformationCase_ == 1) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_); - } - if (transformationCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, (com.google.privacy.dlp.v2beta1.RecordTransformations) transformation_); - } - 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.privacy.dlp.v2beta1.DeidentifyConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.DeidentifyConfig other = (com.google.privacy.dlp.v2beta1.DeidentifyConfig) obj; - - boolean result = true; - result = result && getTransformationCase().equals( - other.getTransformationCase()); - if (!result) return false; - switch (transformationCase_) { - case 1: - result = result && getInfoTypeTransformations() - .equals(other.getInfoTypeTransformations()); - break; - case 2: - result = result && getRecordTransformations() - .equals(other.getRecordTransformations()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (transformationCase_) { - case 1: - hash = (37 * hash) + INFO_TYPE_TRANSFORMATIONS_FIELD_NUMBER; - hash = (53 * hash) + getInfoTypeTransformations().hashCode(); - break; - case 2: - hash = (37 * hash) + RECORD_TRANSFORMATIONS_FIELD_NUMBER; - hash = (53 * hash) + getRecordTransformations().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.DeidentifyConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyConfig 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.privacy.dlp.v2beta1.DeidentifyConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyConfig 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.privacy.dlp.v2beta1.DeidentifyConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyConfig 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.privacy.dlp.v2beta1.DeidentifyConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.DeidentifyConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * The configuration that controls how the data will change.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DeidentifyConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.DeidentifyConfig) - com.google.privacy.dlp.v2beta1.DeidentifyConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DeidentifyConfig.class, com.google.privacy.dlp.v2beta1.DeidentifyConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.DeidentifyConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - transformationCase_ = 0; - transformation_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.DeidentifyConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.DeidentifyConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.DeidentifyConfig build() { - com.google.privacy.dlp.v2beta1.DeidentifyConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.DeidentifyConfig buildPartial() { - com.google.privacy.dlp.v2beta1.DeidentifyConfig result = new com.google.privacy.dlp.v2beta1.DeidentifyConfig(this); - if (transformationCase_ == 1) { - if (infoTypeTransformationsBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = infoTypeTransformationsBuilder_.build(); - } - } - if (transformationCase_ == 2) { - if (recordTransformationsBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = recordTransformationsBuilder_.build(); - } - } - result.transformationCase_ = transformationCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.DeidentifyConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.DeidentifyConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.DeidentifyConfig other) { - if (other == com.google.privacy.dlp.v2beta1.DeidentifyConfig.getDefaultInstance()) return this; - switch (other.getTransformationCase()) { - case INFO_TYPE_TRANSFORMATIONS: { - mergeInfoTypeTransformations(other.getInfoTypeTransformations()); - break; - } - case RECORD_TRANSFORMATIONS: { - mergeRecordTransformations(other.getRecordTransformations()); - break; - } - case TRANSFORMATION_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.DeidentifyConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.DeidentifyConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int transformationCase_ = 0; - private java.lang.Object transformation_; - public TransformationCase - getTransformationCase() { - return TransformationCase.forNumber( - transformationCase_); - } - - public Builder clearTransformation() { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - return this; - } - - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeTransformations, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder, com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder> infoTypeTransformationsBuilder_; - /** - *
-     * Treat the dataset as free-form text and apply the same free text
-     * transformation everywhere.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public boolean hasInfoTypeTransformations() { - return transformationCase_ == 1; - } - /** - *
-     * Treat the dataset as free-form text and apply the same free text
-     * transformation everywhere.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations getInfoTypeTransformations() { - if (infoTypeTransformationsBuilder_ == null) { - if (transformationCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } else { - if (transformationCase_ == 1) { - return infoTypeTransformationsBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - } - /** - *
-     * Treat the dataset as free-form text and apply the same free text
-     * transformation everywhere.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public Builder setInfoTypeTransformations(com.google.privacy.dlp.v2beta1.InfoTypeTransformations value) { - if (infoTypeTransformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - infoTypeTransformationsBuilder_.setMessage(value); - } - transformationCase_ = 1; - return this; - } - /** - *
-     * Treat the dataset as free-form text and apply the same free text
-     * transformation everywhere.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public Builder setInfoTypeTransformations( - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder builderForValue) { - if (infoTypeTransformationsBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - infoTypeTransformationsBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 1; - return this; - } - /** - *
-     * Treat the dataset as free-form text and apply the same free text
-     * transformation everywhere.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public Builder mergeInfoTypeTransformations(com.google.privacy.dlp.v2beta1.InfoTypeTransformations value) { - if (infoTypeTransformationsBuilder_ == null) { - if (transformationCase_ == 1 && - transformation_ != com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.InfoTypeTransformations.newBuilder((com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 1) { - infoTypeTransformationsBuilder_.mergeFrom(value); - } - infoTypeTransformationsBuilder_.setMessage(value); - } - transformationCase_ = 1; - return this; - } - /** - *
-     * Treat the dataset as free-form text and apply the same free text
-     * transformation everywhere.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public Builder clearInfoTypeTransformations() { - if (infoTypeTransformationsBuilder_ == null) { - if (transformationCase_ == 1) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 1) { - transformationCase_ = 0; - transformation_ = null; - } - infoTypeTransformationsBuilder_.clear(); - } - return this; - } - /** - *
-     * Treat the dataset as free-form text and apply the same free text
-     * transformation everywhere.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder getInfoTypeTransformationsBuilder() { - return getInfoTypeTransformationsFieldBuilder().getBuilder(); - } - /** - *
-     * Treat the dataset as free-form text and apply the same free text
-     * transformation everywhere.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder getInfoTypeTransformationsOrBuilder() { - if ((transformationCase_ == 1) && (infoTypeTransformationsBuilder_ != null)) { - return infoTypeTransformationsBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - } - /** - *
-     * Treat the dataset as free-form text and apply the same free text
-     * transformation everywhere.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeTransformations, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder, com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder> - getInfoTypeTransformationsFieldBuilder() { - if (infoTypeTransformationsBuilder_ == null) { - if (!(transformationCase_ == 1)) { - transformation_ = com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - infoTypeTransformationsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeTransformations, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder, com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder>( - (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 1; - onChanged();; - return infoTypeTransformationsBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordTransformations, com.google.privacy.dlp.v2beta1.RecordTransformations.Builder, com.google.privacy.dlp.v2beta1.RecordTransformationsOrBuilder> recordTransformationsBuilder_; - /** - *
-     * Treat the dataset as structured. Transformations can be applied to
-     * specific locations within structured datasets, such as transforming
-     * a column within a table.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public boolean hasRecordTransformations() { - return transformationCase_ == 2; - } - /** - *
-     * Treat the dataset as structured. Transformations can be applied to
-     * specific locations within structured datasets, such as transforming
-     * a column within a table.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordTransformations getRecordTransformations() { - if (recordTransformationsBuilder_ == null) { - if (transformationCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.RecordTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.RecordTransformations.getDefaultInstance(); - } else { - if (transformationCase_ == 2) { - return recordTransformationsBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.RecordTransformations.getDefaultInstance(); - } - } - /** - *
-     * Treat the dataset as structured. Transformations can be applied to
-     * specific locations within structured datasets, such as transforming
-     * a column within a table.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public Builder setRecordTransformations(com.google.privacy.dlp.v2beta1.RecordTransformations value) { - if (recordTransformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - recordTransformationsBuilder_.setMessage(value); - } - transformationCase_ = 2; - return this; - } - /** - *
-     * Treat the dataset as structured. Transformations can be applied to
-     * specific locations within structured datasets, such as transforming
-     * a column within a table.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public Builder setRecordTransformations( - com.google.privacy.dlp.v2beta1.RecordTransformations.Builder builderForValue) { - if (recordTransformationsBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - recordTransformationsBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 2; - return this; - } - /** - *
-     * Treat the dataset as structured. Transformations can be applied to
-     * specific locations within structured datasets, such as transforming
-     * a column within a table.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public Builder mergeRecordTransformations(com.google.privacy.dlp.v2beta1.RecordTransformations value) { - if (recordTransformationsBuilder_ == null) { - if (transformationCase_ == 2 && - transformation_ != com.google.privacy.dlp.v2beta1.RecordTransformations.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.RecordTransformations.newBuilder((com.google.privacy.dlp.v2beta1.RecordTransformations) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 2) { - recordTransformationsBuilder_.mergeFrom(value); - } - recordTransformationsBuilder_.setMessage(value); - } - transformationCase_ = 2; - return this; - } - /** - *
-     * Treat the dataset as structured. Transformations can be applied to
-     * specific locations within structured datasets, such as transforming
-     * a column within a table.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public Builder clearRecordTransformations() { - if (recordTransformationsBuilder_ == null) { - if (transformationCase_ == 2) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 2) { - transformationCase_ = 0; - transformation_ = null; - } - recordTransformationsBuilder_.clear(); - } - return this; - } - /** - *
-     * Treat the dataset as structured. Transformations can be applied to
-     * specific locations within structured datasets, such as transforming
-     * a column within a table.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordTransformations.Builder getRecordTransformationsBuilder() { - return getRecordTransformationsFieldBuilder().getBuilder(); - } - /** - *
-     * Treat the dataset as structured. Transformations can be applied to
-     * specific locations within structured datasets, such as transforming
-     * a column within a table.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordTransformationsOrBuilder getRecordTransformationsOrBuilder() { - if ((transformationCase_ == 2) && (recordTransformationsBuilder_ != null)) { - return recordTransformationsBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.RecordTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.RecordTransformations.getDefaultInstance(); - } - } - /** - *
-     * Treat the dataset as structured. Transformations can be applied to
-     * specific locations within structured datasets, such as transforming
-     * a column within a table.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordTransformations, com.google.privacy.dlp.v2beta1.RecordTransformations.Builder, com.google.privacy.dlp.v2beta1.RecordTransformationsOrBuilder> - getRecordTransformationsFieldBuilder() { - if (recordTransformationsBuilder_ == null) { - if (!(transformationCase_ == 2)) { - transformation_ = com.google.privacy.dlp.v2beta1.RecordTransformations.getDefaultInstance(); - } - recordTransformationsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordTransformations, com.google.privacy.dlp.v2beta1.RecordTransformations.Builder, com.google.privacy.dlp.v2beta1.RecordTransformationsOrBuilder>( - (com.google.privacy.dlp.v2beta1.RecordTransformations) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 2; - onChanged();; - return recordTransformationsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.DeidentifyConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.DeidentifyConfig) - private static final com.google.privacy.dlp.v2beta1.DeidentifyConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.DeidentifyConfig(); - } - - public static com.google.privacy.dlp.v2beta1.DeidentifyConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public DeidentifyConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DeidentifyConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.DeidentifyConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyConfigOrBuilder.java deleted file mode 100644 index a7161f374a07..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyConfigOrBuilder.java +++ /dev/null @@ -1,70 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface DeidentifyConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.DeidentifyConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Treat the dataset as free-form text and apply the same free text
-   * transformation everywhere.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - boolean hasInfoTypeTransformations(); - /** - *
-   * Treat the dataset as free-form text and apply the same free text
-   * transformation everywhere.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeTransformations getInfoTypeTransformations(); - /** - *
-   * Treat the dataset as free-form text and apply the same free text
-   * transformation everywhere.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder getInfoTypeTransformationsOrBuilder(); - - /** - *
-   * Treat the dataset as structured. Transformations can be applied to
-   * specific locations within structured datasets, such as transforming
-   * a column within a table.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - boolean hasRecordTransformations(); - /** - *
-   * Treat the dataset as structured. Transformations can be applied to
-   * specific locations within structured datasets, such as transforming
-   * a column within a table.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - com.google.privacy.dlp.v2beta1.RecordTransformations getRecordTransformations(); - /** - *
-   * Treat the dataset as structured. Transformations can be applied to
-   * specific locations within structured datasets, such as transforming
-   * a column within a table.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordTransformations record_transformations = 2; - */ - com.google.privacy.dlp.v2beta1.RecordTransformationsOrBuilder getRecordTransformationsOrBuilder(); - - public com.google.privacy.dlp.v2beta1.DeidentifyConfig.TransformationCase getTransformationCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentRequest.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentRequest.java deleted file mode 100644 index facf35c6cf44..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentRequest.java +++ /dev/null @@ -1,1318 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Request to de-identify a list of items.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DeidentifyContentRequest} - */ -public final class DeidentifyContentRequest extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.DeidentifyContentRequest) - DeidentifyContentRequestOrBuilder { -private static final long serialVersionUID = 0L; - // Use DeidentifyContentRequest.newBuilder() to construct. - private DeidentifyContentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private DeidentifyContentRequest() { - items_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private DeidentifyContentRequest( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.DeidentifyConfig.Builder subBuilder = null; - if (deidentifyConfig_ != null) { - subBuilder = deidentifyConfig_.toBuilder(); - } - deidentifyConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.DeidentifyConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(deidentifyConfig_); - deidentifyConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.InspectConfig.Builder subBuilder = null; - if (inspectConfig_ != null) { - subBuilder = inspectConfig_.toBuilder(); - } - inspectConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.InspectConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(inspectConfig_); - inspectConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { - items_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000004; - } - items_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.ContentItem.parser(), extensionRegistry)); - 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_ & 0x00000004) == 0x00000004)) { - items_ = java.util.Collections.unmodifiableList(items_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyContentRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyContentRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DeidentifyContentRequest.class, com.google.privacy.dlp.v2beta1.DeidentifyContentRequest.Builder.class); - } - - private int bitField0_; - public static final int DEIDENTIFY_CONFIG_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.DeidentifyConfig deidentifyConfig_; - /** - *
-   * Configuration for the de-identification of the list of content items.
-   * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public boolean hasDeidentifyConfig() { - return deidentifyConfig_ != null; - } - /** - *
-   * Configuration for the de-identification of the list of content items.
-   * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public com.google.privacy.dlp.v2beta1.DeidentifyConfig getDeidentifyConfig() { - return deidentifyConfig_ == null ? com.google.privacy.dlp.v2beta1.DeidentifyConfig.getDefaultInstance() : deidentifyConfig_; - } - /** - *
-   * Configuration for the de-identification of the list of content items.
-   * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public com.google.privacy.dlp.v2beta1.DeidentifyConfigOrBuilder getDeidentifyConfigOrBuilder() { - return getDeidentifyConfig(); - } - - public static final int INSPECT_CONFIG_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.InspectConfig inspectConfig_; - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public boolean hasInspectConfig() { - return inspectConfig_ != null; - } - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig() { - return inspectConfig_ == null ? com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder() { - return getInspectConfig(); - } - - public static final int ITEMS_FIELD_NUMBER = 3; - private java.util.List items_; - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * All items will be treated as text/*.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public java.util.List getItemsList() { - return items_; - } - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * All items will be treated as text/*.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public java.util.List - getItemsOrBuilderList() { - return items_; - } - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * All items will be treated as text/*.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public int getItemsCount() { - return items_.size(); - } - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * All items will be treated as text/*.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public com.google.privacy.dlp.v2beta1.ContentItem getItems(int index) { - return items_.get(index); - } - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * All items will be treated as text/*.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index) { - return items_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (deidentifyConfig_ != null) { - output.writeMessage(1, getDeidentifyConfig()); - } - if (inspectConfig_ != null) { - output.writeMessage(2, getInspectConfig()); - } - for (int i = 0; i < items_.size(); i++) { - output.writeMessage(3, items_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (deidentifyConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getDeidentifyConfig()); - } - if (inspectConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getInspectConfig()); - } - for (int i = 0; i < items_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, items_.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.privacy.dlp.v2beta1.DeidentifyContentRequest)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.DeidentifyContentRequest other = (com.google.privacy.dlp.v2beta1.DeidentifyContentRequest) obj; - - boolean result = true; - result = result && (hasDeidentifyConfig() == other.hasDeidentifyConfig()); - if (hasDeidentifyConfig()) { - result = result && getDeidentifyConfig() - .equals(other.getDeidentifyConfig()); - } - result = result && (hasInspectConfig() == other.hasInspectConfig()); - if (hasInspectConfig()) { - result = result && getInspectConfig() - .equals(other.getInspectConfig()); - } - result = result && getItemsList() - .equals(other.getItemsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasDeidentifyConfig()) { - hash = (37 * hash) + DEIDENTIFY_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getDeidentifyConfig().hashCode(); - } - if (hasInspectConfig()) { - hash = (37 * hash) + INSPECT_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getInspectConfig().hashCode(); - } - if (getItemsCount() > 0) { - hash = (37 * hash) + ITEMS_FIELD_NUMBER; - hash = (53 * hash) + getItemsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.DeidentifyContentRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentRequest 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.privacy.dlp.v2beta1.DeidentifyContentRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentRequest 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.privacy.dlp.v2beta1.DeidentifyContentRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentRequest 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.privacy.dlp.v2beta1.DeidentifyContentRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.DeidentifyContentRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Request to de-identify a list of items.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DeidentifyContentRequest} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.DeidentifyContentRequest) - com.google.privacy.dlp.v2beta1.DeidentifyContentRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyContentRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyContentRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DeidentifyContentRequest.class, com.google.privacy.dlp.v2beta1.DeidentifyContentRequest.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.DeidentifyContentRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getItemsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (deidentifyConfigBuilder_ == null) { - deidentifyConfig_ = null; - } else { - deidentifyConfig_ = null; - deidentifyConfigBuilder_ = null; - } - if (inspectConfigBuilder_ == null) { - inspectConfig_ = null; - } else { - inspectConfig_ = null; - inspectConfigBuilder_ = null; - } - if (itemsBuilder_ == null) { - items_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - } else { - itemsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyContentRequest_descriptor; - } - - public com.google.privacy.dlp.v2beta1.DeidentifyContentRequest getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.DeidentifyContentRequest.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.DeidentifyContentRequest build() { - com.google.privacy.dlp.v2beta1.DeidentifyContentRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.DeidentifyContentRequest buildPartial() { - com.google.privacy.dlp.v2beta1.DeidentifyContentRequest result = new com.google.privacy.dlp.v2beta1.DeidentifyContentRequest(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (deidentifyConfigBuilder_ == null) { - result.deidentifyConfig_ = deidentifyConfig_; - } else { - result.deidentifyConfig_ = deidentifyConfigBuilder_.build(); - } - if (inspectConfigBuilder_ == null) { - result.inspectConfig_ = inspectConfig_; - } else { - result.inspectConfig_ = inspectConfigBuilder_.build(); - } - if (itemsBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { - items_ = java.util.Collections.unmodifiableList(items_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.items_ = items_; - } else { - result.items_ = itemsBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.DeidentifyContentRequest) { - return mergeFrom((com.google.privacy.dlp.v2beta1.DeidentifyContentRequest)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.DeidentifyContentRequest other) { - if (other == com.google.privacy.dlp.v2beta1.DeidentifyContentRequest.getDefaultInstance()) return this; - if (other.hasDeidentifyConfig()) { - mergeDeidentifyConfig(other.getDeidentifyConfig()); - } - if (other.hasInspectConfig()) { - mergeInspectConfig(other.getInspectConfig()); - } - if (itemsBuilder_ == null) { - if (!other.items_.isEmpty()) { - if (items_.isEmpty()) { - items_ = other.items_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureItemsIsMutable(); - items_.addAll(other.items_); - } - onChanged(); - } - } else { - if (!other.items_.isEmpty()) { - if (itemsBuilder_.isEmpty()) { - itemsBuilder_.dispose(); - itemsBuilder_ = null; - items_ = other.items_; - bitField0_ = (bitField0_ & ~0x00000004); - itemsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getItemsFieldBuilder() : null; - } else { - itemsBuilder_.addAllMessages(other.items_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.DeidentifyContentRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.DeidentifyContentRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private com.google.privacy.dlp.v2beta1.DeidentifyConfig deidentifyConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DeidentifyConfig, com.google.privacy.dlp.v2beta1.DeidentifyConfig.Builder, com.google.privacy.dlp.v2beta1.DeidentifyConfigOrBuilder> deidentifyConfigBuilder_; - /** - *
-     * Configuration for the de-identification of the list of content items.
-     * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public boolean hasDeidentifyConfig() { - return deidentifyConfigBuilder_ != null || deidentifyConfig_ != null; - } - /** - *
-     * Configuration for the de-identification of the list of content items.
-     * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public com.google.privacy.dlp.v2beta1.DeidentifyConfig getDeidentifyConfig() { - if (deidentifyConfigBuilder_ == null) { - return deidentifyConfig_ == null ? com.google.privacy.dlp.v2beta1.DeidentifyConfig.getDefaultInstance() : deidentifyConfig_; - } else { - return deidentifyConfigBuilder_.getMessage(); - } - } - /** - *
-     * Configuration for the de-identification of the list of content items.
-     * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public Builder setDeidentifyConfig(com.google.privacy.dlp.v2beta1.DeidentifyConfig value) { - if (deidentifyConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - deidentifyConfig_ = value; - onChanged(); - } else { - deidentifyConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Configuration for the de-identification of the list of content items.
-     * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public Builder setDeidentifyConfig( - com.google.privacy.dlp.v2beta1.DeidentifyConfig.Builder builderForValue) { - if (deidentifyConfigBuilder_ == null) { - deidentifyConfig_ = builderForValue.build(); - onChanged(); - } else { - deidentifyConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Configuration for the de-identification of the list of content items.
-     * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public Builder mergeDeidentifyConfig(com.google.privacy.dlp.v2beta1.DeidentifyConfig value) { - if (deidentifyConfigBuilder_ == null) { - if (deidentifyConfig_ != null) { - deidentifyConfig_ = - com.google.privacy.dlp.v2beta1.DeidentifyConfig.newBuilder(deidentifyConfig_).mergeFrom(value).buildPartial(); - } else { - deidentifyConfig_ = value; - } - onChanged(); - } else { - deidentifyConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Configuration for the de-identification of the list of content items.
-     * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public Builder clearDeidentifyConfig() { - if (deidentifyConfigBuilder_ == null) { - deidentifyConfig_ = null; - onChanged(); - } else { - deidentifyConfig_ = null; - deidentifyConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * Configuration for the de-identification of the list of content items.
-     * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public com.google.privacy.dlp.v2beta1.DeidentifyConfig.Builder getDeidentifyConfigBuilder() { - - onChanged(); - return getDeidentifyConfigFieldBuilder().getBuilder(); - } - /** - *
-     * Configuration for the de-identification of the list of content items.
-     * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - public com.google.privacy.dlp.v2beta1.DeidentifyConfigOrBuilder getDeidentifyConfigOrBuilder() { - if (deidentifyConfigBuilder_ != null) { - return deidentifyConfigBuilder_.getMessageOrBuilder(); - } else { - return deidentifyConfig_ == null ? - com.google.privacy.dlp.v2beta1.DeidentifyConfig.getDefaultInstance() : deidentifyConfig_; - } - } - /** - *
-     * Configuration for the de-identification of the list of content items.
-     * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DeidentifyConfig, com.google.privacy.dlp.v2beta1.DeidentifyConfig.Builder, com.google.privacy.dlp.v2beta1.DeidentifyConfigOrBuilder> - getDeidentifyConfigFieldBuilder() { - if (deidentifyConfigBuilder_ == null) { - deidentifyConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DeidentifyConfig, com.google.privacy.dlp.v2beta1.DeidentifyConfig.Builder, com.google.privacy.dlp.v2beta1.DeidentifyConfigOrBuilder>( - getDeidentifyConfig(), - getParentForChildren(), - isClean()); - deidentifyConfig_ = null; - } - return deidentifyConfigBuilder_; - } - - private com.google.privacy.dlp.v2beta1.InspectConfig inspectConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder> inspectConfigBuilder_; - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public boolean hasInspectConfig() { - return inspectConfigBuilder_ != null || inspectConfig_ != null; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig() { - if (inspectConfigBuilder_ == null) { - return inspectConfig_ == null ? com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } else { - return inspectConfigBuilder_.getMessage(); - } - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public Builder setInspectConfig(com.google.privacy.dlp.v2beta1.InspectConfig value) { - if (inspectConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - inspectConfig_ = value; - onChanged(); - } else { - inspectConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public Builder setInspectConfig( - com.google.privacy.dlp.v2beta1.InspectConfig.Builder builderForValue) { - if (inspectConfigBuilder_ == null) { - inspectConfig_ = builderForValue.build(); - onChanged(); - } else { - inspectConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public Builder mergeInspectConfig(com.google.privacy.dlp.v2beta1.InspectConfig value) { - if (inspectConfigBuilder_ == null) { - if (inspectConfig_ != null) { - inspectConfig_ = - com.google.privacy.dlp.v2beta1.InspectConfig.newBuilder(inspectConfig_).mergeFrom(value).buildPartial(); - } else { - inspectConfig_ = value; - } - onChanged(); - } else { - inspectConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public Builder clearInspectConfig() { - if (inspectConfigBuilder_ == null) { - inspectConfig_ = null; - onChanged(); - } else { - inspectConfig_ = null; - inspectConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.Builder getInspectConfigBuilder() { - - onChanged(); - return getInspectConfigFieldBuilder().getBuilder(); - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - public com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder() { - if (inspectConfigBuilder_ != null) { - return inspectConfigBuilder_.getMessageOrBuilder(); - } else { - return inspectConfig_ == null ? - com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder> - getInspectConfigFieldBuilder() { - if (inspectConfigBuilder_ == null) { - inspectConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder>( - getInspectConfig(), - getParentForChildren(), - isClean()); - inspectConfig_ = null; - } - return inspectConfigBuilder_; - } - - private java.util.List items_ = - java.util.Collections.emptyList(); - private void ensureItemsIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { - items_ = new java.util.ArrayList(items_); - bitField0_ |= 0x00000004; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder> itemsBuilder_; - - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public java.util.List getItemsList() { - if (itemsBuilder_ == null) { - return java.util.Collections.unmodifiableList(items_); - } else { - return itemsBuilder_.getMessageList(); - } - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public int getItemsCount() { - if (itemsBuilder_ == null) { - return items_.size(); - } else { - return itemsBuilder_.getCount(); - } - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public com.google.privacy.dlp.v2beta1.ContentItem getItems(int index) { - if (itemsBuilder_ == null) { - return items_.get(index); - } else { - return itemsBuilder_.getMessage(index); - } - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public Builder setItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.set(index, value); - onChanged(); - } else { - itemsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public Builder setItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.set(index, builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public Builder addItems(com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.add(value); - onChanged(); - } else { - itemsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public Builder addItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.add(index, value); - onChanged(); - } else { - itemsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public Builder addItems( - com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.add(builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public Builder addItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.add(index, builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public Builder addAllItems( - java.lang.Iterable values) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, items_); - onChanged(); - } else { - itemsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public Builder clearItems() { - if (itemsBuilder_ == null) { - items_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - } else { - itemsBuilder_.clear(); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public Builder removeItems(int index) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.remove(index); - onChanged(); - } else { - itemsBuilder_.remove(index); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder getItemsBuilder( - int index) { - return getItemsFieldBuilder().getBuilder(index); - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index) { - if (itemsBuilder_ == null) { - return items_.get(index); } else { - return itemsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public java.util.List - getItemsOrBuilderList() { - if (itemsBuilder_ != null) { - return itemsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(items_); - } - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder addItemsBuilder() { - return getItemsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()); - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder addItemsBuilder( - int index) { - return getItemsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()); - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * All items will be treated as text/*.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - public java.util.List - getItemsBuilderList() { - return getItemsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder> - getItemsFieldBuilder() { - if (itemsBuilder_ == null) { - itemsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder>( - items_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); - items_ = null; - } - return itemsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.DeidentifyContentRequest) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.DeidentifyContentRequest) - private static final com.google.privacy.dlp.v2beta1.DeidentifyContentRequest DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.DeidentifyContentRequest(); - } - - public static com.google.privacy.dlp.v2beta1.DeidentifyContentRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public DeidentifyContentRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DeidentifyContentRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.DeidentifyContentRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentRequestOrBuilder.java deleted file mode 100644 index 55975f91e079..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentRequestOrBuilder.java +++ /dev/null @@ -1,108 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface DeidentifyContentRequestOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.DeidentifyContentRequest) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Configuration for the de-identification of the list of content items.
-   * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - boolean hasDeidentifyConfig(); - /** - *
-   * Configuration for the de-identification of the list of content items.
-   * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - com.google.privacy.dlp.v2beta1.DeidentifyConfig getDeidentifyConfig(); - /** - *
-   * Configuration for the de-identification of the list of content items.
-   * 
- * - * .google.privacy.dlp.v2beta1.DeidentifyConfig deidentify_config = 1; - */ - com.google.privacy.dlp.v2beta1.DeidentifyConfigOrBuilder getDeidentifyConfigOrBuilder(); - - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - boolean hasInspectConfig(); - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig(); - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 2; - */ - com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder(); - - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * All items will be treated as text/*.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - java.util.List - getItemsList(); - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * All items will be treated as text/*.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - com.google.privacy.dlp.v2beta1.ContentItem getItems(int index); - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * All items will be treated as text/*.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - int getItemsCount(); - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * All items will be treated as text/*.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - java.util.List - getItemsOrBuilderList(); - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * All items will be treated as text/*.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 3; - */ - com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentResponse.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentResponse.java deleted file mode 100644 index dc7333862a27..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentResponse.java +++ /dev/null @@ -1,1177 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Results of de-identifying a list of items.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DeidentifyContentResponse} - */ -public final class DeidentifyContentResponse extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.DeidentifyContentResponse) - DeidentifyContentResponseOrBuilder { -private static final long serialVersionUID = 0L; - // Use DeidentifyContentResponse.newBuilder() to construct. - private DeidentifyContentResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private DeidentifyContentResponse() { - items_ = java.util.Collections.emptyList(); - summaries_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private DeidentifyContentResponse( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - items_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - items_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.ContentItem.parser(), extensionRegistry)); - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - summaries_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - summaries_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.DeidentificationSummary.parser(), extensionRegistry)); - 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) == 0x00000001)) { - items_ = java.util.Collections.unmodifiableList(items_); - } - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - summaries_ = java.util.Collections.unmodifiableList(summaries_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyContentResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyContentResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DeidentifyContentResponse.class, com.google.privacy.dlp.v2beta1.DeidentifyContentResponse.Builder.class); - } - - public static final int ITEMS_FIELD_NUMBER = 1; - private java.util.List items_; - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public java.util.List getItemsList() { - return items_; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public java.util.List - getItemsOrBuilderList() { - return items_; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public int getItemsCount() { - return items_.size(); - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItem getItems(int index) { - return items_.get(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index) { - return items_.get(index); - } - - public static final int SUMMARIES_FIELD_NUMBER = 2; - private java.util.List summaries_; - /** - *
-   * A review of the transformations that took place for each item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public java.util.List getSummariesList() { - return summaries_; - } - /** - *
-   * A review of the transformations that took place for each item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public java.util.List - getSummariesOrBuilderList() { - return summaries_; - } - /** - *
-   * A review of the transformations that took place for each item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public int getSummariesCount() { - return summaries_.size(); - } - /** - *
-   * A review of the transformations that took place for each item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public com.google.privacy.dlp.v2beta1.DeidentificationSummary getSummaries(int index) { - return summaries_.get(index); - } - /** - *
-   * A review of the transformations that took place for each item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public com.google.privacy.dlp.v2beta1.DeidentificationSummaryOrBuilder getSummariesOrBuilder( - int index) { - return summaries_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < items_.size(); i++) { - output.writeMessage(1, items_.get(i)); - } - for (int i = 0; i < summaries_.size(); i++) { - output.writeMessage(2, summaries_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < items_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, items_.get(i)); - } - for (int i = 0; i < summaries_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, summaries_.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.privacy.dlp.v2beta1.DeidentifyContentResponse)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.DeidentifyContentResponse other = (com.google.privacy.dlp.v2beta1.DeidentifyContentResponse) obj; - - boolean result = true; - result = result && getItemsList() - .equals(other.getItemsList()); - result = result && getSummariesList() - .equals(other.getSummariesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getItemsCount() > 0) { - hash = (37 * hash) + ITEMS_FIELD_NUMBER; - hash = (53 * hash) + getItemsList().hashCode(); - } - if (getSummariesCount() > 0) { - hash = (37 * hash) + SUMMARIES_FIELD_NUMBER; - hash = (53 * hash) + getSummariesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.DeidentifyContentResponse parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentResponse 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.privacy.dlp.v2beta1.DeidentifyContentResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentResponse 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.privacy.dlp.v2beta1.DeidentifyContentResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentResponse 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.privacy.dlp.v2beta1.DeidentifyContentResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.DeidentifyContentResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.DeidentifyContentResponse prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Results of de-identifying a list of items.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.DeidentifyContentResponse} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.DeidentifyContentResponse) - com.google.privacy.dlp.v2beta1.DeidentifyContentResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyContentResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyContentResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.DeidentifyContentResponse.class, com.google.privacy.dlp.v2beta1.DeidentifyContentResponse.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.DeidentifyContentResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getItemsFieldBuilder(); - getSummariesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (itemsBuilder_ == null) { - items_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - itemsBuilder_.clear(); - } - if (summariesBuilder_ == null) { - summaries_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - summariesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_DeidentifyContentResponse_descriptor; - } - - public com.google.privacy.dlp.v2beta1.DeidentifyContentResponse getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.DeidentifyContentResponse.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.DeidentifyContentResponse build() { - com.google.privacy.dlp.v2beta1.DeidentifyContentResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.DeidentifyContentResponse buildPartial() { - com.google.privacy.dlp.v2beta1.DeidentifyContentResponse result = new com.google.privacy.dlp.v2beta1.DeidentifyContentResponse(this); - int from_bitField0_ = bitField0_; - if (itemsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - items_ = java.util.Collections.unmodifiableList(items_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.items_ = items_; - } else { - result.items_ = itemsBuilder_.build(); - } - if (summariesBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - summaries_ = java.util.Collections.unmodifiableList(summaries_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.summaries_ = summaries_; - } else { - result.summaries_ = summariesBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.DeidentifyContentResponse) { - return mergeFrom((com.google.privacy.dlp.v2beta1.DeidentifyContentResponse)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.DeidentifyContentResponse other) { - if (other == com.google.privacy.dlp.v2beta1.DeidentifyContentResponse.getDefaultInstance()) return this; - if (itemsBuilder_ == null) { - if (!other.items_.isEmpty()) { - if (items_.isEmpty()) { - items_ = other.items_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureItemsIsMutable(); - items_.addAll(other.items_); - } - onChanged(); - } - } else { - if (!other.items_.isEmpty()) { - if (itemsBuilder_.isEmpty()) { - itemsBuilder_.dispose(); - itemsBuilder_ = null; - items_ = other.items_; - bitField0_ = (bitField0_ & ~0x00000001); - itemsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getItemsFieldBuilder() : null; - } else { - itemsBuilder_.addAllMessages(other.items_); - } - } - } - if (summariesBuilder_ == null) { - if (!other.summaries_.isEmpty()) { - if (summaries_.isEmpty()) { - summaries_ = other.summaries_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureSummariesIsMutable(); - summaries_.addAll(other.summaries_); - } - onChanged(); - } - } else { - if (!other.summaries_.isEmpty()) { - if (summariesBuilder_.isEmpty()) { - summariesBuilder_.dispose(); - summariesBuilder_ = null; - summaries_ = other.summaries_; - bitField0_ = (bitField0_ & ~0x00000002); - summariesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getSummariesFieldBuilder() : null; - } else { - summariesBuilder_.addAllMessages(other.summaries_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.DeidentifyContentResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.DeidentifyContentResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List items_ = - java.util.Collections.emptyList(); - private void ensureItemsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - items_ = new java.util.ArrayList(items_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder> itemsBuilder_; - - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public java.util.List getItemsList() { - if (itemsBuilder_ == null) { - return java.util.Collections.unmodifiableList(items_); - } else { - return itemsBuilder_.getMessageList(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public int getItemsCount() { - if (itemsBuilder_ == null) { - return items_.size(); - } else { - return itemsBuilder_.getCount(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItem getItems(int index) { - if (itemsBuilder_ == null) { - return items_.get(index); - } else { - return itemsBuilder_.getMessage(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder setItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.set(index, value); - onChanged(); - } else { - itemsBuilder_.setMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder setItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.set(index, builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder addItems(com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.add(value); - onChanged(); - } else { - itemsBuilder_.addMessage(value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder addItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.add(index, value); - onChanged(); - } else { - itemsBuilder_.addMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder addItems( - com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.add(builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder addItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.add(index, builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder addAllItems( - java.lang.Iterable values) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, items_); - onChanged(); - } else { - itemsBuilder_.addAllMessages(values); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder clearItems() { - if (itemsBuilder_ == null) { - items_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - itemsBuilder_.clear(); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder removeItems(int index) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.remove(index); - onChanged(); - } else { - itemsBuilder_.remove(index); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder getItemsBuilder( - int index) { - return getItemsFieldBuilder().getBuilder(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index) { - if (itemsBuilder_ == null) { - return items_.get(index); } else { - return itemsBuilder_.getMessageOrBuilder(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public java.util.List - getItemsOrBuilderList() { - if (itemsBuilder_ != null) { - return itemsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(items_); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder addItemsBuilder() { - return getItemsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder addItemsBuilder( - int index) { - return getItemsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public java.util.List - getItemsBuilderList() { - return getItemsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder> - getItemsFieldBuilder() { - if (itemsBuilder_ == null) { - itemsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder>( - items_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - items_ = null; - } - return itemsBuilder_; - } - - private java.util.List summaries_ = - java.util.Collections.emptyList(); - private void ensureSummariesIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - summaries_ = new java.util.ArrayList(summaries_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DeidentificationSummary, com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder, com.google.privacy.dlp.v2beta1.DeidentificationSummaryOrBuilder> summariesBuilder_; - - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public java.util.List getSummariesList() { - if (summariesBuilder_ == null) { - return java.util.Collections.unmodifiableList(summaries_); - } else { - return summariesBuilder_.getMessageList(); - } - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public int getSummariesCount() { - if (summariesBuilder_ == null) { - return summaries_.size(); - } else { - return summariesBuilder_.getCount(); - } - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public com.google.privacy.dlp.v2beta1.DeidentificationSummary getSummaries(int index) { - if (summariesBuilder_ == null) { - return summaries_.get(index); - } else { - return summariesBuilder_.getMessage(index); - } - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public Builder setSummaries( - int index, com.google.privacy.dlp.v2beta1.DeidentificationSummary value) { - if (summariesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSummariesIsMutable(); - summaries_.set(index, value); - onChanged(); - } else { - summariesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public Builder setSummaries( - int index, com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder builderForValue) { - if (summariesBuilder_ == null) { - ensureSummariesIsMutable(); - summaries_.set(index, builderForValue.build()); - onChanged(); - } else { - summariesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public Builder addSummaries(com.google.privacy.dlp.v2beta1.DeidentificationSummary value) { - if (summariesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSummariesIsMutable(); - summaries_.add(value); - onChanged(); - } else { - summariesBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public Builder addSummaries( - int index, com.google.privacy.dlp.v2beta1.DeidentificationSummary value) { - if (summariesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSummariesIsMutable(); - summaries_.add(index, value); - onChanged(); - } else { - summariesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public Builder addSummaries( - com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder builderForValue) { - if (summariesBuilder_ == null) { - ensureSummariesIsMutable(); - summaries_.add(builderForValue.build()); - onChanged(); - } else { - summariesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public Builder addSummaries( - int index, com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder builderForValue) { - if (summariesBuilder_ == null) { - ensureSummariesIsMutable(); - summaries_.add(index, builderForValue.build()); - onChanged(); - } else { - summariesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public Builder addAllSummaries( - java.lang.Iterable values) { - if (summariesBuilder_ == null) { - ensureSummariesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, summaries_); - onChanged(); - } else { - summariesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public Builder clearSummaries() { - if (summariesBuilder_ == null) { - summaries_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - summariesBuilder_.clear(); - } - return this; - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public Builder removeSummaries(int index) { - if (summariesBuilder_ == null) { - ensureSummariesIsMutable(); - summaries_.remove(index); - onChanged(); - } else { - summariesBuilder_.remove(index); - } - return this; - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder getSummariesBuilder( - int index) { - return getSummariesFieldBuilder().getBuilder(index); - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public com.google.privacy.dlp.v2beta1.DeidentificationSummaryOrBuilder getSummariesOrBuilder( - int index) { - if (summariesBuilder_ == null) { - return summaries_.get(index); } else { - return summariesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public java.util.List - getSummariesOrBuilderList() { - if (summariesBuilder_ != null) { - return summariesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(summaries_); - } - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder addSummariesBuilder() { - return getSummariesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.DeidentificationSummary.getDefaultInstance()); - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder addSummariesBuilder( - int index) { - return getSummariesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.DeidentificationSummary.getDefaultInstance()); - } - /** - *
-     * A review of the transformations that took place for each item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - public java.util.List - getSummariesBuilderList() { - return getSummariesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DeidentificationSummary, com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder, com.google.privacy.dlp.v2beta1.DeidentificationSummaryOrBuilder> - getSummariesFieldBuilder() { - if (summariesBuilder_ == null) { - summariesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DeidentificationSummary, com.google.privacy.dlp.v2beta1.DeidentificationSummary.Builder, com.google.privacy.dlp.v2beta1.DeidentificationSummaryOrBuilder>( - summaries_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - summaries_ = null; - } - return summariesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.DeidentifyContentResponse) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.DeidentifyContentResponse) - private static final com.google.privacy.dlp.v2beta1.DeidentifyContentResponse DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.DeidentifyContentResponse(); - } - - public static com.google.privacy.dlp.v2beta1.DeidentifyContentResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public DeidentifyContentResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new DeidentifyContentResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.DeidentifyContentResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentResponseOrBuilder.java deleted file mode 100644 index a73d8565f0d0..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DeidentifyContentResponseOrBuilder.java +++ /dev/null @@ -1,77 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface DeidentifyContentResponseOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.DeidentifyContentResponse) - com.google.protobuf.MessageOrBuilder { - - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - java.util.List - getItemsList(); - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - com.google.privacy.dlp.v2beta1.ContentItem getItems(int index); - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - int getItemsCount(); - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - java.util.List - getItemsOrBuilderList(); - /** - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index); - - /** - *
-   * A review of the transformations that took place for each item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - java.util.List - getSummariesList(); - /** - *
-   * A review of the transformations that took place for each item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - com.google.privacy.dlp.v2beta1.DeidentificationSummary getSummaries(int index); - /** - *
-   * A review of the transformations that took place for each item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - int getSummariesCount(); - /** - *
-   * A review of the transformations that took place for each item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - java.util.List - getSummariesOrBuilderList(); - /** - *
-   * A review of the transformations that took place for each item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.DeidentificationSummary summaries = 2; - */ - com.google.privacy.dlp.v2beta1.DeidentificationSummaryOrBuilder getSummariesOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DlpProto.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DlpProto.java deleted file mode 100644 index e8fc2226353b..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DlpProto.java +++ /dev/null @@ -1,1370 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public final class DlpProto { - private DlpProto() {} - 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_privacy_dlp_v2beta1_InspectConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InspectConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_InspectConfig_InfoTypeLimit_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InspectConfig_InfoTypeLimit_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_OperationConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_OperationConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ContentItem_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ContentItem_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_Table_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_Table_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_Table_Row_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_Table_Row_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_InspectResult_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InspectResult_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_Finding_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_Finding_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_Location_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_Location_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_TableLocation_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_TableLocation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_Range_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_Range_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ImageLocation_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ImageLocation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ReplaceConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ReplaceConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ImageRedactionConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ImageRedactionConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_Color_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_Color_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RedactContentResponse_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RedactContentResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_DeidentifyContentRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_DeidentifyContentRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_DeidentifyContentResponse_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_DeidentifyContentResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_InspectContentRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InspectContentRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_InspectContentResponse_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InspectContentResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CreateInspectOperationRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CreateInspectOperationRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_OutputStorageConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_OutputStorageConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_InfoTypeStatistics_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InfoTypeStatistics_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_InspectOperationMetadata_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InspectOperationMetadata_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_InspectOperationResult_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InspectOperationResult_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsResponse_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_InfoTypeDescription_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InfoTypeDescription_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ListInfoTypesRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ListInfoTypesRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ListInfoTypesResponse_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ListInfoTypesResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CategoryDescription_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CategoryDescription_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesResponse_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_AnalyzeDataSourceRiskRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_AnalyzeDataSourceRiskRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationMetadata_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationMetadata_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_NumericalStatsResult_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_NumericalStatsResult_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_CategoricalStatsHistogramBucket_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_CategoricalStatsHistogramBucket_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityEquivalenceClass_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityEquivalenceClass_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityHistogramBucket_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityHistogramBucket_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityEquivalenceClass_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityEquivalenceClass_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityHistogramBucket_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityHistogramBucket_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ValueFrequency_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ValueFrequency_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_Value_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_Value_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_DeidentifyConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_DeidentifyConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_PrimitiveTransformation_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_PrimitiveTransformation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_TimePartConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_TimePartConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CryptoHashConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CryptoHashConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ReplaceValueConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ReplaceValueConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_ReplaceWithInfoTypeConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_ReplaceWithInfoTypeConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RedactConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RedactConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CharsToIgnore_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CharsToIgnore_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CharacterMaskConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CharacterMaskConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_FixedSizeBucketingConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_FixedSizeBucketingConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_Bucket_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_Bucket_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CryptoReplaceFfxFpeConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CryptoReplaceFfxFpeConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CryptoKey_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CryptoKey_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_TransientCryptoKey_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_TransientCryptoKey_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_UnwrappedCryptoKey_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_UnwrappedCryptoKey_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_KmsWrappedCryptoKey_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_KmsWrappedCryptoKey_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_InfoTypeTransformation_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_InfoTypeTransformation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_FieldTransformation_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_FieldTransformation_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RecordTransformations_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RecordTransformations_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RecordSuppression_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RecordSuppression_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RecordCondition_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RecordCondition_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Condition_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Condition_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Conditions_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Conditions_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Expressions_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Expressions_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_DeidentificationSummary_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_DeidentificationSummary_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_SummaryResult_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_SummaryResult_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/privacy/dlp/v2beta1/dlp.proto\022\032" + - "google.privacy.dlp.v2beta1\032\034google/api/a" + - "nnotations.proto\032#google/longrunning/ope" + - "rations.proto\032(google/privacy/dlp/v2beta" + - "1/storage.proto\032\033google/protobuf/empty.p" + - "roto\032\037google/protobuf/timestamp.proto\032\026g" + - "oogle/type/date.proto\032\033google/type/timeo" + - "fday.proto\"\307\003\n\rInspectConfig\0228\n\ninfo_typ" + - "es\030\001 \003(\0132$.google.privacy.dlp.v2beta1.In" + - "foType\022>\n\016min_likelihood\030\002 \001(\0162&.google." + - "privacy.dlp.v2beta1.Likelihood\022\024\n\014max_fi" + - "ndings\030\003 \001(\005\022\025\n\rinclude_quote\030\004 \001(\010\022\025\n\re" + - "xclude_types\030\006 \001(\010\022Q\n\020info_type_limits\030\007" + - " \003(\01327.google.privacy.dlp.v2beta1.Inspec" + - "tConfig.InfoTypeLimit\022E\n\021custom_info_typ" + - "es\030\010 \003(\0132*.google.privacy.dlp.v2beta1.Cu" + - "stomInfoType\032^\n\rInfoTypeLimit\0227\n\tinfo_ty" + - "pe\030\001 \001(\0132$.google.privacy.dlp.v2beta1.In" + - "foType\022\024\n\014max_findings\030\002 \001(\005\",\n\017Operatio" + - "nConfig\022\031\n\021max_item_findings\030\001 \001(\003\"}\n\013Co" + - "ntentItem\022\014\n\004type\030\001 \001(\t\022\016\n\004data\030\002 \001(\014H\000\022" + - "\017\n\005value\030\003 \001(\tH\000\0222\n\005table\030\004 \001(\0132!.google" + - ".privacy.dlp.v2beta1.TableH\000B\013\n\tdata_ite" + - "m\"\254\001\n\005Table\0224\n\007headers\030\001 \003(\0132#.google.pr" + - "ivacy.dlp.v2beta1.FieldId\0223\n\004rows\030\002 \003(\0132" + - "%.google.privacy.dlp.v2beta1.Table.Row\0328" + - "\n\003Row\0221\n\006values\030\001 \003(\0132!.google.privacy.d" + - "lp.v2beta1.Value\"b\n\rInspectResult\0225\n\010fin" + - "dings\030\001 \003(\0132#.google.privacy.dlp.v2beta1" + - ".Finding\022\032\n\022findings_truncated\030\002 \001(\010\"\366\001\n" + - "\007Finding\022\r\n\005quote\030\001 \001(\t\0227\n\tinfo_type\030\002 \001" + - "(\0132$.google.privacy.dlp.v2beta1.InfoType" + - "\022:\n\nlikelihood\030\003 \001(\0162&.google.privacy.dl" + - "p.v2beta1.Likelihood\0226\n\010location\030\004 \001(\0132$" + - ".google.privacy.dlp.v2beta1.Location\022/\n\013" + - "create_time\030\006 \001(\0132\032.google.protobuf.Time" + - "stamp\"\362\002\n\010Location\0225\n\nbyte_range\030\001 \001(\0132!" + - ".google.privacy.dlp.v2beta1.Range\022:\n\017cod" + - "epoint_range\030\002 \001(\0132!.google.privacy.dlp." + - "v2beta1.Range\022>\n\013image_boxes\030\003 \003(\0132).goo" + - "gle.privacy.dlp.v2beta1.ImageLocation\0229\n" + - "\nrecord_key\030\004 \001(\0132%.google.privacy.dlp.v" + - "2beta1.RecordKey\0225\n\010field_id\030\005 \001(\0132#.goo" + - "gle.privacy.dlp.v2beta1.FieldId\022A\n\016table" + - "_location\030\006 \001(\0132).google.privacy.dlp.v2b" + - "eta1.TableLocation\"\"\n\rTableLocation\022\021\n\tr" + - "ow_index\030\001 \001(\003\"#\n\005Range\022\r\n\005start\030\001 \001(\003\022\013" + - "\n\003end\030\002 \001(\003\"I\n\rImageLocation\022\013\n\003top\030\001 \001(" + - "\005\022\014\n\004left\030\002 \001(\005\022\r\n\005width\030\003 \001(\005\022\016\n\006height" + - "\030\004 \001(\005\"\347\004\n\024RedactContentRequest\022A\n\016inspe" + - "ct_config\030\001 \001(\0132).google.privacy.dlp.v2b" + - "eta1.InspectConfig\0226\n\005items\030\002 \003(\0132\'.goog" + - "le.privacy.dlp.v2beta1.ContentItem\022W\n\017re" + - "place_configs\030\003 \003(\0132>.google.privacy.dlp" + - ".v2beta1.RedactContentRequest.ReplaceCon" + - "fig\022f\n\027image_redaction_configs\030\004 \003(\0132E.g" + - "oogle.privacy.dlp.v2beta1.RedactContentR" + - "equest.ImageRedactionConfig\032^\n\rReplaceCo" + - "nfig\0227\n\tinfo_type\030\001 \001(\0132$.google.privacy" + - ".dlp.v2beta1.InfoType\022\024\n\014replace_with\030\002 " + - "\001(\t\032\262\001\n\024ImageRedactionConfig\0229\n\tinfo_typ" + - "e\030\001 \001(\0132$.google.privacy.dlp.v2beta1.Inf" + - "oTypeH\000\022\031\n\017redact_all_text\030\002 \001(\010H\000\022:\n\017re" + - "daction_color\030\003 \001(\0132!.google.privacy.dlp" + - ".v2beta1.ColorB\010\n\006target\"1\n\005Color\022\013\n\003red" + - "\030\001 \001(\002\022\r\n\005green\030\002 \001(\002\022\014\n\004blue\030\003 \001(\002\"O\n\025R" + - "edactContentResponse\0226\n\005items\030\001 \003(\0132\'.go" + - "ogle.privacy.dlp.v2beta1.ContentItem\"\336\001\n" + - "\030DeidentifyContentRequest\022G\n\021deidentify_" + - "config\030\001 \001(\0132,.google.privacy.dlp.v2beta" + - "1.DeidentifyConfig\022A\n\016inspect_config\030\002 \001" + - "(\0132).google.privacy.dlp.v2beta1.InspectC" + - "onfig\0226\n\005items\030\003 \003(\0132\'.google.privacy.dl" + - "p.v2beta1.ContentItem\"\233\001\n\031DeidentifyCont" + - "entResponse\0226\n\005items\030\001 \003(\0132\'.google.priv" + - "acy.dlp.v2beta1.ContentItem\022F\n\tsummaries" + - "\030\002 \003(\01323.google.privacy.dlp.v2beta1.Deid" + - "entificationSummary\"\222\001\n\025InspectContentRe" + - "quest\022A\n\016inspect_config\030\001 \001(\0132).google.p" + - "rivacy.dlp.v2beta1.InspectConfig\0226\n\005item" + - "s\030\002 \003(\0132\'.google.privacy.dlp.v2beta1.Con" + - "tentItem\"T\n\026InspectContentResponse\022:\n\007re" + - "sults\030\001 \003(\0132).google.privacy.dlp.v2beta1" + - ".InspectResult\"\264\002\n\035CreateInspectOperatio" + - "nRequest\022A\n\016inspect_config\030\001 \001(\0132).googl" + - "e.privacy.dlp.v2beta1.InspectConfig\022A\n\016s" + - "torage_config\030\002 \001(\0132).google.privacy.dlp" + - ".v2beta1.StorageConfig\022F\n\routput_config\030" + - "\003 \001(\0132/.google.privacy.dlp.v2beta1.Outpu" + - "tStorageConfig\022E\n\020operation_config\030\005 \001(\013" + - "2+.google.privacy.dlp.v2beta1.OperationC" + - "onfig\"\237\001\n\023OutputStorageConfig\022:\n\005table\030\001" + - " \001(\0132).google.privacy.dlp.v2beta1.BigQue" + - "ryTableH\000\022D\n\014storage_path\030\002 \001(\0132,.google" + - ".privacy.dlp.v2beta1.CloudStoragePathH\000B" + - "\006\n\004type\"\\\n\022InfoTypeStatistics\0227\n\tinfo_ty" + - "pe\030\001 \001(\0132$.google.privacy.dlp.v2beta1.In" + - "foType\022\r\n\005count\030\002 \001(\003\"\262\003\n\030InspectOperati" + - "onMetadata\022\027\n\017processed_bytes\030\001 \001(\003\022\035\n\025t" + - "otal_estimated_bytes\030\004 \001(\003\022G\n\017info_type_" + - "stats\030\002 \003(\0132..google.privacy.dlp.v2beta1" + - ".InfoTypeStatistics\022/\n\013create_time\030\003 \001(\013" + - "2\032.google.protobuf.Timestamp\022I\n\026request_" + - "inspect_config\030\005 \001(\0132).google.privacy.dl" + - "p.v2beta1.InspectConfig\022I\n\026request_stora" + - "ge_config\030\006 \001(\0132).google.privacy.dlp.v2b" + - "eta1.StorageConfig\022N\n\025request_output_con" + - "fig\030\007 \001(\0132/.google.privacy.dlp.v2beta1.O" + - "utputStorageConfig\"&\n\026InspectOperationRe" + - "sult\022\014\n\004name\030\001 \001(\t\"a\n\032ListInspectFinding" + - "sRequest\022\014\n\004name\030\001 \001(\t\022\021\n\tpage_size\030\002 \001(" + - "\005\022\022\n\npage_token\030\003 \001(\t\022\016\n\006filter\030\004 \001(\t\"q\n" + - "\033ListInspectFindingsResponse\0229\n\006result\030\001" + - " \001(\0132).google.privacy.dlp.v2beta1.Inspec" + - "tResult\022\027\n\017next_page_token\030\002 \001(\t\"~\n\023Info" + - "TypeDescription\022\014\n\004name\030\001 \001(\t\022\024\n\014display" + - "_name\030\002 \001(\t\022C\n\ncategories\030\003 \003(\0132/.google" + - ".privacy.dlp.v2beta1.CategoryDescription" + - "\"?\n\024ListInfoTypesRequest\022\020\n\010category\030\001 \001" + - "(\t\022\025\n\rlanguage_code\030\002 \001(\t\"\\\n\025ListInfoTyp" + - "esResponse\022C\n\ninfo_types\030\001 \003(\0132/.google." + - "privacy.dlp.v2beta1.InfoTypeDescription\"" + - "9\n\023CategoryDescription\022\014\n\004name\030\001 \001(\t\022\024\n\014" + - "display_name\030\002 \001(\t\"2\n\031ListRootCategories" + - "Request\022\025\n\rlanguage_code\030\001 \001(\t\"a\n\032ListRo" + - "otCategoriesResponse\022C\n\ncategories\030\001 \003(\013" + - "2/.google.privacy.dlp.v2beta1.CategoryDe" + - "scription\"\242\001\n\034AnalyzeDataSourceRiskReque" + - "st\022A\n\016privacy_metric\030\001 \001(\0132).google.priv" + - "acy.dlp.v2beta1.PrivacyMetric\022?\n\014source_" + - "table\030\003 \001(\0132).google.privacy.dlp.v2beta1" + - ".BigQueryTable\"\302\006\n\rPrivacyMetric\022`\n\026nume" + - "rical_stats_config\030\001 \001(\0132>.google.privac" + - "y.dlp.v2beta1.PrivacyMetric.NumericalSta" + - "tsConfigH\000\022d\n\030categorical_stats_config\030\002" + - " \001(\0132@.google.privacy.dlp.v2beta1.Privac" + - "yMetric.CategoricalStatsConfigH\000\022X\n\022k_an" + - "onymity_config\030\003 \001(\0132:.google.privacy.dl" + - "p.v2beta1.PrivacyMetric.KAnonymityConfig" + - "H\000\022X\n\022l_diversity_config\030\004 \001(\0132:.google." + - "privacy.dlp.v2beta1.PrivacyMetric.LDiver" + - "sityConfigH\000\032J\n\024NumericalStatsConfig\0222\n\005" + - "field\030\001 \001(\0132#.google.privacy.dlp.v2beta1" + - ".FieldId\032L\n\026CategoricalStatsConfig\0222\n\005fi" + - "eld\030\001 \001(\0132#.google.privacy.dlp.v2beta1.F" + - "ieldId\032\203\001\n\020KAnonymityConfig\0226\n\tquasi_ids" + - "\030\001 \003(\0132#.google.privacy.dlp.v2beta1.Fiel" + - "dId\0227\n\tentity_id\030\002 \001(\0132$.google.privacy." + - "dlp.v2beta1.EntityId\032\214\001\n\020LDiversityConfi" + - "g\0226\n\tquasi_ids\030\001 \003(\0132#.google.privacy.dl" + - "p.v2beta1.FieldId\022@\n\023sensitive_attribute" + - "\030\002 \001(\0132#.google.privacy.dlp.v2beta1.Fiel" + - "dIdB\006\n\004type\"\350\001\n\035RiskAnalysisOperationMet" + - "adata\022/\n\013create_time\030\001 \001(\0132\032.google.prot" + - "obuf.Timestamp\022K\n\030requested_privacy_metr" + - "ic\030\002 \001(\0132).google.privacy.dlp.v2beta1.Pr" + - "ivacyMetric\022I\n\026requested_source_table\030\003 " + - "\001(\0132).google.privacy.dlp.v2beta1.BigQuer" + - "yTable\"\353\021\n\033RiskAnalysisOperationResult\022n" + - "\n\026numerical_stats_result\030\003 \001(\0132L.google." + - "privacy.dlp.v2beta1.RiskAnalysisOperatio" + - "nResult.NumericalStatsResultH\000\022r\n\030catego" + - "rical_stats_result\030\004 \001(\0132N.google.privac" + - "y.dlp.v2beta1.RiskAnalysisOperationResul" + - "t.CategoricalStatsResultH\000\022f\n\022k_anonymit" + - "y_result\030\005 \001(\0132H.google.privacy.dlp.v2be" + - "ta1.RiskAnalysisOperationResult.KAnonymi" + - "tyResultH\000\022f\n\022l_diversity_result\030\006 \001(\0132H" + - ".google.privacy.dlp.v2beta1.RiskAnalysis" + - "OperationResult.LDiversityResultH\000\032\276\001\n\024N" + - "umericalStatsResult\0224\n\tmin_value\030\001 \001(\0132!" + - ".google.privacy.dlp.v2beta1.Value\0224\n\tmax" + - "_value\030\002 \001(\0132!.google.privacy.dlp.v2beta" + - "1.Value\022:\n\017quantile_values\030\004 \003(\0132!.googl" + - "e.privacy.dlp.v2beta1.Value\032\372\002\n\026Categori" + - "calStatsResult\022\231\001\n!value_frequency_histo" + - "gram_buckets\030\005 \003(\0132n.google.privacy.dlp." + - "v2beta1.RiskAnalysisOperationResult.Cate" + - "goricalStatsResult.CategoricalStatsHisto" + - "gramBucket\032\303\001\n\037CategoricalStatsHistogram" + - "Bucket\022#\n\033value_frequency_lower_bound\030\001 " + - "\001(\003\022#\n\033value_frequency_upper_bound\030\002 \001(\003" + - "\022\023\n\013bucket_size\030\003 \001(\003\022A\n\rbucket_values\030\004" + - " \003(\0132*.google.privacy.dlp.v2beta1.ValueF" + - "requency\032\246\004\n\020KAnonymityResult\022\217\001\n#equiva" + - "lence_class_histogram_buckets\030\005 \003(\0132b.go" + - "ogle.privacy.dlp.v2beta1.RiskAnalysisOpe" + - "rationResult.KAnonymityResult.KAnonymity" + - "HistogramBucket\032y\n\032KAnonymityEquivalence" + - "Class\022;\n\020quasi_ids_values\030\001 \003(\0132!.google" + - ".privacy.dlp.v2beta1.Value\022\036\n\026equivalenc" + - "e_class_size\030\002 \001(\003\032\204\002\n\031KAnonymityHistogr" + - "amBucket\022*\n\"equivalence_class_size_lower" + - "_bound\030\001 \001(\003\022*\n\"equivalence_class_size_u" + - "pper_bound\030\002 \001(\003\022\023\n\013bucket_size\030\003 \001(\003\022z\n" + - "\rbucket_values\030\004 \003(\0132c.google.privacy.dl" + - "p.v2beta1.RiskAnalysisOperationResult.KA" + - "nonymityResult.KAnonymityEquivalenceClas" + - "s\032\246\005\n\020LDiversityResult\022\227\001\n+sensitive_val" + - "ue_frequency_histogram_buckets\030\005 \003(\0132b.g" + - "oogle.privacy.dlp.v2beta1.RiskAnalysisOp" + - "erationResult.LDiversityResult.LDiversit" + - "yHistogramBucket\032\352\001\n\032LDiversityEquivalen" + - "ceClass\022;\n\020quasi_ids_values\030\001 \003(\0132!.goog" + - "le.privacy.dlp.v2beta1.Value\022\036\n\026equivale" + - "nce_class_size\030\002 \001(\003\022%\n\035num_distinct_sen" + - "sitive_values\030\003 \001(\003\022H\n\024top_sensitive_val" + - "ues\030\004 \003(\0132*.google.privacy.dlp.v2beta1.V" + - "alueFrequency\032\212\002\n\031LDiversityHistogramBuc" + - "ket\022-\n%sensitive_value_frequency_lower_b" + - "ound\030\001 \001(\003\022-\n%sensitive_value_frequency_" + - "upper_bound\030\002 \001(\003\022\023\n\013bucket_size\030\003 \001(\003\022z" + - "\n\rbucket_values\030\004 \003(\0132c.google.privacy.d" + - "lp.v2beta1.RiskAnalysisOperationResult.L" + - "DiversityResult.LDiversityEquivalenceCla" + - "ssB\010\n\006result\"Q\n\016ValueFrequency\0220\n\005value\030" + - "\001 \001(\0132!.google.privacy.dlp.v2beta1.Value" + - "\022\r\n\005count\030\002 \001(\003\"\376\001\n\005Value\022\027\n\rinteger_val" + - "ue\030\001 \001(\003H\000\022\025\n\013float_value\030\002 \001(\001H\000\022\026\n\014str" + - "ing_value\030\003 \001(\tH\000\022\027\n\rboolean_value\030\004 \001(\010" + - "H\000\0225\n\017timestamp_value\030\005 \001(\0132\032.google.pro" + - "tobuf.TimestampH\000\022,\n\ntime_value\030\006 \001(\0132\026." + - "google.type.TimeOfDayH\000\022\'\n\ndate_value\030\007 " + - "\001(\0132\021.google.type.DateH\000B\006\n\004type\"\323\001\n\020Dei" + - "dentifyConfig\022X\n\031info_type_transformatio" + - "ns\030\001 \001(\01323.google.privacy.dlp.v2beta1.In" + - "foTypeTransformationsH\000\022S\n\026record_transf" + - "ormations\030\002 \001(\01321.google.privacy.dlp.v2b" + - "eta1.RecordTransformationsH\000B\020\n\016transfor" + - "mation\"\204\006\n\027PrimitiveTransformation\022H\n\016re" + - "place_config\030\001 \001(\0132..google.privacy.dlp." + - "v2beta1.ReplaceValueConfigH\000\022A\n\rredact_c" + - "onfig\030\002 \001(\0132(.google.privacy.dlp.v2beta1" + - ".RedactConfigH\000\022P\n\025character_mask_config" + - "\030\003 \001(\0132/.google.privacy.dlp.v2beta1.Char" + - "acterMaskConfigH\000\022^\n\035crypto_replace_ffx_" + - "fpe_config\030\004 \001(\01325.google.privacy.dlp.v2" + - "beta1.CryptoReplaceFfxFpeConfigH\000\022[\n\033fix" + - "ed_size_bucketing_config\030\005 \001(\01324.google." + - "privacy.dlp.v2beta1.FixedSizeBucketingCo" + - "nfigH\000\022G\n\020bucketing_config\030\006 \001(\0132+.googl" + - "e.privacy.dlp.v2beta1.BucketingConfigH\000\022" + - "^\n\035replace_with_info_type_config\030\007 \001(\01325" + - ".google.privacy.dlp.v2beta1.ReplaceWithI" + - "nfoTypeConfigH\000\022F\n\020time_part_config\030\010 \001(" + - "\0132*.google.privacy.dlp.v2beta1.TimePartC" + - "onfigH\000\022J\n\022crypto_hash_config\030\t \001(\0132,.go" + - "ogle.privacy.dlp.v2beta1.CryptoHashConfi" + - "gH\000B\020\n\016transformation\"\341\001\n\016TimePartConfig" + - "\022L\n\017part_to_extract\030\001 \001(\01623.google.priva" + - "cy.dlp.v2beta1.TimePartConfig.TimePart\"\200" + - "\001\n\010TimePart\022\031\n\025TIME_PART_UNSPECIFIED\020\000\022\010" + - "\n\004YEAR\020\001\022\t\n\005MONTH\020\002\022\020\n\014DAY_OF_MONTH\020\003\022\017\n" + - "\013DAY_OF_WEEK\020\004\022\020\n\014WEEK_OF_YEAR\020\005\022\017\n\013HOUR" + - "_OF_DAY\020\006\"M\n\020CryptoHashConfig\0229\n\ncrypto_" + - "key\030\001 \001(\0132%.google.privacy.dlp.v2beta1.C" + - "ryptoKey\"J\n\022ReplaceValueConfig\0224\n\tnew_va" + - "lue\030\001 \001(\0132!.google.privacy.dlp.v2beta1.V" + - "alue\"\033\n\031ReplaceWithInfoTypeConfig\"\016\n\014Red" + - "actConfig\"\252\002\n\rCharsToIgnore\022\034\n\022character" + - "s_to_skip\030\001 \001(\tH\000\022_\n\033common_characters_t" + - "o_ignore\030\002 \001(\01628.google.privacy.dlp.v2be" + - "ta1.CharsToIgnore.CharacterGroupH\000\"\213\001\n\016C" + - "haracterGroup\022\037\n\033CHARACTER_GROUP_UNSPECI" + - "FIED\020\000\022\013\n\007NUMERIC\020\001\022\024\n\020ALPHA_UPPER_CASE\020" + - "\002\022\024\n\020ALPHA_LOWER_CASE\020\003\022\017\n\013PUNCTUATION\020\004" + - "\022\016\n\nWHITESPACE\020\005B\014\n\ncharacters\"\250\001\n\023Chara" + - "cterMaskConfig\022\031\n\021masking_character\030\001 \001(" + - "\t\022\026\n\016number_to_mask\030\002 \001(\005\022\025\n\rreverse_ord" + - "er\030\003 \001(\010\022G\n\024characters_to_ignore\030\004 \003(\0132)" + - ".google.privacy.dlp.v2beta1.CharsToIgnor" + - "e\"\237\001\n\030FixedSizeBucketingConfig\0226\n\013lower_" + - "bound\030\001 \001(\0132!.google.privacy.dlp.v2beta1" + - ".Value\0226\n\013upper_bound\030\002 \001(\0132!.google.pri" + - "vacy.dlp.v2beta1.Value\022\023\n\013bucket_size\030\003 " + - "\001(\001\"\377\001\n\017BucketingConfig\022C\n\007buckets\030\001 \003(\013" + - "22.google.privacy.dlp.v2beta1.BucketingC" + - "onfig.Bucket\032\246\001\n\006Bucket\022.\n\003min\030\001 \001(\0132!.g" + - "oogle.privacy.dlp.v2beta1.Value\022.\n\003max\030\002" + - " \001(\0132!.google.privacy.dlp.v2beta1.Value\022" + - "<\n\021replacement_value\030\003 \001(\0132!.google.priv" + - "acy.dlp.v2beta1.Value\"\305\003\n\031CryptoReplaceF" + - "fxFpeConfig\0229\n\ncrypto_key\030\001 \001(\0132%.google" + - ".privacy.dlp.v2beta1.CryptoKey\0224\n\007contex" + - "t\030\002 \001(\0132#.google.privacy.dlp.v2beta1.Fie" + - "ldId\022h\n\017common_alphabet\030\004 \001(\0162M.google.p" + - "rivacy.dlp.v2beta1.CryptoReplaceFfxFpeCo" + - "nfig.FfxCommonNativeAlphabetH\000\022\031\n\017custom" + - "_alphabet\030\005 \001(\tH\000\022\017\n\005radix\030\006 \001(\005H\000\"\224\001\n\027F" + - "fxCommonNativeAlphabet\022*\n&FFX_COMMON_NAT" + - "IVE_ALPHABET_UNSPECIFIED\020\000\022\013\n\007NUMERIC\020\001\022" + - "\017\n\013HEXADECIMAL\020\002\022\034\n\030UPPER_CASE_ALPHA_NUM" + - "ERIC\020\003\022\021\n\rALPHA_NUMERIC\020\004B\n\n\010alphabet\"\347\001" + - "\n\tCryptoKey\022C\n\ttransient\030\001 \001(\0132..google." + - "privacy.dlp.v2beta1.TransientCryptoKeyH\000" + - "\022C\n\tunwrapped\030\002 \001(\0132..google.privacy.dlp" + - ".v2beta1.UnwrappedCryptoKeyH\000\022F\n\013kms_wra" + - "pped\030\003 \001(\0132/.google.privacy.dlp.v2beta1." + - "KmsWrappedCryptoKeyH\000B\010\n\006source\"\"\n\022Trans" + - "ientCryptoKey\022\014\n\004name\030\001 \001(\t\"!\n\022Unwrapped" + - "CryptoKey\022\013\n\003key\030\001 \001(\014\"C\n\023KmsWrappedCryp" + - "toKey\022\023\n\013wrapped_key\030\001 \001(\014\022\027\n\017crypto_key" + - "_name\030\002 \001(\t\"\252\002\n\027InfoTypeTransformations\022" + - "c\n\017transformations\030\001 \003(\0132J.google.privac" + - "y.dlp.v2beta1.InfoTypeTransformations.In" + - "foTypeTransformation\032\251\001\n\026InfoTypeTransfo" + - "rmation\0228\n\ninfo_types\030\001 \003(\0132$.google.pri" + - "vacy.dlp.v2beta1.InfoType\022U\n\030primitive_t" + - "ransformation\030\002 \001(\01323.google.privacy.dlp" + - ".v2beta1.PrimitiveTransformation\"\317\002\n\023Fie" + - "ldTransformation\0223\n\006fields\030\001 \003(\0132#.googl" + - "e.privacy.dlp.v2beta1.FieldId\022>\n\tconditi" + - "on\030\003 \001(\0132+.google.privacy.dlp.v2beta1.Re" + - "cordCondition\022W\n\030primitive_transformatio" + - "n\030\004 \001(\01323.google.privacy.dlp.v2beta1.Pri" + - "mitiveTransformationH\000\022X\n\031info_type_tran" + - "sformations\030\005 \001(\01323.google.privacy.dlp.v" + - "2beta1.InfoTypeTransformationsH\000B\020\n\016tran" + - "sformation\"\263\001\n\025RecordTransformations\022N\n\025" + - "field_transformations\030\001 \003(\0132/.google.pri" + - "vacy.dlp.v2beta1.FieldTransformation\022J\n\023" + - "record_suppressions\030\002 \003(\0132-.google.priva" + - "cy.dlp.v2beta1.RecordSuppression\"S\n\021Reco" + - "rdSuppression\022>\n\tcondition\030\001 \001(\0132+.googl" + - "e.privacy.dlp.v2beta1.RecordCondition\"\365\004" + - "\n\017RecordCondition\022L\n\013expressions\030\003 \001(\01327" + - ".google.privacy.dlp.v2beta1.RecordCondit" + - "ion.Expressions\032\263\001\n\tCondition\0222\n\005field\030\001" + - " \001(\0132#.google.privacy.dlp.v2beta1.FieldI" + - "d\022@\n\010operator\030\003 \001(\0162..google.privacy.dlp" + - ".v2beta1.RelationalOperator\0220\n\005value\030\004 \001" + - "(\0132!.google.privacy.dlp.v2beta1.Value\032W\n" + - "\nConditions\022I\n\nconditions\030\001 \003(\01325.google" + - ".privacy.dlp.v2beta1.RecordCondition.Con" + - "dition\032\204\002\n\013Expressions\022a\n\020logical_operat" + - "or\030\001 \001(\0162G.google.privacy.dlp.v2beta1.Re" + - "cordCondition.Expressions.LogicalOperato" + - "r\022L\n\nconditions\030\003 \001(\01326.google.privacy.d" + - "lp.v2beta1.RecordCondition.ConditionsH\000\"" + - "<\n\017LogicalOperator\022 \n\034LOGICAL_OPERATOR_U" + - "NSPECIFIED\020\000\022\007\n\003AND\020\001B\006\n\004type\"\211\001\n\027Deiden" + - "tificationSummary\022\031\n\021transformed_bytes\030\002" + - " \001(\003\022S\n\030transformation_summaries\030\003 \003(\01321" + - ".google.privacy.dlp.v2beta1.Transformati" + - "onSummary\"\247\005\n\025TransformationSummary\0227\n\ti" + - "nfo_type\030\001 \001(\0132$.google.privacy.dlp.v2be" + - "ta1.InfoType\0222\n\005field\030\002 \001(\0132#.google.pri" + - "vacy.dlp.v2beta1.FieldId\022K\n\016transformati" + - "on\030\003 \001(\01323.google.privacy.dlp.v2beta1.Pr" + - "imitiveTransformation\022N\n\025field_transform" + - "ations\030\005 \003(\0132/.google.privacy.dlp.v2beta" + - "1.FieldTransformation\022F\n\017record_suppress" + - "\030\006 \001(\0132-.google.privacy.dlp.v2beta1.Reco" + - "rdSuppression\022P\n\007results\030\004 \003(\0132?.google." + - "privacy.dlp.v2beta1.TransformationSummar" + - "y.SummaryResult\032\211\001\n\rSummaryResult\022\r\n\005cou" + - "nt\030\001 \001(\003\022X\n\004code\030\002 \001(\0162J.google.privacy." + - "dlp.v2beta1.TransformationSummary.Transf" + - "ormationResultCode\022\017\n\007details\030\003 \001(\t\"^\n\030T" + - "ransformationResultCode\022*\n&TRANSFORMATIO" + - "N_RESULT_CODE_UNSPECIFIED\020\000\022\013\n\007SUCCESS\020\001" + - "\022\t\n\005ERROR\020\002*t\n\nLikelihood\022\032\n\026LIKELIHOOD_" + - "UNSPECIFIED\020\000\022\021\n\rVERY_UNLIKELY\020\001\022\014\n\010UNLI" + - "KELY\020\002\022\014\n\010POSSIBLE\020\003\022\n\n\006LIKELY\020\004\022\017\n\013VERY" + - "_LIKELY\020\005*\273\001\n\022RelationalOperator\022#\n\037RELA" + - "TIONAL_OPERATOR_UNSPECIFIED\020\000\022\014\n\010EQUAL_T" + - "O\020\001\022\020\n\014NOT_EQUAL_TO\020\002\022\020\n\014GREATER_THAN\020\003\022" + - "\r\n\tLESS_THAN\020\004\022\032\n\026GREATER_THAN_OR_EQUALS" + - "\020\005\022\027\n\023LESS_THAN_OR_EQUALS\020\006\022\n\n\006EXISTS\020\0072" + - "\274\n\n\nDlpService\022\234\001\n\016InspectContent\0221.goog" + - "le.privacy.dlp.v2beta1.InspectContentReq" + - "uest\0322.google.privacy.dlp.v2beta1.Inspec" + - "tContentResponse\"#\202\323\344\223\002\035\"\030/v2beta1/conte" + - "nt:inspect:\001*\022\230\001\n\rRedactContent\0220.google" + - ".privacy.dlp.v2beta1.RedactContentReques" + - "t\0321.google.privacy.dlp.v2beta1.RedactCon" + - "tentResponse\"\"\202\323\344\223\002\034\"\027/v2beta1/content:r" + - "edact:\001*\022\250\001\n\021DeidentifyContent\0224.google." + - "privacy.dlp.v2beta1.DeidentifyContentReq" + - "uest\0325.google.privacy.dlp.v2beta1.Deiden" + - "tifyContentResponse\"&\202\323\344\223\002 \"\033/v2beta1/co" + - "ntent:deidentify:\001*\022\232\001\n\026CreateInspectOpe" + - "ration\0229.google.privacy.dlp.v2beta1.Crea" + - "teInspectOperationRequest\032\035.google.longr" + - "unning.Operation\"&\202\323\344\223\002 \"\033/v2beta1/inspe" + - "ct/operations:\001*\022\230\001\n\025AnalyzeDataSourceRi" + - "sk\0228.google.privacy.dlp.v2beta1.AnalyzeD" + - "ataSourceRiskRequest\032\035.google.longrunnin" + - "g.Operation\"&\202\323\344\223\002 \"\033/v2beta1/dataSource" + - ":analyze:\001*\022\272\001\n\023ListInspectFindings\0226.go" + - "ogle.privacy.dlp.v2beta1.ListInspectFind" + - "ingsRequest\0327.google.privacy.dlp.v2beta1" + - ".ListInspectFindingsResponse\"2\202\323\344\223\002,\022*/v" + - "2beta1/{name=inspect/results/*}/findings" + - "\022\254\001\n\rListInfoTypes\0220.google.privacy.dlp." + - "v2beta1.ListInfoTypesRequest\0321.google.pr" + - "ivacy.dlp.v2beta1.ListInfoTypesResponse\"" + - "6\202\323\344\223\0020\022./v2beta1/rootCategories/{catego" + - "ry=*}/infoTypes\022\244\001\n\022ListRootCategories\0225" + - ".google.privacy.dlp.v2beta1.ListRootCate", - "goriesRequest\0326.google.privacy.dlp.v2bet" + - "a1.ListRootCategoriesResponse\"\037\202\323\344\223\002\031\022\027/" + - "v2beta1/rootCategoriesB\241\001\n\036com.google.pr" + - "ivacy.dlp.v2beta1B\010DlpProtoP\001Z=google.go" + - "lang.org/genproto/googleapis/privacy/dlp" + - "/v2beta1;dlp\252\002\030Google.Cloud.Dlp.V2Beta1\312" + - "\002\030Google\\Cloud\\Dlp\\V2beta1b\006proto3" - }; - com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = - new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { - public com.google.protobuf.ExtensionRegistry assignDescriptors( - com.google.protobuf.Descriptors.FileDescriptor root) { - descriptor = root; - return null; - } - }; - com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - com.google.api.AnnotationsProto.getDescriptor(), - com.google.longrunning.OperationsProto.getDescriptor(), - com.google.privacy.dlp.v2beta1.DlpStorage.getDescriptor(), - com.google.protobuf.EmptyProto.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - com.google.type.DateProto.getDescriptor(), - com.google.type.TimeOfDayProto.getDescriptor(), - }, assigner); - internal_static_google_privacy_dlp_v2beta1_InspectConfig_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_InspectConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InspectConfig_descriptor, - new java.lang.String[] { "InfoTypes", "MinLikelihood", "MaxFindings", "IncludeQuote", "ExcludeTypes", "InfoTypeLimits", "CustomInfoTypes", }); - internal_static_google_privacy_dlp_v2beta1_InspectConfig_InfoTypeLimit_descriptor = - internal_static_google_privacy_dlp_v2beta1_InspectConfig_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_InspectConfig_InfoTypeLimit_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InspectConfig_InfoTypeLimit_descriptor, - new java.lang.String[] { "InfoType", "MaxFindings", }); - internal_static_google_privacy_dlp_v2beta1_OperationConfig_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_google_privacy_dlp_v2beta1_OperationConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_OperationConfig_descriptor, - new java.lang.String[] { "MaxItemFindings", }); - internal_static_google_privacy_dlp_v2beta1_ContentItem_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_google_privacy_dlp_v2beta1_ContentItem_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ContentItem_descriptor, - new java.lang.String[] { "Type", "Data", "Value", "Table", "DataItem", }); - internal_static_google_privacy_dlp_v2beta1_Table_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_google_privacy_dlp_v2beta1_Table_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_Table_descriptor, - new java.lang.String[] { "Headers", "Rows", }); - internal_static_google_privacy_dlp_v2beta1_Table_Row_descriptor = - internal_static_google_privacy_dlp_v2beta1_Table_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_Table_Row_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_Table_Row_descriptor, - new java.lang.String[] { "Values", }); - internal_static_google_privacy_dlp_v2beta1_InspectResult_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_google_privacy_dlp_v2beta1_InspectResult_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InspectResult_descriptor, - new java.lang.String[] { "Findings", "FindingsTruncated", }); - internal_static_google_privacy_dlp_v2beta1_Finding_descriptor = - getDescriptor().getMessageTypes().get(5); - internal_static_google_privacy_dlp_v2beta1_Finding_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_Finding_descriptor, - new java.lang.String[] { "Quote", "InfoType", "Likelihood", "Location", "CreateTime", }); - internal_static_google_privacy_dlp_v2beta1_Location_descriptor = - getDescriptor().getMessageTypes().get(6); - internal_static_google_privacy_dlp_v2beta1_Location_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_Location_descriptor, - new java.lang.String[] { "ByteRange", "CodepointRange", "ImageBoxes", "RecordKey", "FieldId", "TableLocation", }); - internal_static_google_privacy_dlp_v2beta1_TableLocation_descriptor = - getDescriptor().getMessageTypes().get(7); - internal_static_google_privacy_dlp_v2beta1_TableLocation_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_TableLocation_descriptor, - new java.lang.String[] { "RowIndex", }); - internal_static_google_privacy_dlp_v2beta1_Range_descriptor = - getDescriptor().getMessageTypes().get(8); - internal_static_google_privacy_dlp_v2beta1_Range_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_Range_descriptor, - new java.lang.String[] { "Start", "End", }); - internal_static_google_privacy_dlp_v2beta1_ImageLocation_descriptor = - getDescriptor().getMessageTypes().get(9); - internal_static_google_privacy_dlp_v2beta1_ImageLocation_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ImageLocation_descriptor, - new java.lang.String[] { "Top", "Left", "Width", "Height", }); - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_descriptor = - getDescriptor().getMessageTypes().get(10); - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_descriptor, - new java.lang.String[] { "InspectConfig", "Items", "ReplaceConfigs", "ImageRedactionConfigs", }); - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ReplaceConfig_descriptor = - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ReplaceConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ReplaceConfig_descriptor, - new java.lang.String[] { "InfoType", "ReplaceWith", }); - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ImageRedactionConfig_descriptor = - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_descriptor.getNestedTypes().get(1); - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ImageRedactionConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ImageRedactionConfig_descriptor, - new java.lang.String[] { "InfoType", "RedactAllText", "RedactionColor", "Target", }); - internal_static_google_privacy_dlp_v2beta1_Color_descriptor = - getDescriptor().getMessageTypes().get(11); - internal_static_google_privacy_dlp_v2beta1_Color_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_Color_descriptor, - new java.lang.String[] { "Red", "Green", "Blue", }); - internal_static_google_privacy_dlp_v2beta1_RedactContentResponse_descriptor = - getDescriptor().getMessageTypes().get(12); - internal_static_google_privacy_dlp_v2beta1_RedactContentResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RedactContentResponse_descriptor, - new java.lang.String[] { "Items", }); - internal_static_google_privacy_dlp_v2beta1_DeidentifyContentRequest_descriptor = - getDescriptor().getMessageTypes().get(13); - internal_static_google_privacy_dlp_v2beta1_DeidentifyContentRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_DeidentifyContentRequest_descriptor, - new java.lang.String[] { "DeidentifyConfig", "InspectConfig", "Items", }); - internal_static_google_privacy_dlp_v2beta1_DeidentifyContentResponse_descriptor = - getDescriptor().getMessageTypes().get(14); - internal_static_google_privacy_dlp_v2beta1_DeidentifyContentResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_DeidentifyContentResponse_descriptor, - new java.lang.String[] { "Items", "Summaries", }); - internal_static_google_privacy_dlp_v2beta1_InspectContentRequest_descriptor = - getDescriptor().getMessageTypes().get(15); - internal_static_google_privacy_dlp_v2beta1_InspectContentRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InspectContentRequest_descriptor, - new java.lang.String[] { "InspectConfig", "Items", }); - internal_static_google_privacy_dlp_v2beta1_InspectContentResponse_descriptor = - getDescriptor().getMessageTypes().get(16); - internal_static_google_privacy_dlp_v2beta1_InspectContentResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InspectContentResponse_descriptor, - new java.lang.String[] { "Results", }); - internal_static_google_privacy_dlp_v2beta1_CreateInspectOperationRequest_descriptor = - getDescriptor().getMessageTypes().get(17); - internal_static_google_privacy_dlp_v2beta1_CreateInspectOperationRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CreateInspectOperationRequest_descriptor, - new java.lang.String[] { "InspectConfig", "StorageConfig", "OutputConfig", "OperationConfig", }); - internal_static_google_privacy_dlp_v2beta1_OutputStorageConfig_descriptor = - getDescriptor().getMessageTypes().get(18); - internal_static_google_privacy_dlp_v2beta1_OutputStorageConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_OutputStorageConfig_descriptor, - new java.lang.String[] { "Table", "StoragePath", "Type", }); - internal_static_google_privacy_dlp_v2beta1_InfoTypeStatistics_descriptor = - getDescriptor().getMessageTypes().get(19); - internal_static_google_privacy_dlp_v2beta1_InfoTypeStatistics_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InfoTypeStatistics_descriptor, - new java.lang.String[] { "InfoType", "Count", }); - internal_static_google_privacy_dlp_v2beta1_InspectOperationMetadata_descriptor = - getDescriptor().getMessageTypes().get(20); - internal_static_google_privacy_dlp_v2beta1_InspectOperationMetadata_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InspectOperationMetadata_descriptor, - new java.lang.String[] { "ProcessedBytes", "TotalEstimatedBytes", "InfoTypeStats", "CreateTime", "RequestInspectConfig", "RequestStorageConfig", "RequestOutputConfig", }); - internal_static_google_privacy_dlp_v2beta1_InspectOperationResult_descriptor = - getDescriptor().getMessageTypes().get(21); - internal_static_google_privacy_dlp_v2beta1_InspectOperationResult_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InspectOperationResult_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsRequest_descriptor = - getDescriptor().getMessageTypes().get(22); - internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsRequest_descriptor, - new java.lang.String[] { "Name", "PageSize", "PageToken", "Filter", }); - internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsResponse_descriptor = - getDescriptor().getMessageTypes().get(23); - internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsResponse_descriptor, - new java.lang.String[] { "Result", "NextPageToken", }); - internal_static_google_privacy_dlp_v2beta1_InfoTypeDescription_descriptor = - getDescriptor().getMessageTypes().get(24); - internal_static_google_privacy_dlp_v2beta1_InfoTypeDescription_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InfoTypeDescription_descriptor, - new java.lang.String[] { "Name", "DisplayName", "Categories", }); - internal_static_google_privacy_dlp_v2beta1_ListInfoTypesRequest_descriptor = - getDescriptor().getMessageTypes().get(25); - internal_static_google_privacy_dlp_v2beta1_ListInfoTypesRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ListInfoTypesRequest_descriptor, - new java.lang.String[] { "Category", "LanguageCode", }); - internal_static_google_privacy_dlp_v2beta1_ListInfoTypesResponse_descriptor = - getDescriptor().getMessageTypes().get(26); - internal_static_google_privacy_dlp_v2beta1_ListInfoTypesResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ListInfoTypesResponse_descriptor, - new java.lang.String[] { "InfoTypes", }); - internal_static_google_privacy_dlp_v2beta1_CategoryDescription_descriptor = - getDescriptor().getMessageTypes().get(27); - internal_static_google_privacy_dlp_v2beta1_CategoryDescription_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CategoryDescription_descriptor, - new java.lang.String[] { "Name", "DisplayName", }); - internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesRequest_descriptor = - getDescriptor().getMessageTypes().get(28); - internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesRequest_descriptor, - new java.lang.String[] { "LanguageCode", }); - internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesResponse_descriptor = - getDescriptor().getMessageTypes().get(29); - internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesResponse_descriptor, - new java.lang.String[] { "Categories", }); - internal_static_google_privacy_dlp_v2beta1_AnalyzeDataSourceRiskRequest_descriptor = - getDescriptor().getMessageTypes().get(30); - internal_static_google_privacy_dlp_v2beta1_AnalyzeDataSourceRiskRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_AnalyzeDataSourceRiskRequest_descriptor, - new java.lang.String[] { "PrivacyMetric", "SourceTable", }); - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor = - getDescriptor().getMessageTypes().get(31); - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor, - new java.lang.String[] { "NumericalStatsConfig", "CategoricalStatsConfig", "KAnonymityConfig", "LDiversityConfig", "Type", }); - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_descriptor = - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_descriptor, - new java.lang.String[] { "Field", }); - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_descriptor = - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor.getNestedTypes().get(1); - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_descriptor, - new java.lang.String[] { "Field", }); - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_descriptor = - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor.getNestedTypes().get(2); - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_descriptor, - new java.lang.String[] { "QuasiIds", "EntityId", }); - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_descriptor = - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor.getNestedTypes().get(3); - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_descriptor, - new java.lang.String[] { "QuasiIds", "SensitiveAttribute", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationMetadata_descriptor = - getDescriptor().getMessageTypes().get(32); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationMetadata_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationMetadata_descriptor, - new java.lang.String[] { "CreateTime", "RequestedPrivacyMetric", "RequestedSourceTable", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_descriptor = - getDescriptor().getMessageTypes().get(33); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_descriptor, - new java.lang.String[] { "NumericalStatsResult", "CategoricalStatsResult", "KAnonymityResult", "LDiversityResult", "Result", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_NumericalStatsResult_descriptor = - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_NumericalStatsResult_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_NumericalStatsResult_descriptor, - new java.lang.String[] { "MinValue", "MaxValue", "QuantileValues", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_descriptor = - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_descriptor.getNestedTypes().get(1); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_descriptor, - new java.lang.String[] { "ValueFrequencyHistogramBuckets", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_CategoricalStatsHistogramBucket_descriptor = - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_CategoricalStatsHistogramBucket_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_CategoricalStatsHistogramBucket_descriptor, - new java.lang.String[] { "ValueFrequencyLowerBound", "ValueFrequencyUpperBound", "BucketSize", "BucketValues", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_descriptor = - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_descriptor.getNestedTypes().get(2); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_descriptor, - new java.lang.String[] { "EquivalenceClassHistogramBuckets", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityEquivalenceClass_descriptor = - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityEquivalenceClass_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityEquivalenceClass_descriptor, - new java.lang.String[] { "QuasiIdsValues", "EquivalenceClassSize", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityHistogramBucket_descriptor = - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_descriptor.getNestedTypes().get(1); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityHistogramBucket_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityHistogramBucket_descriptor, - new java.lang.String[] { "EquivalenceClassSizeLowerBound", "EquivalenceClassSizeUpperBound", "BucketSize", "BucketValues", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_descriptor = - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_descriptor.getNestedTypes().get(3); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_descriptor, - new java.lang.String[] { "SensitiveValueFrequencyHistogramBuckets", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityEquivalenceClass_descriptor = - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityEquivalenceClass_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityEquivalenceClass_descriptor, - new java.lang.String[] { "QuasiIdsValues", "EquivalenceClassSize", "NumDistinctSensitiveValues", "TopSensitiveValues", }); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityHistogramBucket_descriptor = - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_descriptor.getNestedTypes().get(1); - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityHistogramBucket_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityHistogramBucket_descriptor, - new java.lang.String[] { "SensitiveValueFrequencyLowerBound", "SensitiveValueFrequencyUpperBound", "BucketSize", "BucketValues", }); - internal_static_google_privacy_dlp_v2beta1_ValueFrequency_descriptor = - getDescriptor().getMessageTypes().get(34); - internal_static_google_privacy_dlp_v2beta1_ValueFrequency_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ValueFrequency_descriptor, - new java.lang.String[] { "Value", "Count", }); - internal_static_google_privacy_dlp_v2beta1_Value_descriptor = - getDescriptor().getMessageTypes().get(35); - internal_static_google_privacy_dlp_v2beta1_Value_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_Value_descriptor, - new java.lang.String[] { "IntegerValue", "FloatValue", "StringValue", "BooleanValue", "TimestampValue", "TimeValue", "DateValue", "Type", }); - internal_static_google_privacy_dlp_v2beta1_DeidentifyConfig_descriptor = - getDescriptor().getMessageTypes().get(36); - internal_static_google_privacy_dlp_v2beta1_DeidentifyConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_DeidentifyConfig_descriptor, - new java.lang.String[] { "InfoTypeTransformations", "RecordTransformations", "Transformation", }); - internal_static_google_privacy_dlp_v2beta1_PrimitiveTransformation_descriptor = - getDescriptor().getMessageTypes().get(37); - internal_static_google_privacy_dlp_v2beta1_PrimitiveTransformation_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_PrimitiveTransformation_descriptor, - new java.lang.String[] { "ReplaceConfig", "RedactConfig", "CharacterMaskConfig", "CryptoReplaceFfxFpeConfig", "FixedSizeBucketingConfig", "BucketingConfig", "ReplaceWithInfoTypeConfig", "TimePartConfig", "CryptoHashConfig", "Transformation", }); - internal_static_google_privacy_dlp_v2beta1_TimePartConfig_descriptor = - getDescriptor().getMessageTypes().get(38); - internal_static_google_privacy_dlp_v2beta1_TimePartConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_TimePartConfig_descriptor, - new java.lang.String[] { "PartToExtract", }); - internal_static_google_privacy_dlp_v2beta1_CryptoHashConfig_descriptor = - getDescriptor().getMessageTypes().get(39); - internal_static_google_privacy_dlp_v2beta1_CryptoHashConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CryptoHashConfig_descriptor, - new java.lang.String[] { "CryptoKey", }); - internal_static_google_privacy_dlp_v2beta1_ReplaceValueConfig_descriptor = - getDescriptor().getMessageTypes().get(40); - internal_static_google_privacy_dlp_v2beta1_ReplaceValueConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ReplaceValueConfig_descriptor, - new java.lang.String[] { "NewValue", }); - internal_static_google_privacy_dlp_v2beta1_ReplaceWithInfoTypeConfig_descriptor = - getDescriptor().getMessageTypes().get(41); - internal_static_google_privacy_dlp_v2beta1_ReplaceWithInfoTypeConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_ReplaceWithInfoTypeConfig_descriptor, - new java.lang.String[] { }); - internal_static_google_privacy_dlp_v2beta1_RedactConfig_descriptor = - getDescriptor().getMessageTypes().get(42); - internal_static_google_privacy_dlp_v2beta1_RedactConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RedactConfig_descriptor, - new java.lang.String[] { }); - internal_static_google_privacy_dlp_v2beta1_CharsToIgnore_descriptor = - getDescriptor().getMessageTypes().get(43); - internal_static_google_privacy_dlp_v2beta1_CharsToIgnore_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CharsToIgnore_descriptor, - new java.lang.String[] { "CharactersToSkip", "CommonCharactersToIgnore", "Characters", }); - internal_static_google_privacy_dlp_v2beta1_CharacterMaskConfig_descriptor = - getDescriptor().getMessageTypes().get(44); - internal_static_google_privacy_dlp_v2beta1_CharacterMaskConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CharacterMaskConfig_descriptor, - new java.lang.String[] { "MaskingCharacter", "NumberToMask", "ReverseOrder", "CharactersToIgnore", }); - internal_static_google_privacy_dlp_v2beta1_FixedSizeBucketingConfig_descriptor = - getDescriptor().getMessageTypes().get(45); - internal_static_google_privacy_dlp_v2beta1_FixedSizeBucketingConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_FixedSizeBucketingConfig_descriptor, - new java.lang.String[] { "LowerBound", "UpperBound", "BucketSize", }); - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_descriptor = - getDescriptor().getMessageTypes().get(46); - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_descriptor, - new java.lang.String[] { "Buckets", }); - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_Bucket_descriptor = - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_Bucket_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_BucketingConfig_Bucket_descriptor, - new java.lang.String[] { "Min", "Max", "ReplacementValue", }); - internal_static_google_privacy_dlp_v2beta1_CryptoReplaceFfxFpeConfig_descriptor = - getDescriptor().getMessageTypes().get(47); - internal_static_google_privacy_dlp_v2beta1_CryptoReplaceFfxFpeConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CryptoReplaceFfxFpeConfig_descriptor, - new java.lang.String[] { "CryptoKey", "Context", "CommonAlphabet", "CustomAlphabet", "Radix", "Alphabet", }); - internal_static_google_privacy_dlp_v2beta1_CryptoKey_descriptor = - getDescriptor().getMessageTypes().get(48); - internal_static_google_privacy_dlp_v2beta1_CryptoKey_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CryptoKey_descriptor, - new java.lang.String[] { "Transient", "Unwrapped", "KmsWrapped", "Source", }); - internal_static_google_privacy_dlp_v2beta1_TransientCryptoKey_descriptor = - getDescriptor().getMessageTypes().get(49); - internal_static_google_privacy_dlp_v2beta1_TransientCryptoKey_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_TransientCryptoKey_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_privacy_dlp_v2beta1_UnwrappedCryptoKey_descriptor = - getDescriptor().getMessageTypes().get(50); - internal_static_google_privacy_dlp_v2beta1_UnwrappedCryptoKey_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_UnwrappedCryptoKey_descriptor, - new java.lang.String[] { "Key", }); - internal_static_google_privacy_dlp_v2beta1_KmsWrappedCryptoKey_descriptor = - getDescriptor().getMessageTypes().get(51); - internal_static_google_privacy_dlp_v2beta1_KmsWrappedCryptoKey_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_KmsWrappedCryptoKey_descriptor, - new java.lang.String[] { "WrappedKey", "CryptoKeyName", }); - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_descriptor = - getDescriptor().getMessageTypes().get(52); - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_descriptor, - new java.lang.String[] { "Transformations", }); - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_InfoTypeTransformation_descriptor = - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_InfoTypeTransformation_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_InfoTypeTransformation_descriptor, - new java.lang.String[] { "InfoTypes", "PrimitiveTransformation", }); - internal_static_google_privacy_dlp_v2beta1_FieldTransformation_descriptor = - getDescriptor().getMessageTypes().get(53); - internal_static_google_privacy_dlp_v2beta1_FieldTransformation_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_FieldTransformation_descriptor, - new java.lang.String[] { "Fields", "Condition", "PrimitiveTransformation", "InfoTypeTransformations", "Transformation", }); - internal_static_google_privacy_dlp_v2beta1_RecordTransformations_descriptor = - getDescriptor().getMessageTypes().get(54); - internal_static_google_privacy_dlp_v2beta1_RecordTransformations_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RecordTransformations_descriptor, - new java.lang.String[] { "FieldTransformations", "RecordSuppressions", }); - internal_static_google_privacy_dlp_v2beta1_RecordSuppression_descriptor = - getDescriptor().getMessageTypes().get(55); - internal_static_google_privacy_dlp_v2beta1_RecordSuppression_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RecordSuppression_descriptor, - new java.lang.String[] { "Condition", }); - internal_static_google_privacy_dlp_v2beta1_RecordCondition_descriptor = - getDescriptor().getMessageTypes().get(56); - internal_static_google_privacy_dlp_v2beta1_RecordCondition_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RecordCondition_descriptor, - new java.lang.String[] { "Expressions", }); - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Condition_descriptor = - internal_static_google_privacy_dlp_v2beta1_RecordCondition_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Condition_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Condition_descriptor, - new java.lang.String[] { "Field", "Operator", "Value", }); - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Conditions_descriptor = - internal_static_google_privacy_dlp_v2beta1_RecordCondition_descriptor.getNestedTypes().get(1); - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Conditions_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Conditions_descriptor, - new java.lang.String[] { "Conditions", }); - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Expressions_descriptor = - internal_static_google_privacy_dlp_v2beta1_RecordCondition_descriptor.getNestedTypes().get(2); - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Expressions_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RecordCondition_Expressions_descriptor, - new java.lang.String[] { "LogicalOperator", "Conditions", "Type", }); - internal_static_google_privacy_dlp_v2beta1_DeidentificationSummary_descriptor = - getDescriptor().getMessageTypes().get(57); - internal_static_google_privacy_dlp_v2beta1_DeidentificationSummary_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_DeidentificationSummary_descriptor, - new java.lang.String[] { "TransformedBytes", "TransformationSummaries", }); - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_descriptor = - getDescriptor().getMessageTypes().get(58); - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_descriptor, - new java.lang.String[] { "InfoType", "Field", "Transformation", "FieldTransformations", "RecordSuppress", "Results", }); - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_SummaryResult_descriptor = - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_SummaryResult_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_TransformationSummary_SummaryResult_descriptor, - new java.lang.String[] { "Count", "Code", "Details", }); - com.google.protobuf.ExtensionRegistry registry = - com.google.protobuf.ExtensionRegistry.newInstance(); - registry.add(com.google.api.AnnotationsProto.http); - com.google.protobuf.Descriptors.FileDescriptor - .internalUpdateFileDescriptor(descriptor, registry); - com.google.api.AnnotationsProto.getDescriptor(); - com.google.longrunning.OperationsProto.getDescriptor(); - com.google.privacy.dlp.v2beta1.DlpStorage.getDescriptor(); - com.google.protobuf.EmptyProto.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - com.google.type.DateProto.getDescriptor(); - com.google.type.TimeOfDayProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DlpStorage.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DlpStorage.java deleted file mode 100644 index 2e9eb41e7e8b..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/DlpStorage.java +++ /dev/null @@ -1,345 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public final class DlpStorage { - private DlpStorage() {} - 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_privacy_dlp_v2beta1_InfoType_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_InfoType_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_WordList_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_WordList_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_FieldId_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_FieldId_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_PartitionId_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_PartitionId_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_KindExpression_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_KindExpression_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_PropertyReference_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_PropertyReference_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_Projection_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_Projection_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_DatastoreOptions_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_DatastoreOptions_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_FileSet_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_FileSet_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CloudStoragePath_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CloudStoragePath_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_BigQueryOptions_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_BigQueryOptions_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_StorageConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_StorageConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_CloudStorageKey_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_CloudStorageKey_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_DatastoreKey_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_DatastoreKey_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_Key_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_Key_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_Key_PathElement_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_Key_PathElement_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_RecordKey_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_RecordKey_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_BigQueryTable_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_BigQueryTable_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_privacy_dlp_v2beta1_EntityId_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_privacy_dlp_v2beta1_EntityId_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/privacy/dlp/v2beta1/storage.pro" + - "to\022\032google.privacy.dlp.v2beta1\032\034google/a" + - "pi/annotations.proto\032\037google/protobuf/ti" + - "mestamp.proto\"\030\n\010InfoType\022\014\n\004name\030\001 \001(\t\"" + - "\247\002\n\016CustomInfoType\0227\n\tinfo_type\030\001 \001(\0132$." + - "google.privacy.dlp.v2beta1.InfoType\022K\n\nd" + - "ictionary\030\002 \001(\01325.google.privacy.dlp.v2b" + - "eta1.CustomInfoType.DictionaryH\000\032\206\001\n\nDic" + - "tionary\022S\n\tword_list\030\001 \001(\0132>.google.priv" + - "acy.dlp.v2beta1.CustomInfoType.Dictionar" + - "y.WordListH\000\032\031\n\010WordList\022\r\n\005words\030\001 \003(\tB" + - "\010\n\006sourceB\006\n\004type\"\036\n\007FieldId\022\023\n\013column_n" + - "ame\030\001 \001(\t\"7\n\013PartitionId\022\022\n\nproject_id\030\002" + - " \001(\t\022\024\n\014namespace_id\030\004 \001(\t\"\036\n\016KindExpres" + - "sion\022\014\n\004name\030\001 \001(\t\"!\n\021PropertyReference\022" + - "\014\n\004name\030\002 \001(\t\"M\n\nProjection\022?\n\010property\030" + - "\001 \001(\0132-.google.privacy.dlp.v2beta1.Prope" + - "rtyReference\"\307\001\n\020DatastoreOptions\022=\n\014par" + - "tition_id\030\001 \001(\0132\'.google.privacy.dlp.v2b" + - "eta1.PartitionId\0228\n\004kind\030\002 \001(\0132*.google." + - "privacy.dlp.v2beta1.KindExpression\022:\n\npr" + - "ojection\030\003 \003(\0132&.google.privacy.dlp.v2be" + - "ta1.Projection\"x\n\023CloudStorageOptions\022I\n" + - "\010file_set\030\001 \001(\01327.google.privacy.dlp.v2b" + - "eta1.CloudStorageOptions.FileSet\032\026\n\007File" + - "Set\022\013\n\003url\030\001 \001(\t\" \n\020CloudStoragePath\022\014\n\004" + - "path\030\001 \001(\t\"\226\001\n\017BigQueryOptions\022B\n\017table_" + - "reference\030\001 \001(\0132).google.privacy.dlp.v2b" + - "eta1.BigQueryTable\022?\n\022identifying_fields" + - "\030\002 \003(\0132#.google.privacy.dlp.v2beta1.Fiel" + - "dId\"\376\001\n\rStorageConfig\022I\n\021datastore_optio" + - "ns\030\002 \001(\0132,.google.privacy.dlp.v2beta1.Da" + - "tastoreOptionsH\000\022P\n\025cloud_storage_option" + - "s\030\003 \001(\0132/.google.privacy.dlp.v2beta1.Clo" + - "udStorageOptionsH\000\022H\n\021big_query_options\030" + - "\004 \001(\0132+.google.privacy.dlp.v2beta1.BigQu" + - "eryOptionsH\000B\006\n\004type\":\n\017CloudStorageKey\022" + - "\021\n\tfile_path\030\001 \001(\t\022\024\n\014start_offset\030\002 \001(\003" + - "\"C\n\014DatastoreKey\0223\n\nentity_key\030\001 \001(\0132\037.g" + - "oogle.privacy.dlp.v2beta1.Key\"\305\001\n\003Key\022=\n" + - "\014partition_id\030\001 \001(\0132\'.google.privacy.dlp" + - ".v2beta1.PartitionId\0229\n\004path\030\002 \003(\0132+.goo" + - "gle.privacy.dlp.v2beta1.Key.PathElement\032" + - "D\n\013PathElement\022\014\n\004kind\030\001 \001(\t\022\014\n\002id\030\002 \001(\003" + - "H\000\022\016\n\004name\030\003 \001(\tH\000B\t\n\007id_type\"\240\001\n\tRecord" + - "Key\022H\n\021cloud_storage_key\030\001 \001(\0132+.google." + - "privacy.dlp.v2beta1.CloudStorageKeyH\000\022A\n" + - "\rdatastore_key\030\002 \001(\0132(.google.privacy.dl" + - "p.v2beta1.DatastoreKeyH\000B\006\n\004type\"I\n\rBigQ" + - "ueryTable\022\022\n\nproject_id\030\001 \001(\t\022\022\n\ndataset" + - "_id\030\002 \001(\t\022\020\n\010table_id\030\003 \001(\t\">\n\010EntityId\022" + - "2\n\005field\030\001 \001(\0132#.google.privacy.dlp.v2be" + - "ta1.FieldIdB\243\001\n\036com.google.privacy.dlp.v" + - "2beta1B\nDlpStorageP\001Z=google.golang.org/" + - "genproto/googleapis/privacy/dlp/v2beta1;" + - "dlp\252\002\030Google.Cloud.Dlp.V2Beta1\312\002\030Google\\" + - "Cloud\\Dlp\\V2beta1b\006proto3" - }; - com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = - new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { - public com.google.protobuf.ExtensionRegistry assignDescriptors( - com.google.protobuf.Descriptors.FileDescriptor root) { - descriptor = root; - return null; - } - }; - com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - com.google.api.AnnotationsProto.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - }, assigner); - internal_static_google_privacy_dlp_v2beta1_InfoType_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_InfoType_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_InfoType_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_descriptor, - new java.lang.String[] { "InfoType", "Dictionary", "Type", }); - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_descriptor = - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_descriptor, - new java.lang.String[] { "WordList", "Source", }); - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_WordList_descriptor = - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_WordList_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CustomInfoType_Dictionary_WordList_descriptor, - new java.lang.String[] { "Words", }); - internal_static_google_privacy_dlp_v2beta1_FieldId_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_google_privacy_dlp_v2beta1_FieldId_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_FieldId_descriptor, - new java.lang.String[] { "ColumnName", }); - internal_static_google_privacy_dlp_v2beta1_PartitionId_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_google_privacy_dlp_v2beta1_PartitionId_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_PartitionId_descriptor, - new java.lang.String[] { "ProjectId", "NamespaceId", }); - internal_static_google_privacy_dlp_v2beta1_KindExpression_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_google_privacy_dlp_v2beta1_KindExpression_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_KindExpression_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_privacy_dlp_v2beta1_PropertyReference_descriptor = - getDescriptor().getMessageTypes().get(5); - internal_static_google_privacy_dlp_v2beta1_PropertyReference_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_PropertyReference_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_privacy_dlp_v2beta1_Projection_descriptor = - getDescriptor().getMessageTypes().get(6); - internal_static_google_privacy_dlp_v2beta1_Projection_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_Projection_descriptor, - new java.lang.String[] { "Property", }); - internal_static_google_privacy_dlp_v2beta1_DatastoreOptions_descriptor = - getDescriptor().getMessageTypes().get(7); - internal_static_google_privacy_dlp_v2beta1_DatastoreOptions_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_DatastoreOptions_descriptor, - new java.lang.String[] { "PartitionId", "Kind", "Projection", }); - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_descriptor = - getDescriptor().getMessageTypes().get(8); - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_descriptor, - new java.lang.String[] { "FileSet", }); - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_FileSet_descriptor = - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_FileSet_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CloudStorageOptions_FileSet_descriptor, - new java.lang.String[] { "Url", }); - internal_static_google_privacy_dlp_v2beta1_CloudStoragePath_descriptor = - getDescriptor().getMessageTypes().get(9); - internal_static_google_privacy_dlp_v2beta1_CloudStoragePath_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CloudStoragePath_descriptor, - new java.lang.String[] { "Path", }); - internal_static_google_privacy_dlp_v2beta1_BigQueryOptions_descriptor = - getDescriptor().getMessageTypes().get(10); - internal_static_google_privacy_dlp_v2beta1_BigQueryOptions_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_BigQueryOptions_descriptor, - new java.lang.String[] { "TableReference", "IdentifyingFields", }); - internal_static_google_privacy_dlp_v2beta1_StorageConfig_descriptor = - getDescriptor().getMessageTypes().get(11); - internal_static_google_privacy_dlp_v2beta1_StorageConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_StorageConfig_descriptor, - new java.lang.String[] { "DatastoreOptions", "CloudStorageOptions", "BigQueryOptions", "Type", }); - internal_static_google_privacy_dlp_v2beta1_CloudStorageKey_descriptor = - getDescriptor().getMessageTypes().get(12); - internal_static_google_privacy_dlp_v2beta1_CloudStorageKey_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_CloudStorageKey_descriptor, - new java.lang.String[] { "FilePath", "StartOffset", }); - internal_static_google_privacy_dlp_v2beta1_DatastoreKey_descriptor = - getDescriptor().getMessageTypes().get(13); - internal_static_google_privacy_dlp_v2beta1_DatastoreKey_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_DatastoreKey_descriptor, - new java.lang.String[] { "EntityKey", }); - internal_static_google_privacy_dlp_v2beta1_Key_descriptor = - getDescriptor().getMessageTypes().get(14); - internal_static_google_privacy_dlp_v2beta1_Key_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_Key_descriptor, - new java.lang.String[] { "PartitionId", "Path", }); - internal_static_google_privacy_dlp_v2beta1_Key_PathElement_descriptor = - internal_static_google_privacy_dlp_v2beta1_Key_descriptor.getNestedTypes().get(0); - internal_static_google_privacy_dlp_v2beta1_Key_PathElement_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_Key_PathElement_descriptor, - new java.lang.String[] { "Kind", "Id", "Name", "IdType", }); - internal_static_google_privacy_dlp_v2beta1_RecordKey_descriptor = - getDescriptor().getMessageTypes().get(15); - internal_static_google_privacy_dlp_v2beta1_RecordKey_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_RecordKey_descriptor, - new java.lang.String[] { "CloudStorageKey", "DatastoreKey", "Type", }); - internal_static_google_privacy_dlp_v2beta1_BigQueryTable_descriptor = - getDescriptor().getMessageTypes().get(16); - internal_static_google_privacy_dlp_v2beta1_BigQueryTable_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_BigQueryTable_descriptor, - new java.lang.String[] { "ProjectId", "DatasetId", "TableId", }); - internal_static_google_privacy_dlp_v2beta1_EntityId_descriptor = - getDescriptor().getMessageTypes().get(17); - internal_static_google_privacy_dlp_v2beta1_EntityId_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_privacy_dlp_v2beta1_EntityId_descriptor, - new java.lang.String[] { "Field", }); - com.google.api.AnnotationsProto.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/EntityId.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/EntityId.java deleted file mode 100644 index d99d66083f12..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/EntityId.java +++ /dev/null @@ -1,634 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * An entity in a dataset is a field or set of fields that correspond to a
- * single person. For example, in medical records the `EntityId` might be
- * a patient identifier, or for financial records it might be an account
- * identifier. This message is used when generalizations or analysis must be
- * consistent across multiple rows pertaining to the same entity.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.EntityId} - */ -public final class EntityId extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.EntityId) - EntityIdOrBuilder { -private static final long serialVersionUID = 0L; - // Use EntityId.newBuilder() to construct. - private EntityId(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private EntityId() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private EntityId( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null; - if (field_ != null) { - subBuilder = field_.toBuilder(); - } - field_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(field_); - field_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_EntityId_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_EntityId_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.EntityId.class, com.google.privacy.dlp.v2beta1.EntityId.Builder.class); - } - - public static final int FIELD_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.FieldId field_; - /** - *
-   * Composite key indicating which field contains the entity identifier.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public boolean hasField() { - return field_ != null; - } - /** - *
-   * Composite key indicating which field contains the entity identifier.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getField() { - return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } - /** - *
-   * Composite key indicating which field contains the entity identifier.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() { - return getField(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (field_ != null) { - output.writeMessage(1, getField()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (field_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getField()); - } - 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.privacy.dlp.v2beta1.EntityId)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.EntityId other = (com.google.privacy.dlp.v2beta1.EntityId) obj; - - boolean result = true; - result = result && (hasField() == other.hasField()); - if (hasField()) { - result = result && getField() - .equals(other.getField()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasField()) { - hash = (37 * hash) + FIELD_FIELD_NUMBER; - hash = (53 * hash) + getField().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.EntityId parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.EntityId parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.EntityId parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.EntityId 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.privacy.dlp.v2beta1.EntityId parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.EntityId parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.EntityId parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.EntityId 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.privacy.dlp.v2beta1.EntityId parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.EntityId 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.privacy.dlp.v2beta1.EntityId parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.EntityId parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.EntityId prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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 entity in a dataset is a field or set of fields that correspond to a
-   * single person. For example, in medical records the `EntityId` might be
-   * a patient identifier, or for financial records it might be an account
-   * identifier. This message is used when generalizations or analysis must be
-   * consistent across multiple rows pertaining to the same entity.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.EntityId} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.EntityId) - com.google.privacy.dlp.v2beta1.EntityIdOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_EntityId_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_EntityId_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.EntityId.class, com.google.privacy.dlp.v2beta1.EntityId.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.EntityId.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (fieldBuilder_ == null) { - field_ = null; - } else { - field_ = null; - fieldBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_EntityId_descriptor; - } - - public com.google.privacy.dlp.v2beta1.EntityId getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.EntityId.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.EntityId build() { - com.google.privacy.dlp.v2beta1.EntityId result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.EntityId buildPartial() { - com.google.privacy.dlp.v2beta1.EntityId result = new com.google.privacy.dlp.v2beta1.EntityId(this); - if (fieldBuilder_ == null) { - result.field_ = field_; - } else { - result.field_ = fieldBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.EntityId) { - return mergeFrom((com.google.privacy.dlp.v2beta1.EntityId)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.EntityId other) { - if (other == com.google.privacy.dlp.v2beta1.EntityId.getDefaultInstance()) return this; - if (other.hasField()) { - mergeField(other.getField()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.EntityId parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.EntityId) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.FieldId field_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> fieldBuilder_; - /** - *
-     * Composite key indicating which field contains the entity identifier.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public boolean hasField() { - return fieldBuilder_ != null || field_ != null; - } - /** - *
-     * Composite key indicating which field contains the entity identifier.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getField() { - if (fieldBuilder_ == null) { - return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } else { - return fieldBuilder_.getMessage(); - } - } - /** - *
-     * Composite key indicating which field contains the entity identifier.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder setField(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - field_ = value; - onChanged(); - } else { - fieldBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Composite key indicating which field contains the entity identifier.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder setField( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (fieldBuilder_ == null) { - field_ = builderForValue.build(); - onChanged(); - } else { - fieldBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Composite key indicating which field contains the entity identifier.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder mergeField(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldBuilder_ == null) { - if (field_ != null) { - field_ = - com.google.privacy.dlp.v2beta1.FieldId.newBuilder(field_).mergeFrom(value).buildPartial(); - } else { - field_ = value; - } - onChanged(); - } else { - fieldBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Composite key indicating which field contains the entity identifier.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder clearField() { - if (fieldBuilder_ == null) { - field_ = null; - onChanged(); - } else { - field_ = null; - fieldBuilder_ = null; - } - - return this; - } - /** - *
-     * Composite key indicating which field contains the entity identifier.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getFieldBuilder() { - - onChanged(); - return getFieldFieldBuilder().getBuilder(); - } - /** - *
-     * Composite key indicating which field contains the entity identifier.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() { - if (fieldBuilder_ != null) { - return fieldBuilder_.getMessageOrBuilder(); - } else { - return field_ == null ? - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } - } - /** - *
-     * Composite key indicating which field contains the entity identifier.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getFieldFieldBuilder() { - if (fieldBuilder_ == null) { - fieldBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - getField(), - getParentForChildren(), - isClean()); - field_ = null; - } - return fieldBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.EntityId) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.EntityId) - private static final com.google.privacy.dlp.v2beta1.EntityId DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.EntityId(); - } - - public static com.google.privacy.dlp.v2beta1.EntityId getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public EntityId parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new EntityId(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.EntityId getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/EntityIdOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/EntityIdOrBuilder.java deleted file mode 100644 index 79fe99392cde..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/EntityIdOrBuilder.java +++ /dev/null @@ -1,34 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface EntityIdOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.EntityId) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Composite key indicating which field contains the entity identifier.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - boolean hasField(); - /** - *
-   * Composite key indicating which field contains the entity identifier.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - com.google.privacy.dlp.v2beta1.FieldId getField(); - /** - *
-   * Composite key indicating which field contains the entity identifier.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldIdOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldIdOrBuilder.java deleted file mode 100644 index 261cfc1d6cc1..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldIdOrBuilder.java +++ /dev/null @@ -1,27 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface FieldIdOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.FieldId) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Name describing the field.
-   * 
- * - * string column_name = 1; - */ - java.lang.String getColumnName(); - /** - *
-   * Name describing the field.
-   * 
- * - * string column_name = 1; - */ - com.google.protobuf.ByteString - getColumnNameBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldTransformation.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldTransformation.java deleted file mode 100644 index 07629b5ad800..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldTransformation.java +++ /dev/null @@ -1,1722 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * The transformation to apply to the field.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.FieldTransformation} - */ -public final class FieldTransformation extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.FieldTransformation) - FieldTransformationOrBuilder { -private static final long serialVersionUID = 0L; - // Use FieldTransformation.newBuilder() to construct. - private FieldTransformation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private FieldTransformation() { - fields_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private FieldTransformation( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - fields_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - fields_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry)); - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.RecordCondition.Builder subBuilder = null; - if (condition_ != null) { - subBuilder = condition_.toBuilder(); - } - condition_ = input.readMessage(com.google.privacy.dlp.v2beta1.RecordCondition.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(condition_); - condition_ = subBuilder.buildPartial(); - } - - break; - } - case 34: { - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder subBuilder = null; - if (transformationCase_ == 4) { - subBuilder = ((com.google.privacy.dlp.v2beta1.PrimitiveTransformation) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.PrimitiveTransformation.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.PrimitiveTransformation) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 4; - break; - } - case 42: { - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder subBuilder = null; - if (transformationCase_ == 5) { - subBuilder = ((com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.InfoTypeTransformations.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 5; - 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) == 0x00000001)) { - fields_ = java.util.Collections.unmodifiableList(fields_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_FieldTransformation_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_FieldTransformation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.FieldTransformation.class, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder.class); - } - - private int bitField0_; - private int transformationCase_ = 0; - private java.lang.Object transformation_; - public enum TransformationCase - implements com.google.protobuf.Internal.EnumLite { - PRIMITIVE_TRANSFORMATION(4), - INFO_TYPE_TRANSFORMATIONS(5), - TRANSFORMATION_NOT_SET(0); - private final int value; - private TransformationCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TransformationCase valueOf(int value) { - return forNumber(value); - } - - public static TransformationCase forNumber(int value) { - switch (value) { - case 4: return PRIMITIVE_TRANSFORMATION; - case 5: return INFO_TYPE_TRANSFORMATIONS; - case 0: return TRANSFORMATION_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TransformationCase - getTransformationCase() { - return TransformationCase.forNumber( - transformationCase_); - } - - public static final int FIELDS_FIELD_NUMBER = 1; - private java.util.List fields_; - /** - *
-   * Input field(s) to apply the transformation to. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public java.util.List getFieldsList() { - return fields_; - } - /** - *
-   * Input field(s) to apply the transformation to. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public java.util.List - getFieldsOrBuilderList() { - return fields_; - } - /** - *
-   * Input field(s) to apply the transformation to. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public int getFieldsCount() { - return fields_.size(); - } - /** - *
-   * Input field(s) to apply the transformation to. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getFields(int index) { - return fields_.get(index); - } - /** - *
-   * Input field(s) to apply the transformation to. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldsOrBuilder( - int index) { - return fields_.get(index); - } - - public static final int CONDITION_FIELD_NUMBER = 3; - private com.google.privacy.dlp.v2beta1.RecordCondition condition_; - /** - *
-   * Only apply the transformation if the condition evaluates to true for the
-   * given `RecordCondition`. The conditions are allowed to reference fields
-   * that are not used in the actual transformation. [optional]
-   * Example Use Cases:
-   * - Apply a different bucket transformation to an age column if the zip code
-   * column for the same record is within a specific range.
-   * - Redact a field if the date of birth field is greater than 85.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public boolean hasCondition() { - return condition_ != null; - } - /** - *
-   * Only apply the transformation if the condition evaluates to true for the
-   * given `RecordCondition`. The conditions are allowed to reference fields
-   * that are not used in the actual transformation. [optional]
-   * Example Use Cases:
-   * - Apply a different bucket transformation to an age column if the zip code
-   * column for the same record is within a specific range.
-   * - Redact a field if the date of birth field is greater than 85.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition getCondition() { - return condition_ == null ? com.google.privacy.dlp.v2beta1.RecordCondition.getDefaultInstance() : condition_; - } - /** - *
-   * Only apply the transformation if the condition evaluates to true for the
-   * given `RecordCondition`. The conditions are allowed to reference fields
-   * that are not used in the actual transformation. [optional]
-   * Example Use Cases:
-   * - Apply a different bucket transformation to an age column if the zip code
-   * column for the same record is within a specific range.
-   * - Redact a field if the date of birth field is greater than 85.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder getConditionOrBuilder() { - return getCondition(); - } - - public static final int PRIMITIVE_TRANSFORMATION_FIELD_NUMBER = 4; - /** - *
-   * Apply the transformation to the entire field.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public boolean hasPrimitiveTransformation() { - return transformationCase_ == 4; - } - /** - *
-   * Apply the transformation to the entire field.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation getPrimitiveTransformation() { - if (transformationCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.PrimitiveTransformation) transformation_; - } - return com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance(); - } - /** - *
-   * Apply the transformation to the entire field.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder getPrimitiveTransformationOrBuilder() { - if (transformationCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.PrimitiveTransformation) transformation_; - } - return com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance(); - } - - public static final int INFO_TYPE_TRANSFORMATIONS_FIELD_NUMBER = 5; - /** - *
-   * Treat the contents of the field as free text, and selectively
-   * transform content that matches an `InfoType`.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public boolean hasInfoTypeTransformations() { - return transformationCase_ == 5; - } - /** - *
-   * Treat the contents of the field as free text, and selectively
-   * transform content that matches an `InfoType`.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations getInfoTypeTransformations() { - if (transformationCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - /** - *
-   * Treat the contents of the field as free text, and selectively
-   * transform content that matches an `InfoType`.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder getInfoTypeTransformationsOrBuilder() { - if (transformationCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < fields_.size(); i++) { - output.writeMessage(1, fields_.get(i)); - } - if (condition_ != null) { - output.writeMessage(3, getCondition()); - } - if (transformationCase_ == 4) { - output.writeMessage(4, (com.google.privacy.dlp.v2beta1.PrimitiveTransformation) transformation_); - } - if (transformationCase_ == 5) { - output.writeMessage(5, (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < fields_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, fields_.get(i)); - } - if (condition_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, getCondition()); - } - if (transformationCase_ == 4) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, (com.google.privacy.dlp.v2beta1.PrimitiveTransformation) transformation_); - } - if (transformationCase_ == 5) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_); - } - 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.privacy.dlp.v2beta1.FieldTransformation)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.FieldTransformation other = (com.google.privacy.dlp.v2beta1.FieldTransformation) obj; - - boolean result = true; - result = result && getFieldsList() - .equals(other.getFieldsList()); - result = result && (hasCondition() == other.hasCondition()); - if (hasCondition()) { - result = result && getCondition() - .equals(other.getCondition()); - } - result = result && getTransformationCase().equals( - other.getTransformationCase()); - if (!result) return false; - switch (transformationCase_) { - case 4: - result = result && getPrimitiveTransformation() - .equals(other.getPrimitiveTransformation()); - break; - case 5: - result = result && getInfoTypeTransformations() - .equals(other.getInfoTypeTransformations()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @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(); - } - if (hasCondition()) { - hash = (37 * hash) + CONDITION_FIELD_NUMBER; - hash = (53 * hash) + getCondition().hashCode(); - } - switch (transformationCase_) { - case 4: - hash = (37 * hash) + PRIMITIVE_TRANSFORMATION_FIELD_NUMBER; - hash = (53 * hash) + getPrimitiveTransformation().hashCode(); - break; - case 5: - hash = (37 * hash) + INFO_TYPE_TRANSFORMATIONS_FIELD_NUMBER; - hash = (53 * hash) + getInfoTypeTransformations().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.FieldTransformation parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.FieldTransformation parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.FieldTransformation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.FieldTransformation 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.privacy.dlp.v2beta1.FieldTransformation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.FieldTransformation parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.FieldTransformation parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.FieldTransformation 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.privacy.dlp.v2beta1.FieldTransformation parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.FieldTransformation 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.privacy.dlp.v2beta1.FieldTransformation parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.FieldTransformation parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.FieldTransformation prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * The transformation to apply to the field.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.FieldTransformation} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.FieldTransformation) - com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_FieldTransformation_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_FieldTransformation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.FieldTransformation.class, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.FieldTransformation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getFieldsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (fieldsBuilder_ == null) { - fields_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - fieldsBuilder_.clear(); - } - if (conditionBuilder_ == null) { - condition_ = null; - } else { - condition_ = null; - conditionBuilder_ = null; - } - transformationCase_ = 0; - transformation_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_FieldTransformation_descriptor; - } - - public com.google.privacy.dlp.v2beta1.FieldTransformation getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.FieldTransformation.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.FieldTransformation build() { - com.google.privacy.dlp.v2beta1.FieldTransformation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.FieldTransformation buildPartial() { - com.google.privacy.dlp.v2beta1.FieldTransformation result = new com.google.privacy.dlp.v2beta1.FieldTransformation(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (fieldsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - fields_ = java.util.Collections.unmodifiableList(fields_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.fields_ = fields_; - } else { - result.fields_ = fieldsBuilder_.build(); - } - if (conditionBuilder_ == null) { - result.condition_ = condition_; - } else { - result.condition_ = conditionBuilder_.build(); - } - if (transformationCase_ == 4) { - if (primitiveTransformationBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = primitiveTransformationBuilder_.build(); - } - } - if (transformationCase_ == 5) { - if (infoTypeTransformationsBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = infoTypeTransformationsBuilder_.build(); - } - } - result.bitField0_ = to_bitField0_; - result.transformationCase_ = transformationCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.FieldTransformation) { - return mergeFrom((com.google.privacy.dlp.v2beta1.FieldTransformation)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.FieldTransformation other) { - if (other == com.google.privacy.dlp.v2beta1.FieldTransformation.getDefaultInstance()) return this; - if (fieldsBuilder_ == null) { - if (!other.fields_.isEmpty()) { - if (fields_.isEmpty()) { - fields_ = other.fields_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureFieldsIsMutable(); - fields_.addAll(other.fields_); - } - onChanged(); - } - } else { - if (!other.fields_.isEmpty()) { - if (fieldsBuilder_.isEmpty()) { - fieldsBuilder_.dispose(); - fieldsBuilder_ = null; - fields_ = other.fields_; - bitField0_ = (bitField0_ & ~0x00000001); - fieldsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getFieldsFieldBuilder() : null; - } else { - fieldsBuilder_.addAllMessages(other.fields_); - } - } - } - if (other.hasCondition()) { - mergeCondition(other.getCondition()); - } - switch (other.getTransformationCase()) { - case PRIMITIVE_TRANSFORMATION: { - mergePrimitiveTransformation(other.getPrimitiveTransformation()); - break; - } - case INFO_TYPE_TRANSFORMATIONS: { - mergeInfoTypeTransformations(other.getInfoTypeTransformations()); - break; - } - case TRANSFORMATION_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.FieldTransformation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.FieldTransformation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int transformationCase_ = 0; - private java.lang.Object transformation_; - public TransformationCase - getTransformationCase() { - return TransformationCase.forNumber( - transformationCase_); - } - - public Builder clearTransformation() { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - return this; - } - - private int bitField0_; - - private java.util.List fields_ = - java.util.Collections.emptyList(); - private void ensureFieldsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - fields_ = new java.util.ArrayList(fields_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> fieldsBuilder_; - - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public java.util.List getFieldsList() { - if (fieldsBuilder_ == null) { - return java.util.Collections.unmodifiableList(fields_); - } else { - return fieldsBuilder_.getMessageList(); - } - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public int getFieldsCount() { - if (fieldsBuilder_ == null) { - return fields_.size(); - } else { - return fieldsBuilder_.getCount(); - } - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getFields(int index) { - if (fieldsBuilder_ == null) { - return fields_.get(index); - } else { - return fieldsBuilder_.getMessage(index); - } - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public Builder setFields( - int index, com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldsIsMutable(); - fields_.set(index, value); - onChanged(); - } else { - fieldsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public Builder setFields( - int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (fieldsBuilder_ == null) { - ensureFieldsIsMutable(); - fields_.set(index, builderForValue.build()); - onChanged(); - } else { - fieldsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public Builder addFields(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldsIsMutable(); - fields_.add(value); - onChanged(); - } else { - fieldsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public Builder addFields( - int index, com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldsIsMutable(); - fields_.add(index, value); - onChanged(); - } else { - fieldsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public Builder addFields( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (fieldsBuilder_ == null) { - ensureFieldsIsMutable(); - fields_.add(builderForValue.build()); - onChanged(); - } else { - fieldsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public Builder addFields( - int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (fieldsBuilder_ == null) { - ensureFieldsIsMutable(); - fields_.add(index, builderForValue.build()); - onChanged(); - } else { - fieldsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public Builder addAllFields( - java.lang.Iterable values) { - if (fieldsBuilder_ == null) { - ensureFieldsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, fields_); - onChanged(); - } else { - fieldsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public Builder clearFields() { - if (fieldsBuilder_ == null) { - fields_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - fieldsBuilder_.clear(); - } - return this; - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public Builder removeFields(int index) { - if (fieldsBuilder_ == null) { - ensureFieldsIsMutable(); - fields_.remove(index); - onChanged(); - } else { - fieldsBuilder_.remove(index); - } - return this; - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getFieldsBuilder( - int index) { - return getFieldsFieldBuilder().getBuilder(index); - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldsOrBuilder( - int index) { - if (fieldsBuilder_ == null) { - return fields_.get(index); } else { - return fieldsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public java.util.List - getFieldsOrBuilderList() { - if (fieldsBuilder_ != null) { - return fieldsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(fields_); - } - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder addFieldsBuilder() { - return getFieldsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()); - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder addFieldsBuilder( - int index) { - return getFieldsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()); - } - /** - *
-     * Input field(s) to apply the transformation to. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - public java.util.List - getFieldsBuilderList() { - return getFieldsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getFieldsFieldBuilder() { - if (fieldsBuilder_ == null) { - fieldsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - fields_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - fields_ = null; - } - return fieldsBuilder_; - } - - private com.google.privacy.dlp.v2beta1.RecordCondition condition_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition, com.google.privacy.dlp.v2beta1.RecordCondition.Builder, com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder> conditionBuilder_; - /** - *
-     * Only apply the transformation if the condition evaluates to true for the
-     * given `RecordCondition`. The conditions are allowed to reference fields
-     * that are not used in the actual transformation. [optional]
-     * Example Use Cases:
-     * - Apply a different bucket transformation to an age column if the zip code
-     * column for the same record is within a specific range.
-     * - Redact a field if the date of birth field is greater than 85.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public boolean hasCondition() { - return conditionBuilder_ != null || condition_ != null; - } - /** - *
-     * Only apply the transformation if the condition evaluates to true for the
-     * given `RecordCondition`. The conditions are allowed to reference fields
-     * that are not used in the actual transformation. [optional]
-     * Example Use Cases:
-     * - Apply a different bucket transformation to an age column if the zip code
-     * column for the same record is within a specific range.
-     * - Redact a field if the date of birth field is greater than 85.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition getCondition() { - if (conditionBuilder_ == null) { - return condition_ == null ? com.google.privacy.dlp.v2beta1.RecordCondition.getDefaultInstance() : condition_; - } else { - return conditionBuilder_.getMessage(); - } - } - /** - *
-     * Only apply the transformation if the condition evaluates to true for the
-     * given `RecordCondition`. The conditions are allowed to reference fields
-     * that are not used in the actual transformation. [optional]
-     * Example Use Cases:
-     * - Apply a different bucket transformation to an age column if the zip code
-     * column for the same record is within a specific range.
-     * - Redact a field if the date of birth field is greater than 85.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public Builder setCondition(com.google.privacy.dlp.v2beta1.RecordCondition value) { - if (conditionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - condition_ = value; - onChanged(); - } else { - conditionBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Only apply the transformation if the condition evaluates to true for the
-     * given `RecordCondition`. The conditions are allowed to reference fields
-     * that are not used in the actual transformation. [optional]
-     * Example Use Cases:
-     * - Apply a different bucket transformation to an age column if the zip code
-     * column for the same record is within a specific range.
-     * - Redact a field if the date of birth field is greater than 85.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public Builder setCondition( - com.google.privacy.dlp.v2beta1.RecordCondition.Builder builderForValue) { - if (conditionBuilder_ == null) { - condition_ = builderForValue.build(); - onChanged(); - } else { - conditionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Only apply the transformation if the condition evaluates to true for the
-     * given `RecordCondition`. The conditions are allowed to reference fields
-     * that are not used in the actual transformation. [optional]
-     * Example Use Cases:
-     * - Apply a different bucket transformation to an age column if the zip code
-     * column for the same record is within a specific range.
-     * - Redact a field if the date of birth field is greater than 85.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public Builder mergeCondition(com.google.privacy.dlp.v2beta1.RecordCondition value) { - if (conditionBuilder_ == null) { - if (condition_ != null) { - condition_ = - com.google.privacy.dlp.v2beta1.RecordCondition.newBuilder(condition_).mergeFrom(value).buildPartial(); - } else { - condition_ = value; - } - onChanged(); - } else { - conditionBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Only apply the transformation if the condition evaluates to true for the
-     * given `RecordCondition`. The conditions are allowed to reference fields
-     * that are not used in the actual transformation. [optional]
-     * Example Use Cases:
-     * - Apply a different bucket transformation to an age column if the zip code
-     * column for the same record is within a specific range.
-     * - Redact a field if the date of birth field is greater than 85.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public Builder clearCondition() { - if (conditionBuilder_ == null) { - condition_ = null; - onChanged(); - } else { - condition_ = null; - conditionBuilder_ = null; - } - - return this; - } - /** - *
-     * Only apply the transformation if the condition evaluates to true for the
-     * given `RecordCondition`. The conditions are allowed to reference fields
-     * that are not used in the actual transformation. [optional]
-     * Example Use Cases:
-     * - Apply a different bucket transformation to an age column if the zip code
-     * column for the same record is within a specific range.
-     * - Redact a field if the date of birth field is greater than 85.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Builder getConditionBuilder() { - - onChanged(); - return getConditionFieldBuilder().getBuilder(); - } - /** - *
-     * Only apply the transformation if the condition evaluates to true for the
-     * given `RecordCondition`. The conditions are allowed to reference fields
-     * that are not used in the actual transformation. [optional]
-     * Example Use Cases:
-     * - Apply a different bucket transformation to an age column if the zip code
-     * column for the same record is within a specific range.
-     * - Redact a field if the date of birth field is greater than 85.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder getConditionOrBuilder() { - if (conditionBuilder_ != null) { - return conditionBuilder_.getMessageOrBuilder(); - } else { - return condition_ == null ? - com.google.privacy.dlp.v2beta1.RecordCondition.getDefaultInstance() : condition_; - } - } - /** - *
-     * Only apply the transformation if the condition evaluates to true for the
-     * given `RecordCondition`. The conditions are allowed to reference fields
-     * that are not used in the actual transformation. [optional]
-     * Example Use Cases:
-     * - Apply a different bucket transformation to an age column if the zip code
-     * column for the same record is within a specific range.
-     * - Redact a field if the date of birth field is greater than 85.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition, com.google.privacy.dlp.v2beta1.RecordCondition.Builder, com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder> - getConditionFieldBuilder() { - if (conditionBuilder_ == null) { - conditionBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition, com.google.privacy.dlp.v2beta1.RecordCondition.Builder, com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder>( - getCondition(), - getParentForChildren(), - isClean()); - condition_ = null; - } - return conditionBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrimitiveTransformation, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder, com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder> primitiveTransformationBuilder_; - /** - *
-     * Apply the transformation to the entire field.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public boolean hasPrimitiveTransformation() { - return transformationCase_ == 4; - } - /** - *
-     * Apply the transformation to the entire field.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation getPrimitiveTransformation() { - if (primitiveTransformationBuilder_ == null) { - if (transformationCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.PrimitiveTransformation) transformation_; - } - return com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance(); - } else { - if (transformationCase_ == 4) { - return primitiveTransformationBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance(); - } - } - /** - *
-     * Apply the transformation to the entire field.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public Builder setPrimitiveTransformation(com.google.privacy.dlp.v2beta1.PrimitiveTransformation value) { - if (primitiveTransformationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - primitiveTransformationBuilder_.setMessage(value); - } - transformationCase_ = 4; - return this; - } - /** - *
-     * Apply the transformation to the entire field.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public Builder setPrimitiveTransformation( - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder builderForValue) { - if (primitiveTransformationBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - primitiveTransformationBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 4; - return this; - } - /** - *
-     * Apply the transformation to the entire field.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public Builder mergePrimitiveTransformation(com.google.privacy.dlp.v2beta1.PrimitiveTransformation value) { - if (primitiveTransformationBuilder_ == null) { - if (transformationCase_ == 4 && - transformation_ != com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.PrimitiveTransformation.newBuilder((com.google.privacy.dlp.v2beta1.PrimitiveTransformation) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 4) { - primitiveTransformationBuilder_.mergeFrom(value); - } - primitiveTransformationBuilder_.setMessage(value); - } - transformationCase_ = 4; - return this; - } - /** - *
-     * Apply the transformation to the entire field.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public Builder clearPrimitiveTransformation() { - if (primitiveTransformationBuilder_ == null) { - if (transformationCase_ == 4) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 4) { - transformationCase_ = 0; - transformation_ = null; - } - primitiveTransformationBuilder_.clear(); - } - return this; - } - /** - *
-     * Apply the transformation to the entire field.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder getPrimitiveTransformationBuilder() { - return getPrimitiveTransformationFieldBuilder().getBuilder(); - } - /** - *
-     * Apply the transformation to the entire field.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder getPrimitiveTransformationOrBuilder() { - if ((transformationCase_ == 4) && (primitiveTransformationBuilder_ != null)) { - return primitiveTransformationBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.PrimitiveTransformation) transformation_; - } - return com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance(); - } - } - /** - *
-     * Apply the transformation to the entire field.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrimitiveTransformation, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder, com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder> - getPrimitiveTransformationFieldBuilder() { - if (primitiveTransformationBuilder_ == null) { - if (!(transformationCase_ == 4)) { - transformation_ = com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance(); - } - primitiveTransformationBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrimitiveTransformation, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder, com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder>( - (com.google.privacy.dlp.v2beta1.PrimitiveTransformation) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 4; - onChanged();; - return primitiveTransformationBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeTransformations, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder, com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder> infoTypeTransformationsBuilder_; - /** - *
-     * Treat the contents of the field as free text, and selectively
-     * transform content that matches an `InfoType`.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public boolean hasInfoTypeTransformations() { - return transformationCase_ == 5; - } - /** - *
-     * Treat the contents of the field as free text, and selectively
-     * transform content that matches an `InfoType`.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations getInfoTypeTransformations() { - if (infoTypeTransformationsBuilder_ == null) { - if (transformationCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } else { - if (transformationCase_ == 5) { - return infoTypeTransformationsBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - } - /** - *
-     * Treat the contents of the field as free text, and selectively
-     * transform content that matches an `InfoType`.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public Builder setInfoTypeTransformations(com.google.privacy.dlp.v2beta1.InfoTypeTransformations value) { - if (infoTypeTransformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - infoTypeTransformationsBuilder_.setMessage(value); - } - transformationCase_ = 5; - return this; - } - /** - *
-     * Treat the contents of the field as free text, and selectively
-     * transform content that matches an `InfoType`.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public Builder setInfoTypeTransformations( - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder builderForValue) { - if (infoTypeTransformationsBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - infoTypeTransformationsBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 5; - return this; - } - /** - *
-     * Treat the contents of the field as free text, and selectively
-     * transform content that matches an `InfoType`.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public Builder mergeInfoTypeTransformations(com.google.privacy.dlp.v2beta1.InfoTypeTransformations value) { - if (infoTypeTransformationsBuilder_ == null) { - if (transformationCase_ == 5 && - transformation_ != com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.InfoTypeTransformations.newBuilder((com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 5) { - infoTypeTransformationsBuilder_.mergeFrom(value); - } - infoTypeTransformationsBuilder_.setMessage(value); - } - transformationCase_ = 5; - return this; - } - /** - *
-     * Treat the contents of the field as free text, and selectively
-     * transform content that matches an `InfoType`.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public Builder clearInfoTypeTransformations() { - if (infoTypeTransformationsBuilder_ == null) { - if (transformationCase_ == 5) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 5) { - transformationCase_ = 0; - transformation_ = null; - } - infoTypeTransformationsBuilder_.clear(); - } - return this; - } - /** - *
-     * Treat the contents of the field as free text, and selectively
-     * transform content that matches an `InfoType`.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder getInfoTypeTransformationsBuilder() { - return getInfoTypeTransformationsFieldBuilder().getBuilder(); - } - /** - *
-     * Treat the contents of the field as free text, and selectively
-     * transform content that matches an `InfoType`.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder getInfoTypeTransformationsOrBuilder() { - if ((transformationCase_ == 5) && (infoTypeTransformationsBuilder_ != null)) { - return infoTypeTransformationsBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_; - } - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - } - /** - *
-     * Treat the contents of the field as free text, and selectively
-     * transform content that matches an `InfoType`.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeTransformations, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder, com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder> - getInfoTypeTransformationsFieldBuilder() { - if (infoTypeTransformationsBuilder_ == null) { - if (!(transformationCase_ == 5)) { - transformation_ = com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - infoTypeTransformationsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeTransformations, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder, com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder>( - (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 5; - onChanged();; - return infoTypeTransformationsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.FieldTransformation) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.FieldTransformation) - private static final com.google.privacy.dlp.v2beta1.FieldTransformation DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.FieldTransformation(); - } - - public static com.google.privacy.dlp.v2beta1.FieldTransformation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public FieldTransformation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new FieldTransformation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.FieldTransformation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldTransformationOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldTransformationOrBuilder.java deleted file mode 100644 index f1cdd232c69f..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldTransformationOrBuilder.java +++ /dev/null @@ -1,151 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface FieldTransformationOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.FieldTransformation) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Input field(s) to apply the transformation to. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - java.util.List - getFieldsList(); - /** - *
-   * Input field(s) to apply the transformation to. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - com.google.privacy.dlp.v2beta1.FieldId getFields(int index); - /** - *
-   * Input field(s) to apply the transformation to. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - int getFieldsCount(); - /** - *
-   * Input field(s) to apply the transformation to. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - java.util.List - getFieldsOrBuilderList(); - /** - *
-   * Input field(s) to apply the transformation to. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId fields = 1; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldsOrBuilder( - int index); - - /** - *
-   * Only apply the transformation if the condition evaluates to true for the
-   * given `RecordCondition`. The conditions are allowed to reference fields
-   * that are not used in the actual transformation. [optional]
-   * Example Use Cases:
-   * - Apply a different bucket transformation to an age column if the zip code
-   * column for the same record is within a specific range.
-   * - Redact a field if the date of birth field is greater than 85.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - boolean hasCondition(); - /** - *
-   * Only apply the transformation if the condition evaluates to true for the
-   * given `RecordCondition`. The conditions are allowed to reference fields
-   * that are not used in the actual transformation. [optional]
-   * Example Use Cases:
-   * - Apply a different bucket transformation to an age column if the zip code
-   * column for the same record is within a specific range.
-   * - Redact a field if the date of birth field is greater than 85.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - com.google.privacy.dlp.v2beta1.RecordCondition getCondition(); - /** - *
-   * Only apply the transformation if the condition evaluates to true for the
-   * given `RecordCondition`. The conditions are allowed to reference fields
-   * that are not used in the actual transformation. [optional]
-   * Example Use Cases:
-   * - Apply a different bucket transformation to an age column if the zip code
-   * column for the same record is within a specific range.
-   * - Redact a field if the date of birth field is greater than 85.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition condition = 3; - */ - com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder getConditionOrBuilder(); - - /** - *
-   * Apply the transformation to the entire field.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - boolean hasPrimitiveTransformation(); - /** - *
-   * Apply the transformation to the entire field.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - com.google.privacy.dlp.v2beta1.PrimitiveTransformation getPrimitiveTransformation(); - /** - *
-   * Apply the transformation to the entire field.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 4; - */ - com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder getPrimitiveTransformationOrBuilder(); - - /** - *
-   * Treat the contents of the field as free text, and selectively
-   * transform content that matches an `InfoType`.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - boolean hasInfoTypeTransformations(); - /** - *
-   * Treat the contents of the field as free text, and selectively
-   * transform content that matches an `InfoType`.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - com.google.privacy.dlp.v2beta1.InfoTypeTransformations getInfoTypeTransformations(); - /** - *
-   * Treat the contents of the field as free text, and selectively
-   * transform content that matches an `InfoType`.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoTypeTransformations info_type_transformations = 5; - */ - com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder getInfoTypeTransformationsOrBuilder(); - - public com.google.privacy.dlp.v2beta1.FieldTransformation.TransformationCase getTransformationCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Finding.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Finding.java deleted file mode 100644 index 0990cc73563e..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Finding.java +++ /dev/null @@ -1,1350 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Container structure describing a single finding within a string or image.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Finding} - */ -public final class Finding extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.Finding) - FindingOrBuilder { -private static final long serialVersionUID = 0L; - // Use Finding.newBuilder() to construct. - private Finding(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Finding() { - quote_ = ""; - likelihood_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Finding( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - quote_ = s; - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.InfoType.Builder subBuilder = null; - if (infoType_ != null) { - subBuilder = infoType_.toBuilder(); - } - infoType_ = input.readMessage(com.google.privacy.dlp.v2beta1.InfoType.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(infoType_); - infoType_ = subBuilder.buildPartial(); - } - - break; - } - case 24: { - int rawValue = input.readEnum(); - - likelihood_ = rawValue; - break; - } - case 34: { - com.google.privacy.dlp.v2beta1.Location.Builder subBuilder = null; - if (location_ != null) { - subBuilder = location_.toBuilder(); - } - location_ = input.readMessage(com.google.privacy.dlp.v2beta1.Location.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(location_); - location_ = 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; - } - } - } - } 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Finding_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Finding_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Finding.class, com.google.privacy.dlp.v2beta1.Finding.Builder.class); - } - - public static final int QUOTE_FIELD_NUMBER = 1; - private volatile java.lang.Object quote_; - /** - *
-   * The specific string that may be potentially sensitive info.
-   * 
- * - * string quote = 1; - */ - public java.lang.String getQuote() { - java.lang.Object ref = quote_; - 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(); - quote_ = s; - return s; - } - } - /** - *
-   * The specific string that may be potentially sensitive info.
-   * 
- * - * string quote = 1; - */ - public com.google.protobuf.ByteString - getQuoteBytes() { - java.lang.Object ref = quote_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - quote_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int INFO_TYPE_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.InfoType infoType_; - /** - *
-   * The specific type of info the string might be.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public boolean hasInfoType() { - return infoType_ != null; - } - /** - *
-   * The specific type of info the string might be.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - /** - *
-   * The specific type of info the string might be.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - return getInfoType(); - } - - public static final int LIKELIHOOD_FIELD_NUMBER = 3; - private int likelihood_; - /** - *
-   * Estimate of how likely it is that the info_type is correct.
-   * 
- * - * .google.privacy.dlp.v2beta1.Likelihood likelihood = 3; - */ - public int getLikelihoodValue() { - return likelihood_; - } - /** - *
-   * Estimate of how likely it is that the info_type is correct.
-   * 
- * - * .google.privacy.dlp.v2beta1.Likelihood likelihood = 3; - */ - public com.google.privacy.dlp.v2beta1.Likelihood getLikelihood() { - com.google.privacy.dlp.v2beta1.Likelihood result = com.google.privacy.dlp.v2beta1.Likelihood.valueOf(likelihood_); - return result == null ? com.google.privacy.dlp.v2beta1.Likelihood.UNRECOGNIZED : result; - } - - public static final int LOCATION_FIELD_NUMBER = 4; - private com.google.privacy.dlp.v2beta1.Location location_; - /** - *
-   * Location of the info found.
-   * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public boolean hasLocation() { - return location_ != null; - } - /** - *
-   * Location of the info found.
-   * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public com.google.privacy.dlp.v2beta1.Location getLocation() { - return location_ == null ? com.google.privacy.dlp.v2beta1.Location.getDefaultInstance() : location_; - } - /** - *
-   * Location of the info found.
-   * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public com.google.privacy.dlp.v2beta1.LocationOrBuilder getLocationOrBuilder() { - return getLocation(); - } - - public static final int CREATE_TIME_FIELD_NUMBER = 6; - private com.google.protobuf.Timestamp createTime_; - /** - *
-   * Timestamp when finding was detected.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - *
-   * Timestamp when finding was detected.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - *
-   * Timestamp when finding was detected.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getQuoteBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, quote_); - } - if (infoType_ != null) { - output.writeMessage(2, getInfoType()); - } - if (likelihood_ != com.google.privacy.dlp.v2beta1.Likelihood.LIKELIHOOD_UNSPECIFIED.getNumber()) { - output.writeEnum(3, likelihood_); - } - if (location_ != null) { - output.writeMessage(4, getLocation()); - } - if (createTime_ != null) { - output.writeMessage(6, getCreateTime()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getQuoteBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, quote_); - } - if (infoType_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getInfoType()); - } - if (likelihood_ != com.google.privacy.dlp.v2beta1.Likelihood.LIKELIHOOD_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(3, likelihood_); - } - if (location_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, getLocation()); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, getCreateTime()); - } - 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.privacy.dlp.v2beta1.Finding)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.Finding other = (com.google.privacy.dlp.v2beta1.Finding) obj; - - boolean result = true; - result = result && getQuote() - .equals(other.getQuote()); - result = result && (hasInfoType() == other.hasInfoType()); - if (hasInfoType()) { - result = result && getInfoType() - .equals(other.getInfoType()); - } - result = result && likelihood_ == other.likelihood_; - result = result && (hasLocation() == other.hasLocation()); - if (hasLocation()) { - result = result && getLocation() - .equals(other.getLocation()); - } - result = result && (hasCreateTime() == other.hasCreateTime()); - if (hasCreateTime()) { - result = result && getCreateTime() - .equals(other.getCreateTime()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + QUOTE_FIELD_NUMBER; - hash = (53 * hash) + getQuote().hashCode(); - if (hasInfoType()) { - hash = (37 * hash) + INFO_TYPE_FIELD_NUMBER; - hash = (53 * hash) + getInfoType().hashCode(); - } - hash = (37 * hash) + LIKELIHOOD_FIELD_NUMBER; - hash = (53 * hash) + likelihood_; - if (hasLocation()) { - hash = (37 * hash) + LOCATION_FIELD_NUMBER; - hash = (53 * hash) + getLocation().hashCode(); - } - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.Finding parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Finding parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Finding parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Finding 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.privacy.dlp.v2beta1.Finding parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Finding parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Finding parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Finding 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.privacy.dlp.v2beta1.Finding parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Finding 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.privacy.dlp.v2beta1.Finding parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Finding parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.Finding prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Container structure describing a single finding within a string or image.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Finding} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.Finding) - com.google.privacy.dlp.v2beta1.FindingOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Finding_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Finding_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Finding.class, com.google.privacy.dlp.v2beta1.Finding.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.Finding.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - quote_ = ""; - - if (infoTypeBuilder_ == null) { - infoType_ = null; - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - likelihood_ = 0; - - if (locationBuilder_ == null) { - location_ = null; - } else { - location_ = null; - locationBuilder_ = null; - } - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Finding_descriptor; - } - - public com.google.privacy.dlp.v2beta1.Finding getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.Finding.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.Finding build() { - com.google.privacy.dlp.v2beta1.Finding result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.Finding buildPartial() { - com.google.privacy.dlp.v2beta1.Finding result = new com.google.privacy.dlp.v2beta1.Finding(this); - result.quote_ = quote_; - if (infoTypeBuilder_ == null) { - result.infoType_ = infoType_; - } else { - result.infoType_ = infoTypeBuilder_.build(); - } - result.likelihood_ = likelihood_; - if (locationBuilder_ == null) { - result.location_ = location_; - } else { - result.location_ = locationBuilder_.build(); - } - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.Finding) { - return mergeFrom((com.google.privacy.dlp.v2beta1.Finding)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.Finding other) { - if (other == com.google.privacy.dlp.v2beta1.Finding.getDefaultInstance()) return this; - if (!other.getQuote().isEmpty()) { - quote_ = other.quote_; - onChanged(); - } - if (other.hasInfoType()) { - mergeInfoType(other.getInfoType()); - } - if (other.likelihood_ != 0) { - setLikelihoodValue(other.getLikelihoodValue()); - } - if (other.hasLocation()) { - mergeLocation(other.getLocation()); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.Finding parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.Finding) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object quote_ = ""; - /** - *
-     * The specific string that may be potentially sensitive info.
-     * 
- * - * string quote = 1; - */ - public java.lang.String getQuote() { - java.lang.Object ref = quote_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - quote_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * The specific string that may be potentially sensitive info.
-     * 
- * - * string quote = 1; - */ - public com.google.protobuf.ByteString - getQuoteBytes() { - java.lang.Object ref = quote_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - quote_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * The specific string that may be potentially sensitive info.
-     * 
- * - * string quote = 1; - */ - public Builder setQuote( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - quote_ = value; - onChanged(); - return this; - } - /** - *
-     * The specific string that may be potentially sensitive info.
-     * 
- * - * string quote = 1; - */ - public Builder clearQuote() { - - quote_ = getDefaultInstance().getQuote(); - onChanged(); - return this; - } - /** - *
-     * The specific string that may be potentially sensitive info.
-     * 
- * - * string quote = 1; - */ - public Builder setQuoteBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - quote_ = value; - onChanged(); - return this; - } - - private com.google.privacy.dlp.v2beta1.InfoType infoType_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> infoTypeBuilder_; - /** - *
-     * The specific type of info the string might be.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public boolean hasInfoType() { - return infoTypeBuilder_ != null || infoType_ != null; - } - /** - *
-     * The specific type of info the string might be.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - if (infoTypeBuilder_ == null) { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } else { - return infoTypeBuilder_.getMessage(); - } - } - /** - *
-     * The specific type of info the string might be.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public Builder setInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - infoType_ = value; - onChanged(); - } else { - infoTypeBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The specific type of info the string might be.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public Builder setInfoType( - com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypeBuilder_ == null) { - infoType_ = builderForValue.build(); - onChanged(); - } else { - infoTypeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The specific type of info the string might be.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public Builder mergeInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (infoType_ != null) { - infoType_ = - com.google.privacy.dlp.v2beta1.InfoType.newBuilder(infoType_).mergeFrom(value).buildPartial(); - } else { - infoType_ = value; - } - onChanged(); - } else { - infoTypeBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The specific type of info the string might be.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public Builder clearInfoType() { - if (infoTypeBuilder_ == null) { - infoType_ = null; - onChanged(); - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - - return this; - } - /** - *
-     * The specific type of info the string might be.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder getInfoTypeBuilder() { - - onChanged(); - return getInfoTypeFieldBuilder().getBuilder(); - } - /** - *
-     * The specific type of info the string might be.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - if (infoTypeBuilder_ != null) { - return infoTypeBuilder_.getMessageOrBuilder(); - } else { - return infoType_ == null ? - com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - } - /** - *
-     * The specific type of info the string might be.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> - getInfoTypeFieldBuilder() { - if (infoTypeBuilder_ == null) { - infoTypeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder>( - getInfoType(), - getParentForChildren(), - isClean()); - infoType_ = null; - } - return infoTypeBuilder_; - } - - private int likelihood_ = 0; - /** - *
-     * Estimate of how likely it is that the info_type is correct.
-     * 
- * - * .google.privacy.dlp.v2beta1.Likelihood likelihood = 3; - */ - public int getLikelihoodValue() { - return likelihood_; - } - /** - *
-     * Estimate of how likely it is that the info_type is correct.
-     * 
- * - * .google.privacy.dlp.v2beta1.Likelihood likelihood = 3; - */ - public Builder setLikelihoodValue(int value) { - likelihood_ = value; - onChanged(); - return this; - } - /** - *
-     * Estimate of how likely it is that the info_type is correct.
-     * 
- * - * .google.privacy.dlp.v2beta1.Likelihood likelihood = 3; - */ - public com.google.privacy.dlp.v2beta1.Likelihood getLikelihood() { - com.google.privacy.dlp.v2beta1.Likelihood result = com.google.privacy.dlp.v2beta1.Likelihood.valueOf(likelihood_); - return result == null ? com.google.privacy.dlp.v2beta1.Likelihood.UNRECOGNIZED : result; - } - /** - *
-     * Estimate of how likely it is that the info_type is correct.
-     * 
- * - * .google.privacy.dlp.v2beta1.Likelihood likelihood = 3; - */ - public Builder setLikelihood(com.google.privacy.dlp.v2beta1.Likelihood value) { - if (value == null) { - throw new NullPointerException(); - } - - likelihood_ = value.getNumber(); - onChanged(); - return this; - } - /** - *
-     * Estimate of how likely it is that the info_type is correct.
-     * 
- * - * .google.privacy.dlp.v2beta1.Likelihood likelihood = 3; - */ - public Builder clearLikelihood() { - - likelihood_ = 0; - onChanged(); - return this; - } - - private com.google.privacy.dlp.v2beta1.Location location_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Location, com.google.privacy.dlp.v2beta1.Location.Builder, com.google.privacy.dlp.v2beta1.LocationOrBuilder> locationBuilder_; - /** - *
-     * Location of the info found.
-     * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public boolean hasLocation() { - return locationBuilder_ != null || location_ != null; - } - /** - *
-     * Location of the info found.
-     * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public com.google.privacy.dlp.v2beta1.Location getLocation() { - if (locationBuilder_ == null) { - return location_ == null ? com.google.privacy.dlp.v2beta1.Location.getDefaultInstance() : location_; - } else { - return locationBuilder_.getMessage(); - } - } - /** - *
-     * Location of the info found.
-     * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public Builder setLocation(com.google.privacy.dlp.v2beta1.Location value) { - if (locationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - location_ = value; - onChanged(); - } else { - locationBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Location of the info found.
-     * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public Builder setLocation( - com.google.privacy.dlp.v2beta1.Location.Builder builderForValue) { - if (locationBuilder_ == null) { - location_ = builderForValue.build(); - onChanged(); - } else { - locationBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Location of the info found.
-     * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public Builder mergeLocation(com.google.privacy.dlp.v2beta1.Location value) { - if (locationBuilder_ == null) { - if (location_ != null) { - location_ = - com.google.privacy.dlp.v2beta1.Location.newBuilder(location_).mergeFrom(value).buildPartial(); - } else { - location_ = value; - } - onChanged(); - } else { - locationBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Location of the info found.
-     * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public Builder clearLocation() { - if (locationBuilder_ == null) { - location_ = null; - onChanged(); - } else { - location_ = null; - locationBuilder_ = null; - } - - return this; - } - /** - *
-     * Location of the info found.
-     * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public com.google.privacy.dlp.v2beta1.Location.Builder getLocationBuilder() { - - onChanged(); - return getLocationFieldBuilder().getBuilder(); - } - /** - *
-     * Location of the info found.
-     * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - public com.google.privacy.dlp.v2beta1.LocationOrBuilder getLocationOrBuilder() { - if (locationBuilder_ != null) { - return locationBuilder_.getMessageOrBuilder(); - } else { - return location_ == null ? - com.google.privacy.dlp.v2beta1.Location.getDefaultInstance() : location_; - } - } - /** - *
-     * Location of the info found.
-     * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Location, com.google.privacy.dlp.v2beta1.Location.Builder, com.google.privacy.dlp.v2beta1.LocationOrBuilder> - getLocationFieldBuilder() { - if (locationBuilder_ == null) { - locationBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Location, com.google.privacy.dlp.v2beta1.Location.Builder, com.google.privacy.dlp.v2beta1.LocationOrBuilder>( - getLocation(), - getParentForChildren(), - isClean()); - location_ = null; - } - return locationBuilder_; - } - - private com.google.protobuf.Timestamp createTime_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; - /** - *
-     * Timestamp when finding was detected.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - *
-     * Timestamp when finding was detected.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - *
-     * Timestamp when finding was detected.
-     * 
- * - * .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; - } - /** - *
-     * Timestamp when finding was detected.
-     * 
- * - * .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; - } - /** - *
-     * Timestamp when finding was detected.
-     * 
- * - * .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; - } - /** - *
-     * Timestamp when finding was detected.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - *
-     * Timestamp when finding was detected.
-     * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - *
-     * Timestamp when finding was detected.
-     * 
- * - * .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_; - } - } - /** - *
-     * Timestamp when finding was detected.
-     * 
- * - * .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_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.Finding) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.Finding) - private static final com.google.privacy.dlp.v2beta1.Finding DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.Finding(); - } - - public static com.google.privacy.dlp.v2beta1.Finding getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Finding parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Finding(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.Finding getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FindingOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FindingOrBuilder.java deleted file mode 100644 index 12ea64f5dd10..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FindingOrBuilder.java +++ /dev/null @@ -1,119 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface FindingOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.Finding) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The specific string that may be potentially sensitive info.
-   * 
- * - * string quote = 1; - */ - java.lang.String getQuote(); - /** - *
-   * The specific string that may be potentially sensitive info.
-   * 
- * - * string quote = 1; - */ - com.google.protobuf.ByteString - getQuoteBytes(); - - /** - *
-   * The specific type of info the string might be.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - boolean hasInfoType(); - /** - *
-   * The specific type of info the string might be.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - com.google.privacy.dlp.v2beta1.InfoType getInfoType(); - /** - *
-   * The specific type of info the string might be.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 2; - */ - com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder(); - - /** - *
-   * Estimate of how likely it is that the info_type is correct.
-   * 
- * - * .google.privacy.dlp.v2beta1.Likelihood likelihood = 3; - */ - int getLikelihoodValue(); - /** - *
-   * Estimate of how likely it is that the info_type is correct.
-   * 
- * - * .google.privacy.dlp.v2beta1.Likelihood likelihood = 3; - */ - com.google.privacy.dlp.v2beta1.Likelihood getLikelihood(); - - /** - *
-   * Location of the info found.
-   * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - boolean hasLocation(); - /** - *
-   * Location of the info found.
-   * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - com.google.privacy.dlp.v2beta1.Location getLocation(); - /** - *
-   * Location of the info found.
-   * 
- * - * .google.privacy.dlp.v2beta1.Location location = 4; - */ - com.google.privacy.dlp.v2beta1.LocationOrBuilder getLocationOrBuilder(); - - /** - *
-   * Timestamp when finding was detected.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - boolean hasCreateTime(); - /** - *
-   * Timestamp when finding was detected.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - *
-   * Timestamp when finding was detected.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FixedSizeBucketingConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FixedSizeBucketingConfig.java deleted file mode 100644 index b6a5bee8bd3b..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FixedSizeBucketingConfig.java +++ /dev/null @@ -1,1022 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Buckets values based on fixed size ranges. The
- * Bucketing transformation can provide all of this functionality,
- * but requires more configuration. This message is provided as a convenience to
- * the user for simple bucketing strategies.
- * The resulting value will be a hyphenated string of
- * lower_bound-upper_bound.
- * This can be used on data of type: double, long.
- * If the bound Value type differs from the type of data
- * being transformed, we will first attempt converting the type of the data to
- * be transformed to match the type of the bound before comparing.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.FixedSizeBucketingConfig} - */ -public final class FixedSizeBucketingConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) - FixedSizeBucketingConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use FixedSizeBucketingConfig.newBuilder() to construct. - private FixedSizeBucketingConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private FixedSizeBucketingConfig() { - bucketSize_ = 0D; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private FixedSizeBucketingConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.Value.Builder subBuilder = null; - if (lowerBound_ != null) { - subBuilder = lowerBound_.toBuilder(); - } - lowerBound_ = input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(lowerBound_); - lowerBound_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.Value.Builder subBuilder = null; - if (upperBound_ != null) { - subBuilder = upperBound_.toBuilder(); - } - upperBound_ = input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(upperBound_); - upperBound_ = subBuilder.buildPartial(); - } - - break; - } - case 25: { - - bucketSize_ = input.readDouble(); - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_FixedSizeBucketingConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_FixedSizeBucketingConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.class, com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.Builder.class); - } - - public static final int LOWER_BOUND_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.Value lowerBound_; - /** - *
-   * Lower bound value of buckets. All values less than `lower_bound` are
-   * grouped together into a single bucket; for example if `lower_bound` = 10,
-   * then all values less than 10 are replaced with the value “-10”. [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public boolean hasLowerBound() { - return lowerBound_ != null; - } - /** - *
-   * Lower bound value of buckets. All values less than `lower_bound` are
-   * grouped together into a single bucket; for example if `lower_bound` = 10,
-   * then all values less than 10 are replaced with the value “-10”. [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getLowerBound() { - return lowerBound_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : lowerBound_; - } - /** - *
-   * Lower bound value of buckets. All values less than `lower_bound` are
-   * grouped together into a single bucket; for example if `lower_bound` = 10,
-   * then all values less than 10 are replaced with the value “-10”. [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getLowerBoundOrBuilder() { - return getLowerBound(); - } - - public static final int UPPER_BOUND_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.Value upperBound_; - /** - *
-   * Upper bound value of buckets. All values greater than upper_bound are
-   * grouped together into a single bucket; for example if `upper_bound` = 89,
-   * then all values greater than 89 are replaced with the value “89+”.
-   * [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public boolean hasUpperBound() { - return upperBound_ != null; - } - /** - *
-   * Upper bound value of buckets. All values greater than upper_bound are
-   * grouped together into a single bucket; for example if `upper_bound` = 89,
-   * then all values greater than 89 are replaced with the value “89+”.
-   * [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public com.google.privacy.dlp.v2beta1.Value getUpperBound() { - return upperBound_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : upperBound_; - } - /** - *
-   * Upper bound value of buckets. All values greater than upper_bound are
-   * grouped together into a single bucket; for example if `upper_bound` = 89,
-   * then all values greater than 89 are replaced with the value “89+”.
-   * [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getUpperBoundOrBuilder() { - return getUpperBound(); - } - - public static final int BUCKET_SIZE_FIELD_NUMBER = 3; - private double bucketSize_; - /** - *
-   * Size of each bucket (except for minimum and maximum buckets). So if
-   * `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the
-   * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60,
-   * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. [Required].
-   * 
- * - * double bucket_size = 3; - */ - public double getBucketSize() { - return bucketSize_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (lowerBound_ != null) { - output.writeMessage(1, getLowerBound()); - } - if (upperBound_ != null) { - output.writeMessage(2, getUpperBound()); - } - if (bucketSize_ != 0D) { - output.writeDouble(3, bucketSize_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (lowerBound_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getLowerBound()); - } - if (upperBound_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getUpperBound()); - } - if (bucketSize_ != 0D) { - size += com.google.protobuf.CodedOutputStream - .computeDoubleSize(3, bucketSize_); - } - 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.privacy.dlp.v2beta1.FixedSizeBucketingConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig other = (com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) obj; - - boolean result = true; - result = result && (hasLowerBound() == other.hasLowerBound()); - if (hasLowerBound()) { - result = result && getLowerBound() - .equals(other.getLowerBound()); - } - result = result && (hasUpperBound() == other.hasUpperBound()); - if (hasUpperBound()) { - result = result && getUpperBound() - .equals(other.getUpperBound()); - } - result = result && ( - java.lang.Double.doubleToLongBits(getBucketSize()) - == java.lang.Double.doubleToLongBits( - other.getBucketSize())); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasLowerBound()) { - hash = (37 * hash) + LOWER_BOUND_FIELD_NUMBER; - hash = (53 * hash) + getLowerBound().hashCode(); - } - if (hasUpperBound()) { - hash = (37 * hash) + UPPER_BOUND_FIELD_NUMBER; - hash = (53 * hash) + getUpperBound().hashCode(); - } - hash = (37 * hash) + BUCKET_SIZE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - java.lang.Double.doubleToLongBits(getBucketSize())); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig 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.privacy.dlp.v2beta1.FixedSizeBucketingConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig 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.privacy.dlp.v2beta1.FixedSizeBucketingConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig 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.privacy.dlp.v2beta1.FixedSizeBucketingConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Buckets values based on fixed size ranges. The
-   * Bucketing transformation can provide all of this functionality,
-   * but requires more configuration. This message is provided as a convenience to
-   * the user for simple bucketing strategies.
-   * The resulting value will be a hyphenated string of
-   * lower_bound-upper_bound.
-   * This can be used on data of type: double, long.
-   * If the bound Value type differs from the type of data
-   * being transformed, we will first attempt converting the type of the data to
-   * be transformed to match the type of the bound before comparing.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.FixedSizeBucketingConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_FixedSizeBucketingConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_FixedSizeBucketingConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.class, com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (lowerBoundBuilder_ == null) { - lowerBound_ = null; - } else { - lowerBound_ = null; - lowerBoundBuilder_ = null; - } - if (upperBoundBuilder_ == null) { - upperBound_ = null; - } else { - upperBound_ = null; - upperBoundBuilder_ = null; - } - bucketSize_ = 0D; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_FixedSizeBucketingConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig build() { - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig buildPartial() { - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig result = new com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig(this); - if (lowerBoundBuilder_ == null) { - result.lowerBound_ = lowerBound_; - } else { - result.lowerBound_ = lowerBoundBuilder_.build(); - } - if (upperBoundBuilder_ == null) { - result.upperBound_ = upperBound_; - } else { - result.upperBound_ = upperBoundBuilder_.build(); - } - result.bucketSize_ = bucketSize_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig other) { - if (other == com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.getDefaultInstance()) return this; - if (other.hasLowerBound()) { - mergeLowerBound(other.getLowerBound()); - } - if (other.hasUpperBound()) { - mergeUpperBound(other.getUpperBound()); - } - if (other.getBucketSize() != 0D) { - setBucketSize(other.getBucketSize()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.Value lowerBound_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> lowerBoundBuilder_; - /** - *
-     * Lower bound value of buckets. All values less than `lower_bound` are
-     * grouped together into a single bucket; for example if `lower_bound` = 10,
-     * then all values less than 10 are replaced with the value “-10”. [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public boolean hasLowerBound() { - return lowerBoundBuilder_ != null || lowerBound_ != null; - } - /** - *
-     * Lower bound value of buckets. All values less than `lower_bound` are
-     * grouped together into a single bucket; for example if `lower_bound` = 10,
-     * then all values less than 10 are replaced with the value “-10”. [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getLowerBound() { - if (lowerBoundBuilder_ == null) { - return lowerBound_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : lowerBound_; - } else { - return lowerBoundBuilder_.getMessage(); - } - } - /** - *
-     * Lower bound value of buckets. All values less than `lower_bound` are
-     * grouped together into a single bucket; for example if `lower_bound` = 10,
-     * then all values less than 10 are replaced with the value “-10”. [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public Builder setLowerBound(com.google.privacy.dlp.v2beta1.Value value) { - if (lowerBoundBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - lowerBound_ = value; - onChanged(); - } else { - lowerBoundBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Lower bound value of buckets. All values less than `lower_bound` are
-     * grouped together into a single bucket; for example if `lower_bound` = 10,
-     * then all values less than 10 are replaced with the value “-10”. [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public Builder setLowerBound( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (lowerBoundBuilder_ == null) { - lowerBound_ = builderForValue.build(); - onChanged(); - } else { - lowerBoundBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Lower bound value of buckets. All values less than `lower_bound` are
-     * grouped together into a single bucket; for example if `lower_bound` = 10,
-     * then all values less than 10 are replaced with the value “-10”. [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public Builder mergeLowerBound(com.google.privacy.dlp.v2beta1.Value value) { - if (lowerBoundBuilder_ == null) { - if (lowerBound_ != null) { - lowerBound_ = - com.google.privacy.dlp.v2beta1.Value.newBuilder(lowerBound_).mergeFrom(value).buildPartial(); - } else { - lowerBound_ = value; - } - onChanged(); - } else { - lowerBoundBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Lower bound value of buckets. All values less than `lower_bound` are
-     * grouped together into a single bucket; for example if `lower_bound` = 10,
-     * then all values less than 10 are replaced with the value “-10”. [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public Builder clearLowerBound() { - if (lowerBoundBuilder_ == null) { - lowerBound_ = null; - onChanged(); - } else { - lowerBound_ = null; - lowerBoundBuilder_ = null; - } - - return this; - } - /** - *
-     * Lower bound value of buckets. All values less than `lower_bound` are
-     * grouped together into a single bucket; for example if `lower_bound` = 10,
-     * then all values less than 10 are replaced with the value “-10”. [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getLowerBoundBuilder() { - - onChanged(); - return getLowerBoundFieldBuilder().getBuilder(); - } - /** - *
-     * Lower bound value of buckets. All values less than `lower_bound` are
-     * grouped together into a single bucket; for example if `lower_bound` = 10,
-     * then all values less than 10 are replaced with the value “-10”. [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getLowerBoundOrBuilder() { - if (lowerBoundBuilder_ != null) { - return lowerBoundBuilder_.getMessageOrBuilder(); - } else { - return lowerBound_ == null ? - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : lowerBound_; - } - } - /** - *
-     * Lower bound value of buckets. All values less than `lower_bound` are
-     * grouped together into a single bucket; for example if `lower_bound` = 10,
-     * then all values less than 10 are replaced with the value “-10”. [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getLowerBoundFieldBuilder() { - if (lowerBoundBuilder_ == null) { - lowerBoundBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - getLowerBound(), - getParentForChildren(), - isClean()); - lowerBound_ = null; - } - return lowerBoundBuilder_; - } - - private com.google.privacy.dlp.v2beta1.Value upperBound_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> upperBoundBuilder_; - /** - *
-     * Upper bound value of buckets. All values greater than upper_bound are
-     * grouped together into a single bucket; for example if `upper_bound` = 89,
-     * then all values greater than 89 are replaced with the value “89+”.
-     * [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public boolean hasUpperBound() { - return upperBoundBuilder_ != null || upperBound_ != null; - } - /** - *
-     * Upper bound value of buckets. All values greater than upper_bound are
-     * grouped together into a single bucket; for example if `upper_bound` = 89,
-     * then all values greater than 89 are replaced with the value “89+”.
-     * [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public com.google.privacy.dlp.v2beta1.Value getUpperBound() { - if (upperBoundBuilder_ == null) { - return upperBound_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : upperBound_; - } else { - return upperBoundBuilder_.getMessage(); - } - } - /** - *
-     * Upper bound value of buckets. All values greater than upper_bound are
-     * grouped together into a single bucket; for example if `upper_bound` = 89,
-     * then all values greater than 89 are replaced with the value “89+”.
-     * [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public Builder setUpperBound(com.google.privacy.dlp.v2beta1.Value value) { - if (upperBoundBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - upperBound_ = value; - onChanged(); - } else { - upperBoundBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Upper bound value of buckets. All values greater than upper_bound are
-     * grouped together into a single bucket; for example if `upper_bound` = 89,
-     * then all values greater than 89 are replaced with the value “89+”.
-     * [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public Builder setUpperBound( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (upperBoundBuilder_ == null) { - upperBound_ = builderForValue.build(); - onChanged(); - } else { - upperBoundBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Upper bound value of buckets. All values greater than upper_bound are
-     * grouped together into a single bucket; for example if `upper_bound` = 89,
-     * then all values greater than 89 are replaced with the value “89+”.
-     * [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public Builder mergeUpperBound(com.google.privacy.dlp.v2beta1.Value value) { - if (upperBoundBuilder_ == null) { - if (upperBound_ != null) { - upperBound_ = - com.google.privacy.dlp.v2beta1.Value.newBuilder(upperBound_).mergeFrom(value).buildPartial(); - } else { - upperBound_ = value; - } - onChanged(); - } else { - upperBoundBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Upper bound value of buckets. All values greater than upper_bound are
-     * grouped together into a single bucket; for example if `upper_bound` = 89,
-     * then all values greater than 89 are replaced with the value “89+”.
-     * [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public Builder clearUpperBound() { - if (upperBoundBuilder_ == null) { - upperBound_ = null; - onChanged(); - } else { - upperBound_ = null; - upperBoundBuilder_ = null; - } - - return this; - } - /** - *
-     * Upper bound value of buckets. All values greater than upper_bound are
-     * grouped together into a single bucket; for example if `upper_bound` = 89,
-     * then all values greater than 89 are replaced with the value “89+”.
-     * [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getUpperBoundBuilder() { - - onChanged(); - return getUpperBoundFieldBuilder().getBuilder(); - } - /** - *
-     * Upper bound value of buckets. All values greater than upper_bound are
-     * grouped together into a single bucket; for example if `upper_bound` = 89,
-     * then all values greater than 89 are replaced with the value “89+”.
-     * [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getUpperBoundOrBuilder() { - if (upperBoundBuilder_ != null) { - return upperBoundBuilder_.getMessageOrBuilder(); - } else { - return upperBound_ == null ? - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : upperBound_; - } - } - /** - *
-     * Upper bound value of buckets. All values greater than upper_bound are
-     * grouped together into a single bucket; for example if `upper_bound` = 89,
-     * then all values greater than 89 are replaced with the value “89+”.
-     * [Required].
-     * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getUpperBoundFieldBuilder() { - if (upperBoundBuilder_ == null) { - upperBoundBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - getUpperBound(), - getParentForChildren(), - isClean()); - upperBound_ = null; - } - return upperBoundBuilder_; - } - - private double bucketSize_ ; - /** - *
-     * Size of each bucket (except for minimum and maximum buckets). So if
-     * `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the
-     * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60,
-     * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. [Required].
-     * 
- * - * double bucket_size = 3; - */ - public double getBucketSize() { - return bucketSize_; - } - /** - *
-     * Size of each bucket (except for minimum and maximum buckets). So if
-     * `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the
-     * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60,
-     * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. [Required].
-     * 
- * - * double bucket_size = 3; - */ - public Builder setBucketSize(double value) { - - bucketSize_ = value; - onChanged(); - return this; - } - /** - *
-     * Size of each bucket (except for minimum and maximum buckets). So if
-     * `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the
-     * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60,
-     * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. [Required].
-     * 
- * - * double bucket_size = 3; - */ - public Builder clearBucketSize() { - - bucketSize_ = 0D; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) - private static final com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig(); - } - - public static com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public FixedSizeBucketingConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new FixedSizeBucketingConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FixedSizeBucketingConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FixedSizeBucketingConfigOrBuilder.java deleted file mode 100644 index 3dbc5e7bbf21..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FixedSizeBucketingConfigOrBuilder.java +++ /dev/null @@ -1,86 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface FixedSizeBucketingConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Lower bound value of buckets. All values less than `lower_bound` are
-   * grouped together into a single bucket; for example if `lower_bound` = 10,
-   * then all values less than 10 are replaced with the value “-10”. [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - boolean hasLowerBound(); - /** - *
-   * Lower bound value of buckets. All values less than `lower_bound` are
-   * grouped together into a single bucket; for example if `lower_bound` = 10,
-   * then all values less than 10 are replaced with the value “-10”. [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - com.google.privacy.dlp.v2beta1.Value getLowerBound(); - /** - *
-   * Lower bound value of buckets. All values less than `lower_bound` are
-   * grouped together into a single bucket; for example if `lower_bound` = 10,
-   * then all values less than 10 are replaced with the value “-10”. [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value lower_bound = 1; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getLowerBoundOrBuilder(); - - /** - *
-   * Upper bound value of buckets. All values greater than upper_bound are
-   * grouped together into a single bucket; for example if `upper_bound` = 89,
-   * then all values greater than 89 are replaced with the value “89+”.
-   * [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - boolean hasUpperBound(); - /** - *
-   * Upper bound value of buckets. All values greater than upper_bound are
-   * grouped together into a single bucket; for example if `upper_bound` = 89,
-   * then all values greater than 89 are replaced with the value “89+”.
-   * [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - com.google.privacy.dlp.v2beta1.Value getUpperBound(); - /** - *
-   * Upper bound value of buckets. All values greater than upper_bound are
-   * grouped together into a single bucket; for example if `upper_bound` = 89,
-   * then all values greater than 89 are replaced with the value “89+”.
-   * [Required].
-   * 
- * - * .google.privacy.dlp.v2beta1.Value upper_bound = 2; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getUpperBoundOrBuilder(); - - /** - *
-   * Size of each bucket (except for minimum and maximum buckets). So if
-   * `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the
-   * following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60,
-   * 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. [Required].
-   * 
- * - * double bucket_size = 3; - */ - double getBucketSize(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ImageLocation.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ImageLocation.java deleted file mode 100644 index fa3602ee64f0..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ImageLocation.java +++ /dev/null @@ -1,693 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Bounding box encompassing detected text within an image.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ImageLocation} - */ -public final class ImageLocation extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ImageLocation) - ImageLocationOrBuilder { -private static final long serialVersionUID = 0L; - // Use ImageLocation.newBuilder() to construct. - private ImageLocation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ImageLocation() { - top_ = 0; - left_ = 0; - width_ = 0; - height_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ImageLocation( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - - top_ = input.readInt32(); - break; - } - case 16: { - - left_ = input.readInt32(); - break; - } - case 24: { - - width_ = input.readInt32(); - break; - } - case 32: { - - height_ = input.readInt32(); - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ImageLocation_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ImageLocation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ImageLocation.class, com.google.privacy.dlp.v2beta1.ImageLocation.Builder.class); - } - - public static final int TOP_FIELD_NUMBER = 1; - private int top_; - /** - *
-   * Top coordinate of the bounding box. (0,0) is upper left.
-   * 
- * - * int32 top = 1; - */ - public int getTop() { - return top_; - } - - public static final int LEFT_FIELD_NUMBER = 2; - private int left_; - /** - *
-   * Left coordinate of the bounding box. (0,0) is upper left.
-   * 
- * - * int32 left = 2; - */ - public int getLeft() { - return left_; - } - - public static final int WIDTH_FIELD_NUMBER = 3; - private int width_; - /** - *
-   * Width of the bounding box in pixels.
-   * 
- * - * int32 width = 3; - */ - public int getWidth() { - return width_; - } - - public static final int HEIGHT_FIELD_NUMBER = 4; - private int height_; - /** - *
-   * Height of the bounding box in pixels.
-   * 
- * - * int32 height = 4; - */ - public int getHeight() { - return height_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (top_ != 0) { - output.writeInt32(1, top_); - } - if (left_ != 0) { - output.writeInt32(2, left_); - } - if (width_ != 0) { - output.writeInt32(3, width_); - } - if (height_ != 0) { - output.writeInt32(4, height_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (top_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(1, top_); - } - if (left_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(2, left_); - } - if (width_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(3, width_); - } - if (height_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(4, height_); - } - 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.privacy.dlp.v2beta1.ImageLocation)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ImageLocation other = (com.google.privacy.dlp.v2beta1.ImageLocation) obj; - - boolean result = true; - result = result && (getTop() - == other.getTop()); - result = result && (getLeft() - == other.getLeft()); - result = result && (getWidth() - == other.getWidth()); - result = result && (getHeight() - == other.getHeight()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TOP_FIELD_NUMBER; - hash = (53 * hash) + getTop(); - hash = (37 * hash) + LEFT_FIELD_NUMBER; - hash = (53 * hash) + getLeft(); - hash = (37 * hash) + WIDTH_FIELD_NUMBER; - hash = (53 * hash) + getWidth(); - hash = (37 * hash) + HEIGHT_FIELD_NUMBER; - hash = (53 * hash) + getHeight(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.ImageLocation parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ImageLocation parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ImageLocation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ImageLocation 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.privacy.dlp.v2beta1.ImageLocation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ImageLocation parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ImageLocation parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ImageLocation 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.privacy.dlp.v2beta1.ImageLocation parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ImageLocation 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.privacy.dlp.v2beta1.ImageLocation parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ImageLocation parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ImageLocation prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Bounding box encompassing detected text within an image.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ImageLocation} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ImageLocation) - com.google.privacy.dlp.v2beta1.ImageLocationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ImageLocation_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ImageLocation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ImageLocation.class, com.google.privacy.dlp.v2beta1.ImageLocation.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ImageLocation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - top_ = 0; - - left_ = 0; - - width_ = 0; - - height_ = 0; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ImageLocation_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ImageLocation getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ImageLocation.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ImageLocation build() { - com.google.privacy.dlp.v2beta1.ImageLocation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ImageLocation buildPartial() { - com.google.privacy.dlp.v2beta1.ImageLocation result = new com.google.privacy.dlp.v2beta1.ImageLocation(this); - result.top_ = top_; - result.left_ = left_; - result.width_ = width_; - result.height_ = height_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ImageLocation) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ImageLocation)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ImageLocation other) { - if (other == com.google.privacy.dlp.v2beta1.ImageLocation.getDefaultInstance()) return this; - if (other.getTop() != 0) { - setTop(other.getTop()); - } - if (other.getLeft() != 0) { - setLeft(other.getLeft()); - } - if (other.getWidth() != 0) { - setWidth(other.getWidth()); - } - if (other.getHeight() != 0) { - setHeight(other.getHeight()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ImageLocation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ImageLocation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int top_ ; - /** - *
-     * Top coordinate of the bounding box. (0,0) is upper left.
-     * 
- * - * int32 top = 1; - */ - public int getTop() { - return top_; - } - /** - *
-     * Top coordinate of the bounding box. (0,0) is upper left.
-     * 
- * - * int32 top = 1; - */ - public Builder setTop(int value) { - - top_ = value; - onChanged(); - return this; - } - /** - *
-     * Top coordinate of the bounding box. (0,0) is upper left.
-     * 
- * - * int32 top = 1; - */ - public Builder clearTop() { - - top_ = 0; - onChanged(); - return this; - } - - private int left_ ; - /** - *
-     * Left coordinate of the bounding box. (0,0) is upper left.
-     * 
- * - * int32 left = 2; - */ - public int getLeft() { - return left_; - } - /** - *
-     * Left coordinate of the bounding box. (0,0) is upper left.
-     * 
- * - * int32 left = 2; - */ - public Builder setLeft(int value) { - - left_ = value; - onChanged(); - return this; - } - /** - *
-     * Left coordinate of the bounding box. (0,0) is upper left.
-     * 
- * - * int32 left = 2; - */ - public Builder clearLeft() { - - left_ = 0; - onChanged(); - return this; - } - - private int width_ ; - /** - *
-     * Width of the bounding box in pixels.
-     * 
- * - * int32 width = 3; - */ - public int getWidth() { - return width_; - } - /** - *
-     * Width of the bounding box in pixels.
-     * 
- * - * int32 width = 3; - */ - public Builder setWidth(int value) { - - width_ = value; - onChanged(); - return this; - } - /** - *
-     * Width of the bounding box in pixels.
-     * 
- * - * int32 width = 3; - */ - public Builder clearWidth() { - - width_ = 0; - onChanged(); - return this; - } - - private int height_ ; - /** - *
-     * Height of the bounding box in pixels.
-     * 
- * - * int32 height = 4; - */ - public int getHeight() { - return height_; - } - /** - *
-     * Height of the bounding box in pixels.
-     * 
- * - * int32 height = 4; - */ - public Builder setHeight(int value) { - - height_ = value; - onChanged(); - return this; - } - /** - *
-     * Height of the bounding box in pixels.
-     * 
- * - * int32 height = 4; - */ - public Builder clearHeight() { - - height_ = 0; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ImageLocation) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ImageLocation) - private static final com.google.privacy.dlp.v2beta1.ImageLocation DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ImageLocation(); - } - - public static com.google.privacy.dlp.v2beta1.ImageLocation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ImageLocation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ImageLocation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ImageLocation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ImageLocationOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ImageLocationOrBuilder.java deleted file mode 100644 index 8e5ecbdb599b..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ImageLocationOrBuilder.java +++ /dev/null @@ -1,45 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ImageLocationOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ImageLocation) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Top coordinate of the bounding box. (0,0) is upper left.
-   * 
- * - * int32 top = 1; - */ - int getTop(); - - /** - *
-   * Left coordinate of the bounding box. (0,0) is upper left.
-   * 
- * - * int32 left = 2; - */ - int getLeft(); - - /** - *
-   * Width of the bounding box in pixels.
-   * 
- * - * int32 width = 3; - */ - int getWidth(); - - /** - *
-   * Height of the bounding box in pixels.
-   * 
- * - * int32 height = 4; - */ - int getHeight(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoType.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoType.java deleted file mode 100644 index f34148657a6a..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoType.java +++ /dev/null @@ -1,552 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Type of information detected by the API.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InfoType} - */ -public final class InfoType extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InfoType) - InfoTypeOrBuilder { -private static final long serialVersionUID = 0L; - // Use InfoType.newBuilder() to construct. - private InfoType(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InfoType() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InfoType( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_InfoType_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_InfoType_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InfoType.class, com.google.privacy.dlp.v2beta1.InfoType.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - *
-   * Name of the information type.
-   * 
- * - * string name = 1; - */ - 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 information type.
-   * 
- * - * string name = 1; - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - 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.privacy.dlp.v2beta1.InfoType)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InfoType other = (com.google.privacy.dlp.v2beta1.InfoType) obj; - - boolean result = true; - result = result && getName() - .equals(other.getName()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InfoType parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoType parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InfoType parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoType 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.privacy.dlp.v2beta1.InfoType parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoType parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InfoType parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoType 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.privacy.dlp.v2beta1.InfoType parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoType 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.privacy.dlp.v2beta1.InfoType parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoType parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InfoType prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Type of information detected by the API.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InfoType} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InfoType) - com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_InfoType_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_InfoType_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InfoType.class, com.google.privacy.dlp.v2beta1.InfoType.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InfoType.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_InfoType_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InfoType getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InfoType build() { - com.google.privacy.dlp.v2beta1.InfoType result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InfoType buildPartial() { - com.google.privacy.dlp.v2beta1.InfoType result = new com.google.privacy.dlp.v2beta1.InfoType(this); - result.name_ = name_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InfoType) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InfoType)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InfoType other) { - if (other == com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InfoType parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InfoType) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - *
-     * Name of the information type.
-     * 
- * - * string name = 1; - */ - 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 information type.
-     * 
- * - * string name = 1; - */ - 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 information type.
-     * 
- * - * string name = 1; - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - *
-     * Name of the information type.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - *
-     * Name of the information type.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InfoType) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InfoType) - private static final com.google.privacy.dlp.v2beta1.InfoType DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InfoType(); - } - - public static com.google.privacy.dlp.v2beta1.InfoType getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InfoType parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InfoType(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InfoType getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeDescription.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeDescription.java deleted file mode 100644 index 4c71a812c2cf..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeDescription.java +++ /dev/null @@ -1,1147 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Description of the information type (infoType).
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InfoTypeDescription} - */ -public final class InfoTypeDescription extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InfoTypeDescription) - InfoTypeDescriptionOrBuilder { -private static final long serialVersionUID = 0L; - // Use InfoTypeDescription.newBuilder() to construct. - private InfoTypeDescription(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InfoTypeDescription() { - name_ = ""; - displayName_ = ""; - categories_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InfoTypeDescription( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - displayName_ = s; - break; - } - case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { - categories_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000004; - } - categories_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.CategoryDescription.parser(), extensionRegistry)); - 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_ & 0x00000004) == 0x00000004)) { - categories_ = java.util.Collections.unmodifiableList(categories_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeDescription_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeDescription_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InfoTypeDescription.class, com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder.class); - } - - private int bitField0_; - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - *
-   * Internal name of the infoType.
-   * 
- * - * string name = 1; - */ - 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; - } - } - /** - *
-   * Internal name of the infoType.
-   * 
- * - * string name = 1; - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DISPLAY_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object displayName_; - /** - *
-   * Human readable form of the infoType name.
-   * 
- * - * string display_name = 2; - */ - public java.lang.String getDisplayName() { - java.lang.Object ref = displayName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - displayName_ = s; - return s; - } - } - /** - *
-   * Human readable form of the infoType name.
-   * 
- * - * string display_name = 2; - */ - public com.google.protobuf.ByteString - getDisplayNameBytes() { - java.lang.Object ref = displayName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - displayName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CATEGORIES_FIELD_NUMBER = 3; - private java.util.List categories_; - /** - *
-   * List of categories this infoType belongs to.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public java.util.List getCategoriesList() { - return categories_; - } - /** - *
-   * List of categories this infoType belongs to.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public java.util.List - getCategoriesOrBuilderList() { - return categories_; - } - /** - *
-   * List of categories this infoType belongs to.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public int getCategoriesCount() { - return categories_.size(); - } - /** - *
-   * List of categories this infoType belongs to.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescription getCategories(int index) { - return categories_.get(index); - } - /** - *
-   * List of categories this infoType belongs to.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder getCategoriesOrBuilder( - int index) { - return categories_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (!getDisplayNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, displayName_); - } - for (int i = 0; i < categories_.size(); i++) { - output.writeMessage(3, categories_.get(i)); - } - unknownFields.writeTo(output); - } - - 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 (!getDisplayNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, displayName_); - } - for (int i = 0; i < categories_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, categories_.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.privacy.dlp.v2beta1.InfoTypeDescription)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InfoTypeDescription other = (com.google.privacy.dlp.v2beta1.InfoTypeDescription) obj; - - boolean result = true; - result = result && getName() - .equals(other.getName()); - result = result && getDisplayName() - .equals(other.getDisplayName()); - result = result && getCategoriesList() - .equals(other.getCategoriesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; - hash = (53 * hash) + getDisplayName().hashCode(); - if (getCategoriesCount() > 0) { - hash = (37 * hash) + CATEGORIES_FIELD_NUMBER; - hash = (53 * hash) + getCategoriesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InfoTypeDescription parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeDescription parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeDescription parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeDescription 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.privacy.dlp.v2beta1.InfoTypeDescription parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeDescription parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeDescription parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeDescription 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.privacy.dlp.v2beta1.InfoTypeDescription parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeDescription 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.privacy.dlp.v2beta1.InfoTypeDescription parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeDescription parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InfoTypeDescription prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Description of the information type (infoType).
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InfoTypeDescription} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InfoTypeDescription) - com.google.privacy.dlp.v2beta1.InfoTypeDescriptionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeDescription_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeDescription_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InfoTypeDescription.class, com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InfoTypeDescription.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getCategoriesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - name_ = ""; - - displayName_ = ""; - - if (categoriesBuilder_ == null) { - categories_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - } else { - categoriesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeDescription_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeDescription getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InfoTypeDescription.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InfoTypeDescription build() { - com.google.privacy.dlp.v2beta1.InfoTypeDescription result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeDescription buildPartial() { - com.google.privacy.dlp.v2beta1.InfoTypeDescription result = new com.google.privacy.dlp.v2beta1.InfoTypeDescription(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.name_ = name_; - result.displayName_ = displayName_; - if (categoriesBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { - categories_ = java.util.Collections.unmodifiableList(categories_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.categories_ = categories_; - } else { - result.categories_ = categoriesBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InfoTypeDescription) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InfoTypeDescription)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InfoTypeDescription other) { - if (other == com.google.privacy.dlp.v2beta1.InfoTypeDescription.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getDisplayName().isEmpty()) { - displayName_ = other.displayName_; - onChanged(); - } - if (categoriesBuilder_ == null) { - if (!other.categories_.isEmpty()) { - if (categories_.isEmpty()) { - categories_ = other.categories_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureCategoriesIsMutable(); - categories_.addAll(other.categories_); - } - onChanged(); - } - } else { - if (!other.categories_.isEmpty()) { - if (categoriesBuilder_.isEmpty()) { - categoriesBuilder_.dispose(); - categoriesBuilder_ = null; - categories_ = other.categories_; - bitField0_ = (bitField0_ & ~0x00000004); - categoriesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getCategoriesFieldBuilder() : null; - } else { - categoriesBuilder_.addAllMessages(other.categories_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InfoTypeDescription parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InfoTypeDescription) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.lang.Object name_ = ""; - /** - *
-     * Internal name of the infoType.
-     * 
- * - * string name = 1; - */ - 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; - } - } - /** - *
-     * Internal name of the infoType.
-     * 
- * - * string name = 1; - */ - 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; - } - } - /** - *
-     * Internal name of the infoType.
-     * 
- * - * string name = 1; - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - *
-     * Internal name of the infoType.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - *
-     * Internal name of the infoType.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object displayName_ = ""; - /** - *
-     * Human readable form of the infoType name.
-     * 
- * - * string display_name = 2; - */ - public java.lang.String getDisplayName() { - java.lang.Object ref = displayName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - displayName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * Human readable form of the infoType name.
-     * 
- * - * string display_name = 2; - */ - public com.google.protobuf.ByteString - getDisplayNameBytes() { - java.lang.Object ref = displayName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - displayName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * Human readable form of the infoType name.
-     * 
- * - * string display_name = 2; - */ - public Builder setDisplayName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - displayName_ = value; - onChanged(); - return this; - } - /** - *
-     * Human readable form of the infoType name.
-     * 
- * - * string display_name = 2; - */ - public Builder clearDisplayName() { - - displayName_ = getDefaultInstance().getDisplayName(); - onChanged(); - return this; - } - /** - *
-     * Human readable form of the infoType name.
-     * 
- * - * string display_name = 2; - */ - public Builder setDisplayNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - displayName_ = value; - onChanged(); - return this; - } - - private java.util.List categories_ = - java.util.Collections.emptyList(); - private void ensureCategoriesIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { - categories_ = new java.util.ArrayList(categories_); - bitField0_ |= 0x00000004; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CategoryDescription, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder, com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder> categoriesBuilder_; - - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public java.util.List getCategoriesList() { - if (categoriesBuilder_ == null) { - return java.util.Collections.unmodifiableList(categories_); - } else { - return categoriesBuilder_.getMessageList(); - } - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public int getCategoriesCount() { - if (categoriesBuilder_ == null) { - return categories_.size(); - } else { - return categoriesBuilder_.getCount(); - } - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescription getCategories(int index) { - if (categoriesBuilder_ == null) { - return categories_.get(index); - } else { - return categoriesBuilder_.getMessage(index); - } - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public Builder setCategories( - int index, com.google.privacy.dlp.v2beta1.CategoryDescription value) { - if (categoriesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCategoriesIsMutable(); - categories_.set(index, value); - onChanged(); - } else { - categoriesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public Builder setCategories( - int index, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder builderForValue) { - if (categoriesBuilder_ == null) { - ensureCategoriesIsMutable(); - categories_.set(index, builderForValue.build()); - onChanged(); - } else { - categoriesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public Builder addCategories(com.google.privacy.dlp.v2beta1.CategoryDescription value) { - if (categoriesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCategoriesIsMutable(); - categories_.add(value); - onChanged(); - } else { - categoriesBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public Builder addCategories( - int index, com.google.privacy.dlp.v2beta1.CategoryDescription value) { - if (categoriesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCategoriesIsMutable(); - categories_.add(index, value); - onChanged(); - } else { - categoriesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public Builder addCategories( - com.google.privacy.dlp.v2beta1.CategoryDescription.Builder builderForValue) { - if (categoriesBuilder_ == null) { - ensureCategoriesIsMutable(); - categories_.add(builderForValue.build()); - onChanged(); - } else { - categoriesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public Builder addCategories( - int index, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder builderForValue) { - if (categoriesBuilder_ == null) { - ensureCategoriesIsMutable(); - categories_.add(index, builderForValue.build()); - onChanged(); - } else { - categoriesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public Builder addAllCategories( - java.lang.Iterable values) { - if (categoriesBuilder_ == null) { - ensureCategoriesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, categories_); - onChanged(); - } else { - categoriesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public Builder clearCategories() { - if (categoriesBuilder_ == null) { - categories_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - } else { - categoriesBuilder_.clear(); - } - return this; - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public Builder removeCategories(int index) { - if (categoriesBuilder_ == null) { - ensureCategoriesIsMutable(); - categories_.remove(index); - onChanged(); - } else { - categoriesBuilder_.remove(index); - } - return this; - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescription.Builder getCategoriesBuilder( - int index) { - return getCategoriesFieldBuilder().getBuilder(index); - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder getCategoriesOrBuilder( - int index) { - if (categoriesBuilder_ == null) { - return categories_.get(index); } else { - return categoriesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public java.util.List - getCategoriesOrBuilderList() { - if (categoriesBuilder_ != null) { - return categoriesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(categories_); - } - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescription.Builder addCategoriesBuilder() { - return getCategoriesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.CategoryDescription.getDefaultInstance()); - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescription.Builder addCategoriesBuilder( - int index) { - return getCategoriesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.CategoryDescription.getDefaultInstance()); - } - /** - *
-     * List of categories this infoType belongs to.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - public java.util.List - getCategoriesBuilderList() { - return getCategoriesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CategoryDescription, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder, com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder> - getCategoriesFieldBuilder() { - if (categoriesBuilder_ == null) { - categoriesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CategoryDescription, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder, com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder>( - categories_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); - categories_ = null; - } - return categoriesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InfoTypeDescription) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InfoTypeDescription) - private static final com.google.privacy.dlp.v2beta1.InfoTypeDescription DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InfoTypeDescription(); - } - - public static com.google.privacy.dlp.v2beta1.InfoTypeDescription getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InfoTypeDescription parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InfoTypeDescription(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeDescription getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeDescriptionOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeDescriptionOrBuilder.java deleted file mode 100644 index c99e38789aae..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeDescriptionOrBuilder.java +++ /dev/null @@ -1,89 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface InfoTypeDescriptionOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InfoTypeDescription) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Internal name of the infoType.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - *
-   * Internal name of the infoType.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString - getNameBytes(); - - /** - *
-   * Human readable form of the infoType name.
-   * 
- * - * string display_name = 2; - */ - java.lang.String getDisplayName(); - /** - *
-   * Human readable form of the infoType name.
-   * 
- * - * string display_name = 2; - */ - com.google.protobuf.ByteString - getDisplayNameBytes(); - - /** - *
-   * List of categories this infoType belongs to.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - java.util.List - getCategoriesList(); - /** - *
-   * List of categories this infoType belongs to.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - com.google.privacy.dlp.v2beta1.CategoryDescription getCategories(int index); - /** - *
-   * List of categories this infoType belongs to.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - int getCategoriesCount(); - /** - *
-   * List of categories this infoType belongs to.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - java.util.List - getCategoriesOrBuilderList(); - /** - *
-   * List of categories this infoType belongs to.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 3; - */ - com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder getCategoriesOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeOrBuilder.java deleted file mode 100644 index 808bf1867717..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeOrBuilder.java +++ /dev/null @@ -1,27 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface InfoTypeOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InfoType) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Name of the information type.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - *
-   * Name of the information type.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString - getNameBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeStatistics.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeStatistics.java deleted file mode 100644 index f43df3e35124..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeStatistics.java +++ /dev/null @@ -1,701 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Statistics regarding a specific InfoType.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InfoTypeStatistics} - */ -public final class InfoTypeStatistics extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InfoTypeStatistics) - InfoTypeStatisticsOrBuilder { -private static final long serialVersionUID = 0L; - // Use InfoTypeStatistics.newBuilder() to construct. - private InfoTypeStatistics(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InfoTypeStatistics() { - count_ = 0L; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InfoTypeStatistics( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InfoType.Builder subBuilder = null; - if (infoType_ != null) { - subBuilder = infoType_.toBuilder(); - } - infoType_ = input.readMessage(com.google.privacy.dlp.v2beta1.InfoType.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(infoType_); - infoType_ = subBuilder.buildPartial(); - } - - break; - } - case 16: { - - count_ = input.readInt64(); - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeStatistics_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeStatistics_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InfoTypeStatistics.class, com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder.class); - } - - public static final int INFO_TYPE_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.InfoType infoType_; - /** - *
-   * The type of finding this stat is for.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return infoType_ != null; - } - /** - *
-   * The type of finding this stat is for.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - /** - *
-   * The type of finding this stat is for.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - return getInfoType(); - } - - public static final int COUNT_FIELD_NUMBER = 2; - private long count_; - /** - *
-   * Number of findings for this info type.
-   * 
- * - * int64 count = 2; - */ - public long getCount() { - return count_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (infoType_ != null) { - output.writeMessage(1, getInfoType()); - } - if (count_ != 0L) { - output.writeInt64(2, count_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (infoType_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getInfoType()); - } - if (count_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(2, count_); - } - 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.privacy.dlp.v2beta1.InfoTypeStatistics)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InfoTypeStatistics other = (com.google.privacy.dlp.v2beta1.InfoTypeStatistics) obj; - - boolean result = true; - result = result && (hasInfoType() == other.hasInfoType()); - if (hasInfoType()) { - result = result && getInfoType() - .equals(other.getInfoType()); - } - result = result && (getCount() - == other.getCount()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasInfoType()) { - hash = (37 * hash) + INFO_TYPE_FIELD_NUMBER; - hash = (53 * hash) + getInfoType().hashCode(); - } - hash = (37 * hash) + COUNT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getCount()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InfoTypeStatistics parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeStatistics parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeStatistics parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeStatistics 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.privacy.dlp.v2beta1.InfoTypeStatistics parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeStatistics parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeStatistics parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeStatistics 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.privacy.dlp.v2beta1.InfoTypeStatistics parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeStatistics 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.privacy.dlp.v2beta1.InfoTypeStatistics parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeStatistics parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InfoTypeStatistics prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Statistics regarding a specific InfoType.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InfoTypeStatistics} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InfoTypeStatistics) - com.google.privacy.dlp.v2beta1.InfoTypeStatisticsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeStatistics_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeStatistics_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InfoTypeStatistics.class, com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InfoTypeStatistics.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (infoTypeBuilder_ == null) { - infoType_ = null; - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - count_ = 0L; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeStatistics_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeStatistics getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InfoTypeStatistics.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InfoTypeStatistics build() { - com.google.privacy.dlp.v2beta1.InfoTypeStatistics result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeStatistics buildPartial() { - com.google.privacy.dlp.v2beta1.InfoTypeStatistics result = new com.google.privacy.dlp.v2beta1.InfoTypeStatistics(this); - if (infoTypeBuilder_ == null) { - result.infoType_ = infoType_; - } else { - result.infoType_ = infoTypeBuilder_.build(); - } - result.count_ = count_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InfoTypeStatistics) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InfoTypeStatistics)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InfoTypeStatistics other) { - if (other == com.google.privacy.dlp.v2beta1.InfoTypeStatistics.getDefaultInstance()) return this; - if (other.hasInfoType()) { - mergeInfoType(other.getInfoType()); - } - if (other.getCount() != 0L) { - setCount(other.getCount()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InfoTypeStatistics parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InfoTypeStatistics) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.InfoType infoType_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> infoTypeBuilder_; - /** - *
-     * The type of finding this stat is for.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return infoTypeBuilder_ != null || infoType_ != null; - } - /** - *
-     * The type of finding this stat is for.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - if (infoTypeBuilder_ == null) { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } else { - return infoTypeBuilder_.getMessage(); - } - } - /** - *
-     * The type of finding this stat is for.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - infoType_ = value; - onChanged(); - } else { - infoTypeBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The type of finding this stat is for.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType( - com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypeBuilder_ == null) { - infoType_ = builderForValue.build(); - onChanged(); - } else { - infoTypeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The type of finding this stat is for.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder mergeInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (infoType_ != null) { - infoType_ = - com.google.privacy.dlp.v2beta1.InfoType.newBuilder(infoType_).mergeFrom(value).buildPartial(); - } else { - infoType_ = value; - } - onChanged(); - } else { - infoTypeBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The type of finding this stat is for.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder clearInfoType() { - if (infoTypeBuilder_ == null) { - infoType_ = null; - onChanged(); - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - - return this; - } - /** - *
-     * The type of finding this stat is for.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder getInfoTypeBuilder() { - - onChanged(); - return getInfoTypeFieldBuilder().getBuilder(); - } - /** - *
-     * The type of finding this stat is for.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - if (infoTypeBuilder_ != null) { - return infoTypeBuilder_.getMessageOrBuilder(); - } else { - return infoType_ == null ? - com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - } - /** - *
-     * The type of finding this stat is for.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> - getInfoTypeFieldBuilder() { - if (infoTypeBuilder_ == null) { - infoTypeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder>( - getInfoType(), - getParentForChildren(), - isClean()); - infoType_ = null; - } - return infoTypeBuilder_; - } - - private long count_ ; - /** - *
-     * Number of findings for this info type.
-     * 
- * - * int64 count = 2; - */ - public long getCount() { - return count_; - } - /** - *
-     * Number of findings for this info type.
-     * 
- * - * int64 count = 2; - */ - public Builder setCount(long value) { - - count_ = value; - onChanged(); - return this; - } - /** - *
-     * Number of findings for this info type.
-     * 
- * - * int64 count = 2; - */ - public Builder clearCount() { - - count_ = 0L; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InfoTypeStatistics) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InfoTypeStatistics) - private static final com.google.privacy.dlp.v2beta1.InfoTypeStatistics DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InfoTypeStatistics(); - } - - public static com.google.privacy.dlp.v2beta1.InfoTypeStatistics getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InfoTypeStatistics parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InfoTypeStatistics(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeStatistics getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeStatisticsOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeStatisticsOrBuilder.java deleted file mode 100644 index 5d36b01cd30c..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeStatisticsOrBuilder.java +++ /dev/null @@ -1,43 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface InfoTypeStatisticsOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InfoTypeStatistics) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The type of finding this stat is for.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - boolean hasInfoType(); - /** - *
-   * The type of finding this stat is for.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoType getInfoType(); - /** - *
-   * The type of finding this stat is for.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder(); - - /** - *
-   * Number of findings for this info type.
-   * 
- * - * int64 count = 2; - */ - long getCount(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeTransformations.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeTransformations.java deleted file mode 100644 index 33df8f7dac65..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeTransformations.java +++ /dev/null @@ -1,2027 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * A type of transformation that will scan unstructured text and
- * apply various `PrimitiveTransformation`s to each finding, where the
- * transformation is applied to only values that were identified as a specific
- * info_type.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InfoTypeTransformations} - */ -public final class InfoTypeTransformations extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InfoTypeTransformations) - InfoTypeTransformationsOrBuilder { -private static final long serialVersionUID = 0L; - // Use InfoTypeTransformations.newBuilder() to construct. - private InfoTypeTransformations(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InfoTypeTransformations() { - transformations_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InfoTypeTransformations( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - transformations_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - transformations_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.parser(), extensionRegistry)); - 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) == 0x00000001)) { - transformations_ = java.util.Collections.unmodifiableList(transformations_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.class, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder.class); - } - - public interface InfoTypeTransformationOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Info types to apply the transformation to. Empty list will match all
-     * available info types for this transformation.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - java.util.List - getInfoTypesList(); - /** - *
-     * Info types to apply the transformation to. Empty list will match all
-     * available info types for this transformation.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - com.google.privacy.dlp.v2beta1.InfoType getInfoTypes(int index); - /** - *
-     * Info types to apply the transformation to. Empty list will match all
-     * available info types for this transformation.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - int getInfoTypesCount(); - /** - *
-     * Info types to apply the transformation to. Empty list will match all
-     * available info types for this transformation.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - java.util.List - getInfoTypesOrBuilderList(); - /** - *
-     * Info types to apply the transformation to. Empty list will match all
-     * available info types for this transformation.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypesOrBuilder( - int index); - - /** - *
-     * Primitive transformation to apply to the info type. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - boolean hasPrimitiveTransformation(); - /** - *
-     * Primitive transformation to apply to the info type. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - com.google.privacy.dlp.v2beta1.PrimitiveTransformation getPrimitiveTransformation(); - /** - *
-     * Primitive transformation to apply to the info type. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder getPrimitiveTransformationOrBuilder(); - } - /** - *
-   * A transformation to apply to text that is identified as a specific
-   * info_type.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation} - */ - public static final class InfoTypeTransformation extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation) - InfoTypeTransformationOrBuilder { - private static final long serialVersionUID = 0L; - // Use InfoTypeTransformation.newBuilder() to construct. - private InfoTypeTransformation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InfoTypeTransformation() { - infoTypes_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InfoTypeTransformation( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - infoTypes_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - infoTypes_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.InfoType.parser(), extensionRegistry)); - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder subBuilder = null; - if (primitiveTransformation_ != null) { - subBuilder = primitiveTransformation_.toBuilder(); - } - primitiveTransformation_ = input.readMessage(com.google.privacy.dlp.v2beta1.PrimitiveTransformation.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(primitiveTransformation_); - primitiveTransformation_ = subBuilder.buildPartial(); - } - - 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) == 0x00000001)) { - infoTypes_ = java.util.Collections.unmodifiableList(infoTypes_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_InfoTypeTransformation_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_InfoTypeTransformation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.class, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder.class); - } - - private int bitField0_; - public static final int INFO_TYPES_FIELD_NUMBER = 1; - private java.util.List infoTypes_; - /** - *
-     * Info types to apply the transformation to. Empty list will match all
-     * available info types for this transformation.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public java.util.List getInfoTypesList() { - return infoTypes_; - } - /** - *
-     * Info types to apply the transformation to. Empty list will match all
-     * available info types for this transformation.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public java.util.List - getInfoTypesOrBuilderList() { - return infoTypes_; - } - /** - *
-     * Info types to apply the transformation to. Empty list will match all
-     * available info types for this transformation.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public int getInfoTypesCount() { - return infoTypes_.size(); - } - /** - *
-     * Info types to apply the transformation to. Empty list will match all
-     * available info types for this transformation.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoTypes(int index) { - return infoTypes_.get(index); - } - /** - *
-     * Info types to apply the transformation to. Empty list will match all
-     * available info types for this transformation.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypesOrBuilder( - int index) { - return infoTypes_.get(index); - } - - public static final int PRIMITIVE_TRANSFORMATION_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.PrimitiveTransformation primitiveTransformation_; - /** - *
-     * Primitive transformation to apply to the info type. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public boolean hasPrimitiveTransformation() { - return primitiveTransformation_ != null; - } - /** - *
-     * Primitive transformation to apply to the info type. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation getPrimitiveTransformation() { - return primitiveTransformation_ == null ? com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance() : primitiveTransformation_; - } - /** - *
-     * Primitive transformation to apply to the info type. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder getPrimitiveTransformationOrBuilder() { - return getPrimitiveTransformation(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < infoTypes_.size(); i++) { - output.writeMessage(1, infoTypes_.get(i)); - } - if (primitiveTransformation_ != null) { - output.writeMessage(2, getPrimitiveTransformation()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < infoTypes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, infoTypes_.get(i)); - } - if (primitiveTransformation_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getPrimitiveTransformation()); - } - 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.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation other = (com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation) obj; - - boolean result = true; - result = result && getInfoTypesList() - .equals(other.getInfoTypesList()); - result = result && (hasPrimitiveTransformation() == other.hasPrimitiveTransformation()); - if (hasPrimitiveTransformation()) { - result = result && getPrimitiveTransformation() - .equals(other.getPrimitiveTransformation()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getInfoTypesCount() > 0) { - hash = (37 * hash) + INFO_TYPES_FIELD_NUMBER; - hash = (53 * hash) + getInfoTypesList().hashCode(); - } - if (hasPrimitiveTransformation()) { - hash = (37 * hash) + PRIMITIVE_TRANSFORMATION_FIELD_NUMBER; - hash = (53 * hash) + getPrimitiveTransformation().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation 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.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation 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.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation 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.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-     * A transformation to apply to text that is identified as a specific
-     * info_type.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation) - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_InfoTypeTransformation_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_InfoTypeTransformation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.class, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getInfoTypesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (infoTypesBuilder_ == null) { - infoTypes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - infoTypesBuilder_.clear(); - } - if (primitiveTransformationBuilder_ == null) { - primitiveTransformation_ = null; - } else { - primitiveTransformation_ = null; - primitiveTransformationBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_InfoTypeTransformation_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation build() { - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation buildPartial() { - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation result = new com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (infoTypesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - infoTypes_ = java.util.Collections.unmodifiableList(infoTypes_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.infoTypes_ = infoTypes_; - } else { - result.infoTypes_ = infoTypesBuilder_.build(); - } - if (primitiveTransformationBuilder_ == null) { - result.primitiveTransformation_ = primitiveTransformation_; - } else { - result.primitiveTransformation_ = primitiveTransformationBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation other) { - if (other == com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.getDefaultInstance()) return this; - if (infoTypesBuilder_ == null) { - if (!other.infoTypes_.isEmpty()) { - if (infoTypes_.isEmpty()) { - infoTypes_ = other.infoTypes_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureInfoTypesIsMutable(); - infoTypes_.addAll(other.infoTypes_); - } - onChanged(); - } - } else { - if (!other.infoTypes_.isEmpty()) { - if (infoTypesBuilder_.isEmpty()) { - infoTypesBuilder_.dispose(); - infoTypesBuilder_ = null; - infoTypes_ = other.infoTypes_; - bitField0_ = (bitField0_ & ~0x00000001); - infoTypesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getInfoTypesFieldBuilder() : null; - } else { - infoTypesBuilder_.addAllMessages(other.infoTypes_); - } - } - } - if (other.hasPrimitiveTransformation()) { - mergePrimitiveTransformation(other.getPrimitiveTransformation()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List infoTypes_ = - java.util.Collections.emptyList(); - private void ensureInfoTypesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - infoTypes_ = new java.util.ArrayList(infoTypes_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> infoTypesBuilder_; - - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public java.util.List getInfoTypesList() { - if (infoTypesBuilder_ == null) { - return java.util.Collections.unmodifiableList(infoTypes_); - } else { - return infoTypesBuilder_.getMessageList(); - } - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public int getInfoTypesCount() { - if (infoTypesBuilder_ == null) { - return infoTypes_.size(); - } else { - return infoTypesBuilder_.getCount(); - } - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoTypes(int index) { - if (infoTypesBuilder_ == null) { - return infoTypes_.get(index); - } else { - return infoTypesBuilder_.getMessage(index); - } - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder setInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypesIsMutable(); - infoTypes_.set(index, value); - onChanged(); - } else { - infoTypesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder setInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.set(index, builderForValue.build()); - onChanged(); - } else { - infoTypesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder addInfoTypes(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypesIsMutable(); - infoTypes_.add(value); - onChanged(); - } else { - infoTypesBuilder_.addMessage(value); - } - return this; - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder addInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypesIsMutable(); - infoTypes_.add(index, value); - onChanged(); - } else { - infoTypesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder addInfoTypes( - com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.add(builderForValue.build()); - onChanged(); - } else { - infoTypesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder addInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.add(index, builderForValue.build()); - onChanged(); - } else { - infoTypesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder addAllInfoTypes( - java.lang.Iterable values) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, infoTypes_); - onChanged(); - } else { - infoTypesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder clearInfoTypes() { - if (infoTypesBuilder_ == null) { - infoTypes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - infoTypesBuilder_.clear(); - } - return this; - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder removeInfoTypes(int index) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.remove(index); - onChanged(); - } else { - infoTypesBuilder_.remove(index); - } - return this; - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder getInfoTypesBuilder( - int index) { - return getInfoTypesFieldBuilder().getBuilder(index); - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypesOrBuilder( - int index) { - if (infoTypesBuilder_ == null) { - return infoTypes_.get(index); } else { - return infoTypesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public java.util.List - getInfoTypesOrBuilderList() { - if (infoTypesBuilder_ != null) { - return infoTypesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(infoTypes_); - } - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder addInfoTypesBuilder() { - return getInfoTypesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance()); - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder addInfoTypesBuilder( - int index) { - return getInfoTypesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance()); - } - /** - *
-       * Info types to apply the transformation to. Empty list will match all
-       * available info types for this transformation.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public java.util.List - getInfoTypesBuilderList() { - return getInfoTypesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> - getInfoTypesFieldBuilder() { - if (infoTypesBuilder_ == null) { - infoTypesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder>( - infoTypes_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - infoTypes_ = null; - } - return infoTypesBuilder_; - } - - private com.google.privacy.dlp.v2beta1.PrimitiveTransformation primitiveTransformation_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrimitiveTransformation, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder, com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder> primitiveTransformationBuilder_; - /** - *
-       * Primitive transformation to apply to the info type. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public boolean hasPrimitiveTransformation() { - return primitiveTransformationBuilder_ != null || primitiveTransformation_ != null; - } - /** - *
-       * Primitive transformation to apply to the info type. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation getPrimitiveTransformation() { - if (primitiveTransformationBuilder_ == null) { - return primitiveTransformation_ == null ? com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance() : primitiveTransformation_; - } else { - return primitiveTransformationBuilder_.getMessage(); - } - } - /** - *
-       * Primitive transformation to apply to the info type. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public Builder setPrimitiveTransformation(com.google.privacy.dlp.v2beta1.PrimitiveTransformation value) { - if (primitiveTransformationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - primitiveTransformation_ = value; - onChanged(); - } else { - primitiveTransformationBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Primitive transformation to apply to the info type. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public Builder setPrimitiveTransformation( - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder builderForValue) { - if (primitiveTransformationBuilder_ == null) { - primitiveTransformation_ = builderForValue.build(); - onChanged(); - } else { - primitiveTransformationBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Primitive transformation to apply to the info type. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public Builder mergePrimitiveTransformation(com.google.privacy.dlp.v2beta1.PrimitiveTransformation value) { - if (primitiveTransformationBuilder_ == null) { - if (primitiveTransformation_ != null) { - primitiveTransformation_ = - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.newBuilder(primitiveTransformation_).mergeFrom(value).buildPartial(); - } else { - primitiveTransformation_ = value; - } - onChanged(); - } else { - primitiveTransformationBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Primitive transformation to apply to the info type. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public Builder clearPrimitiveTransformation() { - if (primitiveTransformationBuilder_ == null) { - primitiveTransformation_ = null; - onChanged(); - } else { - primitiveTransformation_ = null; - primitiveTransformationBuilder_ = null; - } - - return this; - } - /** - *
-       * Primitive transformation to apply to the info type. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder getPrimitiveTransformationBuilder() { - - onChanged(); - return getPrimitiveTransformationFieldBuilder().getBuilder(); - } - /** - *
-       * Primitive transformation to apply to the info type. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder getPrimitiveTransformationOrBuilder() { - if (primitiveTransformationBuilder_ != null) { - return primitiveTransformationBuilder_.getMessageOrBuilder(); - } else { - return primitiveTransformation_ == null ? - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance() : primitiveTransformation_; - } - } - /** - *
-       * Primitive transformation to apply to the info type. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation primitive_transformation = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrimitiveTransformation, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder, com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder> - getPrimitiveTransformationFieldBuilder() { - if (primitiveTransformationBuilder_ == null) { - primitiveTransformationBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrimitiveTransformation, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder, com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder>( - getPrimitiveTransformation(), - getParentForChildren(), - isClean()); - primitiveTransformation_ = null; - } - return primitiveTransformationBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation) - private static final com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation(); - } - - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InfoTypeTransformation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InfoTypeTransformation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public static final int TRANSFORMATIONS_FIELD_NUMBER = 1; - private java.util.List transformations_; - /** - *
-   * Transformation for each info type. Cannot specify more than one
-   * for a given info type. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public java.util.List getTransformationsList() { - return transformations_; - } - /** - *
-   * Transformation for each info type. Cannot specify more than one
-   * for a given info type. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public java.util.List - getTransformationsOrBuilderList() { - return transformations_; - } - /** - *
-   * Transformation for each info type. Cannot specify more than one
-   * for a given info type. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public int getTransformationsCount() { - return transformations_.size(); - } - /** - *
-   * Transformation for each info type. Cannot specify more than one
-   * for a given info type. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation getTransformations(int index) { - return transformations_.get(index); - } - /** - *
-   * Transformation for each info type. Cannot specify more than one
-   * for a given info type. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformationOrBuilder getTransformationsOrBuilder( - int index) { - return transformations_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < transformations_.size(); i++) { - output.writeMessage(1, transformations_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < transformations_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, transformations_.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.privacy.dlp.v2beta1.InfoTypeTransformations)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InfoTypeTransformations other = (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) obj; - - boolean result = true; - result = result && getTransformationsList() - .equals(other.getTransformationsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getTransformationsCount() > 0) { - hash = (37 * hash) + TRANSFORMATIONS_FIELD_NUMBER; - hash = (53 * hash) + getTransformationsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations 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.privacy.dlp.v2beta1.InfoTypeTransformations parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations 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.privacy.dlp.v2beta1.InfoTypeTransformations parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations 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.privacy.dlp.v2beta1.InfoTypeTransformations parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InfoTypeTransformations prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * A type of transformation that will scan unstructured text and
-   * apply various `PrimitiveTransformation`s to each finding, where the
-   * transformation is applied to only values that were identified as a specific
-   * info_type.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InfoTypeTransformations} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InfoTypeTransformations) - com.google.privacy.dlp.v2beta1.InfoTypeTransformationsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.class, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InfoTypeTransformations.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getTransformationsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (transformationsBuilder_ == null) { - transformations_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - transformationsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InfoTypeTransformations_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations build() { - com.google.privacy.dlp.v2beta1.InfoTypeTransformations result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations buildPartial() { - com.google.privacy.dlp.v2beta1.InfoTypeTransformations result = new com.google.privacy.dlp.v2beta1.InfoTypeTransformations(this); - int from_bitField0_ = bitField0_; - if (transformationsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - transformations_ = java.util.Collections.unmodifiableList(transformations_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.transformations_ = transformations_; - } else { - result.transformations_ = transformationsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InfoTypeTransformations) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InfoTypeTransformations)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InfoTypeTransformations other) { - if (other == com.google.privacy.dlp.v2beta1.InfoTypeTransformations.getDefaultInstance()) return this; - if (transformationsBuilder_ == null) { - if (!other.transformations_.isEmpty()) { - if (transformations_.isEmpty()) { - transformations_ = other.transformations_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureTransformationsIsMutable(); - transformations_.addAll(other.transformations_); - } - onChanged(); - } - } else { - if (!other.transformations_.isEmpty()) { - if (transformationsBuilder_.isEmpty()) { - transformationsBuilder_.dispose(); - transformationsBuilder_ = null; - transformations_ = other.transformations_; - bitField0_ = (bitField0_ & ~0x00000001); - transformationsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getTransformationsFieldBuilder() : null; - } else { - transformationsBuilder_.addAllMessages(other.transformations_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InfoTypeTransformations parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InfoTypeTransformations) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List transformations_ = - java.util.Collections.emptyList(); - private void ensureTransformationsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - transformations_ = new java.util.ArrayList(transformations_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformationOrBuilder> transformationsBuilder_; - - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public java.util.List getTransformationsList() { - if (transformationsBuilder_ == null) { - return java.util.Collections.unmodifiableList(transformations_); - } else { - return transformationsBuilder_.getMessageList(); - } - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public int getTransformationsCount() { - if (transformationsBuilder_ == null) { - return transformations_.size(); - } else { - return transformationsBuilder_.getCount(); - } - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation getTransformations(int index) { - if (transformationsBuilder_ == null) { - return transformations_.get(index); - } else { - return transformationsBuilder_.getMessage(index); - } - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public Builder setTransformations( - int index, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation value) { - if (transformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTransformationsIsMutable(); - transformations_.set(index, value); - onChanged(); - } else { - transformationsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public Builder setTransformations( - int index, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder builderForValue) { - if (transformationsBuilder_ == null) { - ensureTransformationsIsMutable(); - transformations_.set(index, builderForValue.build()); - onChanged(); - } else { - transformationsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public Builder addTransformations(com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation value) { - if (transformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTransformationsIsMutable(); - transformations_.add(value); - onChanged(); - } else { - transformationsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public Builder addTransformations( - int index, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation value) { - if (transformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTransformationsIsMutable(); - transformations_.add(index, value); - onChanged(); - } else { - transformationsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public Builder addTransformations( - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder builderForValue) { - if (transformationsBuilder_ == null) { - ensureTransformationsIsMutable(); - transformations_.add(builderForValue.build()); - onChanged(); - } else { - transformationsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public Builder addTransformations( - int index, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder builderForValue) { - if (transformationsBuilder_ == null) { - ensureTransformationsIsMutable(); - transformations_.add(index, builderForValue.build()); - onChanged(); - } else { - transformationsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public Builder addAllTransformations( - java.lang.Iterable values) { - if (transformationsBuilder_ == null) { - ensureTransformationsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, transformations_); - onChanged(); - } else { - transformationsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public Builder clearTransformations() { - if (transformationsBuilder_ == null) { - transformations_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - transformationsBuilder_.clear(); - } - return this; - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public Builder removeTransformations(int index) { - if (transformationsBuilder_ == null) { - ensureTransformationsIsMutable(); - transformations_.remove(index); - onChanged(); - } else { - transformationsBuilder_.remove(index); - } - return this; - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder getTransformationsBuilder( - int index) { - return getTransformationsFieldBuilder().getBuilder(index); - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformationOrBuilder getTransformationsOrBuilder( - int index) { - if (transformationsBuilder_ == null) { - return transformations_.get(index); } else { - return transformationsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public java.util.List - getTransformationsOrBuilderList() { - if (transformationsBuilder_ != null) { - return transformationsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(transformations_); - } - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder addTransformationsBuilder() { - return getTransformationsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.getDefaultInstance()); - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder addTransformationsBuilder( - int index) { - return getTransformationsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.getDefaultInstance()); - } - /** - *
-     * Transformation for each info type. Cannot specify more than one
-     * for a given info type. [required]
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - public java.util.List - getTransformationsBuilderList() { - return getTransformationsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformationOrBuilder> - getTransformationsFieldBuilder() { - if (transformationsBuilder_ == null) { - transformationsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation.Builder, com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformationOrBuilder>( - transformations_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - transformations_ = null; - } - return transformationsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InfoTypeTransformations) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InfoTypeTransformations) - private static final com.google.privacy.dlp.v2beta1.InfoTypeTransformations DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InfoTypeTransformations(); - } - - public static com.google.privacy.dlp.v2beta1.InfoTypeTransformations getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InfoTypeTransformations parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InfoTypeTransformations(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InfoTypeTransformations getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeTransformationsOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeTransformationsOrBuilder.java deleted file mode 100644 index 1873de436605..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InfoTypeTransformationsOrBuilder.java +++ /dev/null @@ -1,58 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface InfoTypeTransformationsOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InfoTypeTransformations) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Transformation for each info type. Cannot specify more than one
-   * for a given info type. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - java.util.List - getTransformationsList(); - /** - *
-   * Transformation for each info type. Cannot specify more than one
-   * for a given info type. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation getTransformations(int index); - /** - *
-   * Transformation for each info type. Cannot specify more than one
-   * for a given info type. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - int getTransformationsCount(); - /** - *
-   * Transformation for each info type. Cannot specify more than one
-   * for a given info type. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - java.util.List - getTransformationsOrBuilderList(); - /** - *
-   * Transformation for each info type. Cannot specify more than one
-   * for a given info type. [required]
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformation transformations = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeTransformations.InfoTypeTransformationOrBuilder getTransformationsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectConfig.java deleted file mode 100644 index b4d362aeec4b..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectConfig.java +++ /dev/null @@ -1,2876 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Configuration description of the scanning process.
- * When used with redactContent only info_types and min_likelihood are currently
- * used.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectConfig} - */ -public final class InspectConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InspectConfig) - InspectConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use InspectConfig.newBuilder() to construct. - private InspectConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InspectConfig() { - infoTypes_ = java.util.Collections.emptyList(); - minLikelihood_ = 0; - maxFindings_ = 0; - includeQuote_ = false; - excludeTypes_ = false; - infoTypeLimits_ = java.util.Collections.emptyList(); - customInfoTypes_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InspectConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - infoTypes_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - infoTypes_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.InfoType.parser(), extensionRegistry)); - break; - } - case 16: { - int rawValue = input.readEnum(); - - minLikelihood_ = rawValue; - break; - } - case 24: { - - maxFindings_ = input.readInt32(); - break; - } - case 32: { - - includeQuote_ = input.readBool(); - break; - } - case 48: { - - excludeTypes_ = input.readBool(); - break; - } - case 58: { - if (!((mutable_bitField0_ & 0x00000020) == 0x00000020)) { - infoTypeLimits_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000020; - } - infoTypeLimits_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.parser(), extensionRegistry)); - break; - } - case 66: { - if (!((mutable_bitField0_ & 0x00000040) == 0x00000040)) { - customInfoTypes_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000040; - } - customInfoTypes_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.CustomInfoType.parser(), extensionRegistry)); - 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) == 0x00000001)) { - infoTypes_ = java.util.Collections.unmodifiableList(infoTypes_); - } - if (((mutable_bitField0_ & 0x00000020) == 0x00000020)) { - infoTypeLimits_ = java.util.Collections.unmodifiableList(infoTypeLimits_); - } - if (((mutable_bitField0_ & 0x00000040) == 0x00000040)) { - customInfoTypes_ = java.util.Collections.unmodifiableList(customInfoTypes_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectConfig.class, com.google.privacy.dlp.v2beta1.InspectConfig.Builder.class); - } - - public interface InfoTypeLimitOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Type of information the findings limit applies to. Only one limit per
-     * info_type should be provided. If InfoTypeLimit does not have an
-     * info_type, the DLP API applies the limit against all info_types that are
-     * found but not specified in another InfoTypeLimit.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - boolean hasInfoType(); - /** - *
-     * Type of information the findings limit applies to. Only one limit per
-     * info_type should be provided. If InfoTypeLimit does not have an
-     * info_type, the DLP API applies the limit against all info_types that are
-     * found but not specified in another InfoTypeLimit.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoType getInfoType(); - /** - *
-     * Type of information the findings limit applies to. Only one limit per
-     * info_type should be provided. If InfoTypeLimit does not have an
-     * info_type, the DLP API applies the limit against all info_types that are
-     * found but not specified in another InfoTypeLimit.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder(); - - /** - *
-     * Max findings limit for the given infoType.
-     * 
- * - * int32 max_findings = 2; - */ - int getMaxFindings(); - } - /** - *
-   * Max findings configuration per info type, per content item or long running
-   * operation.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit} - */ - public static final class InfoTypeLimit extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit) - InfoTypeLimitOrBuilder { - private static final long serialVersionUID = 0L; - // Use InfoTypeLimit.newBuilder() to construct. - private InfoTypeLimit(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InfoTypeLimit() { - maxFindings_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InfoTypeLimit( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InfoType.Builder subBuilder = null; - if (infoType_ != null) { - subBuilder = infoType_.toBuilder(); - } - infoType_ = input.readMessage(com.google.privacy.dlp.v2beta1.InfoType.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(infoType_); - infoType_ = subBuilder.buildPartial(); - } - - break; - } - case 16: { - - maxFindings_ = input.readInt32(); - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectConfig_InfoTypeLimit_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectConfig_InfoTypeLimit_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.class, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder.class); - } - - public static final int INFO_TYPE_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.InfoType infoType_; - /** - *
-     * Type of information the findings limit applies to. Only one limit per
-     * info_type should be provided. If InfoTypeLimit does not have an
-     * info_type, the DLP API applies the limit against all info_types that are
-     * found but not specified in another InfoTypeLimit.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return infoType_ != null; - } - /** - *
-     * Type of information the findings limit applies to. Only one limit per
-     * info_type should be provided. If InfoTypeLimit does not have an
-     * info_type, the DLP API applies the limit against all info_types that are
-     * found but not specified in another InfoTypeLimit.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - /** - *
-     * Type of information the findings limit applies to. Only one limit per
-     * info_type should be provided. If InfoTypeLimit does not have an
-     * info_type, the DLP API applies the limit against all info_types that are
-     * found but not specified in another InfoTypeLimit.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - return getInfoType(); - } - - public static final int MAX_FINDINGS_FIELD_NUMBER = 2; - private int maxFindings_; - /** - *
-     * Max findings limit for the given infoType.
-     * 
- * - * int32 max_findings = 2; - */ - public int getMaxFindings() { - return maxFindings_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (infoType_ != null) { - output.writeMessage(1, getInfoType()); - } - if (maxFindings_ != 0) { - output.writeInt32(2, maxFindings_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (infoType_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getInfoType()); - } - if (maxFindings_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(2, maxFindings_); - } - 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.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit other = (com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit) obj; - - boolean result = true; - result = result && (hasInfoType() == other.hasInfoType()); - if (hasInfoType()) { - result = result && getInfoType() - .equals(other.getInfoType()); - } - result = result && (getMaxFindings() - == other.getMaxFindings()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasInfoType()) { - hash = (37 * hash) + INFO_TYPE_FIELD_NUMBER; - hash = (53 * hash) + getInfoType().hashCode(); - } - hash = (37 * hash) + MAX_FINDINGS_FIELD_NUMBER; - hash = (53 * hash) + getMaxFindings(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit 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.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit 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.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit 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.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * Max findings configuration per info type, per content item or long running
-     * operation.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit) - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimitOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectConfig_InfoTypeLimit_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectConfig_InfoTypeLimit_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.class, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (infoTypeBuilder_ == null) { - infoType_ = null; - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - maxFindings_ = 0; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectConfig_InfoTypeLimit_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit build() { - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit buildPartial() { - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit result = new com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit(this); - if (infoTypeBuilder_ == null) { - result.infoType_ = infoType_; - } else { - result.infoType_ = infoTypeBuilder_.build(); - } - result.maxFindings_ = maxFindings_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit other) { - if (other == com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.getDefaultInstance()) return this; - if (other.hasInfoType()) { - mergeInfoType(other.getInfoType()); - } - if (other.getMaxFindings() != 0) { - setMaxFindings(other.getMaxFindings()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.InfoType infoType_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> infoTypeBuilder_; - /** - *
-       * Type of information the findings limit applies to. Only one limit per
-       * info_type should be provided. If InfoTypeLimit does not have an
-       * info_type, the DLP API applies the limit against all info_types that are
-       * found but not specified in another InfoTypeLimit.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return infoTypeBuilder_ != null || infoType_ != null; - } - /** - *
-       * Type of information the findings limit applies to. Only one limit per
-       * info_type should be provided. If InfoTypeLimit does not have an
-       * info_type, the DLP API applies the limit against all info_types that are
-       * found but not specified in another InfoTypeLimit.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - if (infoTypeBuilder_ == null) { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } else { - return infoTypeBuilder_.getMessage(); - } - } - /** - *
-       * Type of information the findings limit applies to. Only one limit per
-       * info_type should be provided. If InfoTypeLimit does not have an
-       * info_type, the DLP API applies the limit against all info_types that are
-       * found but not specified in another InfoTypeLimit.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - infoType_ = value; - onChanged(); - } else { - infoTypeBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Type of information the findings limit applies to. Only one limit per
-       * info_type should be provided. If InfoTypeLimit does not have an
-       * info_type, the DLP API applies the limit against all info_types that are
-       * found but not specified in another InfoTypeLimit.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType( - com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypeBuilder_ == null) { - infoType_ = builderForValue.build(); - onChanged(); - } else { - infoTypeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Type of information the findings limit applies to. Only one limit per
-       * info_type should be provided. If InfoTypeLimit does not have an
-       * info_type, the DLP API applies the limit against all info_types that are
-       * found but not specified in another InfoTypeLimit.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder mergeInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (infoType_ != null) { - infoType_ = - com.google.privacy.dlp.v2beta1.InfoType.newBuilder(infoType_).mergeFrom(value).buildPartial(); - } else { - infoType_ = value; - } - onChanged(); - } else { - infoTypeBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Type of information the findings limit applies to. Only one limit per
-       * info_type should be provided. If InfoTypeLimit does not have an
-       * info_type, the DLP API applies the limit against all info_types that are
-       * found but not specified in another InfoTypeLimit.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder clearInfoType() { - if (infoTypeBuilder_ == null) { - infoType_ = null; - onChanged(); - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - - return this; - } - /** - *
-       * Type of information the findings limit applies to. Only one limit per
-       * info_type should be provided. If InfoTypeLimit does not have an
-       * info_type, the DLP API applies the limit against all info_types that are
-       * found but not specified in another InfoTypeLimit.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder getInfoTypeBuilder() { - - onChanged(); - return getInfoTypeFieldBuilder().getBuilder(); - } - /** - *
-       * Type of information the findings limit applies to. Only one limit per
-       * info_type should be provided. If InfoTypeLimit does not have an
-       * info_type, the DLP API applies the limit against all info_types that are
-       * found but not specified in another InfoTypeLimit.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - if (infoTypeBuilder_ != null) { - return infoTypeBuilder_.getMessageOrBuilder(); - } else { - return infoType_ == null ? - com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - } - /** - *
-       * Type of information the findings limit applies to. Only one limit per
-       * info_type should be provided. If InfoTypeLimit does not have an
-       * info_type, the DLP API applies the limit against all info_types that are
-       * found but not specified in another InfoTypeLimit.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> - getInfoTypeFieldBuilder() { - if (infoTypeBuilder_ == null) { - infoTypeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder>( - getInfoType(), - getParentForChildren(), - isClean()); - infoType_ = null; - } - return infoTypeBuilder_; - } - - private int maxFindings_ ; - /** - *
-       * Max findings limit for the given infoType.
-       * 
- * - * int32 max_findings = 2; - */ - public int getMaxFindings() { - return maxFindings_; - } - /** - *
-       * Max findings limit for the given infoType.
-       * 
- * - * int32 max_findings = 2; - */ - public Builder setMaxFindings(int value) { - - maxFindings_ = value; - onChanged(); - return this; - } - /** - *
-       * Max findings limit for the given infoType.
-       * 
- * - * int32 max_findings = 2; - */ - public Builder clearMaxFindings() { - - maxFindings_ = 0; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit) - private static final com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit(); - } - - public static com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InfoTypeLimit parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InfoTypeLimit(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int bitField0_; - public static final int INFO_TYPES_FIELD_NUMBER = 1; - private java.util.List infoTypes_; - /** - *
-   * Restricts what info_types to look for. The values must correspond to
-   * InfoType values returned by ListInfoTypes or found in documentation.
-   * Empty info_types runs all enabled detectors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public java.util.List getInfoTypesList() { - return infoTypes_; - } - /** - *
-   * Restricts what info_types to look for. The values must correspond to
-   * InfoType values returned by ListInfoTypes or found in documentation.
-   * Empty info_types runs all enabled detectors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public java.util.List - getInfoTypesOrBuilderList() { - return infoTypes_; - } - /** - *
-   * Restricts what info_types to look for. The values must correspond to
-   * InfoType values returned by ListInfoTypes or found in documentation.
-   * Empty info_types runs all enabled detectors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public int getInfoTypesCount() { - return infoTypes_.size(); - } - /** - *
-   * Restricts what info_types to look for. The values must correspond to
-   * InfoType values returned by ListInfoTypes or found in documentation.
-   * Empty info_types runs all enabled detectors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoTypes(int index) { - return infoTypes_.get(index); - } - /** - *
-   * Restricts what info_types to look for. The values must correspond to
-   * InfoType values returned by ListInfoTypes or found in documentation.
-   * Empty info_types runs all enabled detectors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypesOrBuilder( - int index) { - return infoTypes_.get(index); - } - - public static final int MIN_LIKELIHOOD_FIELD_NUMBER = 2; - private int minLikelihood_; - /** - *
-   * Only returns findings equal or above this threshold.
-   * 
- * - * .google.privacy.dlp.v2beta1.Likelihood min_likelihood = 2; - */ - public int getMinLikelihoodValue() { - return minLikelihood_; - } - /** - *
-   * Only returns findings equal or above this threshold.
-   * 
- * - * .google.privacy.dlp.v2beta1.Likelihood min_likelihood = 2; - */ - public com.google.privacy.dlp.v2beta1.Likelihood getMinLikelihood() { - com.google.privacy.dlp.v2beta1.Likelihood result = com.google.privacy.dlp.v2beta1.Likelihood.valueOf(minLikelihood_); - return result == null ? com.google.privacy.dlp.v2beta1.Likelihood.UNRECOGNIZED : result; - } - - public static final int MAX_FINDINGS_FIELD_NUMBER = 3; - private int maxFindings_; - /** - *
-   * Limits the number of findings per content item or long running operation.
-   * 
- * - * int32 max_findings = 3; - */ - public int getMaxFindings() { - return maxFindings_; - } - - public static final int INCLUDE_QUOTE_FIELD_NUMBER = 4; - private boolean includeQuote_; - /** - *
-   * When true, a contextual quote from the data that triggered a finding is
-   * included in the response; see Finding.quote.
-   * 
- * - * bool include_quote = 4; - */ - public boolean getIncludeQuote() { - return includeQuote_; - } - - public static final int EXCLUDE_TYPES_FIELD_NUMBER = 6; - private boolean excludeTypes_; - /** - *
-   * When true, excludes type information of the findings.
-   * 
- * - * bool exclude_types = 6; - */ - public boolean getExcludeTypes() { - return excludeTypes_; - } - - public static final int INFO_TYPE_LIMITS_FIELD_NUMBER = 7; - private java.util.List infoTypeLimits_; - /** - *
-   * Configuration of findings limit given for specified info types.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public java.util.List getInfoTypeLimitsList() { - return infoTypeLimits_; - } - /** - *
-   * Configuration of findings limit given for specified info types.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public java.util.List - getInfoTypeLimitsOrBuilderList() { - return infoTypeLimits_; - } - /** - *
-   * Configuration of findings limit given for specified info types.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public int getInfoTypeLimitsCount() { - return infoTypeLimits_.size(); - } - /** - *
-   * Configuration of findings limit given for specified info types.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit getInfoTypeLimits(int index) { - return infoTypeLimits_.get(index); - } - /** - *
-   * Configuration of findings limit given for specified info types.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimitOrBuilder getInfoTypeLimitsOrBuilder( - int index) { - return infoTypeLimits_.get(index); - } - - public static final int CUSTOM_INFO_TYPES_FIELD_NUMBER = 8; - private java.util.List customInfoTypes_; - /** - *
-   * Custom info types provided by the user.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public java.util.List getCustomInfoTypesList() { - return customInfoTypes_; - } - /** - *
-   * Custom info types provided by the user.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public java.util.List - getCustomInfoTypesOrBuilderList() { - return customInfoTypes_; - } - /** - *
-   * Custom info types provided by the user.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public int getCustomInfoTypesCount() { - return customInfoTypes_.size(); - } - /** - *
-   * Custom info types provided by the user.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType getCustomInfoTypes(int index) { - return customInfoTypes_.get(index); - } - /** - *
-   * Custom info types provided by the user.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoTypeOrBuilder getCustomInfoTypesOrBuilder( - int index) { - return customInfoTypes_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < infoTypes_.size(); i++) { - output.writeMessage(1, infoTypes_.get(i)); - } - if (minLikelihood_ != com.google.privacy.dlp.v2beta1.Likelihood.LIKELIHOOD_UNSPECIFIED.getNumber()) { - output.writeEnum(2, minLikelihood_); - } - if (maxFindings_ != 0) { - output.writeInt32(3, maxFindings_); - } - if (includeQuote_ != false) { - output.writeBool(4, includeQuote_); - } - if (excludeTypes_ != false) { - output.writeBool(6, excludeTypes_); - } - for (int i = 0; i < infoTypeLimits_.size(); i++) { - output.writeMessage(7, infoTypeLimits_.get(i)); - } - for (int i = 0; i < customInfoTypes_.size(); i++) { - output.writeMessage(8, customInfoTypes_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < infoTypes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, infoTypes_.get(i)); - } - if (minLikelihood_ != com.google.privacy.dlp.v2beta1.Likelihood.LIKELIHOOD_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(2, minLikelihood_); - } - if (maxFindings_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(3, maxFindings_); - } - if (includeQuote_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(4, includeQuote_); - } - if (excludeTypes_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(6, excludeTypes_); - } - for (int i = 0; i < infoTypeLimits_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(7, infoTypeLimits_.get(i)); - } - for (int i = 0; i < customInfoTypes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(8, customInfoTypes_.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.privacy.dlp.v2beta1.InspectConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InspectConfig other = (com.google.privacy.dlp.v2beta1.InspectConfig) obj; - - boolean result = true; - result = result && getInfoTypesList() - .equals(other.getInfoTypesList()); - result = result && minLikelihood_ == other.minLikelihood_; - result = result && (getMaxFindings() - == other.getMaxFindings()); - result = result && (getIncludeQuote() - == other.getIncludeQuote()); - result = result && (getExcludeTypes() - == other.getExcludeTypes()); - result = result && getInfoTypeLimitsList() - .equals(other.getInfoTypeLimitsList()); - result = result && getCustomInfoTypesList() - .equals(other.getCustomInfoTypesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getInfoTypesCount() > 0) { - hash = (37 * hash) + INFO_TYPES_FIELD_NUMBER; - hash = (53 * hash) + getInfoTypesList().hashCode(); - } - hash = (37 * hash) + MIN_LIKELIHOOD_FIELD_NUMBER; - hash = (53 * hash) + minLikelihood_; - hash = (37 * hash) + MAX_FINDINGS_FIELD_NUMBER; - hash = (53 * hash) + getMaxFindings(); - hash = (37 * hash) + INCLUDE_QUOTE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getIncludeQuote()); - hash = (37 * hash) + EXCLUDE_TYPES_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getExcludeTypes()); - if (getInfoTypeLimitsCount() > 0) { - hash = (37 * hash) + INFO_TYPE_LIMITS_FIELD_NUMBER; - hash = (53 * hash) + getInfoTypeLimitsList().hashCode(); - } - if (getCustomInfoTypesCount() > 0) { - hash = (37 * hash) + CUSTOM_INFO_TYPES_FIELD_NUMBER; - hash = (53 * hash) + getCustomInfoTypesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InspectConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig 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.privacy.dlp.v2beta1.InspectConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig 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.privacy.dlp.v2beta1.InspectConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig 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.privacy.dlp.v2beta1.InspectConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InspectConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Configuration description of the scanning process.
-   * When used with redactContent only info_types and min_likelihood are currently
-   * used.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InspectConfig) - com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectConfig.class, com.google.privacy.dlp.v2beta1.InspectConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InspectConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getInfoTypesFieldBuilder(); - getInfoTypeLimitsFieldBuilder(); - getCustomInfoTypesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (infoTypesBuilder_ == null) { - infoTypes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - infoTypesBuilder_.clear(); - } - minLikelihood_ = 0; - - maxFindings_ = 0; - - includeQuote_ = false; - - excludeTypes_ = false; - - if (infoTypeLimitsBuilder_ == null) { - infoTypeLimits_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000020); - } else { - infoTypeLimitsBuilder_.clear(); - } - if (customInfoTypesBuilder_ == null) { - customInfoTypes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000040); - } else { - customInfoTypesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InspectConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InspectConfig build() { - com.google.privacy.dlp.v2beta1.InspectConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InspectConfig buildPartial() { - com.google.privacy.dlp.v2beta1.InspectConfig result = new com.google.privacy.dlp.v2beta1.InspectConfig(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (infoTypesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - infoTypes_ = java.util.Collections.unmodifiableList(infoTypes_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.infoTypes_ = infoTypes_; - } else { - result.infoTypes_ = infoTypesBuilder_.build(); - } - result.minLikelihood_ = minLikelihood_; - result.maxFindings_ = maxFindings_; - result.includeQuote_ = includeQuote_; - result.excludeTypes_ = excludeTypes_; - if (infoTypeLimitsBuilder_ == null) { - if (((bitField0_ & 0x00000020) == 0x00000020)) { - infoTypeLimits_ = java.util.Collections.unmodifiableList(infoTypeLimits_); - bitField0_ = (bitField0_ & ~0x00000020); - } - result.infoTypeLimits_ = infoTypeLimits_; - } else { - result.infoTypeLimits_ = infoTypeLimitsBuilder_.build(); - } - if (customInfoTypesBuilder_ == null) { - if (((bitField0_ & 0x00000040) == 0x00000040)) { - customInfoTypes_ = java.util.Collections.unmodifiableList(customInfoTypes_); - bitField0_ = (bitField0_ & ~0x00000040); - } - result.customInfoTypes_ = customInfoTypes_; - } else { - result.customInfoTypes_ = customInfoTypesBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InspectConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InspectConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InspectConfig other) { - if (other == com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance()) return this; - if (infoTypesBuilder_ == null) { - if (!other.infoTypes_.isEmpty()) { - if (infoTypes_.isEmpty()) { - infoTypes_ = other.infoTypes_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureInfoTypesIsMutable(); - infoTypes_.addAll(other.infoTypes_); - } - onChanged(); - } - } else { - if (!other.infoTypes_.isEmpty()) { - if (infoTypesBuilder_.isEmpty()) { - infoTypesBuilder_.dispose(); - infoTypesBuilder_ = null; - infoTypes_ = other.infoTypes_; - bitField0_ = (bitField0_ & ~0x00000001); - infoTypesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getInfoTypesFieldBuilder() : null; - } else { - infoTypesBuilder_.addAllMessages(other.infoTypes_); - } - } - } - if (other.minLikelihood_ != 0) { - setMinLikelihoodValue(other.getMinLikelihoodValue()); - } - if (other.getMaxFindings() != 0) { - setMaxFindings(other.getMaxFindings()); - } - if (other.getIncludeQuote() != false) { - setIncludeQuote(other.getIncludeQuote()); - } - if (other.getExcludeTypes() != false) { - setExcludeTypes(other.getExcludeTypes()); - } - if (infoTypeLimitsBuilder_ == null) { - if (!other.infoTypeLimits_.isEmpty()) { - if (infoTypeLimits_.isEmpty()) { - infoTypeLimits_ = other.infoTypeLimits_; - bitField0_ = (bitField0_ & ~0x00000020); - } else { - ensureInfoTypeLimitsIsMutable(); - infoTypeLimits_.addAll(other.infoTypeLimits_); - } - onChanged(); - } - } else { - if (!other.infoTypeLimits_.isEmpty()) { - if (infoTypeLimitsBuilder_.isEmpty()) { - infoTypeLimitsBuilder_.dispose(); - infoTypeLimitsBuilder_ = null; - infoTypeLimits_ = other.infoTypeLimits_; - bitField0_ = (bitField0_ & ~0x00000020); - infoTypeLimitsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getInfoTypeLimitsFieldBuilder() : null; - } else { - infoTypeLimitsBuilder_.addAllMessages(other.infoTypeLimits_); - } - } - } - if (customInfoTypesBuilder_ == null) { - if (!other.customInfoTypes_.isEmpty()) { - if (customInfoTypes_.isEmpty()) { - customInfoTypes_ = other.customInfoTypes_; - bitField0_ = (bitField0_ & ~0x00000040); - } else { - ensureCustomInfoTypesIsMutable(); - customInfoTypes_.addAll(other.customInfoTypes_); - } - onChanged(); - } - } else { - if (!other.customInfoTypes_.isEmpty()) { - if (customInfoTypesBuilder_.isEmpty()) { - customInfoTypesBuilder_.dispose(); - customInfoTypesBuilder_ = null; - customInfoTypes_ = other.customInfoTypes_; - bitField0_ = (bitField0_ & ~0x00000040); - customInfoTypesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getCustomInfoTypesFieldBuilder() : null; - } else { - customInfoTypesBuilder_.addAllMessages(other.customInfoTypes_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InspectConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InspectConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List infoTypes_ = - java.util.Collections.emptyList(); - private void ensureInfoTypesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - infoTypes_ = new java.util.ArrayList(infoTypes_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> infoTypesBuilder_; - - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public java.util.List getInfoTypesList() { - if (infoTypesBuilder_ == null) { - return java.util.Collections.unmodifiableList(infoTypes_); - } else { - return infoTypesBuilder_.getMessageList(); - } - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public int getInfoTypesCount() { - if (infoTypesBuilder_ == null) { - return infoTypes_.size(); - } else { - return infoTypesBuilder_.getCount(); - } - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoTypes(int index) { - if (infoTypesBuilder_ == null) { - return infoTypes_.get(index); - } else { - return infoTypesBuilder_.getMessage(index); - } - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder setInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypesIsMutable(); - infoTypes_.set(index, value); - onChanged(); - } else { - infoTypesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder setInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.set(index, builderForValue.build()); - onChanged(); - } else { - infoTypesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder addInfoTypes(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypesIsMutable(); - infoTypes_.add(value); - onChanged(); - } else { - infoTypesBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder addInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypesIsMutable(); - infoTypes_.add(index, value); - onChanged(); - } else { - infoTypesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder addInfoTypes( - com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.add(builderForValue.build()); - onChanged(); - } else { - infoTypesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder addInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.add(index, builderForValue.build()); - onChanged(); - } else { - infoTypesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder addAllInfoTypes( - java.lang.Iterable values) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, infoTypes_); - onChanged(); - } else { - infoTypesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder clearInfoTypes() { - if (infoTypesBuilder_ == null) { - infoTypes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - infoTypesBuilder_.clear(); - } - return this; - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public Builder removeInfoTypes(int index) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.remove(index); - onChanged(); - } else { - infoTypesBuilder_.remove(index); - } - return this; - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder getInfoTypesBuilder( - int index) { - return getInfoTypesFieldBuilder().getBuilder(index); - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypesOrBuilder( - int index) { - if (infoTypesBuilder_ == null) { - return infoTypes_.get(index); } else { - return infoTypesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public java.util.List - getInfoTypesOrBuilderList() { - if (infoTypesBuilder_ != null) { - return infoTypesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(infoTypes_); - } - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder addInfoTypesBuilder() { - return getInfoTypesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance()); - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder addInfoTypesBuilder( - int index) { - return getInfoTypesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance()); - } - /** - *
-     * Restricts what info_types to look for. The values must correspond to
-     * InfoType values returned by ListInfoTypes or found in documentation.
-     * Empty info_types runs all enabled detectors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - public java.util.List - getInfoTypesBuilderList() { - return getInfoTypesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> - getInfoTypesFieldBuilder() { - if (infoTypesBuilder_ == null) { - infoTypesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder>( - infoTypes_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - infoTypes_ = null; - } - return infoTypesBuilder_; - } - - private int minLikelihood_ = 0; - /** - *
-     * Only returns findings equal or above this threshold.
-     * 
- * - * .google.privacy.dlp.v2beta1.Likelihood min_likelihood = 2; - */ - public int getMinLikelihoodValue() { - return minLikelihood_; - } - /** - *
-     * Only returns findings equal or above this threshold.
-     * 
- * - * .google.privacy.dlp.v2beta1.Likelihood min_likelihood = 2; - */ - public Builder setMinLikelihoodValue(int value) { - minLikelihood_ = value; - onChanged(); - return this; - } - /** - *
-     * Only returns findings equal or above this threshold.
-     * 
- * - * .google.privacy.dlp.v2beta1.Likelihood min_likelihood = 2; - */ - public com.google.privacy.dlp.v2beta1.Likelihood getMinLikelihood() { - com.google.privacy.dlp.v2beta1.Likelihood result = com.google.privacy.dlp.v2beta1.Likelihood.valueOf(minLikelihood_); - return result == null ? com.google.privacy.dlp.v2beta1.Likelihood.UNRECOGNIZED : result; - } - /** - *
-     * Only returns findings equal or above this threshold.
-     * 
- * - * .google.privacy.dlp.v2beta1.Likelihood min_likelihood = 2; - */ - public Builder setMinLikelihood(com.google.privacy.dlp.v2beta1.Likelihood value) { - if (value == null) { - throw new NullPointerException(); - } - - minLikelihood_ = value.getNumber(); - onChanged(); - return this; - } - /** - *
-     * Only returns findings equal or above this threshold.
-     * 
- * - * .google.privacy.dlp.v2beta1.Likelihood min_likelihood = 2; - */ - public Builder clearMinLikelihood() { - - minLikelihood_ = 0; - onChanged(); - return this; - } - - private int maxFindings_ ; - /** - *
-     * Limits the number of findings per content item or long running operation.
-     * 
- * - * int32 max_findings = 3; - */ - public int getMaxFindings() { - return maxFindings_; - } - /** - *
-     * Limits the number of findings per content item or long running operation.
-     * 
- * - * int32 max_findings = 3; - */ - public Builder setMaxFindings(int value) { - - maxFindings_ = value; - onChanged(); - return this; - } - /** - *
-     * Limits the number of findings per content item or long running operation.
-     * 
- * - * int32 max_findings = 3; - */ - public Builder clearMaxFindings() { - - maxFindings_ = 0; - onChanged(); - return this; - } - - private boolean includeQuote_ ; - /** - *
-     * When true, a contextual quote from the data that triggered a finding is
-     * included in the response; see Finding.quote.
-     * 
- * - * bool include_quote = 4; - */ - public boolean getIncludeQuote() { - return includeQuote_; - } - /** - *
-     * When true, a contextual quote from the data that triggered a finding is
-     * included in the response; see Finding.quote.
-     * 
- * - * bool include_quote = 4; - */ - public Builder setIncludeQuote(boolean value) { - - includeQuote_ = value; - onChanged(); - return this; - } - /** - *
-     * When true, a contextual quote from the data that triggered a finding is
-     * included in the response; see Finding.quote.
-     * 
- * - * bool include_quote = 4; - */ - public Builder clearIncludeQuote() { - - includeQuote_ = false; - onChanged(); - return this; - } - - private boolean excludeTypes_ ; - /** - *
-     * When true, excludes type information of the findings.
-     * 
- * - * bool exclude_types = 6; - */ - public boolean getExcludeTypes() { - return excludeTypes_; - } - /** - *
-     * When true, excludes type information of the findings.
-     * 
- * - * bool exclude_types = 6; - */ - public Builder setExcludeTypes(boolean value) { - - excludeTypes_ = value; - onChanged(); - return this; - } - /** - *
-     * When true, excludes type information of the findings.
-     * 
- * - * bool exclude_types = 6; - */ - public Builder clearExcludeTypes() { - - excludeTypes_ = false; - onChanged(); - return this; - } - - private java.util.List infoTypeLimits_ = - java.util.Collections.emptyList(); - private void ensureInfoTypeLimitsIsMutable() { - if (!((bitField0_ & 0x00000020) == 0x00000020)) { - infoTypeLimits_ = new java.util.ArrayList(infoTypeLimits_); - bitField0_ |= 0x00000020; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimitOrBuilder> infoTypeLimitsBuilder_; - - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public java.util.List getInfoTypeLimitsList() { - if (infoTypeLimitsBuilder_ == null) { - return java.util.Collections.unmodifiableList(infoTypeLimits_); - } else { - return infoTypeLimitsBuilder_.getMessageList(); - } - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public int getInfoTypeLimitsCount() { - if (infoTypeLimitsBuilder_ == null) { - return infoTypeLimits_.size(); - } else { - return infoTypeLimitsBuilder_.getCount(); - } - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit getInfoTypeLimits(int index) { - if (infoTypeLimitsBuilder_ == null) { - return infoTypeLimits_.get(index); - } else { - return infoTypeLimitsBuilder_.getMessage(index); - } - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public Builder setInfoTypeLimits( - int index, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit value) { - if (infoTypeLimitsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypeLimitsIsMutable(); - infoTypeLimits_.set(index, value); - onChanged(); - } else { - infoTypeLimitsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public Builder setInfoTypeLimits( - int index, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder builderForValue) { - if (infoTypeLimitsBuilder_ == null) { - ensureInfoTypeLimitsIsMutable(); - infoTypeLimits_.set(index, builderForValue.build()); - onChanged(); - } else { - infoTypeLimitsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public Builder addInfoTypeLimits(com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit value) { - if (infoTypeLimitsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypeLimitsIsMutable(); - infoTypeLimits_.add(value); - onChanged(); - } else { - infoTypeLimitsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public Builder addInfoTypeLimits( - int index, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit value) { - if (infoTypeLimitsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypeLimitsIsMutable(); - infoTypeLimits_.add(index, value); - onChanged(); - } else { - infoTypeLimitsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public Builder addInfoTypeLimits( - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder builderForValue) { - if (infoTypeLimitsBuilder_ == null) { - ensureInfoTypeLimitsIsMutable(); - infoTypeLimits_.add(builderForValue.build()); - onChanged(); - } else { - infoTypeLimitsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public Builder addInfoTypeLimits( - int index, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder builderForValue) { - if (infoTypeLimitsBuilder_ == null) { - ensureInfoTypeLimitsIsMutable(); - infoTypeLimits_.add(index, builderForValue.build()); - onChanged(); - } else { - infoTypeLimitsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public Builder addAllInfoTypeLimits( - java.lang.Iterable values) { - if (infoTypeLimitsBuilder_ == null) { - ensureInfoTypeLimitsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, infoTypeLimits_); - onChanged(); - } else { - infoTypeLimitsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public Builder clearInfoTypeLimits() { - if (infoTypeLimitsBuilder_ == null) { - infoTypeLimits_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000020); - onChanged(); - } else { - infoTypeLimitsBuilder_.clear(); - } - return this; - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public Builder removeInfoTypeLimits(int index) { - if (infoTypeLimitsBuilder_ == null) { - ensureInfoTypeLimitsIsMutable(); - infoTypeLimits_.remove(index); - onChanged(); - } else { - infoTypeLimitsBuilder_.remove(index); - } - return this; - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder getInfoTypeLimitsBuilder( - int index) { - return getInfoTypeLimitsFieldBuilder().getBuilder(index); - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimitOrBuilder getInfoTypeLimitsOrBuilder( - int index) { - if (infoTypeLimitsBuilder_ == null) { - return infoTypeLimits_.get(index); } else { - return infoTypeLimitsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public java.util.List - getInfoTypeLimitsOrBuilderList() { - if (infoTypeLimitsBuilder_ != null) { - return infoTypeLimitsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(infoTypeLimits_); - } - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder addInfoTypeLimitsBuilder() { - return getInfoTypeLimitsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.getDefaultInstance()); - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder addInfoTypeLimitsBuilder( - int index) { - return getInfoTypeLimitsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.getDefaultInstance()); - } - /** - *
-     * Configuration of findings limit given for specified info types.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - public java.util.List - getInfoTypeLimitsBuilderList() { - return getInfoTypeLimitsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimitOrBuilder> - getInfoTypeLimitsFieldBuilder() { - if (infoTypeLimitsBuilder_ == null) { - infoTypeLimitsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit.Builder, com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimitOrBuilder>( - infoTypeLimits_, - ((bitField0_ & 0x00000020) == 0x00000020), - getParentForChildren(), - isClean()); - infoTypeLimits_ = null; - } - return infoTypeLimitsBuilder_; - } - - private java.util.List customInfoTypes_ = - java.util.Collections.emptyList(); - private void ensureCustomInfoTypesIsMutable() { - if (!((bitField0_ & 0x00000040) == 0x00000040)) { - customInfoTypes_ = new java.util.ArrayList(customInfoTypes_); - bitField0_ |= 0x00000040; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CustomInfoType, com.google.privacy.dlp.v2beta1.CustomInfoType.Builder, com.google.privacy.dlp.v2beta1.CustomInfoTypeOrBuilder> customInfoTypesBuilder_; - - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public java.util.List getCustomInfoTypesList() { - if (customInfoTypesBuilder_ == null) { - return java.util.Collections.unmodifiableList(customInfoTypes_); - } else { - return customInfoTypesBuilder_.getMessageList(); - } - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public int getCustomInfoTypesCount() { - if (customInfoTypesBuilder_ == null) { - return customInfoTypes_.size(); - } else { - return customInfoTypesBuilder_.getCount(); - } - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType getCustomInfoTypes(int index) { - if (customInfoTypesBuilder_ == null) { - return customInfoTypes_.get(index); - } else { - return customInfoTypesBuilder_.getMessage(index); - } - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public Builder setCustomInfoTypes( - int index, com.google.privacy.dlp.v2beta1.CustomInfoType value) { - if (customInfoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCustomInfoTypesIsMutable(); - customInfoTypes_.set(index, value); - onChanged(); - } else { - customInfoTypesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public Builder setCustomInfoTypes( - int index, com.google.privacy.dlp.v2beta1.CustomInfoType.Builder builderForValue) { - if (customInfoTypesBuilder_ == null) { - ensureCustomInfoTypesIsMutable(); - customInfoTypes_.set(index, builderForValue.build()); - onChanged(); - } else { - customInfoTypesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public Builder addCustomInfoTypes(com.google.privacy.dlp.v2beta1.CustomInfoType value) { - if (customInfoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCustomInfoTypesIsMutable(); - customInfoTypes_.add(value); - onChanged(); - } else { - customInfoTypesBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public Builder addCustomInfoTypes( - int index, com.google.privacy.dlp.v2beta1.CustomInfoType value) { - if (customInfoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCustomInfoTypesIsMutable(); - customInfoTypes_.add(index, value); - onChanged(); - } else { - customInfoTypesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public Builder addCustomInfoTypes( - com.google.privacy.dlp.v2beta1.CustomInfoType.Builder builderForValue) { - if (customInfoTypesBuilder_ == null) { - ensureCustomInfoTypesIsMutable(); - customInfoTypes_.add(builderForValue.build()); - onChanged(); - } else { - customInfoTypesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public Builder addCustomInfoTypes( - int index, com.google.privacy.dlp.v2beta1.CustomInfoType.Builder builderForValue) { - if (customInfoTypesBuilder_ == null) { - ensureCustomInfoTypesIsMutable(); - customInfoTypes_.add(index, builderForValue.build()); - onChanged(); - } else { - customInfoTypesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public Builder addAllCustomInfoTypes( - java.lang.Iterable values) { - if (customInfoTypesBuilder_ == null) { - ensureCustomInfoTypesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, customInfoTypes_); - onChanged(); - } else { - customInfoTypesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public Builder clearCustomInfoTypes() { - if (customInfoTypesBuilder_ == null) { - customInfoTypes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000040); - onChanged(); - } else { - customInfoTypesBuilder_.clear(); - } - return this; - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public Builder removeCustomInfoTypes(int index) { - if (customInfoTypesBuilder_ == null) { - ensureCustomInfoTypesIsMutable(); - customInfoTypes_.remove(index); - onChanged(); - } else { - customInfoTypesBuilder_.remove(index); - } - return this; - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Builder getCustomInfoTypesBuilder( - int index) { - return getCustomInfoTypesFieldBuilder().getBuilder(index); - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoTypeOrBuilder getCustomInfoTypesOrBuilder( - int index) { - if (customInfoTypesBuilder_ == null) { - return customInfoTypes_.get(index); } else { - return customInfoTypesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public java.util.List - getCustomInfoTypesOrBuilderList() { - if (customInfoTypesBuilder_ != null) { - return customInfoTypesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(customInfoTypes_); - } - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Builder addCustomInfoTypesBuilder() { - return getCustomInfoTypesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.CustomInfoType.getDefaultInstance()); - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public com.google.privacy.dlp.v2beta1.CustomInfoType.Builder addCustomInfoTypesBuilder( - int index) { - return getCustomInfoTypesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.CustomInfoType.getDefaultInstance()); - } - /** - *
-     * Custom info types provided by the user.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - public java.util.List - getCustomInfoTypesBuilderList() { - return getCustomInfoTypesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CustomInfoType, com.google.privacy.dlp.v2beta1.CustomInfoType.Builder, com.google.privacy.dlp.v2beta1.CustomInfoTypeOrBuilder> - getCustomInfoTypesFieldBuilder() { - if (customInfoTypesBuilder_ == null) { - customInfoTypesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CustomInfoType, com.google.privacy.dlp.v2beta1.CustomInfoType.Builder, com.google.privacy.dlp.v2beta1.CustomInfoTypeOrBuilder>( - customInfoTypes_, - ((bitField0_ & 0x00000040) == 0x00000040), - getParentForChildren(), - isClean()); - customInfoTypes_ = null; - } - return customInfoTypesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InspectConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InspectConfig) - private static final com.google.privacy.dlp.v2beta1.InspectConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InspectConfig(); - } - - public static com.google.privacy.dlp.v2beta1.InspectConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InspectConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InspectConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InspectConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectConfigOrBuilder.java deleted file mode 100644 index 36d3adc06626..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectConfigOrBuilder.java +++ /dev/null @@ -1,196 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface InspectConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InspectConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Restricts what info_types to look for. The values must correspond to
-   * InfoType values returned by ListInfoTypes or found in documentation.
-   * Empty info_types runs all enabled detectors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - java.util.List - getInfoTypesList(); - /** - *
-   * Restricts what info_types to look for. The values must correspond to
-   * InfoType values returned by ListInfoTypes or found in documentation.
-   * Empty info_types runs all enabled detectors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - com.google.privacy.dlp.v2beta1.InfoType getInfoTypes(int index); - /** - *
-   * Restricts what info_types to look for. The values must correspond to
-   * InfoType values returned by ListInfoTypes or found in documentation.
-   * Empty info_types runs all enabled detectors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - int getInfoTypesCount(); - /** - *
-   * Restricts what info_types to look for. The values must correspond to
-   * InfoType values returned by ListInfoTypes or found in documentation.
-   * Empty info_types runs all enabled detectors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - java.util.List - getInfoTypesOrBuilderList(); - /** - *
-   * Restricts what info_types to look for. The values must correspond to
-   * InfoType values returned by ListInfoTypes or found in documentation.
-   * Empty info_types runs all enabled detectors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoType info_types = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypesOrBuilder( - int index); - - /** - *
-   * Only returns findings equal or above this threshold.
-   * 
- * - * .google.privacy.dlp.v2beta1.Likelihood min_likelihood = 2; - */ - int getMinLikelihoodValue(); - /** - *
-   * Only returns findings equal or above this threshold.
-   * 
- * - * .google.privacy.dlp.v2beta1.Likelihood min_likelihood = 2; - */ - com.google.privacy.dlp.v2beta1.Likelihood getMinLikelihood(); - - /** - *
-   * Limits the number of findings per content item or long running operation.
-   * 
- * - * int32 max_findings = 3; - */ - int getMaxFindings(); - - /** - *
-   * When true, a contextual quote from the data that triggered a finding is
-   * included in the response; see Finding.quote.
-   * 
- * - * bool include_quote = 4; - */ - boolean getIncludeQuote(); - - /** - *
-   * When true, excludes type information of the findings.
-   * 
- * - * bool exclude_types = 6; - */ - boolean getExcludeTypes(); - - /** - *
-   * Configuration of findings limit given for specified info types.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - java.util.List - getInfoTypeLimitsList(); - /** - *
-   * Configuration of findings limit given for specified info types.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit getInfoTypeLimits(int index); - /** - *
-   * Configuration of findings limit given for specified info types.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - int getInfoTypeLimitsCount(); - /** - *
-   * Configuration of findings limit given for specified info types.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - java.util.List - getInfoTypeLimitsOrBuilderList(); - /** - *
-   * Configuration of findings limit given for specified info types.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimit info_type_limits = 7; - */ - com.google.privacy.dlp.v2beta1.InspectConfig.InfoTypeLimitOrBuilder getInfoTypeLimitsOrBuilder( - int index); - - /** - *
-   * Custom info types provided by the user.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - java.util.List - getCustomInfoTypesList(); - /** - *
-   * Custom info types provided by the user.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - com.google.privacy.dlp.v2beta1.CustomInfoType getCustomInfoTypes(int index); - /** - *
-   * Custom info types provided by the user.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - int getCustomInfoTypesCount(); - /** - *
-   * Custom info types provided by the user.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - java.util.List - getCustomInfoTypesOrBuilderList(); - /** - *
-   * Custom info types provided by the user.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CustomInfoType custom_info_types = 8; - */ - com.google.privacy.dlp.v2beta1.CustomInfoTypeOrBuilder getCustomInfoTypesOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentRequest.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentRequest.java deleted file mode 100644 index 08a0796d9f55..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentRequest.java +++ /dev/null @@ -1,1112 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Request to search for potentially sensitive info in a list of items.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectContentRequest} - */ -public final class InspectContentRequest extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InspectContentRequest) - InspectContentRequestOrBuilder { -private static final long serialVersionUID = 0L; - // Use InspectContentRequest.newBuilder() to construct. - private InspectContentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InspectContentRequest() { - items_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InspectContentRequest( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InspectConfig.Builder subBuilder = null; - if (inspectConfig_ != null) { - subBuilder = inspectConfig_.toBuilder(); - } - inspectConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.InspectConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(inspectConfig_); - inspectConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - items_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - items_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.ContentItem.parser(), extensionRegistry)); - 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_ & 0x00000002) == 0x00000002)) { - items_ = java.util.Collections.unmodifiableList(items_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectContentRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectContentRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectContentRequest.class, com.google.privacy.dlp.v2beta1.InspectContentRequest.Builder.class); - } - - private int bitField0_; - public static final int INSPECT_CONFIG_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.InspectConfig inspectConfig_; - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public boolean hasInspectConfig() { - return inspectConfig_ != null; - } - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig() { - return inspectConfig_ == null ? com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder() { - return getInspectConfig(); - } - - public static final int ITEMS_FIELD_NUMBER = 2; - private java.util.List items_; - /** - *
-   * The list of items to inspect. Items in a single request are
-   * considered "related" unless inspect_config.independent_inputs is true.
-   * Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public java.util.List getItemsList() { - return items_; - } - /** - *
-   * The list of items to inspect. Items in a single request are
-   * considered "related" unless inspect_config.independent_inputs is true.
-   * Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public java.util.List - getItemsOrBuilderList() { - return items_; - } - /** - *
-   * The list of items to inspect. Items in a single request are
-   * considered "related" unless inspect_config.independent_inputs is true.
-   * Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public int getItemsCount() { - return items_.size(); - } - /** - *
-   * The list of items to inspect. Items in a single request are
-   * considered "related" unless inspect_config.independent_inputs is true.
-   * Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItem getItems(int index) { - return items_.get(index); - } - /** - *
-   * The list of items to inspect. Items in a single request are
-   * considered "related" unless inspect_config.independent_inputs is true.
-   * Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index) { - return items_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (inspectConfig_ != null) { - output.writeMessage(1, getInspectConfig()); - } - for (int i = 0; i < items_.size(); i++) { - output.writeMessage(2, items_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (inspectConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getInspectConfig()); - } - for (int i = 0; i < items_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, items_.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.privacy.dlp.v2beta1.InspectContentRequest)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InspectContentRequest other = (com.google.privacy.dlp.v2beta1.InspectContentRequest) obj; - - boolean result = true; - result = result && (hasInspectConfig() == other.hasInspectConfig()); - if (hasInspectConfig()) { - result = result && getInspectConfig() - .equals(other.getInspectConfig()); - } - result = result && getItemsList() - .equals(other.getItemsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasInspectConfig()) { - hash = (37 * hash) + INSPECT_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getInspectConfig().hashCode(); - } - if (getItemsCount() > 0) { - hash = (37 * hash) + ITEMS_FIELD_NUMBER; - hash = (53 * hash) + getItemsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InspectContentRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectContentRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectContentRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectContentRequest 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.privacy.dlp.v2beta1.InspectContentRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectContentRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectContentRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectContentRequest 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.privacy.dlp.v2beta1.InspectContentRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectContentRequest 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.privacy.dlp.v2beta1.InspectContentRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectContentRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InspectContentRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Request to search for potentially sensitive info in a list of items.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectContentRequest} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InspectContentRequest) - com.google.privacy.dlp.v2beta1.InspectContentRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectContentRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectContentRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectContentRequest.class, com.google.privacy.dlp.v2beta1.InspectContentRequest.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InspectContentRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getItemsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (inspectConfigBuilder_ == null) { - inspectConfig_ = null; - } else { - inspectConfig_ = null; - inspectConfigBuilder_ = null; - } - if (itemsBuilder_ == null) { - items_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - itemsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectContentRequest_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InspectContentRequest getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InspectContentRequest.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InspectContentRequest build() { - com.google.privacy.dlp.v2beta1.InspectContentRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InspectContentRequest buildPartial() { - com.google.privacy.dlp.v2beta1.InspectContentRequest result = new com.google.privacy.dlp.v2beta1.InspectContentRequest(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (inspectConfigBuilder_ == null) { - result.inspectConfig_ = inspectConfig_; - } else { - result.inspectConfig_ = inspectConfigBuilder_.build(); - } - if (itemsBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - items_ = java.util.Collections.unmodifiableList(items_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.items_ = items_; - } else { - result.items_ = itemsBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InspectContentRequest) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InspectContentRequest)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InspectContentRequest other) { - if (other == com.google.privacy.dlp.v2beta1.InspectContentRequest.getDefaultInstance()) return this; - if (other.hasInspectConfig()) { - mergeInspectConfig(other.getInspectConfig()); - } - if (itemsBuilder_ == null) { - if (!other.items_.isEmpty()) { - if (items_.isEmpty()) { - items_ = other.items_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureItemsIsMutable(); - items_.addAll(other.items_); - } - onChanged(); - } - } else { - if (!other.items_.isEmpty()) { - if (itemsBuilder_.isEmpty()) { - itemsBuilder_.dispose(); - itemsBuilder_ = null; - items_ = other.items_; - bitField0_ = (bitField0_ & ~0x00000002); - itemsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getItemsFieldBuilder() : null; - } else { - itemsBuilder_.addAllMessages(other.items_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InspectContentRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InspectContentRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private com.google.privacy.dlp.v2beta1.InspectConfig inspectConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder> inspectConfigBuilder_; - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public boolean hasInspectConfig() { - return inspectConfigBuilder_ != null || inspectConfig_ != null; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig() { - if (inspectConfigBuilder_ == null) { - return inspectConfig_ == null ? com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } else { - return inspectConfigBuilder_.getMessage(); - } - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder setInspectConfig(com.google.privacy.dlp.v2beta1.InspectConfig value) { - if (inspectConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - inspectConfig_ = value; - onChanged(); - } else { - inspectConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder setInspectConfig( - com.google.privacy.dlp.v2beta1.InspectConfig.Builder builderForValue) { - if (inspectConfigBuilder_ == null) { - inspectConfig_ = builderForValue.build(); - onChanged(); - } else { - inspectConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder mergeInspectConfig(com.google.privacy.dlp.v2beta1.InspectConfig value) { - if (inspectConfigBuilder_ == null) { - if (inspectConfig_ != null) { - inspectConfig_ = - com.google.privacy.dlp.v2beta1.InspectConfig.newBuilder(inspectConfig_).mergeFrom(value).buildPartial(); - } else { - inspectConfig_ = value; - } - onChanged(); - } else { - inspectConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder clearInspectConfig() { - if (inspectConfigBuilder_ == null) { - inspectConfig_ = null; - onChanged(); - } else { - inspectConfig_ = null; - inspectConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.Builder getInspectConfigBuilder() { - - onChanged(); - return getInspectConfigFieldBuilder().getBuilder(); - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder() { - if (inspectConfigBuilder_ != null) { - return inspectConfigBuilder_.getMessageOrBuilder(); - } else { - return inspectConfig_ == null ? - com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder> - getInspectConfigFieldBuilder() { - if (inspectConfigBuilder_ == null) { - inspectConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder>( - getInspectConfig(), - getParentForChildren(), - isClean()); - inspectConfig_ = null; - } - return inspectConfigBuilder_; - } - - private java.util.List items_ = - java.util.Collections.emptyList(); - private void ensureItemsIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - items_ = new java.util.ArrayList(items_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder> itemsBuilder_; - - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public java.util.List getItemsList() { - if (itemsBuilder_ == null) { - return java.util.Collections.unmodifiableList(items_); - } else { - return itemsBuilder_.getMessageList(); - } - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public int getItemsCount() { - if (itemsBuilder_ == null) { - return items_.size(); - } else { - return itemsBuilder_.getCount(); - } - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItem getItems(int index) { - if (itemsBuilder_ == null) { - return items_.get(index); - } else { - return itemsBuilder_.getMessage(index); - } - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder setItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.set(index, value); - onChanged(); - } else { - itemsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder setItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.set(index, builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder addItems(com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.add(value); - onChanged(); - } else { - itemsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder addItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.add(index, value); - onChanged(); - } else { - itemsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder addItems( - com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.add(builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder addItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.add(index, builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder addAllItems( - java.lang.Iterable values) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, items_); - onChanged(); - } else { - itemsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder clearItems() { - if (itemsBuilder_ == null) { - items_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - itemsBuilder_.clear(); - } - return this; - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder removeItems(int index) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.remove(index); - onChanged(); - } else { - itemsBuilder_.remove(index); - } - return this; - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder getItemsBuilder( - int index) { - return getItemsFieldBuilder().getBuilder(index); - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index) { - if (itemsBuilder_ == null) { - return items_.get(index); } else { - return itemsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public java.util.List - getItemsOrBuilderList() { - if (itemsBuilder_ != null) { - return itemsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(items_); - } - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder addItemsBuilder() { - return getItemsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()); - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder addItemsBuilder( - int index) { - return getItemsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()); - } - /** - *
-     * The list of items to inspect. Items in a single request are
-     * considered "related" unless inspect_config.independent_inputs is true.
-     * Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public java.util.List - getItemsBuilderList() { - return getItemsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder> - getItemsFieldBuilder() { - if (itemsBuilder_ == null) { - itemsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder>( - items_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - items_ = null; - } - return itemsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InspectContentRequest) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InspectContentRequest) - private static final com.google.privacy.dlp.v2beta1.InspectContentRequest DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InspectContentRequest(); - } - - public static com.google.privacy.dlp.v2beta1.InspectContentRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InspectContentRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InspectContentRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InspectContentRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentRequestOrBuilder.java deleted file mode 100644 index f5af0636f851..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentRequestOrBuilder.java +++ /dev/null @@ -1,88 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface InspectContentRequestOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InspectContentRequest) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - boolean hasInspectConfig(); - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig(); - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder(); - - /** - *
-   * The list of items to inspect. Items in a single request are
-   * considered "related" unless inspect_config.independent_inputs is true.
-   * Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - java.util.List - getItemsList(); - /** - *
-   * The list of items to inspect. Items in a single request are
-   * considered "related" unless inspect_config.independent_inputs is true.
-   * Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - com.google.privacy.dlp.v2beta1.ContentItem getItems(int index); - /** - *
-   * The list of items to inspect. Items in a single request are
-   * considered "related" unless inspect_config.independent_inputs is true.
-   * Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - int getItemsCount(); - /** - *
-   * The list of items to inspect. Items in a single request are
-   * considered "related" unless inspect_config.independent_inputs is true.
-   * Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - java.util.List - getItemsOrBuilderList(); - /** - *
-   * The list of items to inspect. Items in a single request are
-   * considered "related" unless inspect_config.independent_inputs is true.
-   * Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentResponse.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentResponse.java deleted file mode 100644 index 0c8b20d41575..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentResponse.java +++ /dev/null @@ -1,857 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Results of inspecting a list of items.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectContentResponse} - */ -public final class InspectContentResponse extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InspectContentResponse) - InspectContentResponseOrBuilder { -private static final long serialVersionUID = 0L; - // Use InspectContentResponse.newBuilder() to construct. - private InspectContentResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InspectContentResponse() { - results_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InspectContentResponse( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - results_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - results_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.InspectResult.parser(), extensionRegistry)); - 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) == 0x00000001)) { - results_ = java.util.Collections.unmodifiableList(results_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectContentResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectContentResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectContentResponse.class, com.google.privacy.dlp.v2beta1.InspectContentResponse.Builder.class); - } - - public static final int RESULTS_FIELD_NUMBER = 1; - private java.util.List results_; - /** - *
-   * Each content_item from the request has a result in this list, in the
-   * same order as the request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public java.util.List getResultsList() { - return results_; - } - /** - *
-   * Each content_item from the request has a result in this list, in the
-   * same order as the request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public java.util.List - getResultsOrBuilderList() { - return results_; - } - /** - *
-   * Each content_item from the request has a result in this list, in the
-   * same order as the request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public int getResultsCount() { - return results_.size(); - } - /** - *
-   * Each content_item from the request has a result in this list, in the
-   * same order as the request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResult getResults(int index) { - return results_.get(index); - } - /** - *
-   * Each content_item from the request has a result in this list, in the
-   * same order as the request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResultOrBuilder getResultsOrBuilder( - int index) { - return results_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < results_.size(); i++) { - output.writeMessage(1, results_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < results_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, results_.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.privacy.dlp.v2beta1.InspectContentResponse)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InspectContentResponse other = (com.google.privacy.dlp.v2beta1.InspectContentResponse) obj; - - boolean result = true; - result = result && getResultsList() - .equals(other.getResultsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getResultsCount() > 0) { - hash = (37 * hash) + RESULTS_FIELD_NUMBER; - hash = (53 * hash) + getResultsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InspectContentResponse parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectContentResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectContentResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectContentResponse 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.privacy.dlp.v2beta1.InspectContentResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectContentResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectContentResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectContentResponse 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.privacy.dlp.v2beta1.InspectContentResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectContentResponse 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.privacy.dlp.v2beta1.InspectContentResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectContentResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InspectContentResponse prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Results of inspecting a list of items.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectContentResponse} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InspectContentResponse) - com.google.privacy.dlp.v2beta1.InspectContentResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectContentResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectContentResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectContentResponse.class, com.google.privacy.dlp.v2beta1.InspectContentResponse.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InspectContentResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getResultsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (resultsBuilder_ == null) { - results_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - resultsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectContentResponse_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InspectContentResponse getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InspectContentResponse.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InspectContentResponse build() { - com.google.privacy.dlp.v2beta1.InspectContentResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InspectContentResponse buildPartial() { - com.google.privacy.dlp.v2beta1.InspectContentResponse result = new com.google.privacy.dlp.v2beta1.InspectContentResponse(this); - int from_bitField0_ = bitField0_; - if (resultsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - results_ = java.util.Collections.unmodifiableList(results_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.results_ = results_; - } else { - result.results_ = resultsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InspectContentResponse) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InspectContentResponse)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InspectContentResponse other) { - if (other == com.google.privacy.dlp.v2beta1.InspectContentResponse.getDefaultInstance()) return this; - if (resultsBuilder_ == null) { - if (!other.results_.isEmpty()) { - if (results_.isEmpty()) { - results_ = other.results_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureResultsIsMutable(); - results_.addAll(other.results_); - } - onChanged(); - } - } else { - if (!other.results_.isEmpty()) { - if (resultsBuilder_.isEmpty()) { - resultsBuilder_.dispose(); - resultsBuilder_ = null; - results_ = other.results_; - bitField0_ = (bitField0_ & ~0x00000001); - resultsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getResultsFieldBuilder() : null; - } else { - resultsBuilder_.addAllMessages(other.results_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InspectContentResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InspectContentResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List results_ = - java.util.Collections.emptyList(); - private void ensureResultsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - results_ = new java.util.ArrayList(results_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectResult, com.google.privacy.dlp.v2beta1.InspectResult.Builder, com.google.privacy.dlp.v2beta1.InspectResultOrBuilder> resultsBuilder_; - - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public java.util.List getResultsList() { - if (resultsBuilder_ == null) { - return java.util.Collections.unmodifiableList(results_); - } else { - return resultsBuilder_.getMessageList(); - } - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public int getResultsCount() { - if (resultsBuilder_ == null) { - return results_.size(); - } else { - return resultsBuilder_.getCount(); - } - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResult getResults(int index) { - if (resultsBuilder_ == null) { - return results_.get(index); - } else { - return resultsBuilder_.getMessage(index); - } - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public Builder setResults( - int index, com.google.privacy.dlp.v2beta1.InspectResult value) { - if (resultsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureResultsIsMutable(); - results_.set(index, value); - onChanged(); - } else { - resultsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public Builder setResults( - int index, com.google.privacy.dlp.v2beta1.InspectResult.Builder builderForValue) { - if (resultsBuilder_ == null) { - ensureResultsIsMutable(); - results_.set(index, builderForValue.build()); - onChanged(); - } else { - resultsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public Builder addResults(com.google.privacy.dlp.v2beta1.InspectResult value) { - if (resultsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureResultsIsMutable(); - results_.add(value); - onChanged(); - } else { - resultsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public Builder addResults( - int index, com.google.privacy.dlp.v2beta1.InspectResult value) { - if (resultsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureResultsIsMutable(); - results_.add(index, value); - onChanged(); - } else { - resultsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public Builder addResults( - com.google.privacy.dlp.v2beta1.InspectResult.Builder builderForValue) { - if (resultsBuilder_ == null) { - ensureResultsIsMutable(); - results_.add(builderForValue.build()); - onChanged(); - } else { - resultsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public Builder addResults( - int index, com.google.privacy.dlp.v2beta1.InspectResult.Builder builderForValue) { - if (resultsBuilder_ == null) { - ensureResultsIsMutable(); - results_.add(index, builderForValue.build()); - onChanged(); - } else { - resultsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public Builder addAllResults( - java.lang.Iterable values) { - if (resultsBuilder_ == null) { - ensureResultsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, results_); - onChanged(); - } else { - resultsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public Builder clearResults() { - if (resultsBuilder_ == null) { - results_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - resultsBuilder_.clear(); - } - return this; - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public Builder removeResults(int index) { - if (resultsBuilder_ == null) { - ensureResultsIsMutable(); - results_.remove(index); - onChanged(); - } else { - resultsBuilder_.remove(index); - } - return this; - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResult.Builder getResultsBuilder( - int index) { - return getResultsFieldBuilder().getBuilder(index); - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResultOrBuilder getResultsOrBuilder( - int index) { - if (resultsBuilder_ == null) { - return results_.get(index); } else { - return resultsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public java.util.List - getResultsOrBuilderList() { - if (resultsBuilder_ != null) { - return resultsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(results_); - } - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResult.Builder addResultsBuilder() { - return getResultsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.InspectResult.getDefaultInstance()); - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResult.Builder addResultsBuilder( - int index) { - return getResultsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.InspectResult.getDefaultInstance()); - } - /** - *
-     * Each content_item from the request has a result in this list, in the
-     * same order as the request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - public java.util.List - getResultsBuilderList() { - return getResultsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectResult, com.google.privacy.dlp.v2beta1.InspectResult.Builder, com.google.privacy.dlp.v2beta1.InspectResultOrBuilder> - getResultsFieldBuilder() { - if (resultsBuilder_ == null) { - resultsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectResult, com.google.privacy.dlp.v2beta1.InspectResult.Builder, com.google.privacy.dlp.v2beta1.InspectResultOrBuilder>( - results_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - results_ = null; - } - return resultsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InspectContentResponse) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InspectContentResponse) - private static final com.google.privacy.dlp.v2beta1.InspectContentResponse DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InspectContentResponse(); - } - - public static com.google.privacy.dlp.v2beta1.InspectContentResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InspectContentResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InspectContentResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InspectContentResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentResponseOrBuilder.java deleted file mode 100644 index 63b47c7d747d..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectContentResponseOrBuilder.java +++ /dev/null @@ -1,58 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface InspectContentResponseOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InspectContentResponse) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Each content_item from the request has a result in this list, in the
-   * same order as the request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - java.util.List - getResultsList(); - /** - *
-   * Each content_item from the request has a result in this list, in the
-   * same order as the request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - com.google.privacy.dlp.v2beta1.InspectResult getResults(int index); - /** - *
-   * Each content_item from the request has a result in this list, in the
-   * same order as the request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - int getResultsCount(); - /** - *
-   * Each content_item from the request has a result in this list, in the
-   * same order as the request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - java.util.List - getResultsOrBuilderList(); - /** - *
-   * Each content_item from the request has a result in this list, in the
-   * same order as the request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InspectResult results = 1; - */ - com.google.privacy.dlp.v2beta1.InspectResultOrBuilder getResultsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationMetadata.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationMetadata.java deleted file mode 100644 index 200f4675f487..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationMetadata.java +++ /dev/null @@ -1,1811 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Metadata returned within GetOperation for an inspect request.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectOperationMetadata} - */ -public final class InspectOperationMetadata extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InspectOperationMetadata) - InspectOperationMetadataOrBuilder { -private static final long serialVersionUID = 0L; - // Use InspectOperationMetadata.newBuilder() to construct. - private InspectOperationMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InspectOperationMetadata() { - processedBytes_ = 0L; - totalEstimatedBytes_ = 0L; - infoTypeStats_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InspectOperationMetadata( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - - processedBytes_ = input.readInt64(); - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { - infoTypeStats_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000004; - } - infoTypeStats_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.InfoTypeStatistics.parser(), extensionRegistry)); - 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 32: { - - totalEstimatedBytes_ = input.readInt64(); - break; - } - case 42: { - com.google.privacy.dlp.v2beta1.InspectConfig.Builder subBuilder = null; - if (requestInspectConfig_ != null) { - subBuilder = requestInspectConfig_.toBuilder(); - } - requestInspectConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.InspectConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestInspectConfig_); - requestInspectConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 50: { - com.google.privacy.dlp.v2beta1.StorageConfig.Builder subBuilder = null; - if (requestStorageConfig_ != null) { - subBuilder = requestStorageConfig_.toBuilder(); - } - requestStorageConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.StorageConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestStorageConfig_); - requestStorageConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 58: { - com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder subBuilder = null; - if (requestOutputConfig_ != null) { - subBuilder = requestOutputConfig_.toBuilder(); - } - requestOutputConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.OutputStorageConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestOutputConfig_); - requestOutputConfig_ = subBuilder.buildPartial(); - } - - 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_ & 0x00000004) == 0x00000004)) { - infoTypeStats_ = java.util.Collections.unmodifiableList(infoTypeStats_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectOperationMetadata_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectOperationMetadata.class, com.google.privacy.dlp.v2beta1.InspectOperationMetadata.Builder.class); - } - - private int bitField0_; - public static final int PROCESSED_BYTES_FIELD_NUMBER = 1; - private long processedBytes_; - /** - *
-   * Total size in bytes that were processed.
-   * 
- * - * int64 processed_bytes = 1; - */ - public long getProcessedBytes() { - return processedBytes_; - } - - public static final int TOTAL_ESTIMATED_BYTES_FIELD_NUMBER = 4; - private long totalEstimatedBytes_; - /** - *
-   * Estimate of the number of bytes to process.
-   * 
- * - * int64 total_estimated_bytes = 4; - */ - public long getTotalEstimatedBytes() { - return totalEstimatedBytes_; - } - - public static final int INFO_TYPE_STATS_FIELD_NUMBER = 2; - private java.util.List infoTypeStats_; - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public java.util.List getInfoTypeStatsList() { - return infoTypeStats_; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public java.util.List - getInfoTypeStatsOrBuilderList() { - return infoTypeStats_; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public int getInfoTypeStatsCount() { - return infoTypeStats_.size(); - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeStatistics getInfoTypeStats(int index) { - return infoTypeStats_.get(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeStatisticsOrBuilder getInfoTypeStatsOrBuilder( - int index) { - return infoTypeStats_.get(index); - } - - public static final int CREATE_TIME_FIELD_NUMBER = 3; - private com.google.protobuf.Timestamp createTime_; - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int REQUEST_INSPECT_CONFIG_FIELD_NUMBER = 5; - private com.google.privacy.dlp.v2beta1.InspectConfig requestInspectConfig_; - /** - *
-   * The inspect config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public boolean hasRequestInspectConfig() { - return requestInspectConfig_ != null; - } - /** - *
-   * The inspect config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig getRequestInspectConfig() { - return requestInspectConfig_ == null ? com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : requestInspectConfig_; - } - /** - *
-   * The inspect config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getRequestInspectConfigOrBuilder() { - return getRequestInspectConfig(); - } - - public static final int REQUEST_STORAGE_CONFIG_FIELD_NUMBER = 6; - private com.google.privacy.dlp.v2beta1.StorageConfig requestStorageConfig_; - /** - *
-   * The storage config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public boolean hasRequestStorageConfig() { - return requestStorageConfig_ != null; - } - /** - *
-   * The storage config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public com.google.privacy.dlp.v2beta1.StorageConfig getRequestStorageConfig() { - return requestStorageConfig_ == null ? com.google.privacy.dlp.v2beta1.StorageConfig.getDefaultInstance() : requestStorageConfig_; - } - /** - *
-   * The storage config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder getRequestStorageConfigOrBuilder() { - return getRequestStorageConfig(); - } - - public static final int REQUEST_OUTPUT_CONFIG_FIELD_NUMBER = 7; - private com.google.privacy.dlp.v2beta1.OutputStorageConfig requestOutputConfig_; - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public boolean hasRequestOutputConfig() { - return requestOutputConfig_ != null; - } - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public com.google.privacy.dlp.v2beta1.OutputStorageConfig getRequestOutputConfig() { - return requestOutputConfig_ == null ? com.google.privacy.dlp.v2beta1.OutputStorageConfig.getDefaultInstance() : requestOutputConfig_; - } - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder getRequestOutputConfigOrBuilder() { - return getRequestOutputConfig(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (processedBytes_ != 0L) { - output.writeInt64(1, processedBytes_); - } - for (int i = 0; i < infoTypeStats_.size(); i++) { - output.writeMessage(2, infoTypeStats_.get(i)); - } - if (createTime_ != null) { - output.writeMessage(3, getCreateTime()); - } - if (totalEstimatedBytes_ != 0L) { - output.writeInt64(4, totalEstimatedBytes_); - } - if (requestInspectConfig_ != null) { - output.writeMessage(5, getRequestInspectConfig()); - } - if (requestStorageConfig_ != null) { - output.writeMessage(6, getRequestStorageConfig()); - } - if (requestOutputConfig_ != null) { - output.writeMessage(7, getRequestOutputConfig()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (processedBytes_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(1, processedBytes_); - } - for (int i = 0; i < infoTypeStats_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, infoTypeStats_.get(i)); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, getCreateTime()); - } - if (totalEstimatedBytes_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(4, totalEstimatedBytes_); - } - if (requestInspectConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, getRequestInspectConfig()); - } - if (requestStorageConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, getRequestStorageConfig()); - } - if (requestOutputConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(7, getRequestOutputConfig()); - } - 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.privacy.dlp.v2beta1.InspectOperationMetadata)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InspectOperationMetadata other = (com.google.privacy.dlp.v2beta1.InspectOperationMetadata) obj; - - boolean result = true; - result = result && (getProcessedBytes() - == other.getProcessedBytes()); - result = result && (getTotalEstimatedBytes() - == other.getTotalEstimatedBytes()); - result = result && getInfoTypeStatsList() - .equals(other.getInfoTypeStatsList()); - result = result && (hasCreateTime() == other.hasCreateTime()); - if (hasCreateTime()) { - result = result && getCreateTime() - .equals(other.getCreateTime()); - } - result = result && (hasRequestInspectConfig() == other.hasRequestInspectConfig()); - if (hasRequestInspectConfig()) { - result = result && getRequestInspectConfig() - .equals(other.getRequestInspectConfig()); - } - result = result && (hasRequestStorageConfig() == other.hasRequestStorageConfig()); - if (hasRequestStorageConfig()) { - result = result && getRequestStorageConfig() - .equals(other.getRequestStorageConfig()); - } - result = result && (hasRequestOutputConfig() == other.hasRequestOutputConfig()); - if (hasRequestOutputConfig()) { - result = result && getRequestOutputConfig() - .equals(other.getRequestOutputConfig()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PROCESSED_BYTES_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getProcessedBytes()); - hash = (37 * hash) + TOTAL_ESTIMATED_BYTES_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getTotalEstimatedBytes()); - if (getInfoTypeStatsCount() > 0) { - hash = (37 * hash) + INFO_TYPE_STATS_FIELD_NUMBER; - hash = (53 * hash) + getInfoTypeStatsList().hashCode(); - } - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasRequestInspectConfig()) { - hash = (37 * hash) + REQUEST_INSPECT_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getRequestInspectConfig().hashCode(); - } - if (hasRequestStorageConfig()) { - hash = (37 * hash) + REQUEST_STORAGE_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getRequestStorageConfig().hashCode(); - } - if (hasRequestOutputConfig()) { - hash = (37 * hash) + REQUEST_OUTPUT_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getRequestOutputConfig().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InspectOperationMetadata parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationMetadata parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationMetadata parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationMetadata 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.privacy.dlp.v2beta1.InspectOperationMetadata parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationMetadata parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationMetadata parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationMetadata 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.privacy.dlp.v2beta1.InspectOperationMetadata parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationMetadata 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.privacy.dlp.v2beta1.InspectOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InspectOperationMetadata prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Metadata returned within GetOperation for an inspect request.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectOperationMetadata} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InspectOperationMetadata) - com.google.privacy.dlp.v2beta1.InspectOperationMetadataOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectOperationMetadata_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectOperationMetadata.class, com.google.privacy.dlp.v2beta1.InspectOperationMetadata.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InspectOperationMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getInfoTypeStatsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - processedBytes_ = 0L; - - totalEstimatedBytes_ = 0L; - - if (infoTypeStatsBuilder_ == null) { - infoTypeStats_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - } else { - infoTypeStatsBuilder_.clear(); - } - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (requestInspectConfigBuilder_ == null) { - requestInspectConfig_ = null; - } else { - requestInspectConfig_ = null; - requestInspectConfigBuilder_ = null; - } - if (requestStorageConfigBuilder_ == null) { - requestStorageConfig_ = null; - } else { - requestStorageConfig_ = null; - requestStorageConfigBuilder_ = null; - } - if (requestOutputConfigBuilder_ == null) { - requestOutputConfig_ = null; - } else { - requestOutputConfig_ = null; - requestOutputConfigBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectOperationMetadata_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InspectOperationMetadata getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InspectOperationMetadata.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InspectOperationMetadata build() { - com.google.privacy.dlp.v2beta1.InspectOperationMetadata result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InspectOperationMetadata buildPartial() { - com.google.privacy.dlp.v2beta1.InspectOperationMetadata result = new com.google.privacy.dlp.v2beta1.InspectOperationMetadata(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.processedBytes_ = processedBytes_; - result.totalEstimatedBytes_ = totalEstimatedBytes_; - if (infoTypeStatsBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { - infoTypeStats_ = java.util.Collections.unmodifiableList(infoTypeStats_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.infoTypeStats_ = infoTypeStats_; - } else { - result.infoTypeStats_ = infoTypeStatsBuilder_.build(); - } - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (requestInspectConfigBuilder_ == null) { - result.requestInspectConfig_ = requestInspectConfig_; - } else { - result.requestInspectConfig_ = requestInspectConfigBuilder_.build(); - } - if (requestStorageConfigBuilder_ == null) { - result.requestStorageConfig_ = requestStorageConfig_; - } else { - result.requestStorageConfig_ = requestStorageConfigBuilder_.build(); - } - if (requestOutputConfigBuilder_ == null) { - result.requestOutputConfig_ = requestOutputConfig_; - } else { - result.requestOutputConfig_ = requestOutputConfigBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InspectOperationMetadata) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InspectOperationMetadata)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InspectOperationMetadata other) { - if (other == com.google.privacy.dlp.v2beta1.InspectOperationMetadata.getDefaultInstance()) return this; - if (other.getProcessedBytes() != 0L) { - setProcessedBytes(other.getProcessedBytes()); - } - if (other.getTotalEstimatedBytes() != 0L) { - setTotalEstimatedBytes(other.getTotalEstimatedBytes()); - } - if (infoTypeStatsBuilder_ == null) { - if (!other.infoTypeStats_.isEmpty()) { - if (infoTypeStats_.isEmpty()) { - infoTypeStats_ = other.infoTypeStats_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureInfoTypeStatsIsMutable(); - infoTypeStats_.addAll(other.infoTypeStats_); - } - onChanged(); - } - } else { - if (!other.infoTypeStats_.isEmpty()) { - if (infoTypeStatsBuilder_.isEmpty()) { - infoTypeStatsBuilder_.dispose(); - infoTypeStatsBuilder_ = null; - infoTypeStats_ = other.infoTypeStats_; - bitField0_ = (bitField0_ & ~0x00000004); - infoTypeStatsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getInfoTypeStatsFieldBuilder() : null; - } else { - infoTypeStatsBuilder_.addAllMessages(other.infoTypeStats_); - } - } - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasRequestInspectConfig()) { - mergeRequestInspectConfig(other.getRequestInspectConfig()); - } - if (other.hasRequestStorageConfig()) { - mergeRequestStorageConfig(other.getRequestStorageConfig()); - } - if (other.hasRequestOutputConfig()) { - mergeRequestOutputConfig(other.getRequestOutputConfig()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InspectOperationMetadata parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InspectOperationMetadata) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private long processedBytes_ ; - /** - *
-     * Total size in bytes that were processed.
-     * 
- * - * int64 processed_bytes = 1; - */ - public long getProcessedBytes() { - return processedBytes_; - } - /** - *
-     * Total size in bytes that were processed.
-     * 
- * - * int64 processed_bytes = 1; - */ - public Builder setProcessedBytes(long value) { - - processedBytes_ = value; - onChanged(); - return this; - } - /** - *
-     * Total size in bytes that were processed.
-     * 
- * - * int64 processed_bytes = 1; - */ - public Builder clearProcessedBytes() { - - processedBytes_ = 0L; - onChanged(); - return this; - } - - private long totalEstimatedBytes_ ; - /** - *
-     * Estimate of the number of bytes to process.
-     * 
- * - * int64 total_estimated_bytes = 4; - */ - public long getTotalEstimatedBytes() { - return totalEstimatedBytes_; - } - /** - *
-     * Estimate of the number of bytes to process.
-     * 
- * - * int64 total_estimated_bytes = 4; - */ - public Builder setTotalEstimatedBytes(long value) { - - totalEstimatedBytes_ = value; - onChanged(); - return this; - } - /** - *
-     * Estimate of the number of bytes to process.
-     * 
- * - * int64 total_estimated_bytes = 4; - */ - public Builder clearTotalEstimatedBytes() { - - totalEstimatedBytes_ = 0L; - onChanged(); - return this; - } - - private java.util.List infoTypeStats_ = - java.util.Collections.emptyList(); - private void ensureInfoTypeStatsIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { - infoTypeStats_ = new java.util.ArrayList(infoTypeStats_); - bitField0_ |= 0x00000004; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeStatistics, com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder, com.google.privacy.dlp.v2beta1.InfoTypeStatisticsOrBuilder> infoTypeStatsBuilder_; - - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public java.util.List getInfoTypeStatsList() { - if (infoTypeStatsBuilder_ == null) { - return java.util.Collections.unmodifiableList(infoTypeStats_); - } else { - return infoTypeStatsBuilder_.getMessageList(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public int getInfoTypeStatsCount() { - if (infoTypeStatsBuilder_ == null) { - return infoTypeStats_.size(); - } else { - return infoTypeStatsBuilder_.getCount(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeStatistics getInfoTypeStats(int index) { - if (infoTypeStatsBuilder_ == null) { - return infoTypeStats_.get(index); - } else { - return infoTypeStatsBuilder_.getMessage(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public Builder setInfoTypeStats( - int index, com.google.privacy.dlp.v2beta1.InfoTypeStatistics value) { - if (infoTypeStatsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypeStatsIsMutable(); - infoTypeStats_.set(index, value); - onChanged(); - } else { - infoTypeStatsBuilder_.setMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public Builder setInfoTypeStats( - int index, com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder builderForValue) { - if (infoTypeStatsBuilder_ == null) { - ensureInfoTypeStatsIsMutable(); - infoTypeStats_.set(index, builderForValue.build()); - onChanged(); - } else { - infoTypeStatsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public Builder addInfoTypeStats(com.google.privacy.dlp.v2beta1.InfoTypeStatistics value) { - if (infoTypeStatsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypeStatsIsMutable(); - infoTypeStats_.add(value); - onChanged(); - } else { - infoTypeStatsBuilder_.addMessage(value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public Builder addInfoTypeStats( - int index, com.google.privacy.dlp.v2beta1.InfoTypeStatistics value) { - if (infoTypeStatsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypeStatsIsMutable(); - infoTypeStats_.add(index, value); - onChanged(); - } else { - infoTypeStatsBuilder_.addMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public Builder addInfoTypeStats( - com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder builderForValue) { - if (infoTypeStatsBuilder_ == null) { - ensureInfoTypeStatsIsMutable(); - infoTypeStats_.add(builderForValue.build()); - onChanged(); - } else { - infoTypeStatsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public Builder addInfoTypeStats( - int index, com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder builderForValue) { - if (infoTypeStatsBuilder_ == null) { - ensureInfoTypeStatsIsMutable(); - infoTypeStats_.add(index, builderForValue.build()); - onChanged(); - } else { - infoTypeStatsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public Builder addAllInfoTypeStats( - java.lang.Iterable values) { - if (infoTypeStatsBuilder_ == null) { - ensureInfoTypeStatsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, infoTypeStats_); - onChanged(); - } else { - infoTypeStatsBuilder_.addAllMessages(values); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public Builder clearInfoTypeStats() { - if (infoTypeStatsBuilder_ == null) { - infoTypeStats_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - } else { - infoTypeStatsBuilder_.clear(); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public Builder removeInfoTypeStats(int index) { - if (infoTypeStatsBuilder_ == null) { - ensureInfoTypeStatsIsMutable(); - infoTypeStats_.remove(index); - onChanged(); - } else { - infoTypeStatsBuilder_.remove(index); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder getInfoTypeStatsBuilder( - int index) { - return getInfoTypeStatsFieldBuilder().getBuilder(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeStatisticsOrBuilder getInfoTypeStatsOrBuilder( - int index) { - if (infoTypeStatsBuilder_ == null) { - return infoTypeStats_.get(index); } else { - return infoTypeStatsBuilder_.getMessageOrBuilder(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public java.util.List - getInfoTypeStatsOrBuilderList() { - if (infoTypeStatsBuilder_ != null) { - return infoTypeStatsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(infoTypeStats_); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder addInfoTypeStatsBuilder() { - return getInfoTypeStatsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.InfoTypeStatistics.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder addInfoTypeStatsBuilder( - int index) { - return getInfoTypeStatsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.InfoTypeStatistics.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - public java.util.List - getInfoTypeStatsBuilderList() { - return getInfoTypeStatsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeStatistics, com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder, com.google.privacy.dlp.v2beta1.InfoTypeStatisticsOrBuilder> - getInfoTypeStatsFieldBuilder() { - if (infoTypeStatsBuilder_ == null) { - infoTypeStatsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeStatistics, com.google.privacy.dlp.v2beta1.InfoTypeStatistics.Builder, com.google.privacy.dlp.v2beta1.InfoTypeStatisticsOrBuilder>( - infoTypeStats_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); - infoTypeStats_ = null; - } - return infoTypeStatsBuilder_; - } - - private com.google.protobuf.Timestamp createTime_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; - /** - *
-     * The time which this request was started.
-     * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .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; - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .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; - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .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; - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .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_; - } - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .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.privacy.dlp.v2beta1.InspectConfig requestInspectConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder> requestInspectConfigBuilder_; - /** - *
-     * The inspect config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public boolean hasRequestInspectConfig() { - return requestInspectConfigBuilder_ != null || requestInspectConfig_ != null; - } - /** - *
-     * The inspect config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig getRequestInspectConfig() { - if (requestInspectConfigBuilder_ == null) { - return requestInspectConfig_ == null ? com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : requestInspectConfig_; - } else { - return requestInspectConfigBuilder_.getMessage(); - } - } - /** - *
-     * The inspect config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public Builder setRequestInspectConfig(com.google.privacy.dlp.v2beta1.InspectConfig value) { - if (requestInspectConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - requestInspectConfig_ = value; - onChanged(); - } else { - requestInspectConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The inspect config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public Builder setRequestInspectConfig( - com.google.privacy.dlp.v2beta1.InspectConfig.Builder builderForValue) { - if (requestInspectConfigBuilder_ == null) { - requestInspectConfig_ = builderForValue.build(); - onChanged(); - } else { - requestInspectConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The inspect config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public Builder mergeRequestInspectConfig(com.google.privacy.dlp.v2beta1.InspectConfig value) { - if (requestInspectConfigBuilder_ == null) { - if (requestInspectConfig_ != null) { - requestInspectConfig_ = - com.google.privacy.dlp.v2beta1.InspectConfig.newBuilder(requestInspectConfig_).mergeFrom(value).buildPartial(); - } else { - requestInspectConfig_ = value; - } - onChanged(); - } else { - requestInspectConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The inspect config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public Builder clearRequestInspectConfig() { - if (requestInspectConfigBuilder_ == null) { - requestInspectConfig_ = null; - onChanged(); - } else { - requestInspectConfig_ = null; - requestInspectConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * The inspect config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.Builder getRequestInspectConfigBuilder() { - - onChanged(); - return getRequestInspectConfigFieldBuilder().getBuilder(); - } - /** - *
-     * The inspect config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - public com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getRequestInspectConfigOrBuilder() { - if (requestInspectConfigBuilder_ != null) { - return requestInspectConfigBuilder_.getMessageOrBuilder(); - } else { - return requestInspectConfig_ == null ? - com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : requestInspectConfig_; - } - } - /** - *
-     * The inspect config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder> - getRequestInspectConfigFieldBuilder() { - if (requestInspectConfigBuilder_ == null) { - requestInspectConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder>( - getRequestInspectConfig(), - getParentForChildren(), - isClean()); - requestInspectConfig_ = null; - } - return requestInspectConfigBuilder_; - } - - private com.google.privacy.dlp.v2beta1.StorageConfig requestStorageConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.StorageConfig, com.google.privacy.dlp.v2beta1.StorageConfig.Builder, com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder> requestStorageConfigBuilder_; - /** - *
-     * The storage config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public boolean hasRequestStorageConfig() { - return requestStorageConfigBuilder_ != null || requestStorageConfig_ != null; - } - /** - *
-     * The storage config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public com.google.privacy.dlp.v2beta1.StorageConfig getRequestStorageConfig() { - if (requestStorageConfigBuilder_ == null) { - return requestStorageConfig_ == null ? com.google.privacy.dlp.v2beta1.StorageConfig.getDefaultInstance() : requestStorageConfig_; - } else { - return requestStorageConfigBuilder_.getMessage(); - } - } - /** - *
-     * The storage config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public Builder setRequestStorageConfig(com.google.privacy.dlp.v2beta1.StorageConfig value) { - if (requestStorageConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - requestStorageConfig_ = value; - onChanged(); - } else { - requestStorageConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The storage config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public Builder setRequestStorageConfig( - com.google.privacy.dlp.v2beta1.StorageConfig.Builder builderForValue) { - if (requestStorageConfigBuilder_ == null) { - requestStorageConfig_ = builderForValue.build(); - onChanged(); - } else { - requestStorageConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The storage config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public Builder mergeRequestStorageConfig(com.google.privacy.dlp.v2beta1.StorageConfig value) { - if (requestStorageConfigBuilder_ == null) { - if (requestStorageConfig_ != null) { - requestStorageConfig_ = - com.google.privacy.dlp.v2beta1.StorageConfig.newBuilder(requestStorageConfig_).mergeFrom(value).buildPartial(); - } else { - requestStorageConfig_ = value; - } - onChanged(); - } else { - requestStorageConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The storage config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public Builder clearRequestStorageConfig() { - if (requestStorageConfigBuilder_ == null) { - requestStorageConfig_ = null; - onChanged(); - } else { - requestStorageConfig_ = null; - requestStorageConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * The storage config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public com.google.privacy.dlp.v2beta1.StorageConfig.Builder getRequestStorageConfigBuilder() { - - onChanged(); - return getRequestStorageConfigFieldBuilder().getBuilder(); - } - /** - *
-     * The storage config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - public com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder getRequestStorageConfigOrBuilder() { - if (requestStorageConfigBuilder_ != null) { - return requestStorageConfigBuilder_.getMessageOrBuilder(); - } else { - return requestStorageConfig_ == null ? - com.google.privacy.dlp.v2beta1.StorageConfig.getDefaultInstance() : requestStorageConfig_; - } - } - /** - *
-     * The storage config used to create the Operation.
-     * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.StorageConfig, com.google.privacy.dlp.v2beta1.StorageConfig.Builder, com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder> - getRequestStorageConfigFieldBuilder() { - if (requestStorageConfigBuilder_ == null) { - requestStorageConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.StorageConfig, com.google.privacy.dlp.v2beta1.StorageConfig.Builder, com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder>( - getRequestStorageConfig(), - getParentForChildren(), - isClean()); - requestStorageConfig_ = null; - } - return requestStorageConfigBuilder_; - } - - private com.google.privacy.dlp.v2beta1.OutputStorageConfig requestOutputConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.OutputStorageConfig, com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder, com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder> requestOutputConfigBuilder_; - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public boolean hasRequestOutputConfig() { - return requestOutputConfigBuilder_ != null || requestOutputConfig_ != null; - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public com.google.privacy.dlp.v2beta1.OutputStorageConfig getRequestOutputConfig() { - if (requestOutputConfigBuilder_ == null) { - return requestOutputConfig_ == null ? com.google.privacy.dlp.v2beta1.OutputStorageConfig.getDefaultInstance() : requestOutputConfig_; - } else { - return requestOutputConfigBuilder_.getMessage(); - } - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public Builder setRequestOutputConfig(com.google.privacy.dlp.v2beta1.OutputStorageConfig value) { - if (requestOutputConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - requestOutputConfig_ = value; - onChanged(); - } else { - requestOutputConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public Builder setRequestOutputConfig( - com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder builderForValue) { - if (requestOutputConfigBuilder_ == null) { - requestOutputConfig_ = builderForValue.build(); - onChanged(); - } else { - requestOutputConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public Builder mergeRequestOutputConfig(com.google.privacy.dlp.v2beta1.OutputStorageConfig value) { - if (requestOutputConfigBuilder_ == null) { - if (requestOutputConfig_ != null) { - requestOutputConfig_ = - com.google.privacy.dlp.v2beta1.OutputStorageConfig.newBuilder(requestOutputConfig_).mergeFrom(value).buildPartial(); - } else { - requestOutputConfig_ = value; - } - onChanged(); - } else { - requestOutputConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public Builder clearRequestOutputConfig() { - if (requestOutputConfigBuilder_ == null) { - requestOutputConfig_ = null; - onChanged(); - } else { - requestOutputConfig_ = null; - requestOutputConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder getRequestOutputConfigBuilder() { - - onChanged(); - return getRequestOutputConfigFieldBuilder().getBuilder(); - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - public com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder getRequestOutputConfigOrBuilder() { - if (requestOutputConfigBuilder_ != null) { - return requestOutputConfigBuilder_.getMessageOrBuilder(); - } else { - return requestOutputConfig_ == null ? - com.google.privacy.dlp.v2beta1.OutputStorageConfig.getDefaultInstance() : requestOutputConfig_; - } - } - /** - *
-     * Optional location to store findings.
-     * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.OutputStorageConfig, com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder, com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder> - getRequestOutputConfigFieldBuilder() { - if (requestOutputConfigBuilder_ == null) { - requestOutputConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.OutputStorageConfig, com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder, com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder>( - getRequestOutputConfig(), - getParentForChildren(), - isClean()); - requestOutputConfig_ = null; - } - return requestOutputConfigBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InspectOperationMetadata) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InspectOperationMetadata) - private static final com.google.privacy.dlp.v2beta1.InspectOperationMetadata DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InspectOperationMetadata(); - } - - public static com.google.privacy.dlp.v2beta1.InspectOperationMetadata getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InspectOperationMetadata parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InspectOperationMetadata(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InspectOperationMetadata getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationMetadataOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationMetadataOrBuilder.java deleted file mode 100644 index 32ae7d60924e..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationMetadataOrBuilder.java +++ /dev/null @@ -1,151 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface InspectOperationMetadataOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InspectOperationMetadata) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Total size in bytes that were processed.
-   * 
- * - * int64 processed_bytes = 1; - */ - long getProcessedBytes(); - - /** - *
-   * Estimate of the number of bytes to process.
-   * 
- * - * int64 total_estimated_bytes = 4; - */ - long getTotalEstimatedBytes(); - - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - java.util.List - getInfoTypeStatsList(); - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - com.google.privacy.dlp.v2beta1.InfoTypeStatistics getInfoTypeStats(int index); - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - int getInfoTypeStatsCount(); - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - java.util.List - getInfoTypeStatsOrBuilderList(); - /** - * repeated .google.privacy.dlp.v2beta1.InfoTypeStatistics info_type_stats = 2; - */ - com.google.privacy.dlp.v2beta1.InfoTypeStatisticsOrBuilder getInfoTypeStatsOrBuilder( - int index); - - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - boolean hasCreateTime(); - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 3; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - *
-   * The inspect config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - boolean hasRequestInspectConfig(); - /** - *
-   * The inspect config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - com.google.privacy.dlp.v2beta1.InspectConfig getRequestInspectConfig(); - /** - *
-   * The inspect config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig request_inspect_config = 5; - */ - com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getRequestInspectConfigOrBuilder(); - - /** - *
-   * The storage config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - boolean hasRequestStorageConfig(); - /** - *
-   * The storage config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - com.google.privacy.dlp.v2beta1.StorageConfig getRequestStorageConfig(); - /** - *
-   * The storage config used to create the Operation.
-   * 
- * - * .google.privacy.dlp.v2beta1.StorageConfig request_storage_config = 6; - */ - com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder getRequestStorageConfigOrBuilder(); - - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - boolean hasRequestOutputConfig(); - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - com.google.privacy.dlp.v2beta1.OutputStorageConfig getRequestOutputConfig(); - /** - *
-   * Optional location to store findings.
-   * 
- * - * .google.privacy.dlp.v2beta1.OutputStorageConfig request_output_config = 7; - */ - com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder getRequestOutputConfigOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationResult.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationResult.java deleted file mode 100644 index 26456ec96aca..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationResult.java +++ /dev/null @@ -1,566 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * The operational data.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectOperationResult} - */ -public final class InspectOperationResult extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InspectOperationResult) - InspectOperationResultOrBuilder { -private static final long serialVersionUID = 0L; - // Use InspectOperationResult.newBuilder() to construct. - private InspectOperationResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InspectOperationResult() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InspectOperationResult( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectOperationResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectOperationResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectOperationResult.class, com.google.privacy.dlp.v2beta1.InspectOperationResult.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - *
-   * The server-assigned name, which is only unique within the same service that
-   * originally returns it. If you use the default HTTP mapping, the
-   * `name` should have the format of `inspect/results/{id}`.
-   * 
- * - * string name = 1; - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - *
-   * The server-assigned name, which is only unique within the same service that
-   * originally returns it. If you use the default HTTP mapping, the
-   * `name` should have the format of `inspect/results/{id}`.
-   * 
- * - * string name = 1; - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - 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.privacy.dlp.v2beta1.InspectOperationResult)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InspectOperationResult other = (com.google.privacy.dlp.v2beta1.InspectOperationResult) obj; - - boolean result = true; - result = result && getName() - .equals(other.getName()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InspectOperationResult parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationResult parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationResult parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationResult 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.privacy.dlp.v2beta1.InspectOperationResult parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationResult parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationResult parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationResult 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.privacy.dlp.v2beta1.InspectOperationResult parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationResult 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.privacy.dlp.v2beta1.InspectOperationResult parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectOperationResult parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InspectOperationResult prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * The operational data.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectOperationResult} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InspectOperationResult) - com.google.privacy.dlp.v2beta1.InspectOperationResultOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectOperationResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectOperationResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectOperationResult.class, com.google.privacy.dlp.v2beta1.InspectOperationResult.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InspectOperationResult.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectOperationResult_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InspectOperationResult getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InspectOperationResult.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InspectOperationResult build() { - com.google.privacy.dlp.v2beta1.InspectOperationResult result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InspectOperationResult buildPartial() { - com.google.privacy.dlp.v2beta1.InspectOperationResult result = new com.google.privacy.dlp.v2beta1.InspectOperationResult(this); - result.name_ = name_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InspectOperationResult) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InspectOperationResult)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InspectOperationResult other) { - if (other == com.google.privacy.dlp.v2beta1.InspectOperationResult.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InspectOperationResult parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InspectOperationResult) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - *
-     * The server-assigned name, which is only unique within the same service that
-     * originally returns it. If you use the default HTTP mapping, the
-     * `name` should have the format of `inspect/results/{id}`.
-     * 
- * - * string name = 1; - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * The server-assigned name, which is only unique within the same service that
-     * originally returns it. If you use the default HTTP mapping, the
-     * `name` should have the format of `inspect/results/{id}`.
-     * 
- * - * string name = 1; - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * The server-assigned name, which is only unique within the same service that
-     * originally returns it. If you use the default HTTP mapping, the
-     * `name` should have the format of `inspect/results/{id}`.
-     * 
- * - * string name = 1; - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - *
-     * The server-assigned name, which is only unique within the same service that
-     * originally returns it. If you use the default HTTP mapping, the
-     * `name` should have the format of `inspect/results/{id}`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - *
-     * The server-assigned name, which is only unique within the same service that
-     * originally returns it. If you use the default HTTP mapping, the
-     * `name` should have the format of `inspect/results/{id}`.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InspectOperationResult) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InspectOperationResult) - private static final com.google.privacy.dlp.v2beta1.InspectOperationResult DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InspectOperationResult(); - } - - public static com.google.privacy.dlp.v2beta1.InspectOperationResult getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InspectOperationResult parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InspectOperationResult(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InspectOperationResult getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationResultOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationResultOrBuilder.java deleted file mode 100644 index 37e2942e96ad..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectOperationResultOrBuilder.java +++ /dev/null @@ -1,31 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface InspectOperationResultOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InspectOperationResult) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The server-assigned name, which is only unique within the same service that
-   * originally returns it. If you use the default HTTP mapping, the
-   * `name` should have the format of `inspect/results/{id}`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - *
-   * The server-assigned name, which is only unique within the same service that
-   * originally returns it. If you use the default HTTP mapping, the
-   * `name` should have the format of `inspect/results/{id}`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString - getNameBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectResult.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectResult.java deleted file mode 100644 index 29ccd1c0d8b6..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectResult.java +++ /dev/null @@ -1,932 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * All the findings for a single scanned item.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectResult} - */ -public final class InspectResult extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.InspectResult) - InspectResultOrBuilder { -private static final long serialVersionUID = 0L; - // Use InspectResult.newBuilder() to construct. - private InspectResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private InspectResult() { - findings_ = java.util.Collections.emptyList(); - findingsTruncated_ = false; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private InspectResult( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - findings_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - findings_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.Finding.parser(), extensionRegistry)); - break; - } - case 16: { - - findingsTruncated_ = input.readBool(); - 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) == 0x00000001)) { - findings_ = java.util.Collections.unmodifiableList(findings_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectResult.class, com.google.privacy.dlp.v2beta1.InspectResult.Builder.class); - } - - private int bitField0_; - public static final int FINDINGS_FIELD_NUMBER = 1; - private java.util.List findings_; - /** - *
-   * List of findings for an item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public java.util.List getFindingsList() { - return findings_; - } - /** - *
-   * List of findings for an item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public java.util.List - getFindingsOrBuilderList() { - return findings_; - } - /** - *
-   * List of findings for an item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public int getFindingsCount() { - return findings_.size(); - } - /** - *
-   * List of findings for an item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public com.google.privacy.dlp.v2beta1.Finding getFindings(int index) { - return findings_.get(index); - } - /** - *
-   * List of findings for an item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public com.google.privacy.dlp.v2beta1.FindingOrBuilder getFindingsOrBuilder( - int index) { - return findings_.get(index); - } - - public static final int FINDINGS_TRUNCATED_FIELD_NUMBER = 2; - private boolean findingsTruncated_; - /** - *
-   * If true, then this item might have more findings than were returned,
-   * and the findings returned are an arbitrary subset of all findings.
-   * The findings list might be truncated because the input items were too
-   * large, or because the server reached the maximum amount of resources
-   * allowed for a single API call. For best results, divide the input into
-   * smaller batches.
-   * 
- * - * bool findings_truncated = 2; - */ - public boolean getFindingsTruncated() { - return findingsTruncated_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < findings_.size(); i++) { - output.writeMessage(1, findings_.get(i)); - } - if (findingsTruncated_ != false) { - output.writeBool(2, findingsTruncated_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < findings_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, findings_.get(i)); - } - if (findingsTruncated_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(2, findingsTruncated_); - } - 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.privacy.dlp.v2beta1.InspectResult)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.InspectResult other = (com.google.privacy.dlp.v2beta1.InspectResult) obj; - - boolean result = true; - result = result && getFindingsList() - .equals(other.getFindingsList()); - result = result && (getFindingsTruncated() - == other.getFindingsTruncated()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getFindingsCount() > 0) { - hash = (37 * hash) + FINDINGS_FIELD_NUMBER; - hash = (53 * hash) + getFindingsList().hashCode(); - } - hash = (37 * hash) + FINDINGS_TRUNCATED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getFindingsTruncated()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.InspectResult parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectResult parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectResult parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectResult 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.privacy.dlp.v2beta1.InspectResult parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.InspectResult parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.InspectResult parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectResult 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.privacy.dlp.v2beta1.InspectResult parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectResult 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.privacy.dlp.v2beta1.InspectResult parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.InspectResult parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.InspectResult prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * All the findings for a single scanned item.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.InspectResult} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.InspectResult) - com.google.privacy.dlp.v2beta1.InspectResultOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.InspectResult.class, com.google.privacy.dlp.v2beta1.InspectResult.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.InspectResult.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getFindingsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (findingsBuilder_ == null) { - findings_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - findingsBuilder_.clear(); - } - findingsTruncated_ = false; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_InspectResult_descriptor; - } - - public com.google.privacy.dlp.v2beta1.InspectResult getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.InspectResult.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.InspectResult build() { - com.google.privacy.dlp.v2beta1.InspectResult result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.InspectResult buildPartial() { - com.google.privacy.dlp.v2beta1.InspectResult result = new com.google.privacy.dlp.v2beta1.InspectResult(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (findingsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - findings_ = java.util.Collections.unmodifiableList(findings_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.findings_ = findings_; - } else { - result.findings_ = findingsBuilder_.build(); - } - result.findingsTruncated_ = findingsTruncated_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.InspectResult) { - return mergeFrom((com.google.privacy.dlp.v2beta1.InspectResult)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.InspectResult other) { - if (other == com.google.privacy.dlp.v2beta1.InspectResult.getDefaultInstance()) return this; - if (findingsBuilder_ == null) { - if (!other.findings_.isEmpty()) { - if (findings_.isEmpty()) { - findings_ = other.findings_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureFindingsIsMutable(); - findings_.addAll(other.findings_); - } - onChanged(); - } - } else { - if (!other.findings_.isEmpty()) { - if (findingsBuilder_.isEmpty()) { - findingsBuilder_.dispose(); - findingsBuilder_ = null; - findings_ = other.findings_; - bitField0_ = (bitField0_ & ~0x00000001); - findingsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getFindingsFieldBuilder() : null; - } else { - findingsBuilder_.addAllMessages(other.findings_); - } - } - } - if (other.getFindingsTruncated() != false) { - setFindingsTruncated(other.getFindingsTruncated()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.InspectResult parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.InspectResult) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List findings_ = - java.util.Collections.emptyList(); - private void ensureFindingsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - findings_ = new java.util.ArrayList(findings_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Finding, com.google.privacy.dlp.v2beta1.Finding.Builder, com.google.privacy.dlp.v2beta1.FindingOrBuilder> findingsBuilder_; - - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public java.util.List getFindingsList() { - if (findingsBuilder_ == null) { - return java.util.Collections.unmodifiableList(findings_); - } else { - return findingsBuilder_.getMessageList(); - } - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public int getFindingsCount() { - if (findingsBuilder_ == null) { - return findings_.size(); - } else { - return findingsBuilder_.getCount(); - } - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public com.google.privacy.dlp.v2beta1.Finding getFindings(int index) { - if (findingsBuilder_ == null) { - return findings_.get(index); - } else { - return findingsBuilder_.getMessage(index); - } - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public Builder setFindings( - int index, com.google.privacy.dlp.v2beta1.Finding value) { - if (findingsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFindingsIsMutable(); - findings_.set(index, value); - onChanged(); - } else { - findingsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public Builder setFindings( - int index, com.google.privacy.dlp.v2beta1.Finding.Builder builderForValue) { - if (findingsBuilder_ == null) { - ensureFindingsIsMutable(); - findings_.set(index, builderForValue.build()); - onChanged(); - } else { - findingsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public Builder addFindings(com.google.privacy.dlp.v2beta1.Finding value) { - if (findingsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFindingsIsMutable(); - findings_.add(value); - onChanged(); - } else { - findingsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public Builder addFindings( - int index, com.google.privacy.dlp.v2beta1.Finding value) { - if (findingsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFindingsIsMutable(); - findings_.add(index, value); - onChanged(); - } else { - findingsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public Builder addFindings( - com.google.privacy.dlp.v2beta1.Finding.Builder builderForValue) { - if (findingsBuilder_ == null) { - ensureFindingsIsMutable(); - findings_.add(builderForValue.build()); - onChanged(); - } else { - findingsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public Builder addFindings( - int index, com.google.privacy.dlp.v2beta1.Finding.Builder builderForValue) { - if (findingsBuilder_ == null) { - ensureFindingsIsMutable(); - findings_.add(index, builderForValue.build()); - onChanged(); - } else { - findingsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public Builder addAllFindings( - java.lang.Iterable values) { - if (findingsBuilder_ == null) { - ensureFindingsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, findings_); - onChanged(); - } else { - findingsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public Builder clearFindings() { - if (findingsBuilder_ == null) { - findings_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - findingsBuilder_.clear(); - } - return this; - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public Builder removeFindings(int index) { - if (findingsBuilder_ == null) { - ensureFindingsIsMutable(); - findings_.remove(index); - onChanged(); - } else { - findingsBuilder_.remove(index); - } - return this; - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public com.google.privacy.dlp.v2beta1.Finding.Builder getFindingsBuilder( - int index) { - return getFindingsFieldBuilder().getBuilder(index); - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public com.google.privacy.dlp.v2beta1.FindingOrBuilder getFindingsOrBuilder( - int index) { - if (findingsBuilder_ == null) { - return findings_.get(index); } else { - return findingsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public java.util.List - getFindingsOrBuilderList() { - if (findingsBuilder_ != null) { - return findingsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(findings_); - } - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public com.google.privacy.dlp.v2beta1.Finding.Builder addFindingsBuilder() { - return getFindingsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.Finding.getDefaultInstance()); - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public com.google.privacy.dlp.v2beta1.Finding.Builder addFindingsBuilder( - int index) { - return getFindingsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.Finding.getDefaultInstance()); - } - /** - *
-     * List of findings for an item.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - public java.util.List - getFindingsBuilderList() { - return getFindingsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Finding, com.google.privacy.dlp.v2beta1.Finding.Builder, com.google.privacy.dlp.v2beta1.FindingOrBuilder> - getFindingsFieldBuilder() { - if (findingsBuilder_ == null) { - findingsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Finding, com.google.privacy.dlp.v2beta1.Finding.Builder, com.google.privacy.dlp.v2beta1.FindingOrBuilder>( - findings_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - findings_ = null; - } - return findingsBuilder_; - } - - private boolean findingsTruncated_ ; - /** - *
-     * If true, then this item might have more findings than were returned,
-     * and the findings returned are an arbitrary subset of all findings.
-     * The findings list might be truncated because the input items were too
-     * large, or because the server reached the maximum amount of resources
-     * allowed for a single API call. For best results, divide the input into
-     * smaller batches.
-     * 
- * - * bool findings_truncated = 2; - */ - public boolean getFindingsTruncated() { - return findingsTruncated_; - } - /** - *
-     * If true, then this item might have more findings than were returned,
-     * and the findings returned are an arbitrary subset of all findings.
-     * The findings list might be truncated because the input items were too
-     * large, or because the server reached the maximum amount of resources
-     * allowed for a single API call. For best results, divide the input into
-     * smaller batches.
-     * 
- * - * bool findings_truncated = 2; - */ - public Builder setFindingsTruncated(boolean value) { - - findingsTruncated_ = value; - onChanged(); - return this; - } - /** - *
-     * If true, then this item might have more findings than were returned,
-     * and the findings returned are an arbitrary subset of all findings.
-     * The findings list might be truncated because the input items were too
-     * large, or because the server reached the maximum amount of resources
-     * allowed for a single API call. For best results, divide the input into
-     * smaller batches.
-     * 
- * - * bool findings_truncated = 2; - */ - public Builder clearFindingsTruncated() { - - findingsTruncated_ = false; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.InspectResult) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.InspectResult) - private static final com.google.privacy.dlp.v2beta1.InspectResult DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.InspectResult(); - } - - public static com.google.privacy.dlp.v2beta1.InspectResult getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public InspectResult parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new InspectResult(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.InspectResult getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectResultOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectResultOrBuilder.java deleted file mode 100644 index 10553fe97191..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/InspectResultOrBuilder.java +++ /dev/null @@ -1,67 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface InspectResultOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.InspectResult) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * List of findings for an item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - java.util.List - getFindingsList(); - /** - *
-   * List of findings for an item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - com.google.privacy.dlp.v2beta1.Finding getFindings(int index); - /** - *
-   * List of findings for an item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - int getFindingsCount(); - /** - *
-   * List of findings for an item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - java.util.List - getFindingsOrBuilderList(); - /** - *
-   * List of findings for an item.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Finding findings = 1; - */ - com.google.privacy.dlp.v2beta1.FindingOrBuilder getFindingsOrBuilder( - int index); - - /** - *
-   * If true, then this item might have more findings than were returned,
-   * and the findings returned are an arbitrary subset of all findings.
-   * The findings list might be truncated because the input items were too
-   * large, or because the server reached the maximum amount of resources
-   * allowed for a single API call. For best results, divide the input into
-   * smaller batches.
-   * 
- * - * bool findings_truncated = 2; - */ - boolean getFindingsTruncated(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Key.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Key.java deleted file mode 100644 index 7e66f013f40f..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Key.java +++ /dev/null @@ -1,2262 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * A unique identifier for a Datastore entity.
- * If a key's partition ID or any of its path kinds or names are
- * reserved/read-only, the key is reserved/read-only.
- * A reserved/read-only key is forbidden in certain documented contexts.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Key} - */ -public final class Key extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.Key) - KeyOrBuilder { -private static final long serialVersionUID = 0L; - // Use Key.newBuilder() to construct. - private Key(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Key() { - path_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Key( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.PartitionId.Builder subBuilder = null; - if (partitionId_ != null) { - subBuilder = partitionId_.toBuilder(); - } - partitionId_ = input.readMessage(com.google.privacy.dlp.v2beta1.PartitionId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(partitionId_); - partitionId_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - path_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - path_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.Key.PathElement.parser(), extensionRegistry)); - 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_ & 0x00000002) == 0x00000002)) { - path_ = java.util.Collections.unmodifiableList(path_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Key_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Key_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Key.class, com.google.privacy.dlp.v2beta1.Key.Builder.class); - } - - public interface PathElementOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.Key.PathElement) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * The kind of the entity.
-     * A kind matching regex `__.*__` is reserved/read-only.
-     * A kind must not contain more than 1500 bytes when UTF-8 encoded.
-     * Cannot be `""`.
-     * 
- * - * string kind = 1; - */ - java.lang.String getKind(); - /** - *
-     * The kind of the entity.
-     * A kind matching regex `__.*__` is reserved/read-only.
-     * A kind must not contain more than 1500 bytes when UTF-8 encoded.
-     * Cannot be `""`.
-     * 
- * - * string kind = 1; - */ - com.google.protobuf.ByteString - getKindBytes(); - - /** - *
-     * The auto-allocated ID of the entity.
-     * Never equal to zero. Values less than zero are discouraged and may not
-     * be supported in the future.
-     * 
- * - * int64 id = 2; - */ - long getId(); - - /** - *
-     * The name of the entity.
-     * A name matching regex `__.*__` is reserved/read-only.
-     * A name must not be more than 1500 bytes when UTF-8 encoded.
-     * Cannot be `""`.
-     * 
- * - * string name = 3; - */ - java.lang.String getName(); - /** - *
-     * The name of the entity.
-     * A name matching regex `__.*__` is reserved/read-only.
-     * A name must not be more than 1500 bytes when UTF-8 encoded.
-     * Cannot be `""`.
-     * 
- * - * string name = 3; - */ - com.google.protobuf.ByteString - getNameBytes(); - - public com.google.privacy.dlp.v2beta1.Key.PathElement.IdTypeCase getIdTypeCase(); - } - /** - *
-   * A (kind, ID/name) pair used to construct a key path.
-   * If either name or ID is set, the element is complete.
-   * If neither is set, the element is incomplete.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Key.PathElement} - */ - public static final class PathElement extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.Key.PathElement) - PathElementOrBuilder { - private static final long serialVersionUID = 0L; - // Use PathElement.newBuilder() to construct. - private PathElement(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private PathElement() { - kind_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private PathElement( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - kind_ = s; - break; - } - case 16: { - idTypeCase_ = 2; - idType_ = input.readInt64(); - break; - } - case 26: { - java.lang.String s = input.readStringRequireUtf8(); - idTypeCase_ = 3; - idType_ = s; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Key_PathElement_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Key_PathElement_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Key.PathElement.class, com.google.privacy.dlp.v2beta1.Key.PathElement.Builder.class); - } - - private int idTypeCase_ = 0; - private java.lang.Object idType_; - public enum IdTypeCase - implements com.google.protobuf.Internal.EnumLite { - ID(2), - NAME(3), - IDTYPE_NOT_SET(0); - private final int value; - private IdTypeCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static IdTypeCase valueOf(int value) { - return forNumber(value); - } - - public static IdTypeCase forNumber(int value) { - switch (value) { - case 2: return ID; - case 3: return NAME; - case 0: return IDTYPE_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public IdTypeCase - getIdTypeCase() { - return IdTypeCase.forNumber( - idTypeCase_); - } - - public static final int KIND_FIELD_NUMBER = 1; - private volatile java.lang.Object kind_; - /** - *
-     * The kind of the entity.
-     * A kind matching regex `__.*__` is reserved/read-only.
-     * A kind must not contain more than 1500 bytes when UTF-8 encoded.
-     * Cannot be `""`.
-     * 
- * - * string kind = 1; - */ - public java.lang.String getKind() { - java.lang.Object ref = kind_; - 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(); - kind_ = s; - return s; - } - } - /** - *
-     * The kind of the entity.
-     * A kind matching regex `__.*__` is reserved/read-only.
-     * A kind must not contain more than 1500 bytes when UTF-8 encoded.
-     * Cannot be `""`.
-     * 
- * - * string kind = 1; - */ - public com.google.protobuf.ByteString - getKindBytes() { - java.lang.Object ref = kind_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - kind_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ID_FIELD_NUMBER = 2; - /** - *
-     * The auto-allocated ID of the entity.
-     * Never equal to zero. Values less than zero are discouraged and may not
-     * be supported in the future.
-     * 
- * - * int64 id = 2; - */ - public long getId() { - if (idTypeCase_ == 2) { - return (java.lang.Long) idType_; - } - return 0L; - } - - public static final int NAME_FIELD_NUMBER = 3; - /** - *
-     * The name of the entity.
-     * A name matching regex `__.*__` is reserved/read-only.
-     * A name must not be more than 1500 bytes when UTF-8 encoded.
-     * Cannot be `""`.
-     * 
- * - * string name = 3; - */ - public java.lang.String getName() { - java.lang.Object ref = ""; - if (idTypeCase_ == 3) { - ref = idType_; - } - 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 (idTypeCase_ == 3) { - idType_ = s; - } - return s; - } - } - /** - *
-     * The name of the entity.
-     * A name matching regex `__.*__` is reserved/read-only.
-     * A name must not be more than 1500 bytes when UTF-8 encoded.
-     * Cannot be `""`.
-     * 
- * - * string name = 3; - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = ""; - if (idTypeCase_ == 3) { - ref = idType_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - if (idTypeCase_ == 3) { - idType_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getKindBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, kind_); - } - if (idTypeCase_ == 2) { - output.writeInt64( - 2, (long)((java.lang.Long) idType_)); - } - if (idTypeCase_ == 3) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, idType_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getKindBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, kind_); - } - if (idTypeCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size( - 2, (long)((java.lang.Long) idType_)); - } - if (idTypeCase_ == 3) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, idType_); - } - 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.privacy.dlp.v2beta1.Key.PathElement)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.Key.PathElement other = (com.google.privacy.dlp.v2beta1.Key.PathElement) obj; - - boolean result = true; - result = result && getKind() - .equals(other.getKind()); - result = result && getIdTypeCase().equals( - other.getIdTypeCase()); - if (!result) return false; - switch (idTypeCase_) { - case 2: - result = result && (getId() - == other.getId()); - break; - case 3: - result = result && getName() - .equals(other.getName()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + KIND_FIELD_NUMBER; - hash = (53 * hash) + getKind().hashCode(); - switch (idTypeCase_) { - case 2: - hash = (37 * hash) + ID_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getId()); - break; - case 3: - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.Key.PathElement parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Key.PathElement parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Key.PathElement parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Key.PathElement 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.privacy.dlp.v2beta1.Key.PathElement parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Key.PathElement parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Key.PathElement parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Key.PathElement 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.privacy.dlp.v2beta1.Key.PathElement parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Key.PathElement 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.privacy.dlp.v2beta1.Key.PathElement parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Key.PathElement parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.Key.PathElement prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-     * A (kind, ID/name) pair used to construct a key path.
-     * If either name or ID is set, the element is complete.
-     * If neither is set, the element is incomplete.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Key.PathElement} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.Key.PathElement) - com.google.privacy.dlp.v2beta1.Key.PathElementOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Key_PathElement_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Key_PathElement_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Key.PathElement.class, com.google.privacy.dlp.v2beta1.Key.PathElement.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.Key.PathElement.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - kind_ = ""; - - idTypeCase_ = 0; - idType_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Key_PathElement_descriptor; - } - - public com.google.privacy.dlp.v2beta1.Key.PathElement getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.Key.PathElement.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.Key.PathElement build() { - com.google.privacy.dlp.v2beta1.Key.PathElement result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.Key.PathElement buildPartial() { - com.google.privacy.dlp.v2beta1.Key.PathElement result = new com.google.privacy.dlp.v2beta1.Key.PathElement(this); - result.kind_ = kind_; - if (idTypeCase_ == 2) { - result.idType_ = idType_; - } - if (idTypeCase_ == 3) { - result.idType_ = idType_; - } - result.idTypeCase_ = idTypeCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.Key.PathElement) { - return mergeFrom((com.google.privacy.dlp.v2beta1.Key.PathElement)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.Key.PathElement other) { - if (other == com.google.privacy.dlp.v2beta1.Key.PathElement.getDefaultInstance()) return this; - if (!other.getKind().isEmpty()) { - kind_ = other.kind_; - onChanged(); - } - switch (other.getIdTypeCase()) { - case ID: { - setId(other.getId()); - break; - } - case NAME: { - idTypeCase_ = 3; - idType_ = other.idType_; - onChanged(); - break; - } - case IDTYPE_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.Key.PathElement parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.Key.PathElement) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int idTypeCase_ = 0; - private java.lang.Object idType_; - public IdTypeCase - getIdTypeCase() { - return IdTypeCase.forNumber( - idTypeCase_); - } - - public Builder clearIdType() { - idTypeCase_ = 0; - idType_ = null; - onChanged(); - return this; - } - - - private java.lang.Object kind_ = ""; - /** - *
-       * The kind of the entity.
-       * A kind matching regex `__.*__` is reserved/read-only.
-       * A kind must not contain more than 1500 bytes when UTF-8 encoded.
-       * Cannot be `""`.
-       * 
- * - * string kind = 1; - */ - public java.lang.String getKind() { - java.lang.Object ref = kind_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - kind_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-       * The kind of the entity.
-       * A kind matching regex `__.*__` is reserved/read-only.
-       * A kind must not contain more than 1500 bytes when UTF-8 encoded.
-       * Cannot be `""`.
-       * 
- * - * string kind = 1; - */ - public com.google.protobuf.ByteString - getKindBytes() { - java.lang.Object ref = kind_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - kind_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-       * The kind of the entity.
-       * A kind matching regex `__.*__` is reserved/read-only.
-       * A kind must not contain more than 1500 bytes when UTF-8 encoded.
-       * Cannot be `""`.
-       * 
- * - * string kind = 1; - */ - public Builder setKind( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - kind_ = value; - onChanged(); - return this; - } - /** - *
-       * The kind of the entity.
-       * A kind matching regex `__.*__` is reserved/read-only.
-       * A kind must not contain more than 1500 bytes when UTF-8 encoded.
-       * Cannot be `""`.
-       * 
- * - * string kind = 1; - */ - public Builder clearKind() { - - kind_ = getDefaultInstance().getKind(); - onChanged(); - return this; - } - /** - *
-       * The kind of the entity.
-       * A kind matching regex `__.*__` is reserved/read-only.
-       * A kind must not contain more than 1500 bytes when UTF-8 encoded.
-       * Cannot be `""`.
-       * 
- * - * string kind = 1; - */ - public Builder setKindBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - kind_ = value; - onChanged(); - return this; - } - - /** - *
-       * The auto-allocated ID of the entity.
-       * Never equal to zero. Values less than zero are discouraged and may not
-       * be supported in the future.
-       * 
- * - * int64 id = 2; - */ - public long getId() { - if (idTypeCase_ == 2) { - return (java.lang.Long) idType_; - } - return 0L; - } - /** - *
-       * The auto-allocated ID of the entity.
-       * Never equal to zero. Values less than zero are discouraged and may not
-       * be supported in the future.
-       * 
- * - * int64 id = 2; - */ - public Builder setId(long value) { - idTypeCase_ = 2; - idType_ = value; - onChanged(); - return this; - } - /** - *
-       * The auto-allocated ID of the entity.
-       * Never equal to zero. Values less than zero are discouraged and may not
-       * be supported in the future.
-       * 
- * - * int64 id = 2; - */ - public Builder clearId() { - if (idTypeCase_ == 2) { - idTypeCase_ = 0; - idType_ = null; - onChanged(); - } - return this; - } - - /** - *
-       * The name of the entity.
-       * A name matching regex `__.*__` is reserved/read-only.
-       * A name must not be more than 1500 bytes when UTF-8 encoded.
-       * Cannot be `""`.
-       * 
- * - * string name = 3; - */ - public java.lang.String getName() { - java.lang.Object ref = ""; - if (idTypeCase_ == 3) { - ref = idType_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (idTypeCase_ == 3) { - idType_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-       * The name of the entity.
-       * A name matching regex `__.*__` is reserved/read-only.
-       * A name must not be more than 1500 bytes when UTF-8 encoded.
-       * Cannot be `""`.
-       * 
- * - * string name = 3; - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = ""; - if (idTypeCase_ == 3) { - ref = idType_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - if (idTypeCase_ == 3) { - idType_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-       * The name of the entity.
-       * A name matching regex `__.*__` is reserved/read-only.
-       * A name must not be more than 1500 bytes when UTF-8 encoded.
-       * Cannot be `""`.
-       * 
- * - * string name = 3; - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - idTypeCase_ = 3; - idType_ = value; - onChanged(); - return this; - } - /** - *
-       * The name of the entity.
-       * A name matching regex `__.*__` is reserved/read-only.
-       * A name must not be more than 1500 bytes when UTF-8 encoded.
-       * Cannot be `""`.
-       * 
- * - * string name = 3; - */ - public Builder clearName() { - if (idTypeCase_ == 3) { - idTypeCase_ = 0; - idType_ = null; - onChanged(); - } - return this; - } - /** - *
-       * The name of the entity.
-       * A name matching regex `__.*__` is reserved/read-only.
-       * A name must not be more than 1500 bytes when UTF-8 encoded.
-       * Cannot be `""`.
-       * 
- * - * string name = 3; - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - idTypeCase_ = 3; - idType_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.Key.PathElement) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.Key.PathElement) - private static final com.google.privacy.dlp.v2beta1.Key.PathElement DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.Key.PathElement(); - } - - public static com.google.privacy.dlp.v2beta1.Key.PathElement getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public PathElement parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new PathElement(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.Key.PathElement getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int bitField0_; - public static final int PARTITION_ID_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.PartitionId partitionId_; - /** - *
-   * Entities are partitioned into subsets, currently identified by a project
-   * ID and namespace ID.
-   * Queries are scoped to a single partition.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public boolean hasPartitionId() { - return partitionId_ != null; - } - /** - *
-   * Entities are partitioned into subsets, currently identified by a project
-   * ID and namespace ID.
-   * Queries are scoped to a single partition.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public com.google.privacy.dlp.v2beta1.PartitionId getPartitionId() { - return partitionId_ == null ? com.google.privacy.dlp.v2beta1.PartitionId.getDefaultInstance() : partitionId_; - } - /** - *
-   * Entities are partitioned into subsets, currently identified by a project
-   * ID and namespace ID.
-   * Queries are scoped to a single partition.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder getPartitionIdOrBuilder() { - return getPartitionId(); - } - - public static final int PATH_FIELD_NUMBER = 2; - private java.util.List path_; - /** - *
-   * The entity path.
-   * An entity path consists of one or more elements composed of a kind and a
-   * string or numerical identifier, which identify entities. The first
-   * element identifies a _root entity_, the second element identifies
-   * a _child_ of the root entity, the third element identifies a child of the
-   * second entity, and so forth. The entities identified by all prefixes of
-   * the path are called the element's _ancestors_.
-   * A path can never be empty, and a path can have at most 100 elements.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public java.util.List getPathList() { - return path_; - } - /** - *
-   * The entity path.
-   * An entity path consists of one or more elements composed of a kind and a
-   * string or numerical identifier, which identify entities. The first
-   * element identifies a _root entity_, the second element identifies
-   * a _child_ of the root entity, the third element identifies a child of the
-   * second entity, and so forth. The entities identified by all prefixes of
-   * the path are called the element's _ancestors_.
-   * A path can never be empty, and a path can have at most 100 elements.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public java.util.List - getPathOrBuilderList() { - return path_; - } - /** - *
-   * The entity path.
-   * An entity path consists of one or more elements composed of a kind and a
-   * string or numerical identifier, which identify entities. The first
-   * element identifies a _root entity_, the second element identifies
-   * a _child_ of the root entity, the third element identifies a child of the
-   * second entity, and so forth. The entities identified by all prefixes of
-   * the path are called the element's _ancestors_.
-   * A path can never be empty, and a path can have at most 100 elements.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public int getPathCount() { - return path_.size(); - } - /** - *
-   * The entity path.
-   * An entity path consists of one or more elements composed of a kind and a
-   * string or numerical identifier, which identify entities. The first
-   * element identifies a _root entity_, the second element identifies
-   * a _child_ of the root entity, the third element identifies a child of the
-   * second entity, and so forth. The entities identified by all prefixes of
-   * the path are called the element's _ancestors_.
-   * A path can never be empty, and a path can have at most 100 elements.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public com.google.privacy.dlp.v2beta1.Key.PathElement getPath(int index) { - return path_.get(index); - } - /** - *
-   * The entity path.
-   * An entity path consists of one or more elements composed of a kind and a
-   * string or numerical identifier, which identify entities. The first
-   * element identifies a _root entity_, the second element identifies
-   * a _child_ of the root entity, the third element identifies a child of the
-   * second entity, and so forth. The entities identified by all prefixes of
-   * the path are called the element's _ancestors_.
-   * A path can never be empty, and a path can have at most 100 elements.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public com.google.privacy.dlp.v2beta1.Key.PathElementOrBuilder getPathOrBuilder( - int index) { - return path_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (partitionId_ != null) { - output.writeMessage(1, getPartitionId()); - } - for (int i = 0; i < path_.size(); i++) { - output.writeMessage(2, path_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (partitionId_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getPartitionId()); - } - for (int i = 0; i < path_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, path_.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.privacy.dlp.v2beta1.Key)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.Key other = (com.google.privacy.dlp.v2beta1.Key) obj; - - boolean result = true; - result = result && (hasPartitionId() == other.hasPartitionId()); - if (hasPartitionId()) { - result = result && getPartitionId() - .equals(other.getPartitionId()); - } - result = result && getPathList() - .equals(other.getPathList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasPartitionId()) { - hash = (37 * hash) + PARTITION_ID_FIELD_NUMBER; - hash = (53 * hash) + getPartitionId().hashCode(); - } - if (getPathCount() > 0) { - hash = (37 * hash) + PATH_FIELD_NUMBER; - hash = (53 * hash) + getPathList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.Key parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Key parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Key parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Key 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.privacy.dlp.v2beta1.Key parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Key parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Key parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Key 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.privacy.dlp.v2beta1.Key parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Key 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.privacy.dlp.v2beta1.Key parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Key parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.Key prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * A unique identifier for a Datastore entity.
-   * If a key's partition ID or any of its path kinds or names are
-   * reserved/read-only, the key is reserved/read-only.
-   * A reserved/read-only key is forbidden in certain documented contexts.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Key} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.Key) - com.google.privacy.dlp.v2beta1.KeyOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Key_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Key_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Key.class, com.google.privacy.dlp.v2beta1.Key.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.Key.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getPathFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (partitionIdBuilder_ == null) { - partitionId_ = null; - } else { - partitionId_ = null; - partitionIdBuilder_ = null; - } - if (pathBuilder_ == null) { - path_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - pathBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Key_descriptor; - } - - public com.google.privacy.dlp.v2beta1.Key getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.Key.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.Key build() { - com.google.privacy.dlp.v2beta1.Key result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.Key buildPartial() { - com.google.privacy.dlp.v2beta1.Key result = new com.google.privacy.dlp.v2beta1.Key(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (partitionIdBuilder_ == null) { - result.partitionId_ = partitionId_; - } else { - result.partitionId_ = partitionIdBuilder_.build(); - } - if (pathBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - path_ = java.util.Collections.unmodifiableList(path_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.path_ = path_; - } else { - result.path_ = pathBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.Key) { - return mergeFrom((com.google.privacy.dlp.v2beta1.Key)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.Key other) { - if (other == com.google.privacy.dlp.v2beta1.Key.getDefaultInstance()) return this; - if (other.hasPartitionId()) { - mergePartitionId(other.getPartitionId()); - } - if (pathBuilder_ == null) { - if (!other.path_.isEmpty()) { - if (path_.isEmpty()) { - path_ = other.path_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensurePathIsMutable(); - path_.addAll(other.path_); - } - onChanged(); - } - } else { - if (!other.path_.isEmpty()) { - if (pathBuilder_.isEmpty()) { - pathBuilder_.dispose(); - pathBuilder_ = null; - path_ = other.path_; - bitField0_ = (bitField0_ & ~0x00000002); - pathBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getPathFieldBuilder() : null; - } else { - pathBuilder_.addAllMessages(other.path_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.Key parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.Key) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private com.google.privacy.dlp.v2beta1.PartitionId partitionId_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PartitionId, com.google.privacy.dlp.v2beta1.PartitionId.Builder, com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder> partitionIdBuilder_; - /** - *
-     * Entities are partitioned into subsets, currently identified by a project
-     * ID and namespace ID.
-     * Queries are scoped to a single partition.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public boolean hasPartitionId() { - return partitionIdBuilder_ != null || partitionId_ != null; - } - /** - *
-     * Entities are partitioned into subsets, currently identified by a project
-     * ID and namespace ID.
-     * Queries are scoped to a single partition.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public com.google.privacy.dlp.v2beta1.PartitionId getPartitionId() { - if (partitionIdBuilder_ == null) { - return partitionId_ == null ? com.google.privacy.dlp.v2beta1.PartitionId.getDefaultInstance() : partitionId_; - } else { - return partitionIdBuilder_.getMessage(); - } - } - /** - *
-     * Entities are partitioned into subsets, currently identified by a project
-     * ID and namespace ID.
-     * Queries are scoped to a single partition.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public Builder setPartitionId(com.google.privacy.dlp.v2beta1.PartitionId value) { - if (partitionIdBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - partitionId_ = value; - onChanged(); - } else { - partitionIdBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Entities are partitioned into subsets, currently identified by a project
-     * ID and namespace ID.
-     * Queries are scoped to a single partition.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public Builder setPartitionId( - com.google.privacy.dlp.v2beta1.PartitionId.Builder builderForValue) { - if (partitionIdBuilder_ == null) { - partitionId_ = builderForValue.build(); - onChanged(); - } else { - partitionIdBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Entities are partitioned into subsets, currently identified by a project
-     * ID and namespace ID.
-     * Queries are scoped to a single partition.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public Builder mergePartitionId(com.google.privacy.dlp.v2beta1.PartitionId value) { - if (partitionIdBuilder_ == null) { - if (partitionId_ != null) { - partitionId_ = - com.google.privacy.dlp.v2beta1.PartitionId.newBuilder(partitionId_).mergeFrom(value).buildPartial(); - } else { - partitionId_ = value; - } - onChanged(); - } else { - partitionIdBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Entities are partitioned into subsets, currently identified by a project
-     * ID and namespace ID.
-     * Queries are scoped to a single partition.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public Builder clearPartitionId() { - if (partitionIdBuilder_ == null) { - partitionId_ = null; - onChanged(); - } else { - partitionId_ = null; - partitionIdBuilder_ = null; - } - - return this; - } - /** - *
-     * Entities are partitioned into subsets, currently identified by a project
-     * ID and namespace ID.
-     * Queries are scoped to a single partition.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public com.google.privacy.dlp.v2beta1.PartitionId.Builder getPartitionIdBuilder() { - - onChanged(); - return getPartitionIdFieldBuilder().getBuilder(); - } - /** - *
-     * Entities are partitioned into subsets, currently identified by a project
-     * ID and namespace ID.
-     * Queries are scoped to a single partition.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - public com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder getPartitionIdOrBuilder() { - if (partitionIdBuilder_ != null) { - return partitionIdBuilder_.getMessageOrBuilder(); - } else { - return partitionId_ == null ? - com.google.privacy.dlp.v2beta1.PartitionId.getDefaultInstance() : partitionId_; - } - } - /** - *
-     * Entities are partitioned into subsets, currently identified by a project
-     * ID and namespace ID.
-     * Queries are scoped to a single partition.
-     * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PartitionId, com.google.privacy.dlp.v2beta1.PartitionId.Builder, com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder> - getPartitionIdFieldBuilder() { - if (partitionIdBuilder_ == null) { - partitionIdBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PartitionId, com.google.privacy.dlp.v2beta1.PartitionId.Builder, com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder>( - getPartitionId(), - getParentForChildren(), - isClean()); - partitionId_ = null; - } - return partitionIdBuilder_; - } - - private java.util.List path_ = - java.util.Collections.emptyList(); - private void ensurePathIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - path_ = new java.util.ArrayList(path_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Key.PathElement, com.google.privacy.dlp.v2beta1.Key.PathElement.Builder, com.google.privacy.dlp.v2beta1.Key.PathElementOrBuilder> pathBuilder_; - - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public java.util.List getPathList() { - if (pathBuilder_ == null) { - return java.util.Collections.unmodifiableList(path_); - } else { - return pathBuilder_.getMessageList(); - } - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public int getPathCount() { - if (pathBuilder_ == null) { - return path_.size(); - } else { - return pathBuilder_.getCount(); - } - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public com.google.privacy.dlp.v2beta1.Key.PathElement getPath(int index) { - if (pathBuilder_ == null) { - return path_.get(index); - } else { - return pathBuilder_.getMessage(index); - } - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public Builder setPath( - int index, com.google.privacy.dlp.v2beta1.Key.PathElement value) { - if (pathBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensurePathIsMutable(); - path_.set(index, value); - onChanged(); - } else { - pathBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public Builder setPath( - int index, com.google.privacy.dlp.v2beta1.Key.PathElement.Builder builderForValue) { - if (pathBuilder_ == null) { - ensurePathIsMutable(); - path_.set(index, builderForValue.build()); - onChanged(); - } else { - pathBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public Builder addPath(com.google.privacy.dlp.v2beta1.Key.PathElement value) { - if (pathBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensurePathIsMutable(); - path_.add(value); - onChanged(); - } else { - pathBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public Builder addPath( - int index, com.google.privacy.dlp.v2beta1.Key.PathElement value) { - if (pathBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensurePathIsMutable(); - path_.add(index, value); - onChanged(); - } else { - pathBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public Builder addPath( - com.google.privacy.dlp.v2beta1.Key.PathElement.Builder builderForValue) { - if (pathBuilder_ == null) { - ensurePathIsMutable(); - path_.add(builderForValue.build()); - onChanged(); - } else { - pathBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public Builder addPath( - int index, com.google.privacy.dlp.v2beta1.Key.PathElement.Builder builderForValue) { - if (pathBuilder_ == null) { - ensurePathIsMutable(); - path_.add(index, builderForValue.build()); - onChanged(); - } else { - pathBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public Builder addAllPath( - java.lang.Iterable values) { - if (pathBuilder_ == null) { - ensurePathIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, path_); - onChanged(); - } else { - pathBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public Builder clearPath() { - if (pathBuilder_ == null) { - path_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - pathBuilder_.clear(); - } - return this; - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public Builder removePath(int index) { - if (pathBuilder_ == null) { - ensurePathIsMutable(); - path_.remove(index); - onChanged(); - } else { - pathBuilder_.remove(index); - } - return this; - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public com.google.privacy.dlp.v2beta1.Key.PathElement.Builder getPathBuilder( - int index) { - return getPathFieldBuilder().getBuilder(index); - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public com.google.privacy.dlp.v2beta1.Key.PathElementOrBuilder getPathOrBuilder( - int index) { - if (pathBuilder_ == null) { - return path_.get(index); } else { - return pathBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public java.util.List - getPathOrBuilderList() { - if (pathBuilder_ != null) { - return pathBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(path_); - } - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public com.google.privacy.dlp.v2beta1.Key.PathElement.Builder addPathBuilder() { - return getPathFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.Key.PathElement.getDefaultInstance()); - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public com.google.privacy.dlp.v2beta1.Key.PathElement.Builder addPathBuilder( - int index) { - return getPathFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.Key.PathElement.getDefaultInstance()); - } - /** - *
-     * The entity path.
-     * An entity path consists of one or more elements composed of a kind and a
-     * string or numerical identifier, which identify entities. The first
-     * element identifies a _root entity_, the second element identifies
-     * a _child_ of the root entity, the third element identifies a child of the
-     * second entity, and so forth. The entities identified by all prefixes of
-     * the path are called the element's _ancestors_.
-     * A path can never be empty, and a path can have at most 100 elements.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - public java.util.List - getPathBuilderList() { - return getPathFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Key.PathElement, com.google.privacy.dlp.v2beta1.Key.PathElement.Builder, com.google.privacy.dlp.v2beta1.Key.PathElementOrBuilder> - getPathFieldBuilder() { - if (pathBuilder_ == null) { - pathBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Key.PathElement, com.google.privacy.dlp.v2beta1.Key.PathElement.Builder, com.google.privacy.dlp.v2beta1.Key.PathElementOrBuilder>( - path_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - path_ = null; - } - return pathBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.Key) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.Key) - private static final com.google.privacy.dlp.v2beta1.Key DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.Key(); - } - - public static com.google.privacy.dlp.v2beta1.Key getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Key parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Key(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.Key getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KeyOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KeyOrBuilder.java deleted file mode 100644 index b95496286d15..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KeyOrBuilder.java +++ /dev/null @@ -1,119 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface KeyOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.Key) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Entities are partitioned into subsets, currently identified by a project
-   * ID and namespace ID.
-   * Queries are scoped to a single partition.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - boolean hasPartitionId(); - /** - *
-   * Entities are partitioned into subsets, currently identified by a project
-   * ID and namespace ID.
-   * Queries are scoped to a single partition.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - com.google.privacy.dlp.v2beta1.PartitionId getPartitionId(); - /** - *
-   * Entities are partitioned into subsets, currently identified by a project
-   * ID and namespace ID.
-   * Queries are scoped to a single partition.
-   * 
- * - * .google.privacy.dlp.v2beta1.PartitionId partition_id = 1; - */ - com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder getPartitionIdOrBuilder(); - - /** - *
-   * The entity path.
-   * An entity path consists of one or more elements composed of a kind and a
-   * string or numerical identifier, which identify entities. The first
-   * element identifies a _root entity_, the second element identifies
-   * a _child_ of the root entity, the third element identifies a child of the
-   * second entity, and so forth. The entities identified by all prefixes of
-   * the path are called the element's _ancestors_.
-   * A path can never be empty, and a path can have at most 100 elements.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - java.util.List - getPathList(); - /** - *
-   * The entity path.
-   * An entity path consists of one or more elements composed of a kind and a
-   * string or numerical identifier, which identify entities. The first
-   * element identifies a _root entity_, the second element identifies
-   * a _child_ of the root entity, the third element identifies a child of the
-   * second entity, and so forth. The entities identified by all prefixes of
-   * the path are called the element's _ancestors_.
-   * A path can never be empty, and a path can have at most 100 elements.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - com.google.privacy.dlp.v2beta1.Key.PathElement getPath(int index); - /** - *
-   * The entity path.
-   * An entity path consists of one or more elements composed of a kind and a
-   * string or numerical identifier, which identify entities. The first
-   * element identifies a _root entity_, the second element identifies
-   * a _child_ of the root entity, the third element identifies a child of the
-   * second entity, and so forth. The entities identified by all prefixes of
-   * the path are called the element's _ancestors_.
-   * A path can never be empty, and a path can have at most 100 elements.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - int getPathCount(); - /** - *
-   * The entity path.
-   * An entity path consists of one or more elements composed of a kind and a
-   * string or numerical identifier, which identify entities. The first
-   * element identifies a _root entity_, the second element identifies
-   * a _child_ of the root entity, the third element identifies a child of the
-   * second entity, and so forth. The entities identified by all prefixes of
-   * the path are called the element's _ancestors_.
-   * A path can never be empty, and a path can have at most 100 elements.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - java.util.List - getPathOrBuilderList(); - /** - *
-   * The entity path.
-   * An entity path consists of one or more elements composed of a kind and a
-   * string or numerical identifier, which identify entities. The first
-   * element identifies a _root entity_, the second element identifies
-   * a _child_ of the root entity, the third element identifies a child of the
-   * second entity, and so forth. The entities identified by all prefixes of
-   * the path are called the element's _ancestors_.
-   * A path can never be empty, and a path can have at most 100 elements.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.Key.PathElement path = 2; - */ - com.google.privacy.dlp.v2beta1.Key.PathElementOrBuilder getPathOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KindExpressionOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KindExpressionOrBuilder.java deleted file mode 100644 index 5203faab113f..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KindExpressionOrBuilder.java +++ /dev/null @@ -1,27 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface KindExpressionOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.KindExpression) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The name of the kind.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - *
-   * The name of the kind.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString - getNameBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KmsWrappedCryptoKey.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KmsWrappedCryptoKey.java deleted file mode 100644 index ec2597109a06..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KmsWrappedCryptoKey.java +++ /dev/null @@ -1,635 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Include to use an existing data crypto key wrapped by KMS.
- * Authorization requires the following IAM permissions when sending a request
- * to perform a crypto transformation using a kms-wrapped crypto key:
- * dlp.kms.encrypt
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.KmsWrappedCryptoKey} - */ -public final class KmsWrappedCryptoKey extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) - KmsWrappedCryptoKeyOrBuilder { -private static final long serialVersionUID = 0L; - // Use KmsWrappedCryptoKey.newBuilder() to construct. - private KmsWrappedCryptoKey(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private KmsWrappedCryptoKey() { - wrappedKey_ = com.google.protobuf.ByteString.EMPTY; - cryptoKeyName_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private KmsWrappedCryptoKey( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - - wrappedKey_ = input.readBytes(); - break; - } - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - cryptoKeyName_ = s; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_KmsWrappedCryptoKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_KmsWrappedCryptoKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.class, com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.Builder.class); - } - - public static final int WRAPPED_KEY_FIELD_NUMBER = 1; - private com.google.protobuf.ByteString wrappedKey_; - /** - *
-   * The wrapped data crypto key. [required]
-   * 
- * - * bytes wrapped_key = 1; - */ - public com.google.protobuf.ByteString getWrappedKey() { - return wrappedKey_; - } - - public static final int CRYPTO_KEY_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object cryptoKeyName_; - /** - *
-   * The resource name of the KMS CryptoKey to use for unwrapping. [required]
-   * 
- * - * string crypto_key_name = 2; - */ - public java.lang.String getCryptoKeyName() { - java.lang.Object ref = cryptoKeyName_; - 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(); - cryptoKeyName_ = s; - return s; - } - } - /** - *
-   * The resource name of the KMS CryptoKey to use for unwrapping. [required]
-   * 
- * - * string crypto_key_name = 2; - */ - public com.google.protobuf.ByteString - getCryptoKeyNameBytes() { - java.lang.Object ref = cryptoKeyName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - cryptoKeyName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!wrappedKey_.isEmpty()) { - output.writeBytes(1, wrappedKey_); - } - if (!getCryptoKeyNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, cryptoKeyName_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!wrappedKey_.isEmpty()) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, wrappedKey_); - } - if (!getCryptoKeyNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, cryptoKeyName_); - } - 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.privacy.dlp.v2beta1.KmsWrappedCryptoKey)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey other = (com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) obj; - - boolean result = true; - result = result && getWrappedKey() - .equals(other.getWrappedKey()); - result = result && getCryptoKeyName() - .equals(other.getCryptoKeyName()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + WRAPPED_KEY_FIELD_NUMBER; - hash = (53 * hash) + getWrappedKey().hashCode(); - hash = (37 * hash) + CRYPTO_KEY_NAME_FIELD_NUMBER; - hash = (53 * hash) + getCryptoKeyName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey 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.privacy.dlp.v2beta1.KmsWrappedCryptoKey parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey 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.privacy.dlp.v2beta1.KmsWrappedCryptoKey parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey 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.privacy.dlp.v2beta1.KmsWrappedCryptoKey parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Include to use an existing data crypto key wrapped by KMS.
-   * Authorization requires the following IAM permissions when sending a request
-   * to perform a crypto transformation using a kms-wrapped crypto key:
-   * dlp.kms.encrypt
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.KmsWrappedCryptoKey} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKeyOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_KmsWrappedCryptoKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_KmsWrappedCryptoKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.class, com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - wrappedKey_ = com.google.protobuf.ByteString.EMPTY; - - cryptoKeyName_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_KmsWrappedCryptoKey_descriptor; - } - - public com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey build() { - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey buildPartial() { - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey result = new com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey(this); - result.wrappedKey_ = wrappedKey_; - result.cryptoKeyName_ = cryptoKeyName_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) { - return mergeFrom((com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey other) { - if (other == com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey.getDefaultInstance()) return this; - if (other.getWrappedKey() != com.google.protobuf.ByteString.EMPTY) { - setWrappedKey(other.getWrappedKey()); - } - if (!other.getCryptoKeyName().isEmpty()) { - cryptoKeyName_ = other.cryptoKeyName_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.protobuf.ByteString wrappedKey_ = com.google.protobuf.ByteString.EMPTY; - /** - *
-     * The wrapped data crypto key. [required]
-     * 
- * - * bytes wrapped_key = 1; - */ - public com.google.protobuf.ByteString getWrappedKey() { - return wrappedKey_; - } - /** - *
-     * The wrapped data crypto key. [required]
-     * 
- * - * bytes wrapped_key = 1; - */ - public Builder setWrappedKey(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - - wrappedKey_ = value; - onChanged(); - return this; - } - /** - *
-     * The wrapped data crypto key. [required]
-     * 
- * - * bytes wrapped_key = 1; - */ - public Builder clearWrappedKey() { - - wrappedKey_ = getDefaultInstance().getWrappedKey(); - onChanged(); - return this; - } - - private java.lang.Object cryptoKeyName_ = ""; - /** - *
-     * The resource name of the KMS CryptoKey to use for unwrapping. [required]
-     * 
- * - * string crypto_key_name = 2; - */ - public java.lang.String getCryptoKeyName() { - java.lang.Object ref = cryptoKeyName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - cryptoKeyName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * The resource name of the KMS CryptoKey to use for unwrapping. [required]
-     * 
- * - * string crypto_key_name = 2; - */ - public com.google.protobuf.ByteString - getCryptoKeyNameBytes() { - java.lang.Object ref = cryptoKeyName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - cryptoKeyName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * The resource name of the KMS CryptoKey to use for unwrapping. [required]
-     * 
- * - * string crypto_key_name = 2; - */ - public Builder setCryptoKeyName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - cryptoKeyName_ = value; - onChanged(); - return this; - } - /** - *
-     * The resource name of the KMS CryptoKey to use for unwrapping. [required]
-     * 
- * - * string crypto_key_name = 2; - */ - public Builder clearCryptoKeyName() { - - cryptoKeyName_ = getDefaultInstance().getCryptoKeyName(); - onChanged(); - return this; - } - /** - *
-     * The resource name of the KMS CryptoKey to use for unwrapping. [required]
-     * 
- * - * string crypto_key_name = 2; - */ - public Builder setCryptoKeyNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - cryptoKeyName_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) - private static final com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey(); - } - - public static com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public KmsWrappedCryptoKey parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new KmsWrappedCryptoKey(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.KmsWrappedCryptoKey getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KmsWrappedCryptoKeyOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KmsWrappedCryptoKeyOrBuilder.java deleted file mode 100644 index aeae3e711e2e..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KmsWrappedCryptoKeyOrBuilder.java +++ /dev/null @@ -1,36 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface KmsWrappedCryptoKeyOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.KmsWrappedCryptoKey) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The wrapped data crypto key. [required]
-   * 
- * - * bytes wrapped_key = 1; - */ - com.google.protobuf.ByteString getWrappedKey(); - - /** - *
-   * The resource name of the KMS CryptoKey to use for unwrapping. [required]
-   * 
- * - * string crypto_key_name = 2; - */ - java.lang.String getCryptoKeyName(); - /** - *
-   * The resource name of the KMS CryptoKey to use for unwrapping. [required]
-   * 
- * - * string crypto_key_name = 2; - */ - com.google.protobuf.ByteString - getCryptoKeyNameBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Likelihood.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Likelihood.java deleted file mode 100644 index 6288de1af92d..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Likelihood.java +++ /dev/null @@ -1,176 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Categorization of results based on how likely they are to represent a match,
- * based on the number of elements they contain which imply a match.
- * 
- * - * Protobuf enum {@code google.privacy.dlp.v2beta1.Likelihood} - */ -public enum Likelihood - implements com.google.protobuf.ProtocolMessageEnum { - /** - *
-   * Default value; information with all likelihoods is included.
-   * 
- * - * LIKELIHOOD_UNSPECIFIED = 0; - */ - LIKELIHOOD_UNSPECIFIED(0), - /** - *
-   * Few matching elements.
-   * 
- * - * VERY_UNLIKELY = 1; - */ - VERY_UNLIKELY(1), - /** - * UNLIKELY = 2; - */ - UNLIKELY(2), - /** - *
-   * Some matching elements.
-   * 
- * - * POSSIBLE = 3; - */ - POSSIBLE(3), - /** - * LIKELY = 4; - */ - LIKELY(4), - /** - *
-   * Many matching elements.
-   * 
- * - * VERY_LIKELY = 5; - */ - VERY_LIKELY(5), - UNRECOGNIZED(-1), - ; - - /** - *
-   * Default value; information with all likelihoods is included.
-   * 
- * - * LIKELIHOOD_UNSPECIFIED = 0; - */ - public static final int LIKELIHOOD_UNSPECIFIED_VALUE = 0; - /** - *
-   * Few matching elements.
-   * 
- * - * VERY_UNLIKELY = 1; - */ - public static final int VERY_UNLIKELY_VALUE = 1; - /** - * UNLIKELY = 2; - */ - public static final int UNLIKELY_VALUE = 2; - /** - *
-   * Some matching elements.
-   * 
- * - * POSSIBLE = 3; - */ - public static final int POSSIBLE_VALUE = 3; - /** - * LIKELY = 4; - */ - public static final int LIKELY_VALUE = 4; - /** - *
-   * Many matching elements.
-   * 
- * - * VERY_LIKELY = 5; - */ - public static final int VERY_LIKELY_VALUE = 5; - - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Likelihood valueOf(int value) { - return forNumber(value); - } - - public static Likelihood forNumber(int value) { - switch (value) { - case 0: return LIKELIHOOD_UNSPECIFIED; - case 1: return VERY_UNLIKELY; - case 2: return UNLIKELY; - case 3: return POSSIBLE; - case 4: return LIKELY; - case 5: return VERY_LIKELY; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - private static final com.google.protobuf.Internal.EnumLiteMap< - Likelihood> internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Likelihood findValueByNumber(int number) { - return Likelihood.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - 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.privacy.dlp.v2beta1.DlpProto.getDescriptor().getEnumTypes().get(0); - } - - private static final Likelihood[] VALUES = values(); - - public static Likelihood 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 Likelihood(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.privacy.dlp.v2beta1.Likelihood) -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesRequest.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesRequest.java deleted file mode 100644 index 70cd97f593d0..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesRequest.java +++ /dev/null @@ -1,723 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Request for the list of info types belonging to a given category,
- * or all supported info types if no category is specified.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListInfoTypesRequest} - */ -public final class ListInfoTypesRequest extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ListInfoTypesRequest) - ListInfoTypesRequestOrBuilder { -private static final long serialVersionUID = 0L; - // Use ListInfoTypesRequest.newBuilder() to construct. - private ListInfoTypesRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ListInfoTypesRequest() { - category_ = ""; - languageCode_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ListInfoTypesRequest( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - category_ = s; - break; - } - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - languageCode_ = s; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInfoTypesRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInfoTypesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListInfoTypesRequest.class, com.google.privacy.dlp.v2beta1.ListInfoTypesRequest.Builder.class); - } - - public static final int CATEGORY_FIELD_NUMBER = 1; - private volatile java.lang.Object category_; - /** - *
-   * Category name as returned by ListRootCategories.
-   * 
- * - * string category = 1; - */ - public java.lang.String getCategory() { - java.lang.Object ref = category_; - 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(); - category_ = s; - return s; - } - } - /** - *
-   * Category name as returned by ListRootCategories.
-   * 
- * - * string category = 1; - */ - public com.google.protobuf.ByteString - getCategoryBytes() { - java.lang.Object ref = category_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - category_ = 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_; - /** - *
-   * Optional BCP-47 language code for localized info type friendly
-   * names. If omitted, or if localized strings are not available,
-   * en-US strings will be returned.
-   * 
- * - * string language_code = 2; - */ - 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; - } - } - /** - *
-   * Optional BCP-47 language code for localized info type friendly
-   * names. If omitted, or if localized strings are not available,
-   * en-US strings will be returned.
-   * 
- * - * string language_code = 2; - */ - 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; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getCategoryBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, category_); - } - if (!getLanguageCodeBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, languageCode_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getCategoryBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, category_); - } - 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.privacy.dlp.v2beta1.ListInfoTypesRequest)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ListInfoTypesRequest other = (com.google.privacy.dlp.v2beta1.ListInfoTypesRequest) obj; - - boolean result = true; - result = result && getCategory() - .equals(other.getCategory()); - result = result && getLanguageCode() - .equals(other.getLanguageCode()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + CATEGORY_FIELD_NUMBER; - hash = (53 * hash) + getCategory().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.privacy.dlp.v2beta1.ListInfoTypesRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesRequest 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.privacy.dlp.v2beta1.ListInfoTypesRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesRequest 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.privacy.dlp.v2beta1.ListInfoTypesRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesRequest 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.privacy.dlp.v2beta1.ListInfoTypesRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ListInfoTypesRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Request for the list of info types belonging to a given category,
-   * or all supported info types if no category is specified.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListInfoTypesRequest} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ListInfoTypesRequest) - com.google.privacy.dlp.v2beta1.ListInfoTypesRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInfoTypesRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInfoTypesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListInfoTypesRequest.class, com.google.privacy.dlp.v2beta1.ListInfoTypesRequest.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ListInfoTypesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - category_ = ""; - - languageCode_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInfoTypesRequest_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ListInfoTypesRequest getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ListInfoTypesRequest.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ListInfoTypesRequest build() { - com.google.privacy.dlp.v2beta1.ListInfoTypesRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ListInfoTypesRequest buildPartial() { - com.google.privacy.dlp.v2beta1.ListInfoTypesRequest result = new com.google.privacy.dlp.v2beta1.ListInfoTypesRequest(this); - result.category_ = category_; - result.languageCode_ = languageCode_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ListInfoTypesRequest) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ListInfoTypesRequest)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ListInfoTypesRequest other) { - if (other == com.google.privacy.dlp.v2beta1.ListInfoTypesRequest.getDefaultInstance()) return this; - if (!other.getCategory().isEmpty()) { - category_ = other.category_; - onChanged(); - } - if (!other.getLanguageCode().isEmpty()) { - languageCode_ = other.languageCode_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ListInfoTypesRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ListInfoTypesRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object category_ = ""; - /** - *
-     * Category name as returned by ListRootCategories.
-     * 
- * - * string category = 1; - */ - public java.lang.String getCategory() { - java.lang.Object ref = category_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - category_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * Category name as returned by ListRootCategories.
-     * 
- * - * string category = 1; - */ - public com.google.protobuf.ByteString - getCategoryBytes() { - java.lang.Object ref = category_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - category_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * Category name as returned by ListRootCategories.
-     * 
- * - * string category = 1; - */ - public Builder setCategory( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - category_ = value; - onChanged(); - return this; - } - /** - *
-     * Category name as returned by ListRootCategories.
-     * 
- * - * string category = 1; - */ - public Builder clearCategory() { - - category_ = getDefaultInstance().getCategory(); - onChanged(); - return this; - } - /** - *
-     * Category name as returned by ListRootCategories.
-     * 
- * - * string category = 1; - */ - public Builder setCategoryBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - category_ = value; - onChanged(); - return this; - } - - private java.lang.Object languageCode_ = ""; - /** - *
-     * Optional BCP-47 language code for localized info type friendly
-     * names. If omitted, or if localized strings are not available,
-     * en-US strings will be returned.
-     * 
- * - * string language_code = 2; - */ - 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; - } - } - /** - *
-     * Optional BCP-47 language code for localized info type friendly
-     * names. If omitted, or if localized strings are not available,
-     * en-US strings will be returned.
-     * 
- * - * string language_code = 2; - */ - 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; - } - } - /** - *
-     * Optional BCP-47 language code for localized info type friendly
-     * names. If omitted, or if localized strings are not available,
-     * en-US strings will be returned.
-     * 
- * - * string language_code = 2; - */ - public Builder setLanguageCode( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - languageCode_ = value; - onChanged(); - return this; - } - /** - *
-     * Optional BCP-47 language code for localized info type friendly
-     * names. If omitted, or if localized strings are not available,
-     * en-US strings will be returned.
-     * 
- * - * string language_code = 2; - */ - public Builder clearLanguageCode() { - - languageCode_ = getDefaultInstance().getLanguageCode(); - onChanged(); - return this; - } - /** - *
-     * Optional BCP-47 language code for localized info type friendly
-     * names. If omitted, or if localized strings are not available,
-     * en-US strings will be returned.
-     * 
- * - * string language_code = 2; - */ - public Builder setLanguageCodeBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - languageCode_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ListInfoTypesRequest) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ListInfoTypesRequest) - private static final com.google.privacy.dlp.v2beta1.ListInfoTypesRequest DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ListInfoTypesRequest(); - } - - public static com.google.privacy.dlp.v2beta1.ListInfoTypesRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ListInfoTypesRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListInfoTypesRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ListInfoTypesRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesRequestOrBuilder.java deleted file mode 100644 index 0c8a56007c52..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesRequestOrBuilder.java +++ /dev/null @@ -1,49 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ListInfoTypesRequestOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ListInfoTypesRequest) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Category name as returned by ListRootCategories.
-   * 
- * - * string category = 1; - */ - java.lang.String getCategory(); - /** - *
-   * Category name as returned by ListRootCategories.
-   * 
- * - * string category = 1; - */ - com.google.protobuf.ByteString - getCategoryBytes(); - - /** - *
-   * Optional BCP-47 language code for localized info type friendly
-   * names. If omitted, or if localized strings are not available,
-   * en-US strings will be returned.
-   * 
- * - * string language_code = 2; - */ - java.lang.String getLanguageCode(); - /** - *
-   * Optional BCP-47 language code for localized info type friendly
-   * names. If omitted, or if localized strings are not available,
-   * en-US strings will be returned.
-   * 
- * - * string language_code = 2; - */ - com.google.protobuf.ByteString - getLanguageCodeBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesResponse.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesResponse.java deleted file mode 100644 index 4cf2952a25b6..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesResponse.java +++ /dev/null @@ -1,834 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Response to the ListInfoTypes request.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListInfoTypesResponse} - */ -public final class ListInfoTypesResponse extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ListInfoTypesResponse) - ListInfoTypesResponseOrBuilder { -private static final long serialVersionUID = 0L; - // Use ListInfoTypesResponse.newBuilder() to construct. - private ListInfoTypesResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ListInfoTypesResponse() { - infoTypes_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ListInfoTypesResponse( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - infoTypes_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - infoTypes_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.InfoTypeDescription.parser(), extensionRegistry)); - 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) == 0x00000001)) { - infoTypes_ = java.util.Collections.unmodifiableList(infoTypes_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInfoTypesResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInfoTypesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListInfoTypesResponse.class, com.google.privacy.dlp.v2beta1.ListInfoTypesResponse.Builder.class); - } - - public static final int INFO_TYPES_FIELD_NUMBER = 1; - private java.util.List infoTypes_; - /** - *
-   * Set of sensitive info types belonging to a category.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public java.util.List getInfoTypesList() { - return infoTypes_; - } - /** - *
-   * Set of sensitive info types belonging to a category.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public java.util.List - getInfoTypesOrBuilderList() { - return infoTypes_; - } - /** - *
-   * Set of sensitive info types belonging to a category.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public int getInfoTypesCount() { - return infoTypes_.size(); - } - /** - *
-   * Set of sensitive info types belonging to a category.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeDescription getInfoTypes(int index) { - return infoTypes_.get(index); - } - /** - *
-   * Set of sensitive info types belonging to a category.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeDescriptionOrBuilder getInfoTypesOrBuilder( - int index) { - return infoTypes_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < infoTypes_.size(); i++) { - output.writeMessage(1, infoTypes_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < infoTypes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, infoTypes_.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.privacy.dlp.v2beta1.ListInfoTypesResponse)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ListInfoTypesResponse other = (com.google.privacy.dlp.v2beta1.ListInfoTypesResponse) obj; - - boolean result = true; - result = result && getInfoTypesList() - .equals(other.getInfoTypesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getInfoTypesCount() > 0) { - hash = (37 * hash) + INFO_TYPES_FIELD_NUMBER; - hash = (53 * hash) + getInfoTypesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.ListInfoTypesResponse parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesResponse 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.privacy.dlp.v2beta1.ListInfoTypesResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesResponse 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.privacy.dlp.v2beta1.ListInfoTypesResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesResponse 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.privacy.dlp.v2beta1.ListInfoTypesResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInfoTypesResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ListInfoTypesResponse prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Response to the ListInfoTypes request.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListInfoTypesResponse} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ListInfoTypesResponse) - com.google.privacy.dlp.v2beta1.ListInfoTypesResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInfoTypesResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInfoTypesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListInfoTypesResponse.class, com.google.privacy.dlp.v2beta1.ListInfoTypesResponse.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ListInfoTypesResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getInfoTypesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (infoTypesBuilder_ == null) { - infoTypes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - infoTypesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInfoTypesResponse_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ListInfoTypesResponse getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ListInfoTypesResponse.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ListInfoTypesResponse build() { - com.google.privacy.dlp.v2beta1.ListInfoTypesResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ListInfoTypesResponse buildPartial() { - com.google.privacy.dlp.v2beta1.ListInfoTypesResponse result = new com.google.privacy.dlp.v2beta1.ListInfoTypesResponse(this); - int from_bitField0_ = bitField0_; - if (infoTypesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - infoTypes_ = java.util.Collections.unmodifiableList(infoTypes_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.infoTypes_ = infoTypes_; - } else { - result.infoTypes_ = infoTypesBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ListInfoTypesResponse) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ListInfoTypesResponse)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ListInfoTypesResponse other) { - if (other == com.google.privacy.dlp.v2beta1.ListInfoTypesResponse.getDefaultInstance()) return this; - if (infoTypesBuilder_ == null) { - if (!other.infoTypes_.isEmpty()) { - if (infoTypes_.isEmpty()) { - infoTypes_ = other.infoTypes_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureInfoTypesIsMutable(); - infoTypes_.addAll(other.infoTypes_); - } - onChanged(); - } - } else { - if (!other.infoTypes_.isEmpty()) { - if (infoTypesBuilder_.isEmpty()) { - infoTypesBuilder_.dispose(); - infoTypesBuilder_ = null; - infoTypes_ = other.infoTypes_; - bitField0_ = (bitField0_ & ~0x00000001); - infoTypesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getInfoTypesFieldBuilder() : null; - } else { - infoTypesBuilder_.addAllMessages(other.infoTypes_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ListInfoTypesResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ListInfoTypesResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List infoTypes_ = - java.util.Collections.emptyList(); - private void ensureInfoTypesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - infoTypes_ = new java.util.ArrayList(infoTypes_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeDescription, com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder, com.google.privacy.dlp.v2beta1.InfoTypeDescriptionOrBuilder> infoTypesBuilder_; - - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public java.util.List getInfoTypesList() { - if (infoTypesBuilder_ == null) { - return java.util.Collections.unmodifiableList(infoTypes_); - } else { - return infoTypesBuilder_.getMessageList(); - } - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public int getInfoTypesCount() { - if (infoTypesBuilder_ == null) { - return infoTypes_.size(); - } else { - return infoTypesBuilder_.getCount(); - } - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeDescription getInfoTypes(int index) { - if (infoTypesBuilder_ == null) { - return infoTypes_.get(index); - } else { - return infoTypesBuilder_.getMessage(index); - } - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public Builder setInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoTypeDescription value) { - if (infoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypesIsMutable(); - infoTypes_.set(index, value); - onChanged(); - } else { - infoTypesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public Builder setInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder builderForValue) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.set(index, builderForValue.build()); - onChanged(); - } else { - infoTypesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public Builder addInfoTypes(com.google.privacy.dlp.v2beta1.InfoTypeDescription value) { - if (infoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypesIsMutable(); - infoTypes_.add(value); - onChanged(); - } else { - infoTypesBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public Builder addInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoTypeDescription value) { - if (infoTypesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInfoTypesIsMutable(); - infoTypes_.add(index, value); - onChanged(); - } else { - infoTypesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public Builder addInfoTypes( - com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder builderForValue) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.add(builderForValue.build()); - onChanged(); - } else { - infoTypesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public Builder addInfoTypes( - int index, com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder builderForValue) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.add(index, builderForValue.build()); - onChanged(); - } else { - infoTypesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public Builder addAllInfoTypes( - java.lang.Iterable values) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, infoTypes_); - onChanged(); - } else { - infoTypesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public Builder clearInfoTypes() { - if (infoTypesBuilder_ == null) { - infoTypes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - infoTypesBuilder_.clear(); - } - return this; - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public Builder removeInfoTypes(int index) { - if (infoTypesBuilder_ == null) { - ensureInfoTypesIsMutable(); - infoTypes_.remove(index); - onChanged(); - } else { - infoTypesBuilder_.remove(index); - } - return this; - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder getInfoTypesBuilder( - int index) { - return getInfoTypesFieldBuilder().getBuilder(index); - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeDescriptionOrBuilder getInfoTypesOrBuilder( - int index) { - if (infoTypesBuilder_ == null) { - return infoTypes_.get(index); } else { - return infoTypesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public java.util.List - getInfoTypesOrBuilderList() { - if (infoTypesBuilder_ != null) { - return infoTypesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(infoTypes_); - } - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder addInfoTypesBuilder() { - return getInfoTypesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.InfoTypeDescription.getDefaultInstance()); - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder addInfoTypesBuilder( - int index) { - return getInfoTypesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.InfoTypeDescription.getDefaultInstance()); - } - /** - *
-     * Set of sensitive info types belonging to a category.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - public java.util.List - getInfoTypesBuilderList() { - return getInfoTypesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeDescription, com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder, com.google.privacy.dlp.v2beta1.InfoTypeDescriptionOrBuilder> - getInfoTypesFieldBuilder() { - if (infoTypesBuilder_ == null) { - infoTypesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoTypeDescription, com.google.privacy.dlp.v2beta1.InfoTypeDescription.Builder, com.google.privacy.dlp.v2beta1.InfoTypeDescriptionOrBuilder>( - infoTypes_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - infoTypes_ = null; - } - return infoTypesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ListInfoTypesResponse) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ListInfoTypesResponse) - private static final com.google.privacy.dlp.v2beta1.ListInfoTypesResponse DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ListInfoTypesResponse(); - } - - public static com.google.privacy.dlp.v2beta1.ListInfoTypesResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ListInfoTypesResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListInfoTypesResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ListInfoTypesResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesResponseOrBuilder.java deleted file mode 100644 index 7fcd64103926..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInfoTypesResponseOrBuilder.java +++ /dev/null @@ -1,53 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ListInfoTypesResponseOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ListInfoTypesResponse) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Set of sensitive info types belonging to a category.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - java.util.List - getInfoTypesList(); - /** - *
-   * Set of sensitive info types belonging to a category.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeDescription getInfoTypes(int index); - /** - *
-   * Set of sensitive info types belonging to a category.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - int getInfoTypesCount(); - /** - *
-   * Set of sensitive info types belonging to a category.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - java.util.List - getInfoTypesOrBuilderList(); - /** - *
-   * Set of sensitive info types belonging to a category.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.InfoTypeDescription info_types = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeDescriptionOrBuilder getInfoTypesOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsRequest.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsRequest.java deleted file mode 100644 index 517e79d55e63..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsRequest.java +++ /dev/null @@ -1,1010 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Request for the list of results in a given inspect operation.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListInspectFindingsRequest} - */ -public final class ListInspectFindingsRequest extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ListInspectFindingsRequest) - ListInspectFindingsRequestOrBuilder { -private static final long serialVersionUID = 0L; - // Use ListInspectFindingsRequest.newBuilder() to construct. - private ListInspectFindingsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ListInspectFindingsRequest() { - name_ = ""; - pageSize_ = 0; - pageToken_ = ""; - filter_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ListInspectFindingsRequest( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 16: { - - pageSize_ = input.readInt32(); - break; - } - case 26: { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - case 34: { - java.lang.String s = input.readStringRequireUtf8(); - - filter_ = s; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest.class, com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - *
-   * Identifier of the results set returned as metadata of
-   * the longrunning operation created by a call to InspectDataSource.
-   * Should be in the format of `inspect/results/{id}`.
-   * 
- * - * string name = 1; - */ - 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; - } - } - /** - *
-   * Identifier of the results set returned as metadata of
-   * the longrunning operation created by a call to InspectDataSource.
-   * Should be in the format of `inspect/results/{id}`.
-   * 
- * - * string name = 1; - */ - 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 PAGE_SIZE_FIELD_NUMBER = 2; - private int pageSize_; - /** - *
-   * Maximum number of results to return.
-   * If 0, the implementation selects a reasonable value.
-   * 
- * - * int32 page_size = 2; - */ - public int getPageSize() { - return pageSize_; - } - - public static final int PAGE_TOKEN_FIELD_NUMBER = 3; - private volatile java.lang.Object pageToken_; - /** - *
-   * The value returned by the last `ListInspectFindingsResponse`; indicates
-   * that this is a continuation of a prior `ListInspectFindings` call, and that
-   * the system should return the next page of data.
-   * 
- * - * string page_token = 3; - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } - } - /** - *
-   * The value returned by the last `ListInspectFindingsResponse`; indicates
-   * that this is a continuation of a prior `ListInspectFindings` call, and that
-   * the system should return the next page of data.
-   * 
- * - * string page_token = 3; - */ - public com.google.protobuf.ByteString - getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int FILTER_FIELD_NUMBER = 4; - private volatile java.lang.Object filter_; - /** - *
-   * Restricts findings to items that match. Supports info_type and likelihood.
-   * Examples:
-   * - info_type=EMAIL_ADDRESS
-   * - info_type=PHONE_NUMBER,EMAIL_ADDRESS
-   * - likelihood=VERY_LIKELY
-   * - likelihood=VERY_LIKELY,LIKELY
-   * - info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY
-   * 
- * - * string filter = 4; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } - } - /** - *
-   * Restricts findings to items that match. Supports info_type and likelihood.
-   * Examples:
-   * - info_type=EMAIL_ADDRESS
-   * - info_type=PHONE_NUMBER,EMAIL_ADDRESS
-   * - likelihood=VERY_LIKELY
-   * - likelihood=VERY_LIKELY,LIKELY
-   * - info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY
-   * 
- * - * string filter = 4; - */ - public com.google.protobuf.ByteString - getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (pageSize_ != 0) { - output.writeInt32(2, pageSize_); - } - if (!getPageTokenBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); - } - if (!getFilterBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, filter_); - } - unknownFields.writeTo(output); - } - - 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 (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(2, pageSize_); - } - if (!getPageTokenBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); - } - if (!getFilterBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, filter_); - } - 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.privacy.dlp.v2beta1.ListInspectFindingsRequest)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest other = (com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest) obj; - - boolean result = true; - result = result && getName() - .equals(other.getName()); - result = result && (getPageSize() - == other.getPageSize()); - result = result && getPageToken() - .equals(other.getPageToken()); - result = result && getFilter() - .equals(other.getFilter()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @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) + PAGE_SIZE_FIELD_NUMBER; - hash = (53 * hash) + getPageSize(); - hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getPageToken().hashCode(); - hash = (37 * hash) + FILTER_FIELD_NUMBER; - hash = (53 * hash) + getFilter().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest 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.privacy.dlp.v2beta1.ListInspectFindingsRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest 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.privacy.dlp.v2beta1.ListInspectFindingsRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest 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.privacy.dlp.v2beta1.ListInspectFindingsRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Request for the list of results in a given inspect operation.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListInspectFindingsRequest} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ListInspectFindingsRequest) - com.google.privacy.dlp.v2beta1.ListInspectFindingsRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest.class, com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - name_ = ""; - - pageSize_ = 0; - - pageToken_ = ""; - - filter_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsRequest_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest build() { - com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest buildPartial() { - com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest result = new com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest(this); - result.name_ = name_; - result.pageSize_ = pageSize_; - result.pageToken_ = pageToken_; - result.filter_ = filter_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest other) { - if (other == com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (other.getPageSize() != 0) { - setPageSize(other.getPageSize()); - } - if (!other.getPageToken().isEmpty()) { - pageToken_ = other.pageToken_; - onChanged(); - } - if (!other.getFilter().isEmpty()) { - filter_ = other.filter_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - *
-     * Identifier of the results set returned as metadata of
-     * the longrunning operation created by a call to InspectDataSource.
-     * Should be in the format of `inspect/results/{id}`.
-     * 
- * - * string name = 1; - */ - 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; - } - } - /** - *
-     * Identifier of the results set returned as metadata of
-     * the longrunning operation created by a call to InspectDataSource.
-     * Should be in the format of `inspect/results/{id}`.
-     * 
- * - * string name = 1; - */ - 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; - } - } - /** - *
-     * Identifier of the results set returned as metadata of
-     * the longrunning operation created by a call to InspectDataSource.
-     * Should be in the format of `inspect/results/{id}`.
-     * 
- * - * string name = 1; - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - *
-     * Identifier of the results set returned as metadata of
-     * the longrunning operation created by a call to InspectDataSource.
-     * Should be in the format of `inspect/results/{id}`.
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - *
-     * Identifier of the results set returned as metadata of
-     * the longrunning operation created by a call to InspectDataSource.
-     * Should be in the format of `inspect/results/{id}`.
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private int pageSize_ ; - /** - *
-     * Maximum number of results to return.
-     * If 0, the implementation selects a reasonable value.
-     * 
- * - * int32 page_size = 2; - */ - public int getPageSize() { - return pageSize_; - } - /** - *
-     * Maximum number of results to return.
-     * If 0, the implementation selects a reasonable value.
-     * 
- * - * int32 page_size = 2; - */ - public Builder setPageSize(int value) { - - pageSize_ = value; - onChanged(); - return this; - } - /** - *
-     * Maximum number of results to return.
-     * If 0, the implementation selects a reasonable value.
-     * 
- * - * int32 page_size = 2; - */ - public Builder clearPageSize() { - - pageSize_ = 0; - onChanged(); - return this; - } - - private java.lang.Object pageToken_ = ""; - /** - *
-     * The value returned by the last `ListInspectFindingsResponse`; indicates
-     * that this is a continuation of a prior `ListInspectFindings` call, and that
-     * the system should return the next page of data.
-     * 
- * - * string page_token = 3; - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * The value returned by the last `ListInspectFindingsResponse`; indicates
-     * that this is a continuation of a prior `ListInspectFindings` call, and that
-     * the system should return the next page of data.
-     * 
- * - * string page_token = 3; - */ - public com.google.protobuf.ByteString - getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * The value returned by the last `ListInspectFindingsResponse`; indicates
-     * that this is a continuation of a prior `ListInspectFindings` call, and that
-     * the system should return the next page of data.
-     * 
- * - * string page_token = 3; - */ - public Builder setPageToken( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - pageToken_ = value; - onChanged(); - return this; - } - /** - *
-     * The value returned by the last `ListInspectFindingsResponse`; indicates
-     * that this is a continuation of a prior `ListInspectFindings` call, and that
-     * the system should return the next page of data.
-     * 
- * - * string page_token = 3; - */ - public Builder clearPageToken() { - - pageToken_ = getDefaultInstance().getPageToken(); - onChanged(); - return this; - } - /** - *
-     * The value returned by the last `ListInspectFindingsResponse`; indicates
-     * that this is a continuation of a prior `ListInspectFindings` call, and that
-     * the system should return the next page of data.
-     * 
- * - * string page_token = 3; - */ - public Builder setPageTokenBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - pageToken_ = value; - onChanged(); - return this; - } - - private java.lang.Object filter_ = ""; - /** - *
-     * Restricts findings to items that match. Supports info_type and likelihood.
-     * Examples:
-     * - info_type=EMAIL_ADDRESS
-     * - info_type=PHONE_NUMBER,EMAIL_ADDRESS
-     * - likelihood=VERY_LIKELY
-     * - likelihood=VERY_LIKELY,LIKELY
-     * - info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY
-     * 
- * - * string filter = 4; - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * Restricts findings to items that match. Supports info_type and likelihood.
-     * Examples:
-     * - info_type=EMAIL_ADDRESS
-     * - info_type=PHONE_NUMBER,EMAIL_ADDRESS
-     * - likelihood=VERY_LIKELY
-     * - likelihood=VERY_LIKELY,LIKELY
-     * - info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY
-     * 
- * - * string filter = 4; - */ - public com.google.protobuf.ByteString - getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * Restricts findings to items that match. Supports info_type and likelihood.
-     * Examples:
-     * - info_type=EMAIL_ADDRESS
-     * - info_type=PHONE_NUMBER,EMAIL_ADDRESS
-     * - likelihood=VERY_LIKELY
-     * - likelihood=VERY_LIKELY,LIKELY
-     * - info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY
-     * 
- * - * string filter = 4; - */ - public Builder setFilter( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - filter_ = value; - onChanged(); - return this; - } - /** - *
-     * Restricts findings to items that match. Supports info_type and likelihood.
-     * Examples:
-     * - info_type=EMAIL_ADDRESS
-     * - info_type=PHONE_NUMBER,EMAIL_ADDRESS
-     * - likelihood=VERY_LIKELY
-     * - likelihood=VERY_LIKELY,LIKELY
-     * - info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY
-     * 
- * - * string filter = 4; - */ - public Builder clearFilter() { - - filter_ = getDefaultInstance().getFilter(); - onChanged(); - return this; - } - /** - *
-     * Restricts findings to items that match. Supports info_type and likelihood.
-     * Examples:
-     * - info_type=EMAIL_ADDRESS
-     * - info_type=PHONE_NUMBER,EMAIL_ADDRESS
-     * - likelihood=VERY_LIKELY
-     * - likelihood=VERY_LIKELY,LIKELY
-     * - info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY
-     * 
- * - * string filter = 4; - */ - public Builder setFilterBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - filter_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ListInspectFindingsRequest) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ListInspectFindingsRequest) - private static final com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest(); - } - - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ListInspectFindingsRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListInspectFindingsRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsRequestOrBuilder.java deleted file mode 100644 index 767c22e0217b..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsRequestOrBuilder.java +++ /dev/null @@ -1,93 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ListInspectFindingsRequestOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ListInspectFindingsRequest) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Identifier of the results set returned as metadata of
-   * the longrunning operation created by a call to InspectDataSource.
-   * Should be in the format of `inspect/results/{id}`.
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - *
-   * Identifier of the results set returned as metadata of
-   * the longrunning operation created by a call to InspectDataSource.
-   * Should be in the format of `inspect/results/{id}`.
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString - getNameBytes(); - - /** - *
-   * Maximum number of results to return.
-   * If 0, the implementation selects a reasonable value.
-   * 
- * - * int32 page_size = 2; - */ - int getPageSize(); - - /** - *
-   * The value returned by the last `ListInspectFindingsResponse`; indicates
-   * that this is a continuation of a prior `ListInspectFindings` call, and that
-   * the system should return the next page of data.
-   * 
- * - * string page_token = 3; - */ - java.lang.String getPageToken(); - /** - *
-   * The value returned by the last `ListInspectFindingsResponse`; indicates
-   * that this is a continuation of a prior `ListInspectFindings` call, and that
-   * the system should return the next page of data.
-   * 
- * - * string page_token = 3; - */ - com.google.protobuf.ByteString - getPageTokenBytes(); - - /** - *
-   * Restricts findings to items that match. Supports info_type and likelihood.
-   * Examples:
-   * - info_type=EMAIL_ADDRESS
-   * - info_type=PHONE_NUMBER,EMAIL_ADDRESS
-   * - likelihood=VERY_LIKELY
-   * - likelihood=VERY_LIKELY,LIKELY
-   * - info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY
-   * 
- * - * string filter = 4; - */ - java.lang.String getFilter(); - /** - *
-   * Restricts findings to items that match. Supports info_type and likelihood.
-   * Examples:
-   * - info_type=EMAIL_ADDRESS
-   * - info_type=PHONE_NUMBER,EMAIL_ADDRESS
-   * - likelihood=VERY_LIKELY
-   * - likelihood=VERY_LIKELY,LIKELY
-   * - info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY
-   * 
- * - * string filter = 4; - */ - com.google.protobuf.ByteString - getFilterBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsResponse.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsResponse.java deleted file mode 100644 index 32d8db523ebc..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsResponse.java +++ /dev/null @@ -1,788 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Response to the ListInspectFindings request.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListInspectFindingsResponse} - */ -public final class ListInspectFindingsResponse extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ListInspectFindingsResponse) - ListInspectFindingsResponseOrBuilder { -private static final long serialVersionUID = 0L; - // Use ListInspectFindingsResponse.newBuilder() to construct. - private ListInspectFindingsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ListInspectFindingsResponse() { - nextPageToken_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ListInspectFindingsResponse( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InspectResult.Builder subBuilder = null; - if (result_ != null) { - subBuilder = result_.toBuilder(); - } - result_ = input.readMessage(com.google.privacy.dlp.v2beta1.InspectResult.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(result_); - result_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse.class, com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse.Builder.class); - } - - public static final int RESULT_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.InspectResult result_; - /** - *
-   * The results.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public boolean hasResult() { - return result_ != null; - } - /** - *
-   * The results.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResult getResult() { - return result_ == null ? com.google.privacy.dlp.v2beta1.InspectResult.getDefaultInstance() : result_; - } - /** - *
-   * The results.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResultOrBuilder getResultOrBuilder() { - return getResult(); - } - - public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; - private volatile java.lang.Object nextPageToken_; - /** - *
-   * If not empty, indicates that there may be more results that match the
-   * request; this value should be passed in a new `ListInspectFindingsRequest`.
-   * 
- * - * string next_page_token = 2; - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } - } - /** - *
-   * If not empty, indicates that there may be more results that match the
-   * request; this value should be passed in a new `ListInspectFindingsRequest`.
-   * 
- * - * string next_page_token = 2; - */ - public com.google.protobuf.ByteString - getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (result_ != null) { - output.writeMessage(1, getResult()); - } - if (!getNextPageTokenBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (result_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getResult()); - } - if (!getNextPageTokenBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); - } - 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.privacy.dlp.v2beta1.ListInspectFindingsResponse)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse other = (com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse) obj; - - boolean result = true; - result = result && (hasResult() == other.hasResult()); - if (hasResult()) { - result = result && getResult() - .equals(other.getResult()); - } - result = result && getNextPageToken() - .equals(other.getNextPageToken()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasResult()) { - hash = (37 * hash) + RESULT_FIELD_NUMBER; - hash = (53 * hash) + getResult().hashCode(); - } - hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse 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.privacy.dlp.v2beta1.ListInspectFindingsResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse 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.privacy.dlp.v2beta1.ListInspectFindingsResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse 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.privacy.dlp.v2beta1.ListInspectFindingsResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Response to the ListInspectFindings request.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListInspectFindingsResponse} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ListInspectFindingsResponse) - com.google.privacy.dlp.v2beta1.ListInspectFindingsResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse.class, com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (resultBuilder_ == null) { - result_ = null; - } else { - result_ = null; - resultBuilder_ = null; - } - nextPageToken_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListInspectFindingsResponse_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse build() { - com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse buildPartial() { - com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse result = new com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse(this); - if (resultBuilder_ == null) { - result.result_ = result_; - } else { - result.result_ = resultBuilder_.build(); - } - result.nextPageToken_ = nextPageToken_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse other) { - if (other == com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse.getDefaultInstance()) return this; - if (other.hasResult()) { - mergeResult(other.getResult()); - } - if (!other.getNextPageToken().isEmpty()) { - nextPageToken_ = other.nextPageToken_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.InspectResult result_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectResult, com.google.privacy.dlp.v2beta1.InspectResult.Builder, com.google.privacy.dlp.v2beta1.InspectResultOrBuilder> resultBuilder_; - /** - *
-     * The results.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public boolean hasResult() { - return resultBuilder_ != null || result_ != null; - } - /** - *
-     * The results.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResult getResult() { - if (resultBuilder_ == null) { - return result_ == null ? com.google.privacy.dlp.v2beta1.InspectResult.getDefaultInstance() : result_; - } else { - return resultBuilder_.getMessage(); - } - } - /** - *
-     * The results.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public Builder setResult(com.google.privacy.dlp.v2beta1.InspectResult value) { - if (resultBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - result_ = value; - onChanged(); - } else { - resultBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The results.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public Builder setResult( - com.google.privacy.dlp.v2beta1.InspectResult.Builder builderForValue) { - if (resultBuilder_ == null) { - result_ = builderForValue.build(); - onChanged(); - } else { - resultBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The results.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public Builder mergeResult(com.google.privacy.dlp.v2beta1.InspectResult value) { - if (resultBuilder_ == null) { - if (result_ != null) { - result_ = - com.google.privacy.dlp.v2beta1.InspectResult.newBuilder(result_).mergeFrom(value).buildPartial(); - } else { - result_ = value; - } - onChanged(); - } else { - resultBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The results.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public Builder clearResult() { - if (resultBuilder_ == null) { - result_ = null; - onChanged(); - } else { - result_ = null; - resultBuilder_ = null; - } - - return this; - } - /** - *
-     * The results.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResult.Builder getResultBuilder() { - - onChanged(); - return getResultFieldBuilder().getBuilder(); - } - /** - *
-     * The results.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectResultOrBuilder getResultOrBuilder() { - if (resultBuilder_ != null) { - return resultBuilder_.getMessageOrBuilder(); - } else { - return result_ == null ? - com.google.privacy.dlp.v2beta1.InspectResult.getDefaultInstance() : result_; - } - } - /** - *
-     * The results.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectResult, com.google.privacy.dlp.v2beta1.InspectResult.Builder, com.google.privacy.dlp.v2beta1.InspectResultOrBuilder> - getResultFieldBuilder() { - if (resultBuilder_ == null) { - resultBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectResult, com.google.privacy.dlp.v2beta1.InspectResult.Builder, com.google.privacy.dlp.v2beta1.InspectResultOrBuilder>( - getResult(), - getParentForChildren(), - isClean()); - result_ = null; - } - return resultBuilder_; - } - - private java.lang.Object nextPageToken_ = ""; - /** - *
-     * If not empty, indicates that there may be more results that match the
-     * request; this value should be passed in a new `ListInspectFindingsRequest`.
-     * 
- * - * string next_page_token = 2; - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * If not empty, indicates that there may be more results that match the
-     * request; this value should be passed in a new `ListInspectFindingsRequest`.
-     * 
- * - * string next_page_token = 2; - */ - public com.google.protobuf.ByteString - getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * If not empty, indicates that there may be more results that match the
-     * request; this value should be passed in a new `ListInspectFindingsRequest`.
-     * 
- * - * string next_page_token = 2; - */ - public Builder setNextPageToken( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - nextPageToken_ = value; - onChanged(); - return this; - } - /** - *
-     * If not empty, indicates that there may be more results that match the
-     * request; this value should be passed in a new `ListInspectFindingsRequest`.
-     * 
- * - * string next_page_token = 2; - */ - public Builder clearNextPageToken() { - - nextPageToken_ = getDefaultInstance().getNextPageToken(); - onChanged(); - return this; - } - /** - *
-     * If not empty, indicates that there may be more results that match the
-     * request; this value should be passed in a new `ListInspectFindingsRequest`.
-     * 
- * - * string next_page_token = 2; - */ - public Builder setNextPageTokenBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - nextPageToken_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ListInspectFindingsResponse) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ListInspectFindingsResponse) - private static final com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse(); - } - - public static com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ListInspectFindingsResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListInspectFindingsResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsResponseOrBuilder.java deleted file mode 100644 index 08ceb72e0ab3..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListInspectFindingsResponseOrBuilder.java +++ /dev/null @@ -1,54 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ListInspectFindingsResponseOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ListInspectFindingsResponse) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The results.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - boolean hasResult(); - /** - *
-   * The results.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - com.google.privacy.dlp.v2beta1.InspectResult getResult(); - /** - *
-   * The results.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectResult result = 1; - */ - com.google.privacy.dlp.v2beta1.InspectResultOrBuilder getResultOrBuilder(); - - /** - *
-   * If not empty, indicates that there may be more results that match the
-   * request; this value should be passed in a new `ListInspectFindingsRequest`.
-   * 
- * - * string next_page_token = 2; - */ - java.lang.String getNextPageToken(); - /** - *
-   * If not empty, indicates that there may be more results that match the
-   * request; this value should be passed in a new `ListInspectFindingsRequest`.
-   * 
- * - * string next_page_token = 2; - */ - com.google.protobuf.ByteString - getNextPageTokenBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesRequest.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesRequest.java deleted file mode 100644 index 6c4312b5d050..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesRequest.java +++ /dev/null @@ -1,568 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Request for root categories of Info Types supported by the API.
- * Example values might include "FINANCE", "HEALTH", "FAST", "DEFAULT".
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListRootCategoriesRequest} - */ -public final class ListRootCategoriesRequest extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ListRootCategoriesRequest) - ListRootCategoriesRequestOrBuilder { -private static final long serialVersionUID = 0L; - // Use ListRootCategoriesRequest.newBuilder() to construct. - private ListRootCategoriesRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ListRootCategoriesRequest() { - languageCode_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ListRootCategoriesRequest( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - languageCode_ = s; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest.class, com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest.Builder.class); - } - - public static final int LANGUAGE_CODE_FIELD_NUMBER = 1; - private volatile java.lang.Object languageCode_; - /** - *
-   * Optional language code for localized friendly category names.
-   * If omitted or if localized strings are not available,
-   * en-US strings will be returned.
-   * 
- * - * string language_code = 1; - */ - 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; - } - } - /** - *
-   * Optional language code for localized friendly category names.
-   * If omitted or if localized strings are not available,
-   * en-US strings will be returned.
-   * 
- * - * string language_code = 1; - */ - 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; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getLanguageCodeBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, languageCode_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getLanguageCodeBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, 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.privacy.dlp.v2beta1.ListRootCategoriesRequest)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest other = (com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest) obj; - - boolean result = true; - result = result && getLanguageCode() - .equals(other.getLanguageCode()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().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.privacy.dlp.v2beta1.ListRootCategoriesRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest 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.privacy.dlp.v2beta1.ListRootCategoriesRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest 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.privacy.dlp.v2beta1.ListRootCategoriesRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest 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.privacy.dlp.v2beta1.ListRootCategoriesRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Request for root categories of Info Types supported by the API.
-   * Example values might include "FINANCE", "HEALTH", "FAST", "DEFAULT".
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListRootCategoriesRequest} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ListRootCategoriesRequest) - com.google.privacy.dlp.v2beta1.ListRootCategoriesRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest.class, com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - languageCode_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesRequest_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest build() { - com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest buildPartial() { - com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest result = new com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest(this); - result.languageCode_ = languageCode_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest other) { - if (other == com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest.getDefaultInstance()) return this; - if (!other.getLanguageCode().isEmpty()) { - languageCode_ = other.languageCode_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object languageCode_ = ""; - /** - *
-     * Optional language code for localized friendly category names.
-     * If omitted or if localized strings are not available,
-     * en-US strings will be returned.
-     * 
- * - * string language_code = 1; - */ - 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; - } - } - /** - *
-     * Optional language code for localized friendly category names.
-     * If omitted or if localized strings are not available,
-     * en-US strings will be returned.
-     * 
- * - * string language_code = 1; - */ - 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; - } - } - /** - *
-     * Optional language code for localized friendly category names.
-     * If omitted or if localized strings are not available,
-     * en-US strings will be returned.
-     * 
- * - * string language_code = 1; - */ - public Builder setLanguageCode( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - languageCode_ = value; - onChanged(); - return this; - } - /** - *
-     * Optional language code for localized friendly category names.
-     * If omitted or if localized strings are not available,
-     * en-US strings will be returned.
-     * 
- * - * string language_code = 1; - */ - public Builder clearLanguageCode() { - - languageCode_ = getDefaultInstance().getLanguageCode(); - onChanged(); - return this; - } - /** - *
-     * Optional language code for localized friendly category names.
-     * If omitted or if localized strings are not available,
-     * en-US strings will be returned.
-     * 
- * - * string language_code = 1; - */ - public Builder setLanguageCodeBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - languageCode_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ListRootCategoriesRequest) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ListRootCategoriesRequest) - private static final com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest(); - } - - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ListRootCategoriesRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListRootCategoriesRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesRequestOrBuilder.java deleted file mode 100644 index 48cc9a55d213..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesRequestOrBuilder.java +++ /dev/null @@ -1,31 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ListRootCategoriesRequestOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ListRootCategoriesRequest) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Optional language code for localized friendly category names.
-   * If omitted or if localized strings are not available,
-   * en-US strings will be returned.
-   * 
- * - * string language_code = 1; - */ - java.lang.String getLanguageCode(); - /** - *
-   * Optional language code for localized friendly category names.
-   * If omitted or if localized strings are not available,
-   * en-US strings will be returned.
-   * 
- * - * string language_code = 1; - */ - com.google.protobuf.ByteString - getLanguageCodeBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesResponse.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesResponse.java deleted file mode 100644 index 427d6e466b9a..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesResponse.java +++ /dev/null @@ -1,834 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Response for ListRootCategories request.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListRootCategoriesResponse} - */ -public final class ListRootCategoriesResponse extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ListRootCategoriesResponse) - ListRootCategoriesResponseOrBuilder { -private static final long serialVersionUID = 0L; - // Use ListRootCategoriesResponse.newBuilder() to construct. - private ListRootCategoriesResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ListRootCategoriesResponse() { - categories_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ListRootCategoriesResponse( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - categories_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - categories_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.CategoryDescription.parser(), extensionRegistry)); - 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) == 0x00000001)) { - categories_ = java.util.Collections.unmodifiableList(categories_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse.class, com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse.Builder.class); - } - - public static final int CATEGORIES_FIELD_NUMBER = 1; - private java.util.List categories_; - /** - *
-   * List of all into type categories supported by the API.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public java.util.List getCategoriesList() { - return categories_; - } - /** - *
-   * List of all into type categories supported by the API.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public java.util.List - getCategoriesOrBuilderList() { - return categories_; - } - /** - *
-   * List of all into type categories supported by the API.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public int getCategoriesCount() { - return categories_.size(); - } - /** - *
-   * List of all into type categories supported by the API.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescription getCategories(int index) { - return categories_.get(index); - } - /** - *
-   * List of all into type categories supported by the API.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder getCategoriesOrBuilder( - int index) { - return categories_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < categories_.size(); i++) { - output.writeMessage(1, categories_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < categories_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, categories_.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.privacy.dlp.v2beta1.ListRootCategoriesResponse)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse other = (com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse) obj; - - boolean result = true; - result = result && getCategoriesList() - .equals(other.getCategoriesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getCategoriesCount() > 0) { - hash = (37 * hash) + CATEGORIES_FIELD_NUMBER; - hash = (53 * hash) + getCategoriesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse 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.privacy.dlp.v2beta1.ListRootCategoriesResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse 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.privacy.dlp.v2beta1.ListRootCategoriesResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse 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.privacy.dlp.v2beta1.ListRootCategoriesResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Response for ListRootCategories request.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ListRootCategoriesResponse} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ListRootCategoriesResponse) - com.google.privacy.dlp.v2beta1.ListRootCategoriesResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse.class, com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getCategoriesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (categoriesBuilder_ == null) { - categories_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - categoriesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ListRootCategoriesResponse_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse build() { - com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse buildPartial() { - com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse result = new com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse(this); - int from_bitField0_ = bitField0_; - if (categoriesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - categories_ = java.util.Collections.unmodifiableList(categories_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.categories_ = categories_; - } else { - result.categories_ = categoriesBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse other) { - if (other == com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse.getDefaultInstance()) return this; - if (categoriesBuilder_ == null) { - if (!other.categories_.isEmpty()) { - if (categories_.isEmpty()) { - categories_ = other.categories_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureCategoriesIsMutable(); - categories_.addAll(other.categories_); - } - onChanged(); - } - } else { - if (!other.categories_.isEmpty()) { - if (categoriesBuilder_.isEmpty()) { - categoriesBuilder_.dispose(); - categoriesBuilder_ = null; - categories_ = other.categories_; - bitField0_ = (bitField0_ & ~0x00000001); - categoriesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getCategoriesFieldBuilder() : null; - } else { - categoriesBuilder_.addAllMessages(other.categories_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List categories_ = - java.util.Collections.emptyList(); - private void ensureCategoriesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - categories_ = new java.util.ArrayList(categories_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CategoryDescription, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder, com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder> categoriesBuilder_; - - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public java.util.List getCategoriesList() { - if (categoriesBuilder_ == null) { - return java.util.Collections.unmodifiableList(categories_); - } else { - return categoriesBuilder_.getMessageList(); - } - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public int getCategoriesCount() { - if (categoriesBuilder_ == null) { - return categories_.size(); - } else { - return categoriesBuilder_.getCount(); - } - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescription getCategories(int index) { - if (categoriesBuilder_ == null) { - return categories_.get(index); - } else { - return categoriesBuilder_.getMessage(index); - } - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public Builder setCategories( - int index, com.google.privacy.dlp.v2beta1.CategoryDescription value) { - if (categoriesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCategoriesIsMutable(); - categories_.set(index, value); - onChanged(); - } else { - categoriesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public Builder setCategories( - int index, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder builderForValue) { - if (categoriesBuilder_ == null) { - ensureCategoriesIsMutable(); - categories_.set(index, builderForValue.build()); - onChanged(); - } else { - categoriesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public Builder addCategories(com.google.privacy.dlp.v2beta1.CategoryDescription value) { - if (categoriesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCategoriesIsMutable(); - categories_.add(value); - onChanged(); - } else { - categoriesBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public Builder addCategories( - int index, com.google.privacy.dlp.v2beta1.CategoryDescription value) { - if (categoriesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureCategoriesIsMutable(); - categories_.add(index, value); - onChanged(); - } else { - categoriesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public Builder addCategories( - com.google.privacy.dlp.v2beta1.CategoryDescription.Builder builderForValue) { - if (categoriesBuilder_ == null) { - ensureCategoriesIsMutable(); - categories_.add(builderForValue.build()); - onChanged(); - } else { - categoriesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public Builder addCategories( - int index, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder builderForValue) { - if (categoriesBuilder_ == null) { - ensureCategoriesIsMutable(); - categories_.add(index, builderForValue.build()); - onChanged(); - } else { - categoriesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public Builder addAllCategories( - java.lang.Iterable values) { - if (categoriesBuilder_ == null) { - ensureCategoriesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, categories_); - onChanged(); - } else { - categoriesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public Builder clearCategories() { - if (categoriesBuilder_ == null) { - categories_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - categoriesBuilder_.clear(); - } - return this; - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public Builder removeCategories(int index) { - if (categoriesBuilder_ == null) { - ensureCategoriesIsMutable(); - categories_.remove(index); - onChanged(); - } else { - categoriesBuilder_.remove(index); - } - return this; - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescription.Builder getCategoriesBuilder( - int index) { - return getCategoriesFieldBuilder().getBuilder(index); - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder getCategoriesOrBuilder( - int index) { - if (categoriesBuilder_ == null) { - return categories_.get(index); } else { - return categoriesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public java.util.List - getCategoriesOrBuilderList() { - if (categoriesBuilder_ != null) { - return categoriesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(categories_); - } - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescription.Builder addCategoriesBuilder() { - return getCategoriesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.CategoryDescription.getDefaultInstance()); - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public com.google.privacy.dlp.v2beta1.CategoryDescription.Builder addCategoriesBuilder( - int index) { - return getCategoriesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.CategoryDescription.getDefaultInstance()); - } - /** - *
-     * List of all into type categories supported by the API.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - public java.util.List - getCategoriesBuilderList() { - return getCategoriesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CategoryDescription, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder, com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder> - getCategoriesFieldBuilder() { - if (categoriesBuilder_ == null) { - categoriesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CategoryDescription, com.google.privacy.dlp.v2beta1.CategoryDescription.Builder, com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder>( - categories_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - categories_ = null; - } - return categoriesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ListRootCategoriesResponse) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ListRootCategoriesResponse) - private static final com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse(); - } - - public static com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ListRootCategoriesResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ListRootCategoriesResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesResponseOrBuilder.java deleted file mode 100644 index cc999ecc76f5..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ListRootCategoriesResponseOrBuilder.java +++ /dev/null @@ -1,53 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ListRootCategoriesResponseOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ListRootCategoriesResponse) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * List of all into type categories supported by the API.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - java.util.List - getCategoriesList(); - /** - *
-   * List of all into type categories supported by the API.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - com.google.privacy.dlp.v2beta1.CategoryDescription getCategories(int index); - /** - *
-   * List of all into type categories supported by the API.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - int getCategoriesCount(); - /** - *
-   * List of all into type categories supported by the API.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - java.util.List - getCategoriesOrBuilderList(); - /** - *
-   * List of all into type categories supported by the API.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.CategoryDescription categories = 1; - */ - com.google.privacy.dlp.v2beta1.CategoryDescriptionOrBuilder getCategoriesOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Location.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Location.java deleted file mode 100644 index c8df71e34017..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Location.java +++ /dev/null @@ -1,1994 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Specifies the location of a finding within its source item.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Location} - */ -public final class Location extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.Location) - LocationOrBuilder { -private static final long serialVersionUID = 0L; - // Use Location.newBuilder() to construct. - private Location(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Location() { - imageBoxes_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Location( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.Range.Builder subBuilder = null; - if (byteRange_ != null) { - subBuilder = byteRange_.toBuilder(); - } - byteRange_ = input.readMessage(com.google.privacy.dlp.v2beta1.Range.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(byteRange_); - byteRange_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.Range.Builder subBuilder = null; - if (codepointRange_ != null) { - subBuilder = codepointRange_.toBuilder(); - } - codepointRange_ = input.readMessage(com.google.privacy.dlp.v2beta1.Range.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(codepointRange_); - codepointRange_ = subBuilder.buildPartial(); - } - - break; - } - case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { - imageBoxes_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000004; - } - imageBoxes_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.ImageLocation.parser(), extensionRegistry)); - break; - } - case 34: { - com.google.privacy.dlp.v2beta1.RecordKey.Builder subBuilder = null; - if (recordKey_ != null) { - subBuilder = recordKey_.toBuilder(); - } - recordKey_ = input.readMessage(com.google.privacy.dlp.v2beta1.RecordKey.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(recordKey_); - recordKey_ = subBuilder.buildPartial(); - } - - break; - } - case 42: { - com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null; - if (fieldId_ != null) { - subBuilder = fieldId_.toBuilder(); - } - fieldId_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(fieldId_); - fieldId_ = subBuilder.buildPartial(); - } - - break; - } - case 50: { - com.google.privacy.dlp.v2beta1.TableLocation.Builder subBuilder = null; - if (tableLocation_ != null) { - subBuilder = tableLocation_.toBuilder(); - } - tableLocation_ = input.readMessage(com.google.privacy.dlp.v2beta1.TableLocation.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(tableLocation_); - tableLocation_ = subBuilder.buildPartial(); - } - - 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_ & 0x00000004) == 0x00000004)) { - imageBoxes_ = java.util.Collections.unmodifiableList(imageBoxes_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Location_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Location_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Location.class, com.google.privacy.dlp.v2beta1.Location.Builder.class); - } - - private int bitField0_; - public static final int BYTE_RANGE_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.Range byteRange_; - /** - *
-   * Zero-based byte offsets within a content item.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public boolean hasByteRange() { - return byteRange_ != null; - } - /** - *
-   * Zero-based byte offsets within a content item.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public com.google.privacy.dlp.v2beta1.Range getByteRange() { - return byteRange_ == null ? com.google.privacy.dlp.v2beta1.Range.getDefaultInstance() : byteRange_; - } - /** - *
-   * Zero-based byte offsets within a content item.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public com.google.privacy.dlp.v2beta1.RangeOrBuilder getByteRangeOrBuilder() { - return getByteRange(); - } - - public static final int CODEPOINT_RANGE_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.Range codepointRange_; - /** - *
-   * Character offsets within a content item, included when content type
-   * is a text. Default charset assumed to be UTF-8.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public boolean hasCodepointRange() { - return codepointRange_ != null; - } - /** - *
-   * Character offsets within a content item, included when content type
-   * is a text. Default charset assumed to be UTF-8.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public com.google.privacy.dlp.v2beta1.Range getCodepointRange() { - return codepointRange_ == null ? com.google.privacy.dlp.v2beta1.Range.getDefaultInstance() : codepointRange_; - } - /** - *
-   * Character offsets within a content item, included when content type
-   * is a text. Default charset assumed to be UTF-8.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public com.google.privacy.dlp.v2beta1.RangeOrBuilder getCodepointRangeOrBuilder() { - return getCodepointRange(); - } - - public static final int IMAGE_BOXES_FIELD_NUMBER = 3; - private java.util.List imageBoxes_; - /** - *
-   * Location within an image's pixels.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public java.util.List getImageBoxesList() { - return imageBoxes_; - } - /** - *
-   * Location within an image's pixels.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public java.util.List - getImageBoxesOrBuilderList() { - return imageBoxes_; - } - /** - *
-   * Location within an image's pixels.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public int getImageBoxesCount() { - return imageBoxes_.size(); - } - /** - *
-   * Location within an image's pixels.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public com.google.privacy.dlp.v2beta1.ImageLocation getImageBoxes(int index) { - return imageBoxes_.get(index); - } - /** - *
-   * Location within an image's pixels.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public com.google.privacy.dlp.v2beta1.ImageLocationOrBuilder getImageBoxesOrBuilder( - int index) { - return imageBoxes_.get(index); - } - - public static final int RECORD_KEY_FIELD_NUMBER = 4; - private com.google.privacy.dlp.v2beta1.RecordKey recordKey_; - /** - *
-   * Key of the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public boolean hasRecordKey() { - return recordKey_ != null; - } - /** - *
-   * Key of the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public com.google.privacy.dlp.v2beta1.RecordKey getRecordKey() { - return recordKey_ == null ? com.google.privacy.dlp.v2beta1.RecordKey.getDefaultInstance() : recordKey_; - } - /** - *
-   * Key of the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public com.google.privacy.dlp.v2beta1.RecordKeyOrBuilder getRecordKeyOrBuilder() { - return getRecordKey(); - } - - public static final int FIELD_ID_FIELD_NUMBER = 5; - private com.google.privacy.dlp.v2beta1.FieldId fieldId_; - /** - *
-   * Field id of the field containing the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public boolean hasFieldId() { - return fieldId_ != null; - } - /** - *
-   * Field id of the field containing the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldId getFieldId() { - return fieldId_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : fieldId_; - } - /** - *
-   * Field id of the field containing the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldIdOrBuilder() { - return getFieldId(); - } - - public static final int TABLE_LOCATION_FIELD_NUMBER = 6; - private com.google.privacy.dlp.v2beta1.TableLocation tableLocation_; - /** - *
-   * Location within a `ContentItem.Table`.
-   * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public boolean hasTableLocation() { - return tableLocation_ != null; - } - /** - *
-   * Location within a `ContentItem.Table`.
-   * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public com.google.privacy.dlp.v2beta1.TableLocation getTableLocation() { - return tableLocation_ == null ? com.google.privacy.dlp.v2beta1.TableLocation.getDefaultInstance() : tableLocation_; - } - /** - *
-   * Location within a `ContentItem.Table`.
-   * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public com.google.privacy.dlp.v2beta1.TableLocationOrBuilder getTableLocationOrBuilder() { - return getTableLocation(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (byteRange_ != null) { - output.writeMessage(1, getByteRange()); - } - if (codepointRange_ != null) { - output.writeMessage(2, getCodepointRange()); - } - for (int i = 0; i < imageBoxes_.size(); i++) { - output.writeMessage(3, imageBoxes_.get(i)); - } - if (recordKey_ != null) { - output.writeMessage(4, getRecordKey()); - } - if (fieldId_ != null) { - output.writeMessage(5, getFieldId()); - } - if (tableLocation_ != null) { - output.writeMessage(6, getTableLocation()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (byteRange_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getByteRange()); - } - if (codepointRange_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getCodepointRange()); - } - for (int i = 0; i < imageBoxes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, imageBoxes_.get(i)); - } - if (recordKey_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, getRecordKey()); - } - if (fieldId_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, getFieldId()); - } - if (tableLocation_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, getTableLocation()); - } - 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.privacy.dlp.v2beta1.Location)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.Location other = (com.google.privacy.dlp.v2beta1.Location) obj; - - boolean result = true; - result = result && (hasByteRange() == other.hasByteRange()); - if (hasByteRange()) { - result = result && getByteRange() - .equals(other.getByteRange()); - } - result = result && (hasCodepointRange() == other.hasCodepointRange()); - if (hasCodepointRange()) { - result = result && getCodepointRange() - .equals(other.getCodepointRange()); - } - result = result && getImageBoxesList() - .equals(other.getImageBoxesList()); - result = result && (hasRecordKey() == other.hasRecordKey()); - if (hasRecordKey()) { - result = result && getRecordKey() - .equals(other.getRecordKey()); - } - result = result && (hasFieldId() == other.hasFieldId()); - if (hasFieldId()) { - result = result && getFieldId() - .equals(other.getFieldId()); - } - result = result && (hasTableLocation() == other.hasTableLocation()); - if (hasTableLocation()) { - result = result && getTableLocation() - .equals(other.getTableLocation()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasByteRange()) { - hash = (37 * hash) + BYTE_RANGE_FIELD_NUMBER; - hash = (53 * hash) + getByteRange().hashCode(); - } - if (hasCodepointRange()) { - hash = (37 * hash) + CODEPOINT_RANGE_FIELD_NUMBER; - hash = (53 * hash) + getCodepointRange().hashCode(); - } - if (getImageBoxesCount() > 0) { - hash = (37 * hash) + IMAGE_BOXES_FIELD_NUMBER; - hash = (53 * hash) + getImageBoxesList().hashCode(); - } - if (hasRecordKey()) { - hash = (37 * hash) + RECORD_KEY_FIELD_NUMBER; - hash = (53 * hash) + getRecordKey().hashCode(); - } - if (hasFieldId()) { - hash = (37 * hash) + FIELD_ID_FIELD_NUMBER; - hash = (53 * hash) + getFieldId().hashCode(); - } - if (hasTableLocation()) { - hash = (37 * hash) + TABLE_LOCATION_FIELD_NUMBER; - hash = (53 * hash) + getTableLocation().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.Location parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Location parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Location parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Location 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.privacy.dlp.v2beta1.Location parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Location parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Location parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Location 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.privacy.dlp.v2beta1.Location parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Location 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.privacy.dlp.v2beta1.Location parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Location parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.Location prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Specifies the location of a finding within its source item.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Location} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.Location) - com.google.privacy.dlp.v2beta1.LocationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Location_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Location_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Location.class, com.google.privacy.dlp.v2beta1.Location.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.Location.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getImageBoxesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (byteRangeBuilder_ == null) { - byteRange_ = null; - } else { - byteRange_ = null; - byteRangeBuilder_ = null; - } - if (codepointRangeBuilder_ == null) { - codepointRange_ = null; - } else { - codepointRange_ = null; - codepointRangeBuilder_ = null; - } - if (imageBoxesBuilder_ == null) { - imageBoxes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - } else { - imageBoxesBuilder_.clear(); - } - if (recordKeyBuilder_ == null) { - recordKey_ = null; - } else { - recordKey_ = null; - recordKeyBuilder_ = null; - } - if (fieldIdBuilder_ == null) { - fieldId_ = null; - } else { - fieldId_ = null; - fieldIdBuilder_ = null; - } - if (tableLocationBuilder_ == null) { - tableLocation_ = null; - } else { - tableLocation_ = null; - tableLocationBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Location_descriptor; - } - - public com.google.privacy.dlp.v2beta1.Location getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.Location.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.Location build() { - com.google.privacy.dlp.v2beta1.Location result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.Location buildPartial() { - com.google.privacy.dlp.v2beta1.Location result = new com.google.privacy.dlp.v2beta1.Location(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (byteRangeBuilder_ == null) { - result.byteRange_ = byteRange_; - } else { - result.byteRange_ = byteRangeBuilder_.build(); - } - if (codepointRangeBuilder_ == null) { - result.codepointRange_ = codepointRange_; - } else { - result.codepointRange_ = codepointRangeBuilder_.build(); - } - if (imageBoxesBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { - imageBoxes_ = java.util.Collections.unmodifiableList(imageBoxes_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.imageBoxes_ = imageBoxes_; - } else { - result.imageBoxes_ = imageBoxesBuilder_.build(); - } - if (recordKeyBuilder_ == null) { - result.recordKey_ = recordKey_; - } else { - result.recordKey_ = recordKeyBuilder_.build(); - } - if (fieldIdBuilder_ == null) { - result.fieldId_ = fieldId_; - } else { - result.fieldId_ = fieldIdBuilder_.build(); - } - if (tableLocationBuilder_ == null) { - result.tableLocation_ = tableLocation_; - } else { - result.tableLocation_ = tableLocationBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.Location) { - return mergeFrom((com.google.privacy.dlp.v2beta1.Location)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.Location other) { - if (other == com.google.privacy.dlp.v2beta1.Location.getDefaultInstance()) return this; - if (other.hasByteRange()) { - mergeByteRange(other.getByteRange()); - } - if (other.hasCodepointRange()) { - mergeCodepointRange(other.getCodepointRange()); - } - if (imageBoxesBuilder_ == null) { - if (!other.imageBoxes_.isEmpty()) { - if (imageBoxes_.isEmpty()) { - imageBoxes_ = other.imageBoxes_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureImageBoxesIsMutable(); - imageBoxes_.addAll(other.imageBoxes_); - } - onChanged(); - } - } else { - if (!other.imageBoxes_.isEmpty()) { - if (imageBoxesBuilder_.isEmpty()) { - imageBoxesBuilder_.dispose(); - imageBoxesBuilder_ = null; - imageBoxes_ = other.imageBoxes_; - bitField0_ = (bitField0_ & ~0x00000004); - imageBoxesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getImageBoxesFieldBuilder() : null; - } else { - imageBoxesBuilder_.addAllMessages(other.imageBoxes_); - } - } - } - if (other.hasRecordKey()) { - mergeRecordKey(other.getRecordKey()); - } - if (other.hasFieldId()) { - mergeFieldId(other.getFieldId()); - } - if (other.hasTableLocation()) { - mergeTableLocation(other.getTableLocation()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.Location parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.Location) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private com.google.privacy.dlp.v2beta1.Range byteRange_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Range, com.google.privacy.dlp.v2beta1.Range.Builder, com.google.privacy.dlp.v2beta1.RangeOrBuilder> byteRangeBuilder_; - /** - *
-     * Zero-based byte offsets within a content item.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public boolean hasByteRange() { - return byteRangeBuilder_ != null || byteRange_ != null; - } - /** - *
-     * Zero-based byte offsets within a content item.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public com.google.privacy.dlp.v2beta1.Range getByteRange() { - if (byteRangeBuilder_ == null) { - return byteRange_ == null ? com.google.privacy.dlp.v2beta1.Range.getDefaultInstance() : byteRange_; - } else { - return byteRangeBuilder_.getMessage(); - } - } - /** - *
-     * Zero-based byte offsets within a content item.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public Builder setByteRange(com.google.privacy.dlp.v2beta1.Range value) { - if (byteRangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - byteRange_ = value; - onChanged(); - } else { - byteRangeBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Zero-based byte offsets within a content item.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public Builder setByteRange( - com.google.privacy.dlp.v2beta1.Range.Builder builderForValue) { - if (byteRangeBuilder_ == null) { - byteRange_ = builderForValue.build(); - onChanged(); - } else { - byteRangeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Zero-based byte offsets within a content item.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public Builder mergeByteRange(com.google.privacy.dlp.v2beta1.Range value) { - if (byteRangeBuilder_ == null) { - if (byteRange_ != null) { - byteRange_ = - com.google.privacy.dlp.v2beta1.Range.newBuilder(byteRange_).mergeFrom(value).buildPartial(); - } else { - byteRange_ = value; - } - onChanged(); - } else { - byteRangeBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Zero-based byte offsets within a content item.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public Builder clearByteRange() { - if (byteRangeBuilder_ == null) { - byteRange_ = null; - onChanged(); - } else { - byteRange_ = null; - byteRangeBuilder_ = null; - } - - return this; - } - /** - *
-     * Zero-based byte offsets within a content item.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public com.google.privacy.dlp.v2beta1.Range.Builder getByteRangeBuilder() { - - onChanged(); - return getByteRangeFieldBuilder().getBuilder(); - } - /** - *
-     * Zero-based byte offsets within a content item.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - public com.google.privacy.dlp.v2beta1.RangeOrBuilder getByteRangeOrBuilder() { - if (byteRangeBuilder_ != null) { - return byteRangeBuilder_.getMessageOrBuilder(); - } else { - return byteRange_ == null ? - com.google.privacy.dlp.v2beta1.Range.getDefaultInstance() : byteRange_; - } - } - /** - *
-     * Zero-based byte offsets within a content item.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Range, com.google.privacy.dlp.v2beta1.Range.Builder, com.google.privacy.dlp.v2beta1.RangeOrBuilder> - getByteRangeFieldBuilder() { - if (byteRangeBuilder_ == null) { - byteRangeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Range, com.google.privacy.dlp.v2beta1.Range.Builder, com.google.privacy.dlp.v2beta1.RangeOrBuilder>( - getByteRange(), - getParentForChildren(), - isClean()); - byteRange_ = null; - } - return byteRangeBuilder_; - } - - private com.google.privacy.dlp.v2beta1.Range codepointRange_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Range, com.google.privacy.dlp.v2beta1.Range.Builder, com.google.privacy.dlp.v2beta1.RangeOrBuilder> codepointRangeBuilder_; - /** - *
-     * Character offsets within a content item, included when content type
-     * is a text. Default charset assumed to be UTF-8.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public boolean hasCodepointRange() { - return codepointRangeBuilder_ != null || codepointRange_ != null; - } - /** - *
-     * Character offsets within a content item, included when content type
-     * is a text. Default charset assumed to be UTF-8.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public com.google.privacy.dlp.v2beta1.Range getCodepointRange() { - if (codepointRangeBuilder_ == null) { - return codepointRange_ == null ? com.google.privacy.dlp.v2beta1.Range.getDefaultInstance() : codepointRange_; - } else { - return codepointRangeBuilder_.getMessage(); - } - } - /** - *
-     * Character offsets within a content item, included when content type
-     * is a text. Default charset assumed to be UTF-8.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public Builder setCodepointRange(com.google.privacy.dlp.v2beta1.Range value) { - if (codepointRangeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - codepointRange_ = value; - onChanged(); - } else { - codepointRangeBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Character offsets within a content item, included when content type
-     * is a text. Default charset assumed to be UTF-8.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public Builder setCodepointRange( - com.google.privacy.dlp.v2beta1.Range.Builder builderForValue) { - if (codepointRangeBuilder_ == null) { - codepointRange_ = builderForValue.build(); - onChanged(); - } else { - codepointRangeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Character offsets within a content item, included when content type
-     * is a text. Default charset assumed to be UTF-8.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public Builder mergeCodepointRange(com.google.privacy.dlp.v2beta1.Range value) { - if (codepointRangeBuilder_ == null) { - if (codepointRange_ != null) { - codepointRange_ = - com.google.privacy.dlp.v2beta1.Range.newBuilder(codepointRange_).mergeFrom(value).buildPartial(); - } else { - codepointRange_ = value; - } - onChanged(); - } else { - codepointRangeBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Character offsets within a content item, included when content type
-     * is a text. Default charset assumed to be UTF-8.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public Builder clearCodepointRange() { - if (codepointRangeBuilder_ == null) { - codepointRange_ = null; - onChanged(); - } else { - codepointRange_ = null; - codepointRangeBuilder_ = null; - } - - return this; - } - /** - *
-     * Character offsets within a content item, included when content type
-     * is a text. Default charset assumed to be UTF-8.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public com.google.privacy.dlp.v2beta1.Range.Builder getCodepointRangeBuilder() { - - onChanged(); - return getCodepointRangeFieldBuilder().getBuilder(); - } - /** - *
-     * Character offsets within a content item, included when content type
-     * is a text. Default charset assumed to be UTF-8.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - public com.google.privacy.dlp.v2beta1.RangeOrBuilder getCodepointRangeOrBuilder() { - if (codepointRangeBuilder_ != null) { - return codepointRangeBuilder_.getMessageOrBuilder(); - } else { - return codepointRange_ == null ? - com.google.privacy.dlp.v2beta1.Range.getDefaultInstance() : codepointRange_; - } - } - /** - *
-     * Character offsets within a content item, included when content type
-     * is a text. Default charset assumed to be UTF-8.
-     * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Range, com.google.privacy.dlp.v2beta1.Range.Builder, com.google.privacy.dlp.v2beta1.RangeOrBuilder> - getCodepointRangeFieldBuilder() { - if (codepointRangeBuilder_ == null) { - codepointRangeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Range, com.google.privacy.dlp.v2beta1.Range.Builder, com.google.privacy.dlp.v2beta1.RangeOrBuilder>( - getCodepointRange(), - getParentForChildren(), - isClean()); - codepointRange_ = null; - } - return codepointRangeBuilder_; - } - - private java.util.List imageBoxes_ = - java.util.Collections.emptyList(); - private void ensureImageBoxesIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { - imageBoxes_ = new java.util.ArrayList(imageBoxes_); - bitField0_ |= 0x00000004; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ImageLocation, com.google.privacy.dlp.v2beta1.ImageLocation.Builder, com.google.privacy.dlp.v2beta1.ImageLocationOrBuilder> imageBoxesBuilder_; - - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public java.util.List getImageBoxesList() { - if (imageBoxesBuilder_ == null) { - return java.util.Collections.unmodifiableList(imageBoxes_); - } else { - return imageBoxesBuilder_.getMessageList(); - } - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public int getImageBoxesCount() { - if (imageBoxesBuilder_ == null) { - return imageBoxes_.size(); - } else { - return imageBoxesBuilder_.getCount(); - } - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public com.google.privacy.dlp.v2beta1.ImageLocation getImageBoxes(int index) { - if (imageBoxesBuilder_ == null) { - return imageBoxes_.get(index); - } else { - return imageBoxesBuilder_.getMessage(index); - } - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public Builder setImageBoxes( - int index, com.google.privacy.dlp.v2beta1.ImageLocation value) { - if (imageBoxesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureImageBoxesIsMutable(); - imageBoxes_.set(index, value); - onChanged(); - } else { - imageBoxesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public Builder setImageBoxes( - int index, com.google.privacy.dlp.v2beta1.ImageLocation.Builder builderForValue) { - if (imageBoxesBuilder_ == null) { - ensureImageBoxesIsMutable(); - imageBoxes_.set(index, builderForValue.build()); - onChanged(); - } else { - imageBoxesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public Builder addImageBoxes(com.google.privacy.dlp.v2beta1.ImageLocation value) { - if (imageBoxesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureImageBoxesIsMutable(); - imageBoxes_.add(value); - onChanged(); - } else { - imageBoxesBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public Builder addImageBoxes( - int index, com.google.privacy.dlp.v2beta1.ImageLocation value) { - if (imageBoxesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureImageBoxesIsMutable(); - imageBoxes_.add(index, value); - onChanged(); - } else { - imageBoxesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public Builder addImageBoxes( - com.google.privacy.dlp.v2beta1.ImageLocation.Builder builderForValue) { - if (imageBoxesBuilder_ == null) { - ensureImageBoxesIsMutable(); - imageBoxes_.add(builderForValue.build()); - onChanged(); - } else { - imageBoxesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public Builder addImageBoxes( - int index, com.google.privacy.dlp.v2beta1.ImageLocation.Builder builderForValue) { - if (imageBoxesBuilder_ == null) { - ensureImageBoxesIsMutable(); - imageBoxes_.add(index, builderForValue.build()); - onChanged(); - } else { - imageBoxesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public Builder addAllImageBoxes( - java.lang.Iterable values) { - if (imageBoxesBuilder_ == null) { - ensureImageBoxesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, imageBoxes_); - onChanged(); - } else { - imageBoxesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public Builder clearImageBoxes() { - if (imageBoxesBuilder_ == null) { - imageBoxes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - } else { - imageBoxesBuilder_.clear(); - } - return this; - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public Builder removeImageBoxes(int index) { - if (imageBoxesBuilder_ == null) { - ensureImageBoxesIsMutable(); - imageBoxes_.remove(index); - onChanged(); - } else { - imageBoxesBuilder_.remove(index); - } - return this; - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public com.google.privacy.dlp.v2beta1.ImageLocation.Builder getImageBoxesBuilder( - int index) { - return getImageBoxesFieldBuilder().getBuilder(index); - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public com.google.privacy.dlp.v2beta1.ImageLocationOrBuilder getImageBoxesOrBuilder( - int index) { - if (imageBoxesBuilder_ == null) { - return imageBoxes_.get(index); } else { - return imageBoxesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public java.util.List - getImageBoxesOrBuilderList() { - if (imageBoxesBuilder_ != null) { - return imageBoxesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(imageBoxes_); - } - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public com.google.privacy.dlp.v2beta1.ImageLocation.Builder addImageBoxesBuilder() { - return getImageBoxesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.ImageLocation.getDefaultInstance()); - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public com.google.privacy.dlp.v2beta1.ImageLocation.Builder addImageBoxesBuilder( - int index) { - return getImageBoxesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.ImageLocation.getDefaultInstance()); - } - /** - *
-     * Location within an image's pixels.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - public java.util.List - getImageBoxesBuilderList() { - return getImageBoxesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ImageLocation, com.google.privacy.dlp.v2beta1.ImageLocation.Builder, com.google.privacy.dlp.v2beta1.ImageLocationOrBuilder> - getImageBoxesFieldBuilder() { - if (imageBoxesBuilder_ == null) { - imageBoxesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ImageLocation, com.google.privacy.dlp.v2beta1.ImageLocation.Builder, com.google.privacy.dlp.v2beta1.ImageLocationOrBuilder>( - imageBoxes_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); - imageBoxes_ = null; - } - return imageBoxesBuilder_; - } - - private com.google.privacy.dlp.v2beta1.RecordKey recordKey_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordKey, com.google.privacy.dlp.v2beta1.RecordKey.Builder, com.google.privacy.dlp.v2beta1.RecordKeyOrBuilder> recordKeyBuilder_; - /** - *
-     * Key of the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public boolean hasRecordKey() { - return recordKeyBuilder_ != null || recordKey_ != null; - } - /** - *
-     * Key of the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public com.google.privacy.dlp.v2beta1.RecordKey getRecordKey() { - if (recordKeyBuilder_ == null) { - return recordKey_ == null ? com.google.privacy.dlp.v2beta1.RecordKey.getDefaultInstance() : recordKey_; - } else { - return recordKeyBuilder_.getMessage(); - } - } - /** - *
-     * Key of the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public Builder setRecordKey(com.google.privacy.dlp.v2beta1.RecordKey value) { - if (recordKeyBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - recordKey_ = value; - onChanged(); - } else { - recordKeyBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Key of the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public Builder setRecordKey( - com.google.privacy.dlp.v2beta1.RecordKey.Builder builderForValue) { - if (recordKeyBuilder_ == null) { - recordKey_ = builderForValue.build(); - onChanged(); - } else { - recordKeyBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Key of the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public Builder mergeRecordKey(com.google.privacy.dlp.v2beta1.RecordKey value) { - if (recordKeyBuilder_ == null) { - if (recordKey_ != null) { - recordKey_ = - com.google.privacy.dlp.v2beta1.RecordKey.newBuilder(recordKey_).mergeFrom(value).buildPartial(); - } else { - recordKey_ = value; - } - onChanged(); - } else { - recordKeyBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Key of the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public Builder clearRecordKey() { - if (recordKeyBuilder_ == null) { - recordKey_ = null; - onChanged(); - } else { - recordKey_ = null; - recordKeyBuilder_ = null; - } - - return this; - } - /** - *
-     * Key of the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public com.google.privacy.dlp.v2beta1.RecordKey.Builder getRecordKeyBuilder() { - - onChanged(); - return getRecordKeyFieldBuilder().getBuilder(); - } - /** - *
-     * Key of the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - public com.google.privacy.dlp.v2beta1.RecordKeyOrBuilder getRecordKeyOrBuilder() { - if (recordKeyBuilder_ != null) { - return recordKeyBuilder_.getMessageOrBuilder(); - } else { - return recordKey_ == null ? - com.google.privacy.dlp.v2beta1.RecordKey.getDefaultInstance() : recordKey_; - } - } - /** - *
-     * Key of the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordKey, com.google.privacy.dlp.v2beta1.RecordKey.Builder, com.google.privacy.dlp.v2beta1.RecordKeyOrBuilder> - getRecordKeyFieldBuilder() { - if (recordKeyBuilder_ == null) { - recordKeyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordKey, com.google.privacy.dlp.v2beta1.RecordKey.Builder, com.google.privacy.dlp.v2beta1.RecordKeyOrBuilder>( - getRecordKey(), - getParentForChildren(), - isClean()); - recordKey_ = null; - } - return recordKeyBuilder_; - } - - private com.google.privacy.dlp.v2beta1.FieldId fieldId_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> fieldIdBuilder_; - /** - *
-     * Field id of the field containing the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public boolean hasFieldId() { - return fieldIdBuilder_ != null || fieldId_ != null; - } - /** - *
-     * Field id of the field containing the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldId getFieldId() { - if (fieldIdBuilder_ == null) { - return fieldId_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : fieldId_; - } else { - return fieldIdBuilder_.getMessage(); - } - } - /** - *
-     * Field id of the field containing the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public Builder setFieldId(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldIdBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - fieldId_ = value; - onChanged(); - } else { - fieldIdBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Field id of the field containing the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public Builder setFieldId( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (fieldIdBuilder_ == null) { - fieldId_ = builderForValue.build(); - onChanged(); - } else { - fieldIdBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Field id of the field containing the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public Builder mergeFieldId(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldIdBuilder_ == null) { - if (fieldId_ != null) { - fieldId_ = - com.google.privacy.dlp.v2beta1.FieldId.newBuilder(fieldId_).mergeFrom(value).buildPartial(); - } else { - fieldId_ = value; - } - onChanged(); - } else { - fieldIdBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Field id of the field containing the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public Builder clearFieldId() { - if (fieldIdBuilder_ == null) { - fieldId_ = null; - onChanged(); - } else { - fieldId_ = null; - fieldIdBuilder_ = null; - } - - return this; - } - /** - *
-     * Field id of the field containing the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getFieldIdBuilder() { - - onChanged(); - return getFieldIdFieldBuilder().getBuilder(); - } - /** - *
-     * Field id of the field containing the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldIdOrBuilder() { - if (fieldIdBuilder_ != null) { - return fieldIdBuilder_.getMessageOrBuilder(); - } else { - return fieldId_ == null ? - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : fieldId_; - } - } - /** - *
-     * Field id of the field containing the finding.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getFieldIdFieldBuilder() { - if (fieldIdBuilder_ == null) { - fieldIdBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - getFieldId(), - getParentForChildren(), - isClean()); - fieldId_ = null; - } - return fieldIdBuilder_; - } - - private com.google.privacy.dlp.v2beta1.TableLocation tableLocation_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TableLocation, com.google.privacy.dlp.v2beta1.TableLocation.Builder, com.google.privacy.dlp.v2beta1.TableLocationOrBuilder> tableLocationBuilder_; - /** - *
-     * Location within a `ContentItem.Table`.
-     * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public boolean hasTableLocation() { - return tableLocationBuilder_ != null || tableLocation_ != null; - } - /** - *
-     * Location within a `ContentItem.Table`.
-     * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public com.google.privacy.dlp.v2beta1.TableLocation getTableLocation() { - if (tableLocationBuilder_ == null) { - return tableLocation_ == null ? com.google.privacy.dlp.v2beta1.TableLocation.getDefaultInstance() : tableLocation_; - } else { - return tableLocationBuilder_.getMessage(); - } - } - /** - *
-     * Location within a `ContentItem.Table`.
-     * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public Builder setTableLocation(com.google.privacy.dlp.v2beta1.TableLocation value) { - if (tableLocationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - tableLocation_ = value; - onChanged(); - } else { - tableLocationBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Location within a `ContentItem.Table`.
-     * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public Builder setTableLocation( - com.google.privacy.dlp.v2beta1.TableLocation.Builder builderForValue) { - if (tableLocationBuilder_ == null) { - tableLocation_ = builderForValue.build(); - onChanged(); - } else { - tableLocationBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Location within a `ContentItem.Table`.
-     * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public Builder mergeTableLocation(com.google.privacy.dlp.v2beta1.TableLocation value) { - if (tableLocationBuilder_ == null) { - if (tableLocation_ != null) { - tableLocation_ = - com.google.privacy.dlp.v2beta1.TableLocation.newBuilder(tableLocation_).mergeFrom(value).buildPartial(); - } else { - tableLocation_ = value; - } - onChanged(); - } else { - tableLocationBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Location within a `ContentItem.Table`.
-     * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public Builder clearTableLocation() { - if (tableLocationBuilder_ == null) { - tableLocation_ = null; - onChanged(); - } else { - tableLocation_ = null; - tableLocationBuilder_ = null; - } - - return this; - } - /** - *
-     * Location within a `ContentItem.Table`.
-     * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public com.google.privacy.dlp.v2beta1.TableLocation.Builder getTableLocationBuilder() { - - onChanged(); - return getTableLocationFieldBuilder().getBuilder(); - } - /** - *
-     * Location within a `ContentItem.Table`.
-     * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - public com.google.privacy.dlp.v2beta1.TableLocationOrBuilder getTableLocationOrBuilder() { - if (tableLocationBuilder_ != null) { - return tableLocationBuilder_.getMessageOrBuilder(); - } else { - return tableLocation_ == null ? - com.google.privacy.dlp.v2beta1.TableLocation.getDefaultInstance() : tableLocation_; - } - } - /** - *
-     * Location within a `ContentItem.Table`.
-     * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TableLocation, com.google.privacy.dlp.v2beta1.TableLocation.Builder, com.google.privacy.dlp.v2beta1.TableLocationOrBuilder> - getTableLocationFieldBuilder() { - if (tableLocationBuilder_ == null) { - tableLocationBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TableLocation, com.google.privacy.dlp.v2beta1.TableLocation.Builder, com.google.privacy.dlp.v2beta1.TableLocationOrBuilder>( - getTableLocation(), - getParentForChildren(), - isClean()); - tableLocation_ = null; - } - return tableLocationBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.Location) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.Location) - private static final com.google.privacy.dlp.v2beta1.Location DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.Location(); - } - - public static com.google.privacy.dlp.v2beta1.Location getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Location parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Location(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.Location getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/LocationOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/LocationOrBuilder.java deleted file mode 100644 index 10f3262256cb..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/LocationOrBuilder.java +++ /dev/null @@ -1,181 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface LocationOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.Location) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Zero-based byte offsets within a content item.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - boolean hasByteRange(); - /** - *
-   * Zero-based byte offsets within a content item.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - com.google.privacy.dlp.v2beta1.Range getByteRange(); - /** - *
-   * Zero-based byte offsets within a content item.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range byte_range = 1; - */ - com.google.privacy.dlp.v2beta1.RangeOrBuilder getByteRangeOrBuilder(); - - /** - *
-   * Character offsets within a content item, included when content type
-   * is a text. Default charset assumed to be UTF-8.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - boolean hasCodepointRange(); - /** - *
-   * Character offsets within a content item, included when content type
-   * is a text. Default charset assumed to be UTF-8.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - com.google.privacy.dlp.v2beta1.Range getCodepointRange(); - /** - *
-   * Character offsets within a content item, included when content type
-   * is a text. Default charset assumed to be UTF-8.
-   * 
- * - * .google.privacy.dlp.v2beta1.Range codepoint_range = 2; - */ - com.google.privacy.dlp.v2beta1.RangeOrBuilder getCodepointRangeOrBuilder(); - - /** - *
-   * Location within an image's pixels.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - java.util.List - getImageBoxesList(); - /** - *
-   * Location within an image's pixels.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - com.google.privacy.dlp.v2beta1.ImageLocation getImageBoxes(int index); - /** - *
-   * Location within an image's pixels.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - int getImageBoxesCount(); - /** - *
-   * Location within an image's pixels.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - java.util.List - getImageBoxesOrBuilderList(); - /** - *
-   * Location within an image's pixels.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ImageLocation image_boxes = 3; - */ - com.google.privacy.dlp.v2beta1.ImageLocationOrBuilder getImageBoxesOrBuilder( - int index); - - /** - *
-   * Key of the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - boolean hasRecordKey(); - /** - *
-   * Key of the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - com.google.privacy.dlp.v2beta1.RecordKey getRecordKey(); - /** - *
-   * Key of the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordKey record_key = 4; - */ - com.google.privacy.dlp.v2beta1.RecordKeyOrBuilder getRecordKeyOrBuilder(); - - /** - *
-   * Field id of the field containing the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - boolean hasFieldId(); - /** - *
-   * Field id of the field containing the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - com.google.privacy.dlp.v2beta1.FieldId getFieldId(); - /** - *
-   * Field id of the field containing the finding.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field_id = 5; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldIdOrBuilder(); - - /** - *
-   * Location within a `ContentItem.Table`.
-   * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - boolean hasTableLocation(); - /** - *
-   * Location within a `ContentItem.Table`.
-   * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - com.google.privacy.dlp.v2beta1.TableLocation getTableLocation(); - /** - *
-   * Location within a `ContentItem.Table`.
-   * 
- * - * .google.privacy.dlp.v2beta1.TableLocation table_location = 6; - */ - com.google.privacy.dlp.v2beta1.TableLocationOrBuilder getTableLocationOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OperationConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OperationConfig.java deleted file mode 100644 index 6c84f5c137c9..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OperationConfig.java +++ /dev/null @@ -1,472 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Additional configuration for inspect long running operations.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.OperationConfig} - */ -public final class OperationConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.OperationConfig) - OperationConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use OperationConfig.newBuilder() to construct. - private OperationConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private OperationConfig() { - maxItemFindings_ = 0L; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private OperationConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - - maxItemFindings_ = input.readInt64(); - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_OperationConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_OperationConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.OperationConfig.class, com.google.privacy.dlp.v2beta1.OperationConfig.Builder.class); - } - - public static final int MAX_ITEM_FINDINGS_FIELD_NUMBER = 1; - private long maxItemFindings_; - /** - *
-   * Max number of findings per file, Datastore entity, or database row.
-   * 
- * - * int64 max_item_findings = 1; - */ - public long getMaxItemFindings() { - return maxItemFindings_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (maxItemFindings_ != 0L) { - output.writeInt64(1, maxItemFindings_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (maxItemFindings_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(1, maxItemFindings_); - } - 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.privacy.dlp.v2beta1.OperationConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.OperationConfig other = (com.google.privacy.dlp.v2beta1.OperationConfig) obj; - - boolean result = true; - result = result && (getMaxItemFindings() - == other.getMaxItemFindings()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + MAX_ITEM_FINDINGS_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getMaxItemFindings()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.OperationConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.OperationConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.OperationConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.OperationConfig 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.privacy.dlp.v2beta1.OperationConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.OperationConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.OperationConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.OperationConfig 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.privacy.dlp.v2beta1.OperationConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.OperationConfig 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.privacy.dlp.v2beta1.OperationConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.OperationConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.OperationConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Additional configuration for inspect long running operations.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.OperationConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.OperationConfig) - com.google.privacy.dlp.v2beta1.OperationConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_OperationConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_OperationConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.OperationConfig.class, com.google.privacy.dlp.v2beta1.OperationConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.OperationConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - maxItemFindings_ = 0L; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_OperationConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.OperationConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.OperationConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.OperationConfig build() { - com.google.privacy.dlp.v2beta1.OperationConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.OperationConfig buildPartial() { - com.google.privacy.dlp.v2beta1.OperationConfig result = new com.google.privacy.dlp.v2beta1.OperationConfig(this); - result.maxItemFindings_ = maxItemFindings_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.OperationConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.OperationConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.OperationConfig other) { - if (other == com.google.privacy.dlp.v2beta1.OperationConfig.getDefaultInstance()) return this; - if (other.getMaxItemFindings() != 0L) { - setMaxItemFindings(other.getMaxItemFindings()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.OperationConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.OperationConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private long maxItemFindings_ ; - /** - *
-     * Max number of findings per file, Datastore entity, or database row.
-     * 
- * - * int64 max_item_findings = 1; - */ - public long getMaxItemFindings() { - return maxItemFindings_; - } - /** - *
-     * Max number of findings per file, Datastore entity, or database row.
-     * 
- * - * int64 max_item_findings = 1; - */ - public Builder setMaxItemFindings(long value) { - - maxItemFindings_ = value; - onChanged(); - return this; - } - /** - *
-     * Max number of findings per file, Datastore entity, or database row.
-     * 
- * - * int64 max_item_findings = 1; - */ - public Builder clearMaxItemFindings() { - - maxItemFindings_ = 0L; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.OperationConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.OperationConfig) - private static final com.google.privacy.dlp.v2beta1.OperationConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.OperationConfig(); - } - - public static com.google.privacy.dlp.v2beta1.OperationConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public OperationConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new OperationConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.OperationConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OperationConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OperationConfigOrBuilder.java deleted file mode 100644 index 27da310aba0c..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OperationConfigOrBuilder.java +++ /dev/null @@ -1,18 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface OperationConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.OperationConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Max number of findings per file, Datastore entity, or database row.
-   * 
- * - * int64 max_item_findings = 1; - */ - long getMaxItemFindings(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OutputStorageConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OutputStorageConfig.java deleted file mode 100644 index e4bf4aac0610..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OutputStorageConfig.java +++ /dev/null @@ -1,1329 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Cloud repository for storing output.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.OutputStorageConfig} - */ -public final class OutputStorageConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.OutputStorageConfig) - OutputStorageConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use OutputStorageConfig.newBuilder() to construct. - private OutputStorageConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private OutputStorageConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private OutputStorageConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.BigQueryTable.Builder subBuilder = null; - if (typeCase_ == 1) { - subBuilder = ((com.google.privacy.dlp.v2beta1.BigQueryTable) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.BigQueryTable.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.BigQueryTable) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 1; - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.CloudStoragePath.Builder subBuilder = null; - if (typeCase_ == 2) { - subBuilder = ((com.google.privacy.dlp.v2beta1.CloudStoragePath) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.CloudStoragePath.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.CloudStoragePath) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 2; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_OutputStorageConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_OutputStorageConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.OutputStorageConfig.class, com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder.class); - } - - private int typeCase_ = 0; - private java.lang.Object type_; - public enum TypeCase - implements com.google.protobuf.Internal.EnumLite { - TABLE(1), - STORAGE_PATH(2), - TYPE_NOT_SET(0); - private final int value; - private TypeCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TypeCase valueOf(int value) { - return forNumber(value); - } - - public static TypeCase forNumber(int value) { - switch (value) { - case 1: return TABLE; - case 2: return STORAGE_PATH; - case 0: return TYPE_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public static final int TABLE_FIELD_NUMBER = 1; - /** - *
-   * Store findings in a new table in the dataset.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public boolean hasTable() { - return typeCase_ == 1; - } - /** - *
-   * Store findings in a new table in the dataset.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable getTable() { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.BigQueryTable) type_; - } - return com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance(); - } - /** - *
-   * Store findings in a new table in the dataset.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getTableOrBuilder() { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.BigQueryTable) type_; - } - return com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance(); - } - - public static final int STORAGE_PATH_FIELD_NUMBER = 2; - /** - *
-   * The path to a Google Cloud Storage location to store output.
-   * The bucket must already exist and
-   * the Google APIs service account for DLP must have write permission to
-   * write to the given bucket.
-   * Results are split over multiple csv files with each file name matching
-   * the pattern "[operation_id]_[count].csv", for example
-   * `3094877188788974909_1.csv`. The `operation_id` matches the
-   * identifier for the Operation, and the `count` is a counter used for
-   * tracking the number of files written.
-   * The CSV file(s) contain the following columns regardless of storage type
-   * scanned:
-   * - id
-   * - info_type
-   * - likelihood
-   * - byte size of finding
-   * - quote
-   * - timestamp
-   * For Cloud Storage the next columns are:
-   * - file_path
-   * - start_offset
-   * For Cloud Datastore the next columns are:
-   * - project_id
-   * - namespace_id
-   * - path
-   * - column_name
-   * - offset
-   * For BigQuery the next columns are:
-   * - row_number
-   * - project_id
-   * - dataset_id
-   * - table_id
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public boolean hasStoragePath() { - return typeCase_ == 2; - } - /** - *
-   * The path to a Google Cloud Storage location to store output.
-   * The bucket must already exist and
-   * the Google APIs service account for DLP must have write permission to
-   * write to the given bucket.
-   * Results are split over multiple csv files with each file name matching
-   * the pattern "[operation_id]_[count].csv", for example
-   * `3094877188788974909_1.csv`. The `operation_id` matches the
-   * identifier for the Operation, and the `count` is a counter used for
-   * tracking the number of files written.
-   * The CSV file(s) contain the following columns regardless of storage type
-   * scanned:
-   * - id
-   * - info_type
-   * - likelihood
-   * - byte size of finding
-   * - quote
-   * - timestamp
-   * For Cloud Storage the next columns are:
-   * - file_path
-   * - start_offset
-   * For Cloud Datastore the next columns are:
-   * - project_id
-   * - namespace_id
-   * - path
-   * - column_name
-   * - offset
-   * For BigQuery the next columns are:
-   * - row_number
-   * - project_id
-   * - dataset_id
-   * - table_id
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public com.google.privacy.dlp.v2beta1.CloudStoragePath getStoragePath() { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.CloudStoragePath) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStoragePath.getDefaultInstance(); - } - /** - *
-   * The path to a Google Cloud Storage location to store output.
-   * The bucket must already exist and
-   * the Google APIs service account for DLP must have write permission to
-   * write to the given bucket.
-   * Results are split over multiple csv files with each file name matching
-   * the pattern "[operation_id]_[count].csv", for example
-   * `3094877188788974909_1.csv`. The `operation_id` matches the
-   * identifier for the Operation, and the `count` is a counter used for
-   * tracking the number of files written.
-   * The CSV file(s) contain the following columns regardless of storage type
-   * scanned:
-   * - id
-   * - info_type
-   * - likelihood
-   * - byte size of finding
-   * - quote
-   * - timestamp
-   * For Cloud Storage the next columns are:
-   * - file_path
-   * - start_offset
-   * For Cloud Datastore the next columns are:
-   * - project_id
-   * - namespace_id
-   * - path
-   * - column_name
-   * - offset
-   * For BigQuery the next columns are:
-   * - row_number
-   * - project_id
-   * - dataset_id
-   * - table_id
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public com.google.privacy.dlp.v2beta1.CloudStoragePathOrBuilder getStoragePathOrBuilder() { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.CloudStoragePath) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStoragePath.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (typeCase_ == 1) { - output.writeMessage(1, (com.google.privacy.dlp.v2beta1.BigQueryTable) type_); - } - if (typeCase_ == 2) { - output.writeMessage(2, (com.google.privacy.dlp.v2beta1.CloudStoragePath) type_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (typeCase_ == 1) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, (com.google.privacy.dlp.v2beta1.BigQueryTable) type_); - } - if (typeCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, (com.google.privacy.dlp.v2beta1.CloudStoragePath) type_); - } - 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.privacy.dlp.v2beta1.OutputStorageConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.OutputStorageConfig other = (com.google.privacy.dlp.v2beta1.OutputStorageConfig) obj; - - boolean result = true; - result = result && getTypeCase().equals( - other.getTypeCase()); - if (!result) return false; - switch (typeCase_) { - case 1: - result = result && getTable() - .equals(other.getTable()); - break; - case 2: - result = result && getStoragePath() - .equals(other.getStoragePath()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (typeCase_) { - case 1: - hash = (37 * hash) + TABLE_FIELD_NUMBER; - hash = (53 * hash) + getTable().hashCode(); - break; - case 2: - hash = (37 * hash) + STORAGE_PATH_FIELD_NUMBER; - hash = (53 * hash) + getStoragePath().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.OutputStorageConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.OutputStorageConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.OutputStorageConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.OutputStorageConfig 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.privacy.dlp.v2beta1.OutputStorageConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.OutputStorageConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.OutputStorageConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.OutputStorageConfig 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.privacy.dlp.v2beta1.OutputStorageConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.OutputStorageConfig 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.privacy.dlp.v2beta1.OutputStorageConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.OutputStorageConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.OutputStorageConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Cloud repository for storing output.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.OutputStorageConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.OutputStorageConfig) - com.google.privacy.dlp.v2beta1.OutputStorageConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_OutputStorageConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_OutputStorageConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.OutputStorageConfig.class, com.google.privacy.dlp.v2beta1.OutputStorageConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.OutputStorageConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - typeCase_ = 0; - type_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_OutputStorageConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.OutputStorageConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.OutputStorageConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.OutputStorageConfig build() { - com.google.privacy.dlp.v2beta1.OutputStorageConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.OutputStorageConfig buildPartial() { - com.google.privacy.dlp.v2beta1.OutputStorageConfig result = new com.google.privacy.dlp.v2beta1.OutputStorageConfig(this); - if (typeCase_ == 1) { - if (tableBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = tableBuilder_.build(); - } - } - if (typeCase_ == 2) { - if (storagePathBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = storagePathBuilder_.build(); - } - } - result.typeCase_ = typeCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.OutputStorageConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.OutputStorageConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.OutputStorageConfig other) { - if (other == com.google.privacy.dlp.v2beta1.OutputStorageConfig.getDefaultInstance()) return this; - switch (other.getTypeCase()) { - case TABLE: { - mergeTable(other.getTable()); - break; - } - case STORAGE_PATH: { - mergeStoragePath(other.getStoragePath()); - break; - } - case TYPE_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.OutputStorageConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.OutputStorageConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int typeCase_ = 0; - private java.lang.Object type_; - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public Builder clearType() { - typeCase_ = 0; - type_ = null; - onChanged(); - return this; - } - - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder> tableBuilder_; - /** - *
-     * Store findings in a new table in the dataset.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public boolean hasTable() { - return typeCase_ == 1; - } - /** - *
-     * Store findings in a new table in the dataset.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable getTable() { - if (tableBuilder_ == null) { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.BigQueryTable) type_; - } - return com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance(); - } else { - if (typeCase_ == 1) { - return tableBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance(); - } - } - /** - *
-     * Store findings in a new table in the dataset.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public Builder setTable(com.google.privacy.dlp.v2beta1.BigQueryTable value) { - if (tableBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - tableBuilder_.setMessage(value); - } - typeCase_ = 1; - return this; - } - /** - *
-     * Store findings in a new table in the dataset.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public Builder setTable( - com.google.privacy.dlp.v2beta1.BigQueryTable.Builder builderForValue) { - if (tableBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - tableBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 1; - return this; - } - /** - *
-     * Store findings in a new table in the dataset.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public Builder mergeTable(com.google.privacy.dlp.v2beta1.BigQueryTable value) { - if (tableBuilder_ == null) { - if (typeCase_ == 1 && - type_ != com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.BigQueryTable.newBuilder((com.google.privacy.dlp.v2beta1.BigQueryTable) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 1) { - tableBuilder_.mergeFrom(value); - } - tableBuilder_.setMessage(value); - } - typeCase_ = 1; - return this; - } - /** - *
-     * Store findings in a new table in the dataset.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public Builder clearTable() { - if (tableBuilder_ == null) { - if (typeCase_ == 1) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 1) { - typeCase_ = 0; - type_ = null; - } - tableBuilder_.clear(); - } - return this; - } - /** - *
-     * Store findings in a new table in the dataset.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable.Builder getTableBuilder() { - return getTableFieldBuilder().getBuilder(); - } - /** - *
-     * Store findings in a new table in the dataset.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getTableOrBuilder() { - if ((typeCase_ == 1) && (tableBuilder_ != null)) { - return tableBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.BigQueryTable) type_; - } - return com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance(); - } - } - /** - *
-     * Store findings in a new table in the dataset.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder> - getTableFieldBuilder() { - if (tableBuilder_ == null) { - if (!(typeCase_ == 1)) { - type_ = com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance(); - } - tableBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder>( - (com.google.privacy.dlp.v2beta1.BigQueryTable) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 1; - onChanged();; - return tableBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStoragePath, com.google.privacy.dlp.v2beta1.CloudStoragePath.Builder, com.google.privacy.dlp.v2beta1.CloudStoragePathOrBuilder> storagePathBuilder_; - /** - *
-     * The path to a Google Cloud Storage location to store output.
-     * The bucket must already exist and
-     * the Google APIs service account for DLP must have write permission to
-     * write to the given bucket.
-     * Results are split over multiple csv files with each file name matching
-     * the pattern "[operation_id]_[count].csv", for example
-     * `3094877188788974909_1.csv`. The `operation_id` matches the
-     * identifier for the Operation, and the `count` is a counter used for
-     * tracking the number of files written.
-     * The CSV file(s) contain the following columns regardless of storage type
-     * scanned:
-     * - id
-     * - info_type
-     * - likelihood
-     * - byte size of finding
-     * - quote
-     * - timestamp
-     * For Cloud Storage the next columns are:
-     * - file_path
-     * - start_offset
-     * For Cloud Datastore the next columns are:
-     * - project_id
-     * - namespace_id
-     * - path
-     * - column_name
-     * - offset
-     * For BigQuery the next columns are:
-     * - row_number
-     * - project_id
-     * - dataset_id
-     * - table_id
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public boolean hasStoragePath() { - return typeCase_ == 2; - } - /** - *
-     * The path to a Google Cloud Storage location to store output.
-     * The bucket must already exist and
-     * the Google APIs service account for DLP must have write permission to
-     * write to the given bucket.
-     * Results are split over multiple csv files with each file name matching
-     * the pattern "[operation_id]_[count].csv", for example
-     * `3094877188788974909_1.csv`. The `operation_id` matches the
-     * identifier for the Operation, and the `count` is a counter used for
-     * tracking the number of files written.
-     * The CSV file(s) contain the following columns regardless of storage type
-     * scanned:
-     * - id
-     * - info_type
-     * - likelihood
-     * - byte size of finding
-     * - quote
-     * - timestamp
-     * For Cloud Storage the next columns are:
-     * - file_path
-     * - start_offset
-     * For Cloud Datastore the next columns are:
-     * - project_id
-     * - namespace_id
-     * - path
-     * - column_name
-     * - offset
-     * For BigQuery the next columns are:
-     * - row_number
-     * - project_id
-     * - dataset_id
-     * - table_id
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public com.google.privacy.dlp.v2beta1.CloudStoragePath getStoragePath() { - if (storagePathBuilder_ == null) { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.CloudStoragePath) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStoragePath.getDefaultInstance(); - } else { - if (typeCase_ == 2) { - return storagePathBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.CloudStoragePath.getDefaultInstance(); - } - } - /** - *
-     * The path to a Google Cloud Storage location to store output.
-     * The bucket must already exist and
-     * the Google APIs service account for DLP must have write permission to
-     * write to the given bucket.
-     * Results are split over multiple csv files with each file name matching
-     * the pattern "[operation_id]_[count].csv", for example
-     * `3094877188788974909_1.csv`. The `operation_id` matches the
-     * identifier for the Operation, and the `count` is a counter used for
-     * tracking the number of files written.
-     * The CSV file(s) contain the following columns regardless of storage type
-     * scanned:
-     * - id
-     * - info_type
-     * - likelihood
-     * - byte size of finding
-     * - quote
-     * - timestamp
-     * For Cloud Storage the next columns are:
-     * - file_path
-     * - start_offset
-     * For Cloud Datastore the next columns are:
-     * - project_id
-     * - namespace_id
-     * - path
-     * - column_name
-     * - offset
-     * For BigQuery the next columns are:
-     * - row_number
-     * - project_id
-     * - dataset_id
-     * - table_id
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public Builder setStoragePath(com.google.privacy.dlp.v2beta1.CloudStoragePath value) { - if (storagePathBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - storagePathBuilder_.setMessage(value); - } - typeCase_ = 2; - return this; - } - /** - *
-     * The path to a Google Cloud Storage location to store output.
-     * The bucket must already exist and
-     * the Google APIs service account for DLP must have write permission to
-     * write to the given bucket.
-     * Results are split over multiple csv files with each file name matching
-     * the pattern "[operation_id]_[count].csv", for example
-     * `3094877188788974909_1.csv`. The `operation_id` matches the
-     * identifier for the Operation, and the `count` is a counter used for
-     * tracking the number of files written.
-     * The CSV file(s) contain the following columns regardless of storage type
-     * scanned:
-     * - id
-     * - info_type
-     * - likelihood
-     * - byte size of finding
-     * - quote
-     * - timestamp
-     * For Cloud Storage the next columns are:
-     * - file_path
-     * - start_offset
-     * For Cloud Datastore the next columns are:
-     * - project_id
-     * - namespace_id
-     * - path
-     * - column_name
-     * - offset
-     * For BigQuery the next columns are:
-     * - row_number
-     * - project_id
-     * - dataset_id
-     * - table_id
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public Builder setStoragePath( - com.google.privacy.dlp.v2beta1.CloudStoragePath.Builder builderForValue) { - if (storagePathBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - storagePathBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 2; - return this; - } - /** - *
-     * The path to a Google Cloud Storage location to store output.
-     * The bucket must already exist and
-     * the Google APIs service account for DLP must have write permission to
-     * write to the given bucket.
-     * Results are split over multiple csv files with each file name matching
-     * the pattern "[operation_id]_[count].csv", for example
-     * `3094877188788974909_1.csv`. The `operation_id` matches the
-     * identifier for the Operation, and the `count` is a counter used for
-     * tracking the number of files written.
-     * The CSV file(s) contain the following columns regardless of storage type
-     * scanned:
-     * - id
-     * - info_type
-     * - likelihood
-     * - byte size of finding
-     * - quote
-     * - timestamp
-     * For Cloud Storage the next columns are:
-     * - file_path
-     * - start_offset
-     * For Cloud Datastore the next columns are:
-     * - project_id
-     * - namespace_id
-     * - path
-     * - column_name
-     * - offset
-     * For BigQuery the next columns are:
-     * - row_number
-     * - project_id
-     * - dataset_id
-     * - table_id
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public Builder mergeStoragePath(com.google.privacy.dlp.v2beta1.CloudStoragePath value) { - if (storagePathBuilder_ == null) { - if (typeCase_ == 2 && - type_ != com.google.privacy.dlp.v2beta1.CloudStoragePath.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.CloudStoragePath.newBuilder((com.google.privacy.dlp.v2beta1.CloudStoragePath) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 2) { - storagePathBuilder_.mergeFrom(value); - } - storagePathBuilder_.setMessage(value); - } - typeCase_ = 2; - return this; - } - /** - *
-     * The path to a Google Cloud Storage location to store output.
-     * The bucket must already exist and
-     * the Google APIs service account for DLP must have write permission to
-     * write to the given bucket.
-     * Results are split over multiple csv files with each file name matching
-     * the pattern "[operation_id]_[count].csv", for example
-     * `3094877188788974909_1.csv`. The `operation_id` matches the
-     * identifier for the Operation, and the `count` is a counter used for
-     * tracking the number of files written.
-     * The CSV file(s) contain the following columns regardless of storage type
-     * scanned:
-     * - id
-     * - info_type
-     * - likelihood
-     * - byte size of finding
-     * - quote
-     * - timestamp
-     * For Cloud Storage the next columns are:
-     * - file_path
-     * - start_offset
-     * For Cloud Datastore the next columns are:
-     * - project_id
-     * - namespace_id
-     * - path
-     * - column_name
-     * - offset
-     * For BigQuery the next columns are:
-     * - row_number
-     * - project_id
-     * - dataset_id
-     * - table_id
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public Builder clearStoragePath() { - if (storagePathBuilder_ == null) { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - } - storagePathBuilder_.clear(); - } - return this; - } - /** - *
-     * The path to a Google Cloud Storage location to store output.
-     * The bucket must already exist and
-     * the Google APIs service account for DLP must have write permission to
-     * write to the given bucket.
-     * Results are split over multiple csv files with each file name matching
-     * the pattern "[operation_id]_[count].csv", for example
-     * `3094877188788974909_1.csv`. The `operation_id` matches the
-     * identifier for the Operation, and the `count` is a counter used for
-     * tracking the number of files written.
-     * The CSV file(s) contain the following columns regardless of storage type
-     * scanned:
-     * - id
-     * - info_type
-     * - likelihood
-     * - byte size of finding
-     * - quote
-     * - timestamp
-     * For Cloud Storage the next columns are:
-     * - file_path
-     * - start_offset
-     * For Cloud Datastore the next columns are:
-     * - project_id
-     * - namespace_id
-     * - path
-     * - column_name
-     * - offset
-     * For BigQuery the next columns are:
-     * - row_number
-     * - project_id
-     * - dataset_id
-     * - table_id
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public com.google.privacy.dlp.v2beta1.CloudStoragePath.Builder getStoragePathBuilder() { - return getStoragePathFieldBuilder().getBuilder(); - } - /** - *
-     * The path to a Google Cloud Storage location to store output.
-     * The bucket must already exist and
-     * the Google APIs service account for DLP must have write permission to
-     * write to the given bucket.
-     * Results are split over multiple csv files with each file name matching
-     * the pattern "[operation_id]_[count].csv", for example
-     * `3094877188788974909_1.csv`. The `operation_id` matches the
-     * identifier for the Operation, and the `count` is a counter used for
-     * tracking the number of files written.
-     * The CSV file(s) contain the following columns regardless of storage type
-     * scanned:
-     * - id
-     * - info_type
-     * - likelihood
-     * - byte size of finding
-     * - quote
-     * - timestamp
-     * For Cloud Storage the next columns are:
-     * - file_path
-     * - start_offset
-     * For Cloud Datastore the next columns are:
-     * - project_id
-     * - namespace_id
-     * - path
-     * - column_name
-     * - offset
-     * For BigQuery the next columns are:
-     * - row_number
-     * - project_id
-     * - dataset_id
-     * - table_id
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - public com.google.privacy.dlp.v2beta1.CloudStoragePathOrBuilder getStoragePathOrBuilder() { - if ((typeCase_ == 2) && (storagePathBuilder_ != null)) { - return storagePathBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.CloudStoragePath) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStoragePath.getDefaultInstance(); - } - } - /** - *
-     * The path to a Google Cloud Storage location to store output.
-     * The bucket must already exist and
-     * the Google APIs service account for DLP must have write permission to
-     * write to the given bucket.
-     * Results are split over multiple csv files with each file name matching
-     * the pattern "[operation_id]_[count].csv", for example
-     * `3094877188788974909_1.csv`. The `operation_id` matches the
-     * identifier for the Operation, and the `count` is a counter used for
-     * tracking the number of files written.
-     * The CSV file(s) contain the following columns regardless of storage type
-     * scanned:
-     * - id
-     * - info_type
-     * - likelihood
-     * - byte size of finding
-     * - quote
-     * - timestamp
-     * For Cloud Storage the next columns are:
-     * - file_path
-     * - start_offset
-     * For Cloud Datastore the next columns are:
-     * - project_id
-     * - namespace_id
-     * - path
-     * - column_name
-     * - offset
-     * For BigQuery the next columns are:
-     * - row_number
-     * - project_id
-     * - dataset_id
-     * - table_id
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStoragePath, com.google.privacy.dlp.v2beta1.CloudStoragePath.Builder, com.google.privacy.dlp.v2beta1.CloudStoragePathOrBuilder> - getStoragePathFieldBuilder() { - if (storagePathBuilder_ == null) { - if (!(typeCase_ == 2)) { - type_ = com.google.privacy.dlp.v2beta1.CloudStoragePath.getDefaultInstance(); - } - storagePathBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStoragePath, com.google.privacy.dlp.v2beta1.CloudStoragePath.Builder, com.google.privacy.dlp.v2beta1.CloudStoragePathOrBuilder>( - (com.google.privacy.dlp.v2beta1.CloudStoragePath) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 2; - onChanged();; - return storagePathBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.OutputStorageConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.OutputStorageConfig) - private static final com.google.privacy.dlp.v2beta1.OutputStorageConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.OutputStorageConfig(); - } - - public static com.google.privacy.dlp.v2beta1.OutputStorageConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public OutputStorageConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new OutputStorageConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.OutputStorageConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OutputStorageConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OutputStorageConfigOrBuilder.java deleted file mode 100644 index 514b362f0b26..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/OutputStorageConfigOrBuilder.java +++ /dev/null @@ -1,151 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface OutputStorageConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.OutputStorageConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Store findings in a new table in the dataset.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - boolean hasTable(); - /** - *
-   * Store findings in a new table in the dataset.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - com.google.privacy.dlp.v2beta1.BigQueryTable getTable(); - /** - *
-   * Store findings in a new table in the dataset.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable table = 1; - */ - com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getTableOrBuilder(); - - /** - *
-   * The path to a Google Cloud Storage location to store output.
-   * The bucket must already exist and
-   * the Google APIs service account for DLP must have write permission to
-   * write to the given bucket.
-   * Results are split over multiple csv files with each file name matching
-   * the pattern "[operation_id]_[count].csv", for example
-   * `3094877188788974909_1.csv`. The `operation_id` matches the
-   * identifier for the Operation, and the `count` is a counter used for
-   * tracking the number of files written.
-   * The CSV file(s) contain the following columns regardless of storage type
-   * scanned:
-   * - id
-   * - info_type
-   * - likelihood
-   * - byte size of finding
-   * - quote
-   * - timestamp
-   * For Cloud Storage the next columns are:
-   * - file_path
-   * - start_offset
-   * For Cloud Datastore the next columns are:
-   * - project_id
-   * - namespace_id
-   * - path
-   * - column_name
-   * - offset
-   * For BigQuery the next columns are:
-   * - row_number
-   * - project_id
-   * - dataset_id
-   * - table_id
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - boolean hasStoragePath(); - /** - *
-   * The path to a Google Cloud Storage location to store output.
-   * The bucket must already exist and
-   * the Google APIs service account for DLP must have write permission to
-   * write to the given bucket.
-   * Results are split over multiple csv files with each file name matching
-   * the pattern "[operation_id]_[count].csv", for example
-   * `3094877188788974909_1.csv`. The `operation_id` matches the
-   * identifier for the Operation, and the `count` is a counter used for
-   * tracking the number of files written.
-   * The CSV file(s) contain the following columns regardless of storage type
-   * scanned:
-   * - id
-   * - info_type
-   * - likelihood
-   * - byte size of finding
-   * - quote
-   * - timestamp
-   * For Cloud Storage the next columns are:
-   * - file_path
-   * - start_offset
-   * For Cloud Datastore the next columns are:
-   * - project_id
-   * - namespace_id
-   * - path
-   * - column_name
-   * - offset
-   * For BigQuery the next columns are:
-   * - row_number
-   * - project_id
-   * - dataset_id
-   * - table_id
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - com.google.privacy.dlp.v2beta1.CloudStoragePath getStoragePath(); - /** - *
-   * The path to a Google Cloud Storage location to store output.
-   * The bucket must already exist and
-   * the Google APIs service account for DLP must have write permission to
-   * write to the given bucket.
-   * Results are split over multiple csv files with each file name matching
-   * the pattern "[operation_id]_[count].csv", for example
-   * `3094877188788974909_1.csv`. The `operation_id` matches the
-   * identifier for the Operation, and the `count` is a counter used for
-   * tracking the number of files written.
-   * The CSV file(s) contain the following columns regardless of storage type
-   * scanned:
-   * - id
-   * - info_type
-   * - likelihood
-   * - byte size of finding
-   * - quote
-   * - timestamp
-   * For Cloud Storage the next columns are:
-   * - file_path
-   * - start_offset
-   * For Cloud Datastore the next columns are:
-   * - project_id
-   * - namespace_id
-   * - path
-   * - column_name
-   * - offset
-   * For BigQuery the next columns are:
-   * - row_number
-   * - project_id
-   * - dataset_id
-   * - table_id
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStoragePath storage_path = 2; - */ - com.google.privacy.dlp.v2beta1.CloudStoragePathOrBuilder getStoragePathOrBuilder(); - - public com.google.privacy.dlp.v2beta1.OutputStorageConfig.TypeCase getTypeCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PartitionId.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PartitionId.java deleted file mode 100644 index 55853135ca21..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PartitionId.java +++ /dev/null @@ -1,715 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Datastore partition ID.
- * A partition ID identifies a grouping of entities. The grouping is always
- * by project and namespace, however the namespace ID may be empty.
- * A partition ID contains several dimensions:
- * project ID and namespace ID.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PartitionId} - */ -public final class PartitionId extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PartitionId) - PartitionIdOrBuilder { -private static final long serialVersionUID = 0L; - // Use PartitionId.newBuilder() to construct. - private PartitionId(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private PartitionId() { - projectId_ = ""; - namespaceId_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private PartitionId( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 34: { - java.lang.String s = input.readStringRequireUtf8(); - - namespaceId_ = s; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_PartitionId_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_PartitionId_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PartitionId.class, com.google.privacy.dlp.v2beta1.PartitionId.Builder.class); - } - - public static final int PROJECT_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object projectId_; - /** - *
-   * The ID of the project to which the entities belong.
-   * 
- * - * string project_id = 2; - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - *
-   * The ID of the project to which the entities belong.
-   * 
- * - * string project_id = 2; - */ - public com.google.protobuf.ByteString - getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int NAMESPACE_ID_FIELD_NUMBER = 4; - private volatile java.lang.Object namespaceId_; - /** - *
-   * If not empty, the ID of the namespace to which the entities belong.
-   * 
- * - * string namespace_id = 4; - */ - public java.lang.String getNamespaceId() { - java.lang.Object ref = namespaceId_; - 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(); - namespaceId_ = s; - return s; - } - } - /** - *
-   * If not empty, the ID of the namespace to which the entities belong.
-   * 
- * - * string namespace_id = 4; - */ - public com.google.protobuf.ByteString - getNamespaceIdBytes() { - java.lang.Object ref = namespaceId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - namespaceId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getProjectIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, projectId_); - } - if (!getNamespaceIdBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, namespaceId_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getProjectIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, projectId_); - } - if (!getNamespaceIdBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, namespaceId_); - } - 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.privacy.dlp.v2beta1.PartitionId)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.PartitionId other = (com.google.privacy.dlp.v2beta1.PartitionId) obj; - - boolean result = true; - result = result && getProjectId() - .equals(other.getProjectId()); - result = result && getNamespaceId() - .equals(other.getNamespaceId()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + NAMESPACE_ID_FIELD_NUMBER; - hash = (53 * hash) + getNamespaceId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.PartitionId parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PartitionId parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PartitionId parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PartitionId 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.privacy.dlp.v2beta1.PartitionId parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PartitionId parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PartitionId parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PartitionId 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.privacy.dlp.v2beta1.PartitionId parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PartitionId 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.privacy.dlp.v2beta1.PartitionId parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PartitionId parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PartitionId prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Datastore partition ID.
-   * A partition ID identifies a grouping of entities. The grouping is always
-   * by project and namespace, however the namespace ID may be empty.
-   * A partition ID contains several dimensions:
-   * project ID and namespace ID.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PartitionId} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PartitionId) - com.google.privacy.dlp.v2beta1.PartitionIdOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_PartitionId_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_PartitionId_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PartitionId.class, com.google.privacy.dlp.v2beta1.PartitionId.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.PartitionId.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - projectId_ = ""; - - namespaceId_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_PartitionId_descriptor; - } - - public com.google.privacy.dlp.v2beta1.PartitionId getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.PartitionId.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.PartitionId build() { - com.google.privacy.dlp.v2beta1.PartitionId result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.PartitionId buildPartial() { - com.google.privacy.dlp.v2beta1.PartitionId result = new com.google.privacy.dlp.v2beta1.PartitionId(this); - result.projectId_ = projectId_; - result.namespaceId_ = namespaceId_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.PartitionId) { - return mergeFrom((com.google.privacy.dlp.v2beta1.PartitionId)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PartitionId other) { - if (other == com.google.privacy.dlp.v2beta1.PartitionId.getDefaultInstance()) return this; - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getNamespaceId().isEmpty()) { - namespaceId_ = other.namespaceId_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.PartitionId parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.PartitionId) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object projectId_ = ""; - /** - *
-     * The ID of the project to which the entities belong.
-     * 
- * - * string project_id = 2; - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * The ID of the project to which the entities belong.
-     * 
- * - * string project_id = 2; - */ - public com.google.protobuf.ByteString - getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * The ID of the project to which the entities belong.
-     * 
- * - * string project_id = 2; - */ - public Builder setProjectId( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - *
-     * The ID of the project to which the entities belong.
-     * 
- * - * string project_id = 2; - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - *
-     * The ID of the project to which the entities belong.
-     * 
- * - * string project_id = 2; - */ - public Builder setProjectIdBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object namespaceId_ = ""; - /** - *
-     * If not empty, the ID of the namespace to which the entities belong.
-     * 
- * - * string namespace_id = 4; - */ - public java.lang.String getNamespaceId() { - java.lang.Object ref = namespaceId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - namespaceId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * If not empty, the ID of the namespace to which the entities belong.
-     * 
- * - * string namespace_id = 4; - */ - public com.google.protobuf.ByteString - getNamespaceIdBytes() { - java.lang.Object ref = namespaceId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - namespaceId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * If not empty, the ID of the namespace to which the entities belong.
-     * 
- * - * string namespace_id = 4; - */ - public Builder setNamespaceId( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - namespaceId_ = value; - onChanged(); - return this; - } - /** - *
-     * If not empty, the ID of the namespace to which the entities belong.
-     * 
- * - * string namespace_id = 4; - */ - public Builder clearNamespaceId() { - - namespaceId_ = getDefaultInstance().getNamespaceId(); - onChanged(); - return this; - } - /** - *
-     * If not empty, the ID of the namespace to which the entities belong.
-     * 
- * - * string namespace_id = 4; - */ - public Builder setNamespaceIdBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - namespaceId_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PartitionId) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PartitionId) - private static final com.google.privacy.dlp.v2beta1.PartitionId DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PartitionId(); - } - - public static com.google.privacy.dlp.v2beta1.PartitionId getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public PartitionId parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new PartitionId(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.PartitionId getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PartitionIdOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PartitionIdOrBuilder.java deleted file mode 100644 index ae76cc8d0f59..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PartitionIdOrBuilder.java +++ /dev/null @@ -1,45 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface PartitionIdOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PartitionId) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The ID of the project to which the entities belong.
-   * 
- * - * string project_id = 2; - */ - java.lang.String getProjectId(); - /** - *
-   * The ID of the project to which the entities belong.
-   * 
- * - * string project_id = 2; - */ - com.google.protobuf.ByteString - getProjectIdBytes(); - - /** - *
-   * If not empty, the ID of the namespace to which the entities belong.
-   * 
- * - * string namespace_id = 4; - */ - java.lang.String getNamespaceId(); - /** - *
-   * If not empty, the ID of the namespace to which the entities belong.
-   * 
- * - * string namespace_id = 4; - */ - com.google.protobuf.ByteString - getNamespaceIdBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrimitiveTransformation.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrimitiveTransformation.java deleted file mode 100644 index 84d582ba587f..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrimitiveTransformation.java +++ /dev/null @@ -1,2301 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * A rule for transforming a value.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrimitiveTransformation} - */ -public final class PrimitiveTransformation extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrimitiveTransformation) - PrimitiveTransformationOrBuilder { -private static final long serialVersionUID = 0L; - // Use PrimitiveTransformation.newBuilder() to construct. - private PrimitiveTransformation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private PrimitiveTransformation() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private PrimitiveTransformation( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.ReplaceValueConfig.Builder subBuilder = null; - if (transformationCase_ == 1) { - subBuilder = ((com.google.privacy.dlp.v2beta1.ReplaceValueConfig) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.ReplaceValueConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.ReplaceValueConfig) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 1; - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.RedactConfig.Builder subBuilder = null; - if (transformationCase_ == 2) { - subBuilder = ((com.google.privacy.dlp.v2beta1.RedactConfig) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.RedactConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.RedactConfig) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 2; - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.CharacterMaskConfig.Builder subBuilder = null; - if (transformationCase_ == 3) { - subBuilder = ((com.google.privacy.dlp.v2beta1.CharacterMaskConfig) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.CharacterMaskConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.CharacterMaskConfig) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 3; - break; - } - case 34: { - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.Builder subBuilder = null; - if (transformationCase_ == 4) { - subBuilder = ((com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 4; - break; - } - case 42: { - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.Builder subBuilder = null; - if (transformationCase_ == 5) { - subBuilder = ((com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 5; - break; - } - case 50: { - com.google.privacy.dlp.v2beta1.BucketingConfig.Builder subBuilder = null; - if (transformationCase_ == 6) { - subBuilder = ((com.google.privacy.dlp.v2beta1.BucketingConfig) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.BucketingConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.BucketingConfig) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 6; - break; - } - case 58: { - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.Builder subBuilder = null; - if (transformationCase_ == 7) { - subBuilder = ((com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 7; - break; - } - case 66: { - com.google.privacy.dlp.v2beta1.TimePartConfig.Builder subBuilder = null; - if (transformationCase_ == 8) { - subBuilder = ((com.google.privacy.dlp.v2beta1.TimePartConfig) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.TimePartConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.TimePartConfig) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 8; - break; - } - case 74: { - com.google.privacy.dlp.v2beta1.CryptoHashConfig.Builder subBuilder = null; - if (transformationCase_ == 9) { - subBuilder = ((com.google.privacy.dlp.v2beta1.CryptoHashConfig) transformation_).toBuilder(); - } - transformation_ = - input.readMessage(com.google.privacy.dlp.v2beta1.CryptoHashConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.CryptoHashConfig) transformation_); - transformation_ = subBuilder.buildPartial(); - } - transformationCase_ = 9; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrimitiveTransformation_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrimitiveTransformation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.class, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder.class); - } - - private int transformationCase_ = 0; - private java.lang.Object transformation_; - public enum TransformationCase - implements com.google.protobuf.Internal.EnumLite { - REPLACE_CONFIG(1), - REDACT_CONFIG(2), - CHARACTER_MASK_CONFIG(3), - CRYPTO_REPLACE_FFX_FPE_CONFIG(4), - FIXED_SIZE_BUCKETING_CONFIG(5), - BUCKETING_CONFIG(6), - REPLACE_WITH_INFO_TYPE_CONFIG(7), - TIME_PART_CONFIG(8), - CRYPTO_HASH_CONFIG(9), - TRANSFORMATION_NOT_SET(0); - private final int value; - private TransformationCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TransformationCase valueOf(int value) { - return forNumber(value); - } - - public static TransformationCase forNumber(int value) { - switch (value) { - case 1: return REPLACE_CONFIG; - case 2: return REDACT_CONFIG; - case 3: return CHARACTER_MASK_CONFIG; - case 4: return CRYPTO_REPLACE_FFX_FPE_CONFIG; - case 5: return FIXED_SIZE_BUCKETING_CONFIG; - case 6: return BUCKETING_CONFIG; - case 7: return REPLACE_WITH_INFO_TYPE_CONFIG; - case 8: return TIME_PART_CONFIG; - case 9: return CRYPTO_HASH_CONFIG; - case 0: return TRANSFORMATION_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TransformationCase - getTransformationCase() { - return TransformationCase.forNumber( - transformationCase_); - } - - public static final int REPLACE_CONFIG_FIELD_NUMBER = 1; - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public boolean hasReplaceConfig() { - return transformationCase_ == 1; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public com.google.privacy.dlp.v2beta1.ReplaceValueConfig getReplaceConfig() { - if (transformationCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.ReplaceValueConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.ReplaceValueConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public com.google.privacy.dlp.v2beta1.ReplaceValueConfigOrBuilder getReplaceConfigOrBuilder() { - if (transformationCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.ReplaceValueConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.ReplaceValueConfig.getDefaultInstance(); - } - - public static final int REDACT_CONFIG_FIELD_NUMBER = 2; - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public boolean hasRedactConfig() { - return transformationCase_ == 2; - } - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public com.google.privacy.dlp.v2beta1.RedactConfig getRedactConfig() { - if (transformationCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.RedactConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.RedactConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public com.google.privacy.dlp.v2beta1.RedactConfigOrBuilder getRedactConfigOrBuilder() { - if (transformationCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.RedactConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.RedactConfig.getDefaultInstance(); - } - - public static final int CHARACTER_MASK_CONFIG_FIELD_NUMBER = 3; - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public boolean hasCharacterMaskConfig() { - return transformationCase_ == 3; - } - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public com.google.privacy.dlp.v2beta1.CharacterMaskConfig getCharacterMaskConfig() { - if (transformationCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.CharacterMaskConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CharacterMaskConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public com.google.privacy.dlp.v2beta1.CharacterMaskConfigOrBuilder getCharacterMaskConfigOrBuilder() { - if (transformationCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.CharacterMaskConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CharacterMaskConfig.getDefaultInstance(); - } - - public static final int CRYPTO_REPLACE_FFX_FPE_CONFIG_FIELD_NUMBER = 4; - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public boolean hasCryptoReplaceFfxFpeConfig() { - return transformationCase_ == 4; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig getCryptoReplaceFfxFpeConfig() { - if (transformationCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfigOrBuilder getCryptoReplaceFfxFpeConfigOrBuilder() { - if (transformationCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.getDefaultInstance(); - } - - public static final int FIXED_SIZE_BUCKETING_CONFIG_FIELD_NUMBER = 5; - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public boolean hasFixedSizeBucketingConfig() { - return transformationCase_ == 5; - } - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig getFixedSizeBucketingConfig() { - if (transformationCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfigOrBuilder getFixedSizeBucketingConfigOrBuilder() { - if (transformationCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.getDefaultInstance(); - } - - public static final int BUCKETING_CONFIG_FIELD_NUMBER = 6; - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public boolean hasBucketingConfig() { - return transformationCase_ == 6; - } - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfig getBucketingConfig() { - if (transformationCase_ == 6) { - return (com.google.privacy.dlp.v2beta1.BucketingConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.BucketingConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfigOrBuilder getBucketingConfigOrBuilder() { - if (transformationCase_ == 6) { - return (com.google.privacy.dlp.v2beta1.BucketingConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.BucketingConfig.getDefaultInstance(); - } - - public static final int REPLACE_WITH_INFO_TYPE_CONFIG_FIELD_NUMBER = 7; - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public boolean hasReplaceWithInfoTypeConfig() { - return transformationCase_ == 7; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig getReplaceWithInfoTypeConfig() { - if (transformationCase_ == 7) { - return (com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfigOrBuilder getReplaceWithInfoTypeConfigOrBuilder() { - if (transformationCase_ == 7) { - return (com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.getDefaultInstance(); - } - - public static final int TIME_PART_CONFIG_FIELD_NUMBER = 8; - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public boolean hasTimePartConfig() { - return transformationCase_ == 8; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public com.google.privacy.dlp.v2beta1.TimePartConfig getTimePartConfig() { - if (transformationCase_ == 8) { - return (com.google.privacy.dlp.v2beta1.TimePartConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.TimePartConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public com.google.privacy.dlp.v2beta1.TimePartConfigOrBuilder getTimePartConfigOrBuilder() { - if (transformationCase_ == 8) { - return (com.google.privacy.dlp.v2beta1.TimePartConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.TimePartConfig.getDefaultInstance(); - } - - public static final int CRYPTO_HASH_CONFIG_FIELD_NUMBER = 9; - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public boolean hasCryptoHashConfig() { - return transformationCase_ == 9; - } - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public com.google.privacy.dlp.v2beta1.CryptoHashConfig getCryptoHashConfig() { - if (transformationCase_ == 9) { - return (com.google.privacy.dlp.v2beta1.CryptoHashConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CryptoHashConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public com.google.privacy.dlp.v2beta1.CryptoHashConfigOrBuilder getCryptoHashConfigOrBuilder() { - if (transformationCase_ == 9) { - return (com.google.privacy.dlp.v2beta1.CryptoHashConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CryptoHashConfig.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (transformationCase_ == 1) { - output.writeMessage(1, (com.google.privacy.dlp.v2beta1.ReplaceValueConfig) transformation_); - } - if (transformationCase_ == 2) { - output.writeMessage(2, (com.google.privacy.dlp.v2beta1.RedactConfig) transformation_); - } - if (transformationCase_ == 3) { - output.writeMessage(3, (com.google.privacy.dlp.v2beta1.CharacterMaskConfig) transformation_); - } - if (transformationCase_ == 4) { - output.writeMessage(4, (com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) transformation_); - } - if (transformationCase_ == 5) { - output.writeMessage(5, (com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) transformation_); - } - if (transformationCase_ == 6) { - output.writeMessage(6, (com.google.privacy.dlp.v2beta1.BucketingConfig) transformation_); - } - if (transformationCase_ == 7) { - output.writeMessage(7, (com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) transformation_); - } - if (transformationCase_ == 8) { - output.writeMessage(8, (com.google.privacy.dlp.v2beta1.TimePartConfig) transformation_); - } - if (transformationCase_ == 9) { - output.writeMessage(9, (com.google.privacy.dlp.v2beta1.CryptoHashConfig) transformation_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (transformationCase_ == 1) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, (com.google.privacy.dlp.v2beta1.ReplaceValueConfig) transformation_); - } - if (transformationCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, (com.google.privacy.dlp.v2beta1.RedactConfig) transformation_); - } - if (transformationCase_ == 3) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, (com.google.privacy.dlp.v2beta1.CharacterMaskConfig) transformation_); - } - if (transformationCase_ == 4) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, (com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) transformation_); - } - if (transformationCase_ == 5) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, (com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) transformation_); - } - if (transformationCase_ == 6) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, (com.google.privacy.dlp.v2beta1.BucketingConfig) transformation_); - } - if (transformationCase_ == 7) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(7, (com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) transformation_); - } - if (transformationCase_ == 8) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(8, (com.google.privacy.dlp.v2beta1.TimePartConfig) transformation_); - } - if (transformationCase_ == 9) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(9, (com.google.privacy.dlp.v2beta1.CryptoHashConfig) transformation_); - } - 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.privacy.dlp.v2beta1.PrimitiveTransformation)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.PrimitiveTransformation other = (com.google.privacy.dlp.v2beta1.PrimitiveTransformation) obj; - - boolean result = true; - result = result && getTransformationCase().equals( - other.getTransformationCase()); - if (!result) return false; - switch (transformationCase_) { - case 1: - result = result && getReplaceConfig() - .equals(other.getReplaceConfig()); - break; - case 2: - result = result && getRedactConfig() - .equals(other.getRedactConfig()); - break; - case 3: - result = result && getCharacterMaskConfig() - .equals(other.getCharacterMaskConfig()); - break; - case 4: - result = result && getCryptoReplaceFfxFpeConfig() - .equals(other.getCryptoReplaceFfxFpeConfig()); - break; - case 5: - result = result && getFixedSizeBucketingConfig() - .equals(other.getFixedSizeBucketingConfig()); - break; - case 6: - result = result && getBucketingConfig() - .equals(other.getBucketingConfig()); - break; - case 7: - result = result && getReplaceWithInfoTypeConfig() - .equals(other.getReplaceWithInfoTypeConfig()); - break; - case 8: - result = result && getTimePartConfig() - .equals(other.getTimePartConfig()); - break; - case 9: - result = result && getCryptoHashConfig() - .equals(other.getCryptoHashConfig()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (transformationCase_) { - case 1: - hash = (37 * hash) + REPLACE_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getReplaceConfig().hashCode(); - break; - case 2: - hash = (37 * hash) + REDACT_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getRedactConfig().hashCode(); - break; - case 3: - hash = (37 * hash) + CHARACTER_MASK_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getCharacterMaskConfig().hashCode(); - break; - case 4: - hash = (37 * hash) + CRYPTO_REPLACE_FFX_FPE_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getCryptoReplaceFfxFpeConfig().hashCode(); - break; - case 5: - hash = (37 * hash) + FIXED_SIZE_BUCKETING_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getFixedSizeBucketingConfig().hashCode(); - break; - case 6: - hash = (37 * hash) + BUCKETING_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getBucketingConfig().hashCode(); - break; - case 7: - hash = (37 * hash) + REPLACE_WITH_INFO_TYPE_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getReplaceWithInfoTypeConfig().hashCode(); - break; - case 8: - hash = (37 * hash) + TIME_PART_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getTimePartConfig().hashCode(); - break; - case 9: - hash = (37 * hash) + CRYPTO_HASH_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getCryptoHashConfig().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.PrimitiveTransformation parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrimitiveTransformation parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrimitiveTransformation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrimitiveTransformation 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.privacy.dlp.v2beta1.PrimitiveTransformation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrimitiveTransformation parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrimitiveTransformation parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrimitiveTransformation 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.privacy.dlp.v2beta1.PrimitiveTransformation parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrimitiveTransformation 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.privacy.dlp.v2beta1.PrimitiveTransformation parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrimitiveTransformation parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrimitiveTransformation prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * A rule for transforming a value.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrimitiveTransformation} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrimitiveTransformation) - com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrimitiveTransformation_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrimitiveTransformation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.class, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.PrimitiveTransformation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - transformationCase_ = 0; - transformation_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrimitiveTransformation_descriptor; - } - - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation build() { - com.google.privacy.dlp.v2beta1.PrimitiveTransformation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation buildPartial() { - com.google.privacy.dlp.v2beta1.PrimitiveTransformation result = new com.google.privacy.dlp.v2beta1.PrimitiveTransformation(this); - if (transformationCase_ == 1) { - if (replaceConfigBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = replaceConfigBuilder_.build(); - } - } - if (transformationCase_ == 2) { - if (redactConfigBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = redactConfigBuilder_.build(); - } - } - if (transformationCase_ == 3) { - if (characterMaskConfigBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = characterMaskConfigBuilder_.build(); - } - } - if (transformationCase_ == 4) { - if (cryptoReplaceFfxFpeConfigBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = cryptoReplaceFfxFpeConfigBuilder_.build(); - } - } - if (transformationCase_ == 5) { - if (fixedSizeBucketingConfigBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = fixedSizeBucketingConfigBuilder_.build(); - } - } - if (transformationCase_ == 6) { - if (bucketingConfigBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = bucketingConfigBuilder_.build(); - } - } - if (transformationCase_ == 7) { - if (replaceWithInfoTypeConfigBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = replaceWithInfoTypeConfigBuilder_.build(); - } - } - if (transformationCase_ == 8) { - if (timePartConfigBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = timePartConfigBuilder_.build(); - } - } - if (transformationCase_ == 9) { - if (cryptoHashConfigBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = cryptoHashConfigBuilder_.build(); - } - } - result.transformationCase_ = transformationCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.PrimitiveTransformation) { - return mergeFrom((com.google.privacy.dlp.v2beta1.PrimitiveTransformation)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrimitiveTransformation other) { - if (other == com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance()) return this; - switch (other.getTransformationCase()) { - case REPLACE_CONFIG: { - mergeReplaceConfig(other.getReplaceConfig()); - break; - } - case REDACT_CONFIG: { - mergeRedactConfig(other.getRedactConfig()); - break; - } - case CHARACTER_MASK_CONFIG: { - mergeCharacterMaskConfig(other.getCharacterMaskConfig()); - break; - } - case CRYPTO_REPLACE_FFX_FPE_CONFIG: { - mergeCryptoReplaceFfxFpeConfig(other.getCryptoReplaceFfxFpeConfig()); - break; - } - case FIXED_SIZE_BUCKETING_CONFIG: { - mergeFixedSizeBucketingConfig(other.getFixedSizeBucketingConfig()); - break; - } - case BUCKETING_CONFIG: { - mergeBucketingConfig(other.getBucketingConfig()); - break; - } - case REPLACE_WITH_INFO_TYPE_CONFIG: { - mergeReplaceWithInfoTypeConfig(other.getReplaceWithInfoTypeConfig()); - break; - } - case TIME_PART_CONFIG: { - mergeTimePartConfig(other.getTimePartConfig()); - break; - } - case CRYPTO_HASH_CONFIG: { - mergeCryptoHashConfig(other.getCryptoHashConfig()); - break; - } - case TRANSFORMATION_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.PrimitiveTransformation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.PrimitiveTransformation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int transformationCase_ = 0; - private java.lang.Object transformation_; - public TransformationCase - getTransformationCase() { - return TransformationCase.forNumber( - transformationCase_); - } - - public Builder clearTransformation() { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - return this; - } - - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ReplaceValueConfig, com.google.privacy.dlp.v2beta1.ReplaceValueConfig.Builder, com.google.privacy.dlp.v2beta1.ReplaceValueConfigOrBuilder> replaceConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public boolean hasReplaceConfig() { - return transformationCase_ == 1; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public com.google.privacy.dlp.v2beta1.ReplaceValueConfig getReplaceConfig() { - if (replaceConfigBuilder_ == null) { - if (transformationCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.ReplaceValueConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.ReplaceValueConfig.getDefaultInstance(); - } else { - if (transformationCase_ == 1) { - return replaceConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.ReplaceValueConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public Builder setReplaceConfig(com.google.privacy.dlp.v2beta1.ReplaceValueConfig value) { - if (replaceConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - replaceConfigBuilder_.setMessage(value); - } - transformationCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public Builder setReplaceConfig( - com.google.privacy.dlp.v2beta1.ReplaceValueConfig.Builder builderForValue) { - if (replaceConfigBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - replaceConfigBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public Builder mergeReplaceConfig(com.google.privacy.dlp.v2beta1.ReplaceValueConfig value) { - if (replaceConfigBuilder_ == null) { - if (transformationCase_ == 1 && - transformation_ != com.google.privacy.dlp.v2beta1.ReplaceValueConfig.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.ReplaceValueConfig.newBuilder((com.google.privacy.dlp.v2beta1.ReplaceValueConfig) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 1) { - replaceConfigBuilder_.mergeFrom(value); - } - replaceConfigBuilder_.setMessage(value); - } - transformationCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public Builder clearReplaceConfig() { - if (replaceConfigBuilder_ == null) { - if (transformationCase_ == 1) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 1) { - transformationCase_ = 0; - transformation_ = null; - } - replaceConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public com.google.privacy.dlp.v2beta1.ReplaceValueConfig.Builder getReplaceConfigBuilder() { - return getReplaceConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - public com.google.privacy.dlp.v2beta1.ReplaceValueConfigOrBuilder getReplaceConfigOrBuilder() { - if ((transformationCase_ == 1) && (replaceConfigBuilder_ != null)) { - return replaceConfigBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.ReplaceValueConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.ReplaceValueConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ReplaceValueConfig, com.google.privacy.dlp.v2beta1.ReplaceValueConfig.Builder, com.google.privacy.dlp.v2beta1.ReplaceValueConfigOrBuilder> - getReplaceConfigFieldBuilder() { - if (replaceConfigBuilder_ == null) { - if (!(transformationCase_ == 1)) { - transformation_ = com.google.privacy.dlp.v2beta1.ReplaceValueConfig.getDefaultInstance(); - } - replaceConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ReplaceValueConfig, com.google.privacy.dlp.v2beta1.ReplaceValueConfig.Builder, com.google.privacy.dlp.v2beta1.ReplaceValueConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.ReplaceValueConfig) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 1; - onChanged();; - return replaceConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RedactConfig, com.google.privacy.dlp.v2beta1.RedactConfig.Builder, com.google.privacy.dlp.v2beta1.RedactConfigOrBuilder> redactConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public boolean hasRedactConfig() { - return transformationCase_ == 2; - } - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public com.google.privacy.dlp.v2beta1.RedactConfig getRedactConfig() { - if (redactConfigBuilder_ == null) { - if (transformationCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.RedactConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.RedactConfig.getDefaultInstance(); - } else { - if (transformationCase_ == 2) { - return redactConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.RedactConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public Builder setRedactConfig(com.google.privacy.dlp.v2beta1.RedactConfig value) { - if (redactConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - redactConfigBuilder_.setMessage(value); - } - transformationCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public Builder setRedactConfig( - com.google.privacy.dlp.v2beta1.RedactConfig.Builder builderForValue) { - if (redactConfigBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - redactConfigBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public Builder mergeRedactConfig(com.google.privacy.dlp.v2beta1.RedactConfig value) { - if (redactConfigBuilder_ == null) { - if (transformationCase_ == 2 && - transformation_ != com.google.privacy.dlp.v2beta1.RedactConfig.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.RedactConfig.newBuilder((com.google.privacy.dlp.v2beta1.RedactConfig) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 2) { - redactConfigBuilder_.mergeFrom(value); - } - redactConfigBuilder_.setMessage(value); - } - transformationCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public Builder clearRedactConfig() { - if (redactConfigBuilder_ == null) { - if (transformationCase_ == 2) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 2) { - transformationCase_ = 0; - transformation_ = null; - } - redactConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public com.google.privacy.dlp.v2beta1.RedactConfig.Builder getRedactConfigBuilder() { - return getRedactConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - public com.google.privacy.dlp.v2beta1.RedactConfigOrBuilder getRedactConfigOrBuilder() { - if ((transformationCase_ == 2) && (redactConfigBuilder_ != null)) { - return redactConfigBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.RedactConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.RedactConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RedactConfig, com.google.privacy.dlp.v2beta1.RedactConfig.Builder, com.google.privacy.dlp.v2beta1.RedactConfigOrBuilder> - getRedactConfigFieldBuilder() { - if (redactConfigBuilder_ == null) { - if (!(transformationCase_ == 2)) { - transformation_ = com.google.privacy.dlp.v2beta1.RedactConfig.getDefaultInstance(); - } - redactConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RedactConfig, com.google.privacy.dlp.v2beta1.RedactConfig.Builder, com.google.privacy.dlp.v2beta1.RedactConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.RedactConfig) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 2; - onChanged();; - return redactConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CharacterMaskConfig, com.google.privacy.dlp.v2beta1.CharacterMaskConfig.Builder, com.google.privacy.dlp.v2beta1.CharacterMaskConfigOrBuilder> characterMaskConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public boolean hasCharacterMaskConfig() { - return transformationCase_ == 3; - } - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public com.google.privacy.dlp.v2beta1.CharacterMaskConfig getCharacterMaskConfig() { - if (characterMaskConfigBuilder_ == null) { - if (transformationCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.CharacterMaskConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CharacterMaskConfig.getDefaultInstance(); - } else { - if (transformationCase_ == 3) { - return characterMaskConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.CharacterMaskConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public Builder setCharacterMaskConfig(com.google.privacy.dlp.v2beta1.CharacterMaskConfig value) { - if (characterMaskConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - characterMaskConfigBuilder_.setMessage(value); - } - transformationCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public Builder setCharacterMaskConfig( - com.google.privacy.dlp.v2beta1.CharacterMaskConfig.Builder builderForValue) { - if (characterMaskConfigBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - characterMaskConfigBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public Builder mergeCharacterMaskConfig(com.google.privacy.dlp.v2beta1.CharacterMaskConfig value) { - if (characterMaskConfigBuilder_ == null) { - if (transformationCase_ == 3 && - transformation_ != com.google.privacy.dlp.v2beta1.CharacterMaskConfig.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.CharacterMaskConfig.newBuilder((com.google.privacy.dlp.v2beta1.CharacterMaskConfig) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 3) { - characterMaskConfigBuilder_.mergeFrom(value); - } - characterMaskConfigBuilder_.setMessage(value); - } - transformationCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public Builder clearCharacterMaskConfig() { - if (characterMaskConfigBuilder_ == null) { - if (transformationCase_ == 3) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 3) { - transformationCase_ = 0; - transformation_ = null; - } - characterMaskConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public com.google.privacy.dlp.v2beta1.CharacterMaskConfig.Builder getCharacterMaskConfigBuilder() { - return getCharacterMaskConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - public com.google.privacy.dlp.v2beta1.CharacterMaskConfigOrBuilder getCharacterMaskConfigOrBuilder() { - if ((transformationCase_ == 3) && (characterMaskConfigBuilder_ != null)) { - return characterMaskConfigBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.CharacterMaskConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CharacterMaskConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CharacterMaskConfig, com.google.privacy.dlp.v2beta1.CharacterMaskConfig.Builder, com.google.privacy.dlp.v2beta1.CharacterMaskConfigOrBuilder> - getCharacterMaskConfigFieldBuilder() { - if (characterMaskConfigBuilder_ == null) { - if (!(transformationCase_ == 3)) { - transformation_ = com.google.privacy.dlp.v2beta1.CharacterMaskConfig.getDefaultInstance(); - } - characterMaskConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CharacterMaskConfig, com.google.privacy.dlp.v2beta1.CharacterMaskConfig.Builder, com.google.privacy.dlp.v2beta1.CharacterMaskConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.CharacterMaskConfig) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 3; - onChanged();; - return characterMaskConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig, com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.Builder, com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfigOrBuilder> cryptoReplaceFfxFpeConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public boolean hasCryptoReplaceFfxFpeConfig() { - return transformationCase_ == 4; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig getCryptoReplaceFfxFpeConfig() { - if (cryptoReplaceFfxFpeConfigBuilder_ == null) { - if (transformationCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.getDefaultInstance(); - } else { - if (transformationCase_ == 4) { - return cryptoReplaceFfxFpeConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public Builder setCryptoReplaceFfxFpeConfig(com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig value) { - if (cryptoReplaceFfxFpeConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - cryptoReplaceFfxFpeConfigBuilder_.setMessage(value); - } - transformationCase_ = 4; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public Builder setCryptoReplaceFfxFpeConfig( - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.Builder builderForValue) { - if (cryptoReplaceFfxFpeConfigBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - cryptoReplaceFfxFpeConfigBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 4; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public Builder mergeCryptoReplaceFfxFpeConfig(com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig value) { - if (cryptoReplaceFfxFpeConfigBuilder_ == null) { - if (transformationCase_ == 4 && - transformation_ != com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.newBuilder((com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 4) { - cryptoReplaceFfxFpeConfigBuilder_.mergeFrom(value); - } - cryptoReplaceFfxFpeConfigBuilder_.setMessage(value); - } - transformationCase_ = 4; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public Builder clearCryptoReplaceFfxFpeConfig() { - if (cryptoReplaceFfxFpeConfigBuilder_ == null) { - if (transformationCase_ == 4) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 4) { - transformationCase_ = 0; - transformation_ = null; - } - cryptoReplaceFfxFpeConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.Builder getCryptoReplaceFfxFpeConfigBuilder() { - return getCryptoReplaceFfxFpeConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - public com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfigOrBuilder getCryptoReplaceFfxFpeConfigOrBuilder() { - if ((transformationCase_ == 4) && (cryptoReplaceFfxFpeConfigBuilder_ != null)) { - return cryptoReplaceFfxFpeConfigBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig, com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.Builder, com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfigOrBuilder> - getCryptoReplaceFfxFpeConfigFieldBuilder() { - if (cryptoReplaceFfxFpeConfigBuilder_ == null) { - if (!(transformationCase_ == 4)) { - transformation_ = com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.getDefaultInstance(); - } - cryptoReplaceFfxFpeConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig, com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig.Builder, com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 4; - onChanged();; - return cryptoReplaceFfxFpeConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig, com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.Builder, com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfigOrBuilder> fixedSizeBucketingConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public boolean hasFixedSizeBucketingConfig() { - return transformationCase_ == 5; - } - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig getFixedSizeBucketingConfig() { - if (fixedSizeBucketingConfigBuilder_ == null) { - if (transformationCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.getDefaultInstance(); - } else { - if (transformationCase_ == 5) { - return fixedSizeBucketingConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public Builder setFixedSizeBucketingConfig(com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig value) { - if (fixedSizeBucketingConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - fixedSizeBucketingConfigBuilder_.setMessage(value); - } - transformationCase_ = 5; - return this; - } - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public Builder setFixedSizeBucketingConfig( - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.Builder builderForValue) { - if (fixedSizeBucketingConfigBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - fixedSizeBucketingConfigBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 5; - return this; - } - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public Builder mergeFixedSizeBucketingConfig(com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig value) { - if (fixedSizeBucketingConfigBuilder_ == null) { - if (transformationCase_ == 5 && - transformation_ != com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.newBuilder((com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 5) { - fixedSizeBucketingConfigBuilder_.mergeFrom(value); - } - fixedSizeBucketingConfigBuilder_.setMessage(value); - } - transformationCase_ = 5; - return this; - } - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public Builder clearFixedSizeBucketingConfig() { - if (fixedSizeBucketingConfigBuilder_ == null) { - if (transformationCase_ == 5) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 5) { - transformationCase_ = 0; - transformation_ = null; - } - fixedSizeBucketingConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.Builder getFixedSizeBucketingConfigBuilder() { - return getFixedSizeBucketingConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - public com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfigOrBuilder getFixedSizeBucketingConfigOrBuilder() { - if ((transformationCase_ == 5) && (fixedSizeBucketingConfigBuilder_ != null)) { - return fixedSizeBucketingConfigBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig, com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.Builder, com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfigOrBuilder> - getFixedSizeBucketingConfigFieldBuilder() { - if (fixedSizeBucketingConfigBuilder_ == null) { - if (!(transformationCase_ == 5)) { - transformation_ = com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.getDefaultInstance(); - } - fixedSizeBucketingConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig, com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig.Builder, com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 5; - onChanged();; - return fixedSizeBucketingConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BucketingConfig, com.google.privacy.dlp.v2beta1.BucketingConfig.Builder, com.google.privacy.dlp.v2beta1.BucketingConfigOrBuilder> bucketingConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public boolean hasBucketingConfig() { - return transformationCase_ == 6; - } - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfig getBucketingConfig() { - if (bucketingConfigBuilder_ == null) { - if (transformationCase_ == 6) { - return (com.google.privacy.dlp.v2beta1.BucketingConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.BucketingConfig.getDefaultInstance(); - } else { - if (transformationCase_ == 6) { - return bucketingConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.BucketingConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public Builder setBucketingConfig(com.google.privacy.dlp.v2beta1.BucketingConfig value) { - if (bucketingConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - bucketingConfigBuilder_.setMessage(value); - } - transformationCase_ = 6; - return this; - } - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public Builder setBucketingConfig( - com.google.privacy.dlp.v2beta1.BucketingConfig.Builder builderForValue) { - if (bucketingConfigBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - bucketingConfigBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 6; - return this; - } - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public Builder mergeBucketingConfig(com.google.privacy.dlp.v2beta1.BucketingConfig value) { - if (bucketingConfigBuilder_ == null) { - if (transformationCase_ == 6 && - transformation_ != com.google.privacy.dlp.v2beta1.BucketingConfig.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.BucketingConfig.newBuilder((com.google.privacy.dlp.v2beta1.BucketingConfig) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 6) { - bucketingConfigBuilder_.mergeFrom(value); - } - bucketingConfigBuilder_.setMessage(value); - } - transformationCase_ = 6; - return this; - } - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public Builder clearBucketingConfig() { - if (bucketingConfigBuilder_ == null) { - if (transformationCase_ == 6) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 6) { - transformationCase_ = 0; - transformation_ = null; - } - bucketingConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfig.Builder getBucketingConfigBuilder() { - return getBucketingConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - public com.google.privacy.dlp.v2beta1.BucketingConfigOrBuilder getBucketingConfigOrBuilder() { - if ((transformationCase_ == 6) && (bucketingConfigBuilder_ != null)) { - return bucketingConfigBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 6) { - return (com.google.privacy.dlp.v2beta1.BucketingConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.BucketingConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BucketingConfig, com.google.privacy.dlp.v2beta1.BucketingConfig.Builder, com.google.privacy.dlp.v2beta1.BucketingConfigOrBuilder> - getBucketingConfigFieldBuilder() { - if (bucketingConfigBuilder_ == null) { - if (!(transformationCase_ == 6)) { - transformation_ = com.google.privacy.dlp.v2beta1.BucketingConfig.getDefaultInstance(); - } - bucketingConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BucketingConfig, com.google.privacy.dlp.v2beta1.BucketingConfig.Builder, com.google.privacy.dlp.v2beta1.BucketingConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.BucketingConfig) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 6; - onChanged();; - return bucketingConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig, com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.Builder, com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfigOrBuilder> replaceWithInfoTypeConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public boolean hasReplaceWithInfoTypeConfig() { - return transformationCase_ == 7; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig getReplaceWithInfoTypeConfig() { - if (replaceWithInfoTypeConfigBuilder_ == null) { - if (transformationCase_ == 7) { - return (com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.getDefaultInstance(); - } else { - if (transformationCase_ == 7) { - return replaceWithInfoTypeConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public Builder setReplaceWithInfoTypeConfig(com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig value) { - if (replaceWithInfoTypeConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - replaceWithInfoTypeConfigBuilder_.setMessage(value); - } - transformationCase_ = 7; - return this; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public Builder setReplaceWithInfoTypeConfig( - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.Builder builderForValue) { - if (replaceWithInfoTypeConfigBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - replaceWithInfoTypeConfigBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 7; - return this; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public Builder mergeReplaceWithInfoTypeConfig(com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig value) { - if (replaceWithInfoTypeConfigBuilder_ == null) { - if (transformationCase_ == 7 && - transformation_ != com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.newBuilder((com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 7) { - replaceWithInfoTypeConfigBuilder_.mergeFrom(value); - } - replaceWithInfoTypeConfigBuilder_.setMessage(value); - } - transformationCase_ = 7; - return this; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public Builder clearReplaceWithInfoTypeConfig() { - if (replaceWithInfoTypeConfigBuilder_ == null) { - if (transformationCase_ == 7) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 7) { - transformationCase_ = 0; - transformation_ = null; - } - replaceWithInfoTypeConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.Builder getReplaceWithInfoTypeConfigBuilder() { - return getReplaceWithInfoTypeConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - public com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfigOrBuilder getReplaceWithInfoTypeConfigOrBuilder() { - if ((transformationCase_ == 7) && (replaceWithInfoTypeConfigBuilder_ != null)) { - return replaceWithInfoTypeConfigBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 7) { - return (com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig, com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.Builder, com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfigOrBuilder> - getReplaceWithInfoTypeConfigFieldBuilder() { - if (replaceWithInfoTypeConfigBuilder_ == null) { - if (!(transformationCase_ == 7)) { - transformation_ = com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.getDefaultInstance(); - } - replaceWithInfoTypeConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig, com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.Builder, com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 7; - onChanged();; - return replaceWithInfoTypeConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TimePartConfig, com.google.privacy.dlp.v2beta1.TimePartConfig.Builder, com.google.privacy.dlp.v2beta1.TimePartConfigOrBuilder> timePartConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public boolean hasTimePartConfig() { - return transformationCase_ == 8; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public com.google.privacy.dlp.v2beta1.TimePartConfig getTimePartConfig() { - if (timePartConfigBuilder_ == null) { - if (transformationCase_ == 8) { - return (com.google.privacy.dlp.v2beta1.TimePartConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.TimePartConfig.getDefaultInstance(); - } else { - if (transformationCase_ == 8) { - return timePartConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.TimePartConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public Builder setTimePartConfig(com.google.privacy.dlp.v2beta1.TimePartConfig value) { - if (timePartConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - timePartConfigBuilder_.setMessage(value); - } - transformationCase_ = 8; - return this; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public Builder setTimePartConfig( - com.google.privacy.dlp.v2beta1.TimePartConfig.Builder builderForValue) { - if (timePartConfigBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - timePartConfigBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 8; - return this; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public Builder mergeTimePartConfig(com.google.privacy.dlp.v2beta1.TimePartConfig value) { - if (timePartConfigBuilder_ == null) { - if (transformationCase_ == 8 && - transformation_ != com.google.privacy.dlp.v2beta1.TimePartConfig.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.TimePartConfig.newBuilder((com.google.privacy.dlp.v2beta1.TimePartConfig) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 8) { - timePartConfigBuilder_.mergeFrom(value); - } - timePartConfigBuilder_.setMessage(value); - } - transformationCase_ = 8; - return this; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public Builder clearTimePartConfig() { - if (timePartConfigBuilder_ == null) { - if (transformationCase_ == 8) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 8) { - transformationCase_ = 0; - transformation_ = null; - } - timePartConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public com.google.privacy.dlp.v2beta1.TimePartConfig.Builder getTimePartConfigBuilder() { - return getTimePartConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - public com.google.privacy.dlp.v2beta1.TimePartConfigOrBuilder getTimePartConfigOrBuilder() { - if ((transformationCase_ == 8) && (timePartConfigBuilder_ != null)) { - return timePartConfigBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 8) { - return (com.google.privacy.dlp.v2beta1.TimePartConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.TimePartConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TimePartConfig, com.google.privacy.dlp.v2beta1.TimePartConfig.Builder, com.google.privacy.dlp.v2beta1.TimePartConfigOrBuilder> - getTimePartConfigFieldBuilder() { - if (timePartConfigBuilder_ == null) { - if (!(transformationCase_ == 8)) { - transformation_ = com.google.privacy.dlp.v2beta1.TimePartConfig.getDefaultInstance(); - } - timePartConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TimePartConfig, com.google.privacy.dlp.v2beta1.TimePartConfig.Builder, com.google.privacy.dlp.v2beta1.TimePartConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.TimePartConfig) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 8; - onChanged();; - return timePartConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoHashConfig, com.google.privacy.dlp.v2beta1.CryptoHashConfig.Builder, com.google.privacy.dlp.v2beta1.CryptoHashConfigOrBuilder> cryptoHashConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public boolean hasCryptoHashConfig() { - return transformationCase_ == 9; - } - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public com.google.privacy.dlp.v2beta1.CryptoHashConfig getCryptoHashConfig() { - if (cryptoHashConfigBuilder_ == null) { - if (transformationCase_ == 9) { - return (com.google.privacy.dlp.v2beta1.CryptoHashConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CryptoHashConfig.getDefaultInstance(); - } else { - if (transformationCase_ == 9) { - return cryptoHashConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.CryptoHashConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public Builder setCryptoHashConfig(com.google.privacy.dlp.v2beta1.CryptoHashConfig value) { - if (cryptoHashConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - cryptoHashConfigBuilder_.setMessage(value); - } - transformationCase_ = 9; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public Builder setCryptoHashConfig( - com.google.privacy.dlp.v2beta1.CryptoHashConfig.Builder builderForValue) { - if (cryptoHashConfigBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - cryptoHashConfigBuilder_.setMessage(builderForValue.build()); - } - transformationCase_ = 9; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public Builder mergeCryptoHashConfig(com.google.privacy.dlp.v2beta1.CryptoHashConfig value) { - if (cryptoHashConfigBuilder_ == null) { - if (transformationCase_ == 9 && - transformation_ != com.google.privacy.dlp.v2beta1.CryptoHashConfig.getDefaultInstance()) { - transformation_ = com.google.privacy.dlp.v2beta1.CryptoHashConfig.newBuilder((com.google.privacy.dlp.v2beta1.CryptoHashConfig) transformation_) - .mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - if (transformationCase_ == 9) { - cryptoHashConfigBuilder_.mergeFrom(value); - } - cryptoHashConfigBuilder_.setMessage(value); - } - transformationCase_ = 9; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public Builder clearCryptoHashConfig() { - if (cryptoHashConfigBuilder_ == null) { - if (transformationCase_ == 9) { - transformationCase_ = 0; - transformation_ = null; - onChanged(); - } - } else { - if (transformationCase_ == 9) { - transformationCase_ = 0; - transformation_ = null; - } - cryptoHashConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public com.google.privacy.dlp.v2beta1.CryptoHashConfig.Builder getCryptoHashConfigBuilder() { - return getCryptoHashConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - public com.google.privacy.dlp.v2beta1.CryptoHashConfigOrBuilder getCryptoHashConfigOrBuilder() { - if ((transformationCase_ == 9) && (cryptoHashConfigBuilder_ != null)) { - return cryptoHashConfigBuilder_.getMessageOrBuilder(); - } else { - if (transformationCase_ == 9) { - return (com.google.privacy.dlp.v2beta1.CryptoHashConfig) transformation_; - } - return com.google.privacy.dlp.v2beta1.CryptoHashConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoHashConfig, com.google.privacy.dlp.v2beta1.CryptoHashConfig.Builder, com.google.privacy.dlp.v2beta1.CryptoHashConfigOrBuilder> - getCryptoHashConfigFieldBuilder() { - if (cryptoHashConfigBuilder_ == null) { - if (!(transformationCase_ == 9)) { - transformation_ = com.google.privacy.dlp.v2beta1.CryptoHashConfig.getDefaultInstance(); - } - cryptoHashConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CryptoHashConfig, com.google.privacy.dlp.v2beta1.CryptoHashConfig.Builder, com.google.privacy.dlp.v2beta1.CryptoHashConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.CryptoHashConfig) transformation_, - getParentForChildren(), - isClean()); - transformation_ = null; - } - transformationCase_ = 9; - onChanged();; - return cryptoHashConfigBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrimitiveTransformation) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrimitiveTransformation) - private static final com.google.privacy.dlp.v2beta1.PrimitiveTransformation DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrimitiveTransformation(); - } - - public static com.google.privacy.dlp.v2beta1.PrimitiveTransformation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public PrimitiveTransformation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new PrimitiveTransformation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrimitiveTransformationOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrimitiveTransformationOrBuilder.java deleted file mode 100644 index 9c114c8658cf..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrimitiveTransformationOrBuilder.java +++ /dev/null @@ -1,128 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface PrimitiveTransformationOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PrimitiveTransformation) - com.google.protobuf.MessageOrBuilder { - - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - boolean hasReplaceConfig(); - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - com.google.privacy.dlp.v2beta1.ReplaceValueConfig getReplaceConfig(); - /** - * .google.privacy.dlp.v2beta1.ReplaceValueConfig replace_config = 1; - */ - com.google.privacy.dlp.v2beta1.ReplaceValueConfigOrBuilder getReplaceConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - boolean hasRedactConfig(); - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - com.google.privacy.dlp.v2beta1.RedactConfig getRedactConfig(); - /** - * .google.privacy.dlp.v2beta1.RedactConfig redact_config = 2; - */ - com.google.privacy.dlp.v2beta1.RedactConfigOrBuilder getRedactConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - boolean hasCharacterMaskConfig(); - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - com.google.privacy.dlp.v2beta1.CharacterMaskConfig getCharacterMaskConfig(); - /** - * .google.privacy.dlp.v2beta1.CharacterMaskConfig character_mask_config = 3; - */ - com.google.privacy.dlp.v2beta1.CharacterMaskConfigOrBuilder getCharacterMaskConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - boolean hasCryptoReplaceFfxFpeConfig(); - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig getCryptoReplaceFfxFpeConfig(); - /** - * .google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - */ - com.google.privacy.dlp.v2beta1.CryptoReplaceFfxFpeConfigOrBuilder getCryptoReplaceFfxFpeConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - boolean hasFixedSizeBucketingConfig(); - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfig getFixedSizeBucketingConfig(); - /** - * .google.privacy.dlp.v2beta1.FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - */ - com.google.privacy.dlp.v2beta1.FixedSizeBucketingConfigOrBuilder getFixedSizeBucketingConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - boolean hasBucketingConfig(); - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - com.google.privacy.dlp.v2beta1.BucketingConfig getBucketingConfig(); - /** - * .google.privacy.dlp.v2beta1.BucketingConfig bucketing_config = 6; - */ - com.google.privacy.dlp.v2beta1.BucketingConfigOrBuilder getBucketingConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - boolean hasReplaceWithInfoTypeConfig(); - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig getReplaceWithInfoTypeConfig(); - /** - * .google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - */ - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfigOrBuilder getReplaceWithInfoTypeConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - boolean hasTimePartConfig(); - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - com.google.privacy.dlp.v2beta1.TimePartConfig getTimePartConfig(); - /** - * .google.privacy.dlp.v2beta1.TimePartConfig time_part_config = 8; - */ - com.google.privacy.dlp.v2beta1.TimePartConfigOrBuilder getTimePartConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - boolean hasCryptoHashConfig(); - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - com.google.privacy.dlp.v2beta1.CryptoHashConfig getCryptoHashConfig(); - /** - * .google.privacy.dlp.v2beta1.CryptoHashConfig crypto_hash_config = 9; - */ - com.google.privacy.dlp.v2beta1.CryptoHashConfigOrBuilder getCryptoHashConfigOrBuilder(); - - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation.TransformationCase getTransformationCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrivacyMetric.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrivacyMetric.java deleted file mode 100644 index bed00a8b7010..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrivacyMetric.java +++ /dev/null @@ -1,5096 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Privacy metric to compute for reidentification risk analysis.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric} - */ -public final class PrivacyMetric extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrivacyMetric) - PrivacyMetricOrBuilder { -private static final long serialVersionUID = 0L; - // Use PrivacyMetric.newBuilder() to construct. - private PrivacyMetric(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private PrivacyMetric() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private PrivacyMetric( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder subBuilder = null; - if (typeCase_ == 1) { - subBuilder = ((com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 1; - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder subBuilder = null; - if (typeCase_ == 2) { - subBuilder = ((com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 2; - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder subBuilder = null; - if (typeCase_ == 3) { - subBuilder = ((com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 3; - break; - } - case 34: { - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder subBuilder = null; - if (typeCase_ == 4) { - subBuilder = ((com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 4; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrivacyMetric.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder.class); - } - - public interface NumericalStatsConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Field to compute numerical stats on. Supported types are
-     * integer, float, date, datetime, timestamp, time.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - boolean hasField(); - /** - *
-     * Field to compute numerical stats on. Supported types are
-     * integer, float, date, datetime, timestamp, time.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - com.google.privacy.dlp.v2beta1.FieldId getField(); - /** - *
-     * Field to compute numerical stats on. Supported types are
-     * integer, float, date, datetime, timestamp, time.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder(); - } - /** - *
-   * Compute numerical stats over an individual column, including
-   * min, max, and quantiles.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig} - */ - public static final class NumericalStatsConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) - NumericalStatsConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use NumericalStatsConfig.newBuilder() to construct. - private NumericalStatsConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private NumericalStatsConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private NumericalStatsConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null; - if (field_ != null) { - subBuilder = field_.toBuilder(); - } - field_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(field_); - field_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder.class); - } - - public static final int FIELD_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.FieldId field_; - /** - *
-     * Field to compute numerical stats on. Supported types are
-     * integer, float, date, datetime, timestamp, time.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public boolean hasField() { - return field_ != null; - } - /** - *
-     * Field to compute numerical stats on. Supported types are
-     * integer, float, date, datetime, timestamp, time.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getField() { - return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } - /** - *
-     * Field to compute numerical stats on. Supported types are
-     * integer, float, date, datetime, timestamp, time.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() { - return getField(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (field_ != null) { - output.writeMessage(1, getField()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (field_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getField()); - } - 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.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig other = (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) obj; - - boolean result = true; - result = result && (hasField() == other.hasField()); - if (hasField()) { - result = result && getField() - .equals(other.getField()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasField()) { - hash = (37 * hash) + FIELD_FIELD_NUMBER; - hash = (53 * hash) + getField().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * Compute numerical stats over an individual column, including
-     * min, max, and quantiles.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (fieldBuilder_ == null) { - field_ = null; - } else { - field_ = null; - fieldBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig build() { - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig buildPartial() { - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig result = new com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig(this); - if (fieldBuilder_ == null) { - result.field_ = field_; - } else { - result.field_ = fieldBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig other) { - if (other == com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance()) return this; - if (other.hasField()) { - mergeField(other.getField()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.FieldId field_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> fieldBuilder_; - /** - *
-       * Field to compute numerical stats on. Supported types are
-       * integer, float, date, datetime, timestamp, time.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public boolean hasField() { - return fieldBuilder_ != null || field_ != null; - } - /** - *
-       * Field to compute numerical stats on. Supported types are
-       * integer, float, date, datetime, timestamp, time.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getField() { - if (fieldBuilder_ == null) { - return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } else { - return fieldBuilder_.getMessage(); - } - } - /** - *
-       * Field to compute numerical stats on. Supported types are
-       * integer, float, date, datetime, timestamp, time.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder setField(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - field_ = value; - onChanged(); - } else { - fieldBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Field to compute numerical stats on. Supported types are
-       * integer, float, date, datetime, timestamp, time.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder setField( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (fieldBuilder_ == null) { - field_ = builderForValue.build(); - onChanged(); - } else { - fieldBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Field to compute numerical stats on. Supported types are
-       * integer, float, date, datetime, timestamp, time.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder mergeField(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldBuilder_ == null) { - if (field_ != null) { - field_ = - com.google.privacy.dlp.v2beta1.FieldId.newBuilder(field_).mergeFrom(value).buildPartial(); - } else { - field_ = value; - } - onChanged(); - } else { - fieldBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Field to compute numerical stats on. Supported types are
-       * integer, float, date, datetime, timestamp, time.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder clearField() { - if (fieldBuilder_ == null) { - field_ = null; - onChanged(); - } else { - field_ = null; - fieldBuilder_ = null; - } - - return this; - } - /** - *
-       * Field to compute numerical stats on. Supported types are
-       * integer, float, date, datetime, timestamp, time.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getFieldBuilder() { - - onChanged(); - return getFieldFieldBuilder().getBuilder(); - } - /** - *
-       * Field to compute numerical stats on. Supported types are
-       * integer, float, date, datetime, timestamp, time.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() { - if (fieldBuilder_ != null) { - return fieldBuilder_.getMessageOrBuilder(); - } else { - return field_ == null ? - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } - } - /** - *
-       * Field to compute numerical stats on. Supported types are
-       * integer, float, date, datetime, timestamp, time.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getFieldFieldBuilder() { - if (fieldBuilder_ == null) { - fieldBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - getField(), - getParentForChildren(), - isClean()); - field_ = null; - } - return fieldBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) - private static final com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig(); - } - - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public NumericalStatsConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new NumericalStatsConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface CategoricalStatsConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Field to compute categorical stats on. All column types are
-     * supported except for arrays and structs. However, it may be more
-     * informative to use NumericalStats when the field type is supported,
-     * depending on the data.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - boolean hasField(); - /** - *
-     * Field to compute categorical stats on. All column types are
-     * supported except for arrays and structs. However, it may be more
-     * informative to use NumericalStats when the field type is supported,
-     * depending on the data.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - com.google.privacy.dlp.v2beta1.FieldId getField(); - /** - *
-     * Field to compute categorical stats on. All column types are
-     * supported except for arrays and structs. However, it may be more
-     * informative to use NumericalStats when the field type is supported,
-     * depending on the data.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder(); - } - /** - *
-   * Compute numerical stats over an individual column, including
-   * number of distinct values and value count distribution.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig} - */ - public static final class CategoricalStatsConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) - CategoricalStatsConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use CategoricalStatsConfig.newBuilder() to construct. - private CategoricalStatsConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CategoricalStatsConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CategoricalStatsConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null; - if (field_ != null) { - subBuilder = field_.toBuilder(); - } - field_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(field_); - field_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder.class); - } - - public static final int FIELD_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.FieldId field_; - /** - *
-     * Field to compute categorical stats on. All column types are
-     * supported except for arrays and structs. However, it may be more
-     * informative to use NumericalStats when the field type is supported,
-     * depending on the data.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public boolean hasField() { - return field_ != null; - } - /** - *
-     * Field to compute categorical stats on. All column types are
-     * supported except for arrays and structs. However, it may be more
-     * informative to use NumericalStats when the field type is supported,
-     * depending on the data.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getField() { - return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } - /** - *
-     * Field to compute categorical stats on. All column types are
-     * supported except for arrays and structs. However, it may be more
-     * informative to use NumericalStats when the field type is supported,
-     * depending on the data.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() { - return getField(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (field_ != null) { - output.writeMessage(1, getField()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (field_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getField()); - } - 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.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig other = (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) obj; - - boolean result = true; - result = result && (hasField() == other.hasField()); - if (hasField()) { - result = result && getField() - .equals(other.getField()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasField()) { - hash = (37 * hash) + FIELD_FIELD_NUMBER; - hash = (53 * hash) + getField().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * Compute numerical stats over an individual column, including
-     * number of distinct values and value count distribution.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (fieldBuilder_ == null) { - field_ = null; - } else { - field_ = null; - fieldBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig build() { - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig buildPartial() { - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig result = new com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig(this); - if (fieldBuilder_ == null) { - result.field_ = field_; - } else { - result.field_ = fieldBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig other) { - if (other == com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance()) return this; - if (other.hasField()) { - mergeField(other.getField()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.FieldId field_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> fieldBuilder_; - /** - *
-       * Field to compute categorical stats on. All column types are
-       * supported except for arrays and structs. However, it may be more
-       * informative to use NumericalStats when the field type is supported,
-       * depending on the data.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public boolean hasField() { - return fieldBuilder_ != null || field_ != null; - } - /** - *
-       * Field to compute categorical stats on. All column types are
-       * supported except for arrays and structs. However, it may be more
-       * informative to use NumericalStats when the field type is supported,
-       * depending on the data.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getField() { - if (fieldBuilder_ == null) { - return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } else { - return fieldBuilder_.getMessage(); - } - } - /** - *
-       * Field to compute categorical stats on. All column types are
-       * supported except for arrays and structs. However, it may be more
-       * informative to use NumericalStats when the field type is supported,
-       * depending on the data.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder setField(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - field_ = value; - onChanged(); - } else { - fieldBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Field to compute categorical stats on. All column types are
-       * supported except for arrays and structs. However, it may be more
-       * informative to use NumericalStats when the field type is supported,
-       * depending on the data.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder setField( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (fieldBuilder_ == null) { - field_ = builderForValue.build(); - onChanged(); - } else { - fieldBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Field to compute categorical stats on. All column types are
-       * supported except for arrays and structs. However, it may be more
-       * informative to use NumericalStats when the field type is supported,
-       * depending on the data.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder mergeField(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldBuilder_ == null) { - if (field_ != null) { - field_ = - com.google.privacy.dlp.v2beta1.FieldId.newBuilder(field_).mergeFrom(value).buildPartial(); - } else { - field_ = value; - } - onChanged(); - } else { - fieldBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Field to compute categorical stats on. All column types are
-       * supported except for arrays and structs. However, it may be more
-       * informative to use NumericalStats when the field type is supported,
-       * depending on the data.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder clearField() { - if (fieldBuilder_ == null) { - field_ = null; - onChanged(); - } else { - field_ = null; - fieldBuilder_ = null; - } - - return this; - } - /** - *
-       * Field to compute categorical stats on. All column types are
-       * supported except for arrays and structs. However, it may be more
-       * informative to use NumericalStats when the field type is supported,
-       * depending on the data.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getFieldBuilder() { - - onChanged(); - return getFieldFieldBuilder().getBuilder(); - } - /** - *
-       * Field to compute categorical stats on. All column types are
-       * supported except for arrays and structs. However, it may be more
-       * informative to use NumericalStats when the field type is supported,
-       * depending on the data.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() { - if (fieldBuilder_ != null) { - return fieldBuilder_.getMessageOrBuilder(); - } else { - return field_ == null ? - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } - } - /** - *
-       * Field to compute categorical stats on. All column types are
-       * supported except for arrays and structs. However, it may be more
-       * informative to use NumericalStats when the field type is supported,
-       * depending on the data.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getFieldFieldBuilder() { - if (fieldBuilder_ == null) { - fieldBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - getField(), - getParentForChildren(), - isClean()); - field_ = null; - } - return fieldBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) - private static final com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig(); - } - - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CategoricalStatsConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CategoricalStatsConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface KAnonymityConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Set of fields to compute k-anonymity over. When multiple fields are
-     * specified, they are considered a single composite key. Structs and
-     * repeated data types are not supported; however, nested fields are
-     * supported so long as they are not structs themselves or nested within
-     * a repeated field.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - java.util.List - getQuasiIdsList(); - /** - *
-     * Set of fields to compute k-anonymity over. When multiple fields are
-     * specified, they are considered a single composite key. Structs and
-     * repeated data types are not supported; however, nested fields are
-     * supported so long as they are not structs themselves or nested within
-     * a repeated field.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index); - /** - *
-     * Set of fields to compute k-anonymity over. When multiple fields are
-     * specified, they are considered a single composite key. Structs and
-     * repeated data types are not supported; however, nested fields are
-     * supported so long as they are not structs themselves or nested within
-     * a repeated field.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - int getQuasiIdsCount(); - /** - *
-     * Set of fields to compute k-anonymity over. When multiple fields are
-     * specified, they are considered a single composite key. Structs and
-     * repeated data types are not supported; however, nested fields are
-     * supported so long as they are not structs themselves or nested within
-     * a repeated field.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - java.util.List - getQuasiIdsOrBuilderList(); - /** - *
-     * Set of fields to compute k-anonymity over. When multiple fields are
-     * specified, they are considered a single composite key. Structs and
-     * repeated data types are not supported; however, nested fields are
-     * supported so long as they are not structs themselves or nested within
-     * a repeated field.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder( - int index); - - /** - *
-     * Optional message indicating that each distinct `EntityId` should not
-     * contribute to the k-anonymity count more than once per equivalence class.
-     * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - boolean hasEntityId(); - /** - *
-     * Optional message indicating that each distinct `EntityId` should not
-     * contribute to the k-anonymity count more than once per equivalence class.
-     * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - com.google.privacy.dlp.v2beta1.EntityId getEntityId(); - /** - *
-     * Optional message indicating that each distinct `EntityId` should not
-     * contribute to the k-anonymity count more than once per equivalence class.
-     * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - com.google.privacy.dlp.v2beta1.EntityIdOrBuilder getEntityIdOrBuilder(); - } - /** - *
-   * k-anonymity metric, used for analysis of reidentification risk.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig} - */ - public static final class KAnonymityConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) - KAnonymityConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use KAnonymityConfig.newBuilder() to construct. - private KAnonymityConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private KAnonymityConfig() { - quasiIds_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private KAnonymityConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - quasiIds_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - quasiIds_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry)); - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.EntityId.Builder subBuilder = null; - if (entityId_ != null) { - subBuilder = entityId_.toBuilder(); - } - entityId_ = input.readMessage(com.google.privacy.dlp.v2beta1.EntityId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(entityId_); - entityId_ = subBuilder.buildPartial(); - } - - 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) == 0x00000001)) { - quasiIds_ = java.util.Collections.unmodifiableList(quasiIds_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder.class); - } - - private int bitField0_; - public static final int QUASI_IDS_FIELD_NUMBER = 1; - private java.util.List quasiIds_; - /** - *
-     * Set of fields to compute k-anonymity over. When multiple fields are
-     * specified, they are considered a single composite key. Structs and
-     * repeated data types are not supported; however, nested fields are
-     * supported so long as they are not structs themselves or nested within
-     * a repeated field.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public java.util.List getQuasiIdsList() { - return quasiIds_; - } - /** - *
-     * Set of fields to compute k-anonymity over. When multiple fields are
-     * specified, they are considered a single composite key. Structs and
-     * repeated data types are not supported; however, nested fields are
-     * supported so long as they are not structs themselves or nested within
-     * a repeated field.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public java.util.List - getQuasiIdsOrBuilderList() { - return quasiIds_; - } - /** - *
-     * Set of fields to compute k-anonymity over. When multiple fields are
-     * specified, they are considered a single composite key. Structs and
-     * repeated data types are not supported; however, nested fields are
-     * supported so long as they are not structs themselves or nested within
-     * a repeated field.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public int getQuasiIdsCount() { - return quasiIds_.size(); - } - /** - *
-     * Set of fields to compute k-anonymity over. When multiple fields are
-     * specified, they are considered a single composite key. Structs and
-     * repeated data types are not supported; however, nested fields are
-     * supported so long as they are not structs themselves or nested within
-     * a repeated field.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index) { - return quasiIds_.get(index); - } - /** - *
-     * Set of fields to compute k-anonymity over. When multiple fields are
-     * specified, they are considered a single composite key. Structs and
-     * repeated data types are not supported; however, nested fields are
-     * supported so long as they are not structs themselves or nested within
-     * a repeated field.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder( - int index) { - return quasiIds_.get(index); - } - - public static final int ENTITY_ID_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.EntityId entityId_; - /** - *
-     * Optional message indicating that each distinct `EntityId` should not
-     * contribute to the k-anonymity count more than once per equivalence class.
-     * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public boolean hasEntityId() { - return entityId_ != null; - } - /** - *
-     * Optional message indicating that each distinct `EntityId` should not
-     * contribute to the k-anonymity count more than once per equivalence class.
-     * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public com.google.privacy.dlp.v2beta1.EntityId getEntityId() { - return entityId_ == null ? com.google.privacy.dlp.v2beta1.EntityId.getDefaultInstance() : entityId_; - } - /** - *
-     * Optional message indicating that each distinct `EntityId` should not
-     * contribute to the k-anonymity count more than once per equivalence class.
-     * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public com.google.privacy.dlp.v2beta1.EntityIdOrBuilder getEntityIdOrBuilder() { - return getEntityId(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < quasiIds_.size(); i++) { - output.writeMessage(1, quasiIds_.get(i)); - } - if (entityId_ != null) { - output.writeMessage(2, getEntityId()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < quasiIds_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, quasiIds_.get(i)); - } - if (entityId_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getEntityId()); - } - 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.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig other = (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) obj; - - boolean result = true; - result = result && getQuasiIdsList() - .equals(other.getQuasiIdsList()); - result = result && (hasEntityId() == other.hasEntityId()); - if (hasEntityId()) { - result = result && getEntityId() - .equals(other.getEntityId()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getQuasiIdsCount() > 0) { - hash = (37 * hash) + QUASI_IDS_FIELD_NUMBER; - hash = (53 * hash) + getQuasiIdsList().hashCode(); - } - if (hasEntityId()) { - hash = (37 * hash) + ENTITY_ID_FIELD_NUMBER; - hash = (53 * hash) + getEntityId().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * k-anonymity metric, used for analysis of reidentification risk.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getQuasiIdsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (quasiIdsBuilder_ == null) { - quasiIds_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - quasiIdsBuilder_.clear(); - } - if (entityIdBuilder_ == null) { - entityId_ = null; - } else { - entityId_ = null; - entityIdBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig build() { - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig buildPartial() { - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig result = new com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (quasiIdsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - quasiIds_ = java.util.Collections.unmodifiableList(quasiIds_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.quasiIds_ = quasiIds_; - } else { - result.quasiIds_ = quasiIdsBuilder_.build(); - } - if (entityIdBuilder_ == null) { - result.entityId_ = entityId_; - } else { - result.entityId_ = entityIdBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig other) { - if (other == com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance()) return this; - if (quasiIdsBuilder_ == null) { - if (!other.quasiIds_.isEmpty()) { - if (quasiIds_.isEmpty()) { - quasiIds_ = other.quasiIds_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureQuasiIdsIsMutable(); - quasiIds_.addAll(other.quasiIds_); - } - onChanged(); - } - } else { - if (!other.quasiIds_.isEmpty()) { - if (quasiIdsBuilder_.isEmpty()) { - quasiIdsBuilder_.dispose(); - quasiIdsBuilder_ = null; - quasiIds_ = other.quasiIds_; - bitField0_ = (bitField0_ & ~0x00000001); - quasiIdsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getQuasiIdsFieldBuilder() : null; - } else { - quasiIdsBuilder_.addAllMessages(other.quasiIds_); - } - } - } - if (other.hasEntityId()) { - mergeEntityId(other.getEntityId()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List quasiIds_ = - java.util.Collections.emptyList(); - private void ensureQuasiIdsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - quasiIds_ = new java.util.ArrayList(quasiIds_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> quasiIdsBuilder_; - - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public java.util.List getQuasiIdsList() { - if (quasiIdsBuilder_ == null) { - return java.util.Collections.unmodifiableList(quasiIds_); - } else { - return quasiIdsBuilder_.getMessageList(); - } - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public int getQuasiIdsCount() { - if (quasiIdsBuilder_ == null) { - return quasiIds_.size(); - } else { - return quasiIdsBuilder_.getCount(); - } - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index) { - if (quasiIdsBuilder_ == null) { - return quasiIds_.get(index); - } else { - return quasiIdsBuilder_.getMessage(index); - } - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder setQuasiIds( - int index, com.google.privacy.dlp.v2beta1.FieldId value) { - if (quasiIdsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsIsMutable(); - quasiIds_.set(index, value); - onChanged(); - } else { - quasiIdsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder setQuasiIds( - int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (quasiIdsBuilder_ == null) { - ensureQuasiIdsIsMutable(); - quasiIds_.set(index, builderForValue.build()); - onChanged(); - } else { - quasiIdsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder addQuasiIds(com.google.privacy.dlp.v2beta1.FieldId value) { - if (quasiIdsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsIsMutable(); - quasiIds_.add(value); - onChanged(); - } else { - quasiIdsBuilder_.addMessage(value); - } - return this; - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder addQuasiIds( - int index, com.google.privacy.dlp.v2beta1.FieldId value) { - if (quasiIdsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsIsMutable(); - quasiIds_.add(index, value); - onChanged(); - } else { - quasiIdsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder addQuasiIds( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (quasiIdsBuilder_ == null) { - ensureQuasiIdsIsMutable(); - quasiIds_.add(builderForValue.build()); - onChanged(); - } else { - quasiIdsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder addQuasiIds( - int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (quasiIdsBuilder_ == null) { - ensureQuasiIdsIsMutable(); - quasiIds_.add(index, builderForValue.build()); - onChanged(); - } else { - quasiIdsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder addAllQuasiIds( - java.lang.Iterable values) { - if (quasiIdsBuilder_ == null) { - ensureQuasiIdsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, quasiIds_); - onChanged(); - } else { - quasiIdsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder clearQuasiIds() { - if (quasiIdsBuilder_ == null) { - quasiIds_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - quasiIdsBuilder_.clear(); - } - return this; - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder removeQuasiIds(int index) { - if (quasiIdsBuilder_ == null) { - ensureQuasiIdsIsMutable(); - quasiIds_.remove(index); - onChanged(); - } else { - quasiIdsBuilder_.remove(index); - } - return this; - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getQuasiIdsBuilder( - int index) { - return getQuasiIdsFieldBuilder().getBuilder(index); - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder( - int index) { - if (quasiIdsBuilder_ == null) { - return quasiIds_.get(index); } else { - return quasiIdsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public java.util.List - getQuasiIdsOrBuilderList() { - if (quasiIdsBuilder_ != null) { - return quasiIdsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(quasiIds_); - } - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder addQuasiIdsBuilder() { - return getQuasiIdsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()); - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder addQuasiIdsBuilder( - int index) { - return getQuasiIdsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()); - } - /** - *
-       * Set of fields to compute k-anonymity over. When multiple fields are
-       * specified, they are considered a single composite key. Structs and
-       * repeated data types are not supported; however, nested fields are
-       * supported so long as they are not structs themselves or nested within
-       * a repeated field.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public java.util.List - getQuasiIdsBuilderList() { - return getQuasiIdsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getQuasiIdsFieldBuilder() { - if (quasiIdsBuilder_ == null) { - quasiIdsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - quasiIds_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - quasiIds_ = null; - } - return quasiIdsBuilder_; - } - - private com.google.privacy.dlp.v2beta1.EntityId entityId_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.EntityId, com.google.privacy.dlp.v2beta1.EntityId.Builder, com.google.privacy.dlp.v2beta1.EntityIdOrBuilder> entityIdBuilder_; - /** - *
-       * Optional message indicating that each distinct `EntityId` should not
-       * contribute to the k-anonymity count more than once per equivalence class.
-       * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public boolean hasEntityId() { - return entityIdBuilder_ != null || entityId_ != null; - } - /** - *
-       * Optional message indicating that each distinct `EntityId` should not
-       * contribute to the k-anonymity count more than once per equivalence class.
-       * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public com.google.privacy.dlp.v2beta1.EntityId getEntityId() { - if (entityIdBuilder_ == null) { - return entityId_ == null ? com.google.privacy.dlp.v2beta1.EntityId.getDefaultInstance() : entityId_; - } else { - return entityIdBuilder_.getMessage(); - } - } - /** - *
-       * Optional message indicating that each distinct `EntityId` should not
-       * contribute to the k-anonymity count more than once per equivalence class.
-       * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public Builder setEntityId(com.google.privacy.dlp.v2beta1.EntityId value) { - if (entityIdBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - entityId_ = value; - onChanged(); - } else { - entityIdBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Optional message indicating that each distinct `EntityId` should not
-       * contribute to the k-anonymity count more than once per equivalence class.
-       * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public Builder setEntityId( - com.google.privacy.dlp.v2beta1.EntityId.Builder builderForValue) { - if (entityIdBuilder_ == null) { - entityId_ = builderForValue.build(); - onChanged(); - } else { - entityIdBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Optional message indicating that each distinct `EntityId` should not
-       * contribute to the k-anonymity count more than once per equivalence class.
-       * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public Builder mergeEntityId(com.google.privacy.dlp.v2beta1.EntityId value) { - if (entityIdBuilder_ == null) { - if (entityId_ != null) { - entityId_ = - com.google.privacy.dlp.v2beta1.EntityId.newBuilder(entityId_).mergeFrom(value).buildPartial(); - } else { - entityId_ = value; - } - onChanged(); - } else { - entityIdBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Optional message indicating that each distinct `EntityId` should not
-       * contribute to the k-anonymity count more than once per equivalence class.
-       * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public Builder clearEntityId() { - if (entityIdBuilder_ == null) { - entityId_ = null; - onChanged(); - } else { - entityId_ = null; - entityIdBuilder_ = null; - } - - return this; - } - /** - *
-       * Optional message indicating that each distinct `EntityId` should not
-       * contribute to the k-anonymity count more than once per equivalence class.
-       * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public com.google.privacy.dlp.v2beta1.EntityId.Builder getEntityIdBuilder() { - - onChanged(); - return getEntityIdFieldBuilder().getBuilder(); - } - /** - *
-       * Optional message indicating that each distinct `EntityId` should not
-       * contribute to the k-anonymity count more than once per equivalence class.
-       * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - public com.google.privacy.dlp.v2beta1.EntityIdOrBuilder getEntityIdOrBuilder() { - if (entityIdBuilder_ != null) { - return entityIdBuilder_.getMessageOrBuilder(); - } else { - return entityId_ == null ? - com.google.privacy.dlp.v2beta1.EntityId.getDefaultInstance() : entityId_; - } - } - /** - *
-       * Optional message indicating that each distinct `EntityId` should not
-       * contribute to the k-anonymity count more than once per equivalence class.
-       * 
- * - * .google.privacy.dlp.v2beta1.EntityId entity_id = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.EntityId, com.google.privacy.dlp.v2beta1.EntityId.Builder, com.google.privacy.dlp.v2beta1.EntityIdOrBuilder> - getEntityIdFieldBuilder() { - if (entityIdBuilder_ == null) { - entityIdBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.EntityId, com.google.privacy.dlp.v2beta1.EntityId.Builder, com.google.privacy.dlp.v2beta1.EntityIdOrBuilder>( - getEntityId(), - getParentForChildren(), - isClean()); - entityId_ = null; - } - return entityIdBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) - private static final com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig(); - } - - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public KAnonymityConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new KAnonymityConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface LDiversityConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Set of quasi-identifiers indicating how equivalence classes are
-     * defined for the l-diversity computation. When multiple fields are
-     * specified, they are considered a single composite key.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - java.util.List - getQuasiIdsList(); - /** - *
-     * Set of quasi-identifiers indicating how equivalence classes are
-     * defined for the l-diversity computation. When multiple fields are
-     * specified, they are considered a single composite key.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index); - /** - *
-     * Set of quasi-identifiers indicating how equivalence classes are
-     * defined for the l-diversity computation. When multiple fields are
-     * specified, they are considered a single composite key.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - int getQuasiIdsCount(); - /** - *
-     * Set of quasi-identifiers indicating how equivalence classes are
-     * defined for the l-diversity computation. When multiple fields are
-     * specified, they are considered a single composite key.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - java.util.List - getQuasiIdsOrBuilderList(); - /** - *
-     * Set of quasi-identifiers indicating how equivalence classes are
-     * defined for the l-diversity computation. When multiple fields are
-     * specified, they are considered a single composite key.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder( - int index); - - /** - *
-     * Sensitive field for computing the l-value.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - boolean hasSensitiveAttribute(); - /** - *
-     * Sensitive field for computing the l-value.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - com.google.privacy.dlp.v2beta1.FieldId getSensitiveAttribute(); - /** - *
-     * Sensitive field for computing the l-value.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getSensitiveAttributeOrBuilder(); - } - /** - *
-   * l-diversity metric, used for analysis of reidentification risk.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig} - */ - public static final class LDiversityConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) - LDiversityConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use LDiversityConfig.newBuilder() to construct. - private LDiversityConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private LDiversityConfig() { - quasiIds_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private LDiversityConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - quasiIds_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - quasiIds_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry)); - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null; - if (sensitiveAttribute_ != null) { - subBuilder = sensitiveAttribute_.toBuilder(); - } - sensitiveAttribute_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(sensitiveAttribute_); - sensitiveAttribute_ = subBuilder.buildPartial(); - } - - 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) == 0x00000001)) { - quasiIds_ = java.util.Collections.unmodifiableList(quasiIds_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder.class); - } - - private int bitField0_; - public static final int QUASI_IDS_FIELD_NUMBER = 1; - private java.util.List quasiIds_; - /** - *
-     * Set of quasi-identifiers indicating how equivalence classes are
-     * defined for the l-diversity computation. When multiple fields are
-     * specified, they are considered a single composite key.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public java.util.List getQuasiIdsList() { - return quasiIds_; - } - /** - *
-     * Set of quasi-identifiers indicating how equivalence classes are
-     * defined for the l-diversity computation. When multiple fields are
-     * specified, they are considered a single composite key.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public java.util.List - getQuasiIdsOrBuilderList() { - return quasiIds_; - } - /** - *
-     * Set of quasi-identifiers indicating how equivalence classes are
-     * defined for the l-diversity computation. When multiple fields are
-     * specified, they are considered a single composite key.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public int getQuasiIdsCount() { - return quasiIds_.size(); - } - /** - *
-     * Set of quasi-identifiers indicating how equivalence classes are
-     * defined for the l-diversity computation. When multiple fields are
-     * specified, they are considered a single composite key.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index) { - return quasiIds_.get(index); - } - /** - *
-     * Set of quasi-identifiers indicating how equivalence classes are
-     * defined for the l-diversity computation. When multiple fields are
-     * specified, they are considered a single composite key.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder( - int index) { - return quasiIds_.get(index); - } - - public static final int SENSITIVE_ATTRIBUTE_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.FieldId sensitiveAttribute_; - /** - *
-     * Sensitive field for computing the l-value.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public boolean hasSensitiveAttribute() { - return sensitiveAttribute_ != null; - } - /** - *
-     * Sensitive field for computing the l-value.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId getSensitiveAttribute() { - return sensitiveAttribute_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : sensitiveAttribute_; - } - /** - *
-     * Sensitive field for computing the l-value.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getSensitiveAttributeOrBuilder() { - return getSensitiveAttribute(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < quasiIds_.size(); i++) { - output.writeMessage(1, quasiIds_.get(i)); - } - if (sensitiveAttribute_ != null) { - output.writeMessage(2, getSensitiveAttribute()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < quasiIds_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, quasiIds_.get(i)); - } - if (sensitiveAttribute_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getSensitiveAttribute()); - } - 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.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig other = (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) obj; - - boolean result = true; - result = result && getQuasiIdsList() - .equals(other.getQuasiIdsList()); - result = result && (hasSensitiveAttribute() == other.hasSensitiveAttribute()); - if (hasSensitiveAttribute()) { - result = result && getSensitiveAttribute() - .equals(other.getSensitiveAttribute()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getQuasiIdsCount() > 0) { - hash = (37 * hash) + QUASI_IDS_FIELD_NUMBER; - hash = (53 * hash) + getQuasiIdsList().hashCode(); - } - if (hasSensitiveAttribute()) { - hash = (37 * hash) + SENSITIVE_ATTRIBUTE_FIELD_NUMBER; - hash = (53 * hash) + getSensitiveAttribute().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * l-diversity metric, used for analysis of reidentification risk.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getQuasiIdsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (quasiIdsBuilder_ == null) { - quasiIds_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - quasiIdsBuilder_.clear(); - } - if (sensitiveAttributeBuilder_ == null) { - sensitiveAttribute_ = null; - } else { - sensitiveAttribute_ = null; - sensitiveAttributeBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig build() { - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig buildPartial() { - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig result = new com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (quasiIdsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - quasiIds_ = java.util.Collections.unmodifiableList(quasiIds_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.quasiIds_ = quasiIds_; - } else { - result.quasiIds_ = quasiIdsBuilder_.build(); - } - if (sensitiveAttributeBuilder_ == null) { - result.sensitiveAttribute_ = sensitiveAttribute_; - } else { - result.sensitiveAttribute_ = sensitiveAttributeBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig other) { - if (other == com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance()) return this; - if (quasiIdsBuilder_ == null) { - if (!other.quasiIds_.isEmpty()) { - if (quasiIds_.isEmpty()) { - quasiIds_ = other.quasiIds_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureQuasiIdsIsMutable(); - quasiIds_.addAll(other.quasiIds_); - } - onChanged(); - } - } else { - if (!other.quasiIds_.isEmpty()) { - if (quasiIdsBuilder_.isEmpty()) { - quasiIdsBuilder_.dispose(); - quasiIdsBuilder_ = null; - quasiIds_ = other.quasiIds_; - bitField0_ = (bitField0_ & ~0x00000001); - quasiIdsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getQuasiIdsFieldBuilder() : null; - } else { - quasiIdsBuilder_.addAllMessages(other.quasiIds_); - } - } - } - if (other.hasSensitiveAttribute()) { - mergeSensitiveAttribute(other.getSensitiveAttribute()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List quasiIds_ = - java.util.Collections.emptyList(); - private void ensureQuasiIdsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - quasiIds_ = new java.util.ArrayList(quasiIds_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> quasiIdsBuilder_; - - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public java.util.List getQuasiIdsList() { - if (quasiIdsBuilder_ == null) { - return java.util.Collections.unmodifiableList(quasiIds_); - } else { - return quasiIdsBuilder_.getMessageList(); - } - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public int getQuasiIdsCount() { - if (quasiIdsBuilder_ == null) { - return quasiIds_.size(); - } else { - return quasiIdsBuilder_.getCount(); - } - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index) { - if (quasiIdsBuilder_ == null) { - return quasiIds_.get(index); - } else { - return quasiIdsBuilder_.getMessage(index); - } - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder setQuasiIds( - int index, com.google.privacy.dlp.v2beta1.FieldId value) { - if (quasiIdsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsIsMutable(); - quasiIds_.set(index, value); - onChanged(); - } else { - quasiIdsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder setQuasiIds( - int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (quasiIdsBuilder_ == null) { - ensureQuasiIdsIsMutable(); - quasiIds_.set(index, builderForValue.build()); - onChanged(); - } else { - quasiIdsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder addQuasiIds(com.google.privacy.dlp.v2beta1.FieldId value) { - if (quasiIdsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsIsMutable(); - quasiIds_.add(value); - onChanged(); - } else { - quasiIdsBuilder_.addMessage(value); - } - return this; - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder addQuasiIds( - int index, com.google.privacy.dlp.v2beta1.FieldId value) { - if (quasiIdsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsIsMutable(); - quasiIds_.add(index, value); - onChanged(); - } else { - quasiIdsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder addQuasiIds( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (quasiIdsBuilder_ == null) { - ensureQuasiIdsIsMutable(); - quasiIds_.add(builderForValue.build()); - onChanged(); - } else { - quasiIdsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder addQuasiIds( - int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (quasiIdsBuilder_ == null) { - ensureQuasiIdsIsMutable(); - quasiIds_.add(index, builderForValue.build()); - onChanged(); - } else { - quasiIdsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder addAllQuasiIds( - java.lang.Iterable values) { - if (quasiIdsBuilder_ == null) { - ensureQuasiIdsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, quasiIds_); - onChanged(); - } else { - quasiIdsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder clearQuasiIds() { - if (quasiIdsBuilder_ == null) { - quasiIds_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - quasiIdsBuilder_.clear(); - } - return this; - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public Builder removeQuasiIds(int index) { - if (quasiIdsBuilder_ == null) { - ensureQuasiIdsIsMutable(); - quasiIds_.remove(index); - onChanged(); - } else { - quasiIdsBuilder_.remove(index); - } - return this; - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getQuasiIdsBuilder( - int index) { - return getQuasiIdsFieldBuilder().getBuilder(index); - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder( - int index) { - if (quasiIdsBuilder_ == null) { - return quasiIds_.get(index); } else { - return quasiIdsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public java.util.List - getQuasiIdsOrBuilderList() { - if (quasiIdsBuilder_ != null) { - return quasiIdsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(quasiIds_); - } - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder addQuasiIdsBuilder() { - return getQuasiIdsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()); - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder addQuasiIdsBuilder( - int index) { - return getQuasiIdsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()); - } - /** - *
-       * Set of quasi-identifiers indicating how equivalence classes are
-       * defined for the l-diversity computation. When multiple fields are
-       * specified, they are considered a single composite key.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1; - */ - public java.util.List - getQuasiIdsBuilderList() { - return getQuasiIdsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getQuasiIdsFieldBuilder() { - if (quasiIdsBuilder_ == null) { - quasiIdsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - quasiIds_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - quasiIds_ = null; - } - return quasiIdsBuilder_; - } - - private com.google.privacy.dlp.v2beta1.FieldId sensitiveAttribute_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> sensitiveAttributeBuilder_; - /** - *
-       * Sensitive field for computing the l-value.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public boolean hasSensitiveAttribute() { - return sensitiveAttributeBuilder_ != null || sensitiveAttribute_ != null; - } - /** - *
-       * Sensitive field for computing the l-value.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId getSensitiveAttribute() { - if (sensitiveAttributeBuilder_ == null) { - return sensitiveAttribute_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : sensitiveAttribute_; - } else { - return sensitiveAttributeBuilder_.getMessage(); - } - } - /** - *
-       * Sensitive field for computing the l-value.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public Builder setSensitiveAttribute(com.google.privacy.dlp.v2beta1.FieldId value) { - if (sensitiveAttributeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - sensitiveAttribute_ = value; - onChanged(); - } else { - sensitiveAttributeBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Sensitive field for computing the l-value.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public Builder setSensitiveAttribute( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (sensitiveAttributeBuilder_ == null) { - sensitiveAttribute_ = builderForValue.build(); - onChanged(); - } else { - sensitiveAttributeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Sensitive field for computing the l-value.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public Builder mergeSensitiveAttribute(com.google.privacy.dlp.v2beta1.FieldId value) { - if (sensitiveAttributeBuilder_ == null) { - if (sensitiveAttribute_ != null) { - sensitiveAttribute_ = - com.google.privacy.dlp.v2beta1.FieldId.newBuilder(sensitiveAttribute_).mergeFrom(value).buildPartial(); - } else { - sensitiveAttribute_ = value; - } - onChanged(); - } else { - sensitiveAttributeBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Sensitive field for computing the l-value.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public Builder clearSensitiveAttribute() { - if (sensitiveAttributeBuilder_ == null) { - sensitiveAttribute_ = null; - onChanged(); - } else { - sensitiveAttribute_ = null; - sensitiveAttributeBuilder_ = null; - } - - return this; - } - /** - *
-       * Sensitive field for computing the l-value.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getSensitiveAttributeBuilder() { - - onChanged(); - return getSensitiveAttributeFieldBuilder().getBuilder(); - } - /** - *
-       * Sensitive field for computing the l-value.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getSensitiveAttributeOrBuilder() { - if (sensitiveAttributeBuilder_ != null) { - return sensitiveAttributeBuilder_.getMessageOrBuilder(); - } else { - return sensitiveAttribute_ == null ? - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : sensitiveAttribute_; - } - } - /** - *
-       * Sensitive field for computing the l-value.
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getSensitiveAttributeFieldBuilder() { - if (sensitiveAttributeBuilder_ == null) { - sensitiveAttributeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - getSensitiveAttribute(), - getParentForChildren(), - isClean()); - sensitiveAttribute_ = null; - } - return sensitiveAttributeBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) - private static final com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig(); - } - - public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public LDiversityConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new LDiversityConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int typeCase_ = 0; - private java.lang.Object type_; - public enum TypeCase - implements com.google.protobuf.Internal.EnumLite { - NUMERICAL_STATS_CONFIG(1), - CATEGORICAL_STATS_CONFIG(2), - K_ANONYMITY_CONFIG(3), - L_DIVERSITY_CONFIG(4), - TYPE_NOT_SET(0); - private final int value; - private TypeCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TypeCase valueOf(int value) { - return forNumber(value); - } - - public static TypeCase forNumber(int value) { - switch (value) { - case 1: return NUMERICAL_STATS_CONFIG; - case 2: return CATEGORICAL_STATS_CONFIG; - case 3: return K_ANONYMITY_CONFIG; - case 4: return L_DIVERSITY_CONFIG; - case 0: return TYPE_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public static final int NUMERICAL_STATS_CONFIG_FIELD_NUMBER = 1; - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public boolean hasNumericalStatsConfig() { - return typeCase_ == 1; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getNumericalStatsConfig() { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder getNumericalStatsConfigOrBuilder() { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance(); - } - - public static final int CATEGORICAL_STATS_CONFIG_FIELD_NUMBER = 2; - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public boolean hasCategoricalStatsConfig() { - return typeCase_ == 2; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getCategoricalStatsConfig() { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder getCategoricalStatsConfigOrBuilder() { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance(); - } - - public static final int K_ANONYMITY_CONFIG_FIELD_NUMBER = 3; - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public boolean hasKAnonymityConfig() { - return typeCase_ == 3; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getKAnonymityConfig() { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder getKAnonymityConfigOrBuilder() { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance(); - } - - public static final int L_DIVERSITY_CONFIG_FIELD_NUMBER = 4; - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public boolean hasLDiversityConfig() { - return typeCase_ == 4; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getLDiversityConfig() { - if (typeCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder getLDiversityConfigOrBuilder() { - if (typeCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (typeCase_ == 1) { - output.writeMessage(1, (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_); - } - if (typeCase_ == 2) { - output.writeMessage(2, (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_); - } - if (typeCase_ == 3) { - output.writeMessage(3, (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_); - } - if (typeCase_ == 4) { - output.writeMessage(4, (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (typeCase_ == 1) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_); - } - if (typeCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_); - } - if (typeCase_ == 3) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_); - } - if (typeCase_ == 4) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_); - } - 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.privacy.dlp.v2beta1.PrivacyMetric)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.PrivacyMetric other = (com.google.privacy.dlp.v2beta1.PrivacyMetric) obj; - - boolean result = true; - result = result && getTypeCase().equals( - other.getTypeCase()); - if (!result) return false; - switch (typeCase_) { - case 1: - result = result && getNumericalStatsConfig() - .equals(other.getNumericalStatsConfig()); - break; - case 2: - result = result && getCategoricalStatsConfig() - .equals(other.getCategoricalStatsConfig()); - break; - case 3: - result = result && getKAnonymityConfig() - .equals(other.getKAnonymityConfig()); - break; - case 4: - result = result && getLDiversityConfig() - .equals(other.getLDiversityConfig()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (typeCase_) { - case 1: - hash = (37 * hash) + NUMERICAL_STATS_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getNumericalStatsConfig().hashCode(); - break; - case 2: - hash = (37 * hash) + CATEGORICAL_STATS_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getCategoricalStatsConfig().hashCode(); - break; - case 3: - hash = (37 * hash) + K_ANONYMITY_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getKAnonymityConfig().hashCode(); - break; - case 4: - hash = (37 * hash) + L_DIVERSITY_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getLDiversityConfig().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric 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.privacy.dlp.v2beta1.PrivacyMetric parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric 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.privacy.dlp.v2beta1.PrivacyMetric parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric 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.privacy.dlp.v2beta1.PrivacyMetric parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrivacyMetric prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Privacy metric to compute for reidentification risk analysis.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrivacyMetric) - com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PrivacyMetric.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.PrivacyMetric.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - typeCase_ = 0; - type_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.PrivacyMetric.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric build() { - com.google.privacy.dlp.v2beta1.PrivacyMetric result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric buildPartial() { - com.google.privacy.dlp.v2beta1.PrivacyMetric result = new com.google.privacy.dlp.v2beta1.PrivacyMetric(this); - if (typeCase_ == 1) { - if (numericalStatsConfigBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = numericalStatsConfigBuilder_.build(); - } - } - if (typeCase_ == 2) { - if (categoricalStatsConfigBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = categoricalStatsConfigBuilder_.build(); - } - } - if (typeCase_ == 3) { - if (kAnonymityConfigBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = kAnonymityConfigBuilder_.build(); - } - } - if (typeCase_ == 4) { - if (lDiversityConfigBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = lDiversityConfigBuilder_.build(); - } - } - result.typeCase_ = typeCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.PrivacyMetric) { - return mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrivacyMetric other) { - if (other == com.google.privacy.dlp.v2beta1.PrivacyMetric.getDefaultInstance()) return this; - switch (other.getTypeCase()) { - case NUMERICAL_STATS_CONFIG: { - mergeNumericalStatsConfig(other.getNumericalStatsConfig()); - break; - } - case CATEGORICAL_STATS_CONFIG: { - mergeCategoricalStatsConfig(other.getCategoricalStatsConfig()); - break; - } - case K_ANONYMITY_CONFIG: { - mergeKAnonymityConfig(other.getKAnonymityConfig()); - break; - } - case L_DIVERSITY_CONFIG: { - mergeLDiversityConfig(other.getLDiversityConfig()); - break; - } - case TYPE_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.PrivacyMetric parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.PrivacyMetric) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int typeCase_ = 0; - private java.lang.Object type_; - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public Builder clearType() { - typeCase_ = 0; - type_ = null; - onChanged(); - return this; - } - - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder> numericalStatsConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public boolean hasNumericalStatsConfig() { - return typeCase_ == 1; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getNumericalStatsConfig() { - if (numericalStatsConfigBuilder_ == null) { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance(); - } else { - if (typeCase_ == 1) { - return numericalStatsConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public Builder setNumericalStatsConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig value) { - if (numericalStatsConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - numericalStatsConfigBuilder_.setMessage(value); - } - typeCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public Builder setNumericalStatsConfig( - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder builderForValue) { - if (numericalStatsConfigBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - numericalStatsConfigBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public Builder mergeNumericalStatsConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig value) { - if (numericalStatsConfigBuilder_ == null) { - if (typeCase_ == 1 && - type_ != com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.newBuilder((com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 1) { - numericalStatsConfigBuilder_.mergeFrom(value); - } - numericalStatsConfigBuilder_.setMessage(value); - } - typeCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public Builder clearNumericalStatsConfig() { - if (numericalStatsConfigBuilder_ == null) { - if (typeCase_ == 1) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 1) { - typeCase_ = 0; - type_ = null; - } - numericalStatsConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder getNumericalStatsConfigBuilder() { - return getNumericalStatsConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder getNumericalStatsConfigOrBuilder() { - if ((typeCase_ == 1) && (numericalStatsConfigBuilder_ != null)) { - return numericalStatsConfigBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder> - getNumericalStatsConfigFieldBuilder() { - if (numericalStatsConfigBuilder_ == null) { - if (!(typeCase_ == 1)) { - type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance(); - } - numericalStatsConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 1; - onChanged();; - return numericalStatsConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder> categoricalStatsConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public boolean hasCategoricalStatsConfig() { - return typeCase_ == 2; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getCategoricalStatsConfig() { - if (categoricalStatsConfigBuilder_ == null) { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance(); - } else { - if (typeCase_ == 2) { - return categoricalStatsConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public Builder setCategoricalStatsConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig value) { - if (categoricalStatsConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - categoricalStatsConfigBuilder_.setMessage(value); - } - typeCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public Builder setCategoricalStatsConfig( - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder builderForValue) { - if (categoricalStatsConfigBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - categoricalStatsConfigBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public Builder mergeCategoricalStatsConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig value) { - if (categoricalStatsConfigBuilder_ == null) { - if (typeCase_ == 2 && - type_ != com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.newBuilder((com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 2) { - categoricalStatsConfigBuilder_.mergeFrom(value); - } - categoricalStatsConfigBuilder_.setMessage(value); - } - typeCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public Builder clearCategoricalStatsConfig() { - if (categoricalStatsConfigBuilder_ == null) { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - } - categoricalStatsConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder getCategoricalStatsConfigBuilder() { - return getCategoricalStatsConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder getCategoricalStatsConfigOrBuilder() { - if ((typeCase_ == 2) && (categoricalStatsConfigBuilder_ != null)) { - return categoricalStatsConfigBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder> - getCategoricalStatsConfigFieldBuilder() { - if (categoricalStatsConfigBuilder_ == null) { - if (!(typeCase_ == 2)) { - type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance(); - } - categoricalStatsConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 2; - onChanged();; - return categoricalStatsConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder> kAnonymityConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public boolean hasKAnonymityConfig() { - return typeCase_ == 3; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getKAnonymityConfig() { - if (kAnonymityConfigBuilder_ == null) { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance(); - } else { - if (typeCase_ == 3) { - return kAnonymityConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public Builder setKAnonymityConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig value) { - if (kAnonymityConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - kAnonymityConfigBuilder_.setMessage(value); - } - typeCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public Builder setKAnonymityConfig( - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder builderForValue) { - if (kAnonymityConfigBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - kAnonymityConfigBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public Builder mergeKAnonymityConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig value) { - if (kAnonymityConfigBuilder_ == null) { - if (typeCase_ == 3 && - type_ != com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.newBuilder((com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 3) { - kAnonymityConfigBuilder_.mergeFrom(value); - } - kAnonymityConfigBuilder_.setMessage(value); - } - typeCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public Builder clearKAnonymityConfig() { - if (kAnonymityConfigBuilder_ == null) { - if (typeCase_ == 3) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 3) { - typeCase_ = 0; - type_ = null; - } - kAnonymityConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder getKAnonymityConfigBuilder() { - return getKAnonymityConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder getKAnonymityConfigOrBuilder() { - if ((typeCase_ == 3) && (kAnonymityConfigBuilder_ != null)) { - return kAnonymityConfigBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder> - getKAnonymityConfigFieldBuilder() { - if (kAnonymityConfigBuilder_ == null) { - if (!(typeCase_ == 3)) { - type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance(); - } - kAnonymityConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 3; - onChanged();; - return kAnonymityConfigBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder> lDiversityConfigBuilder_; - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public boolean hasLDiversityConfig() { - return typeCase_ == 4; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getLDiversityConfig() { - if (lDiversityConfigBuilder_ == null) { - if (typeCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance(); - } else { - if (typeCase_ == 4) { - return lDiversityConfigBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public Builder setLDiversityConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig value) { - if (lDiversityConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - lDiversityConfigBuilder_.setMessage(value); - } - typeCase_ = 4; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public Builder setLDiversityConfig( - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder builderForValue) { - if (lDiversityConfigBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - lDiversityConfigBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 4; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public Builder mergeLDiversityConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig value) { - if (lDiversityConfigBuilder_ == null) { - if (typeCase_ == 4 && - type_ != com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.newBuilder((com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 4) { - lDiversityConfigBuilder_.mergeFrom(value); - } - lDiversityConfigBuilder_.setMessage(value); - } - typeCase_ = 4; - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public Builder clearLDiversityConfig() { - if (lDiversityConfigBuilder_ == null) { - if (typeCase_ == 4) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 4) { - typeCase_ = 0; - type_ = null; - } - lDiversityConfigBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder getLDiversityConfigBuilder() { - return getLDiversityConfigFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder getLDiversityConfigOrBuilder() { - if ((typeCase_ == 4) && (lDiversityConfigBuilder_ != null)) { - return lDiversityConfigBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_; - } - return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder> - getLDiversityConfigFieldBuilder() { - if (lDiversityConfigBuilder_ == null) { - if (!(typeCase_ == 4)) { - type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance(); - } - lDiversityConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder>( - (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 4; - onChanged();; - return lDiversityConfigBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrivacyMetric) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrivacyMetric) - private static final com.google.privacy.dlp.v2beta1.PrivacyMetric DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrivacyMetric(); - } - - public static com.google.privacy.dlp.v2beta1.PrivacyMetric getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public PrivacyMetric parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new PrivacyMetric(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.PrivacyMetric getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrivacyMetricOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrivacyMetricOrBuilder.java deleted file mode 100644 index 789475a992be..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PrivacyMetricOrBuilder.java +++ /dev/null @@ -1,63 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface PrivacyMetricOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PrivacyMetric) - com.google.protobuf.MessageOrBuilder { - - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - boolean hasNumericalStatsConfig(); - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getNumericalStatsConfig(); - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder getNumericalStatsConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - boolean hasCategoricalStatsConfig(); - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getCategoricalStatsConfig(); - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder getCategoricalStatsConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - boolean hasKAnonymityConfig(); - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getKAnonymityConfig(); - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder getKAnonymityConfigOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - boolean hasLDiversityConfig(); - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getLDiversityConfig(); - /** - * .google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder getLDiversityConfigOrBuilder(); - - public com.google.privacy.dlp.v2beta1.PrivacyMetric.TypeCase getTypeCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Projection.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Projection.java deleted file mode 100644 index 37c53076d5d5..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Projection.java +++ /dev/null @@ -1,626 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * A representation of a Datastore property in a projection.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Projection} - */ -public final class Projection extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.Projection) - ProjectionOrBuilder { -private static final long serialVersionUID = 0L; - // Use Projection.newBuilder() to construct. - private Projection(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Projection() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Projection( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.PropertyReference.Builder subBuilder = null; - if (property_ != null) { - subBuilder = property_.toBuilder(); - } - property_ = input.readMessage(com.google.privacy.dlp.v2beta1.PropertyReference.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(property_); - property_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Projection_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Projection_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Projection.class, com.google.privacy.dlp.v2beta1.Projection.Builder.class); - } - - public static final int PROPERTY_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.PropertyReference property_; - /** - *
-   * The property to project.
-   * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public boolean hasProperty() { - return property_ != null; - } - /** - *
-   * The property to project.
-   * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public com.google.privacy.dlp.v2beta1.PropertyReference getProperty() { - return property_ == null ? com.google.privacy.dlp.v2beta1.PropertyReference.getDefaultInstance() : property_; - } - /** - *
-   * The property to project.
-   * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public com.google.privacy.dlp.v2beta1.PropertyReferenceOrBuilder getPropertyOrBuilder() { - return getProperty(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (property_ != null) { - output.writeMessage(1, getProperty()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (property_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getProperty()); - } - 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.privacy.dlp.v2beta1.Projection)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.Projection other = (com.google.privacy.dlp.v2beta1.Projection) obj; - - boolean result = true; - result = result && (hasProperty() == other.hasProperty()); - if (hasProperty()) { - result = result && getProperty() - .equals(other.getProperty()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasProperty()) { - hash = (37 * hash) + PROPERTY_FIELD_NUMBER; - hash = (53 * hash) + getProperty().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.Projection parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Projection parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Projection parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Projection 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.privacy.dlp.v2beta1.Projection parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Projection parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Projection parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Projection 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.privacy.dlp.v2beta1.Projection parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Projection 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.privacy.dlp.v2beta1.Projection parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Projection parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.Projection prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * A representation of a Datastore property in a projection.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Projection} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.Projection) - com.google.privacy.dlp.v2beta1.ProjectionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Projection_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Projection_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Projection.class, com.google.privacy.dlp.v2beta1.Projection.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.Projection.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (propertyBuilder_ == null) { - property_ = null; - } else { - property_ = null; - propertyBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_Projection_descriptor; - } - - public com.google.privacy.dlp.v2beta1.Projection getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.Projection.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.Projection build() { - com.google.privacy.dlp.v2beta1.Projection result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.Projection buildPartial() { - com.google.privacy.dlp.v2beta1.Projection result = new com.google.privacy.dlp.v2beta1.Projection(this); - if (propertyBuilder_ == null) { - result.property_ = property_; - } else { - result.property_ = propertyBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.Projection) { - return mergeFrom((com.google.privacy.dlp.v2beta1.Projection)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.Projection other) { - if (other == com.google.privacy.dlp.v2beta1.Projection.getDefaultInstance()) return this; - if (other.hasProperty()) { - mergeProperty(other.getProperty()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.Projection parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.Projection) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.PropertyReference property_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PropertyReference, com.google.privacy.dlp.v2beta1.PropertyReference.Builder, com.google.privacy.dlp.v2beta1.PropertyReferenceOrBuilder> propertyBuilder_; - /** - *
-     * The property to project.
-     * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public boolean hasProperty() { - return propertyBuilder_ != null || property_ != null; - } - /** - *
-     * The property to project.
-     * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public com.google.privacy.dlp.v2beta1.PropertyReference getProperty() { - if (propertyBuilder_ == null) { - return property_ == null ? com.google.privacy.dlp.v2beta1.PropertyReference.getDefaultInstance() : property_; - } else { - return propertyBuilder_.getMessage(); - } - } - /** - *
-     * The property to project.
-     * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public Builder setProperty(com.google.privacy.dlp.v2beta1.PropertyReference value) { - if (propertyBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - property_ = value; - onChanged(); - } else { - propertyBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The property to project.
-     * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public Builder setProperty( - com.google.privacy.dlp.v2beta1.PropertyReference.Builder builderForValue) { - if (propertyBuilder_ == null) { - property_ = builderForValue.build(); - onChanged(); - } else { - propertyBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The property to project.
-     * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public Builder mergeProperty(com.google.privacy.dlp.v2beta1.PropertyReference value) { - if (propertyBuilder_ == null) { - if (property_ != null) { - property_ = - com.google.privacy.dlp.v2beta1.PropertyReference.newBuilder(property_).mergeFrom(value).buildPartial(); - } else { - property_ = value; - } - onChanged(); - } else { - propertyBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The property to project.
-     * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public Builder clearProperty() { - if (propertyBuilder_ == null) { - property_ = null; - onChanged(); - } else { - property_ = null; - propertyBuilder_ = null; - } - - return this; - } - /** - *
-     * The property to project.
-     * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public com.google.privacy.dlp.v2beta1.PropertyReference.Builder getPropertyBuilder() { - - onChanged(); - return getPropertyFieldBuilder().getBuilder(); - } - /** - *
-     * The property to project.
-     * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - public com.google.privacy.dlp.v2beta1.PropertyReferenceOrBuilder getPropertyOrBuilder() { - if (propertyBuilder_ != null) { - return propertyBuilder_.getMessageOrBuilder(); - } else { - return property_ == null ? - com.google.privacy.dlp.v2beta1.PropertyReference.getDefaultInstance() : property_; - } - } - /** - *
-     * The property to project.
-     * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PropertyReference, com.google.privacy.dlp.v2beta1.PropertyReference.Builder, com.google.privacy.dlp.v2beta1.PropertyReferenceOrBuilder> - getPropertyFieldBuilder() { - if (propertyBuilder_ == null) { - propertyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PropertyReference, com.google.privacy.dlp.v2beta1.PropertyReference.Builder, com.google.privacy.dlp.v2beta1.PropertyReferenceOrBuilder>( - getProperty(), - getParentForChildren(), - isClean()); - property_ = null; - } - return propertyBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.Projection) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.Projection) - private static final com.google.privacy.dlp.v2beta1.Projection DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.Projection(); - } - - public static com.google.privacy.dlp.v2beta1.Projection getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Projection parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Projection(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.Projection getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ProjectionOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ProjectionOrBuilder.java deleted file mode 100644 index e02fa3eed86e..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ProjectionOrBuilder.java +++ /dev/null @@ -1,34 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ProjectionOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.Projection) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The property to project.
-   * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - boolean hasProperty(); - /** - *
-   * The property to project.
-   * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - com.google.privacy.dlp.v2beta1.PropertyReference getProperty(); - /** - *
-   * The property to project.
-   * 
- * - * .google.privacy.dlp.v2beta1.PropertyReference property = 1; - */ - com.google.privacy.dlp.v2beta1.PropertyReferenceOrBuilder getPropertyOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PropertyReference.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PropertyReference.java deleted file mode 100644 index 35aa60a7cd92..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PropertyReference.java +++ /dev/null @@ -1,559 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * A reference to a property relative to the Datastore kind expressions.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PropertyReference} - */ -public final class PropertyReference extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PropertyReference) - PropertyReferenceOrBuilder { -private static final long serialVersionUID = 0L; - // Use PropertyReference.newBuilder() to construct. - private PropertyReference(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private PropertyReference() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private PropertyReference( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_PropertyReference_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_PropertyReference_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PropertyReference.class, com.google.privacy.dlp.v2beta1.PropertyReference.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object name_; - /** - *
-   * The name of the property.
-   * If name includes "."s, it may be interpreted as a property name path.
-   * 
- * - * string name = 2; - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - *
-   * The name of the property.
-   * If name includes "."s, it may be interpreted as a property name path.
-   * 
- * - * string name = 2; - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, name_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, name_); - } - 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.privacy.dlp.v2beta1.PropertyReference)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.PropertyReference other = (com.google.privacy.dlp.v2beta1.PropertyReference) obj; - - boolean result = true; - result = result && getName() - .equals(other.getName()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.PropertyReference parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PropertyReference parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PropertyReference parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PropertyReference 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.privacy.dlp.v2beta1.PropertyReference parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.PropertyReference parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.PropertyReference parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PropertyReference 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.privacy.dlp.v2beta1.PropertyReference parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PropertyReference 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.privacy.dlp.v2beta1.PropertyReference parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.PropertyReference parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PropertyReference prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * A reference to a property relative to the Datastore kind expressions.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.PropertyReference} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PropertyReference) - com.google.privacy.dlp.v2beta1.PropertyReferenceOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_PropertyReference_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_PropertyReference_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.PropertyReference.class, com.google.privacy.dlp.v2beta1.PropertyReference.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.PropertyReference.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_PropertyReference_descriptor; - } - - public com.google.privacy.dlp.v2beta1.PropertyReference getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.PropertyReference.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.PropertyReference build() { - com.google.privacy.dlp.v2beta1.PropertyReference result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.PropertyReference buildPartial() { - com.google.privacy.dlp.v2beta1.PropertyReference result = new com.google.privacy.dlp.v2beta1.PropertyReference(this); - result.name_ = name_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.PropertyReference) { - return mergeFrom((com.google.privacy.dlp.v2beta1.PropertyReference)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PropertyReference other) { - if (other == com.google.privacy.dlp.v2beta1.PropertyReference.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.PropertyReference parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.PropertyReference) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - *
-     * The name of the property.
-     * If name includes "."s, it may be interpreted as a property name path.
-     * 
- * - * string name = 2; - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-     * The name of the property.
-     * If name includes "."s, it may be interpreted as a property name path.
-     * 
- * - * string name = 2; - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-     * The name of the property.
-     * If name includes "."s, it may be interpreted as a property name path.
-     * 
- * - * string name = 2; - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - *
-     * The name of the property.
-     * If name includes "."s, it may be interpreted as a property name path.
-     * 
- * - * string name = 2; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - *
-     * The name of the property.
-     * If name includes "."s, it may be interpreted as a property name path.
-     * 
- * - * string name = 2; - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PropertyReference) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PropertyReference) - private static final com.google.privacy.dlp.v2beta1.PropertyReference DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PropertyReference(); - } - - public static com.google.privacy.dlp.v2beta1.PropertyReference getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public PropertyReference parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new PropertyReference(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.PropertyReference getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PropertyReferenceOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PropertyReferenceOrBuilder.java deleted file mode 100644 index 07d5e12b4250..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/PropertyReferenceOrBuilder.java +++ /dev/null @@ -1,29 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface PropertyReferenceOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PropertyReference) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The name of the property.
-   * If name includes "."s, it may be interpreted as a property name path.
-   * 
- * - * string name = 2; - */ - java.lang.String getName(); - /** - *
-   * The name of the property.
-   * If name includes "."s, it may be interpreted as a property name path.
-   * 
- * - * string name = 2; - */ - com.google.protobuf.ByteString - getNameBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RangeOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RangeOrBuilder.java deleted file mode 100644 index 868701fe0dd8..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RangeOrBuilder.java +++ /dev/null @@ -1,27 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface RangeOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.Range) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Index of the first character of the range (inclusive).
-   * 
- * - * int64 start = 1; - */ - long getStart(); - - /** - *
-   * Index of the last character of the range (exclusive).
-   * 
- * - * int64 end = 2; - */ - long getEnd(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordCondition.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordCondition.java deleted file mode 100644 index 2199910ed45b..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordCondition.java +++ /dev/null @@ -1,3315 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * A condition for determining whether a transformation should be applied to
- * a field.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordCondition} - */ -public final class RecordCondition extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RecordCondition) - RecordConditionOrBuilder { -private static final long serialVersionUID = 0L; - // Use RecordCondition.newBuilder() to construct. - private RecordCondition(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private RecordCondition() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private RecordCondition( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.Builder subBuilder = null; - if (expressions_ != null) { - subBuilder = expressions_.toBuilder(); - } - expressions_ = input.readMessage(com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(expressions_); - expressions_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordCondition.class, com.google.privacy.dlp.v2beta1.RecordCondition.Builder.class); - } - - public interface ConditionOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RecordCondition.Condition) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Field within the record this condition is evaluated against. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - boolean hasField(); - /** - *
-     * Field within the record this condition is evaluated against. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - com.google.privacy.dlp.v2beta1.FieldId getField(); - /** - *
-     * Field within the record this condition is evaluated against. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder(); - - /** - *
-     * Operator used to compare the field or info type to the value. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.RelationalOperator operator = 3; - */ - int getOperatorValue(); - /** - *
-     * Operator used to compare the field or info type to the value. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.RelationalOperator operator = 3; - */ - com.google.privacy.dlp.v2beta1.RelationalOperator getOperator(); - - /** - *
-     * Value to compare against. [Required, except for `EXISTS` tests.]
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - boolean hasValue(); - /** - *
-     * Value to compare against. [Required, except for `EXISTS` tests.]
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - com.google.privacy.dlp.v2beta1.Value getValue(); - /** - *
-     * Value to compare against. [Required, except for `EXISTS` tests.]
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getValueOrBuilder(); - } - /** - *
-   * The field type of `value` and `field` do not need to match to be
-   * considered equal, but not all comparisons are possible.
-   * A `value` of type:
-   * - `string` can be compared against all other types
-   * - `boolean` can only be compared against other booleans
-   * - `integer` can be compared against doubles or a string if the string value
-   * can be parsed as an integer.
-   * - `double` can be compared against integers or a string if the string can
-   * be parsed as a double.
-   * - `Timestamp` can be compared against strings in RFC 3339 date string
-   * format.
-   * - `TimeOfDay` can be compared against timestamps and strings in the format
-   * of 'HH:mm:ss'.
-   * If we fail to compare do to type mismatch, a warning will be given and
-   * the condition will evaluate to false.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordCondition.Condition} - */ - public static final class Condition extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RecordCondition.Condition) - ConditionOrBuilder { - private static final long serialVersionUID = 0L; - // Use Condition.newBuilder() to construct. - private Condition(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Condition() { - operator_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Condition( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null; - if (field_ != null) { - subBuilder = field_.toBuilder(); - } - field_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(field_); - field_ = subBuilder.buildPartial(); - } - - break; - } - case 24: { - int rawValue = input.readEnum(); - - operator_ = rawValue; - break; - } - case 34: { - com.google.privacy.dlp.v2beta1.Value.Builder subBuilder = null; - if (value_ != null) { - subBuilder = value_.toBuilder(); - } - value_ = input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(value_); - value_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Condition_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Condition_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordCondition.Condition.class, com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder.class); - } - - public static final int FIELD_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.FieldId field_; - /** - *
-     * Field within the record this condition is evaluated against. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public boolean hasField() { - return field_ != null; - } - /** - *
-     * Field within the record this condition is evaluated against. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getField() { - return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } - /** - *
-     * Field within the record this condition is evaluated against. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() { - return getField(); - } - - public static final int OPERATOR_FIELD_NUMBER = 3; - private int operator_; - /** - *
-     * Operator used to compare the field or info type to the value. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.RelationalOperator operator = 3; - */ - public int getOperatorValue() { - return operator_; - } - /** - *
-     * Operator used to compare the field or info type to the value. [required]
-     * 
- * - * .google.privacy.dlp.v2beta1.RelationalOperator operator = 3; - */ - public com.google.privacy.dlp.v2beta1.RelationalOperator getOperator() { - com.google.privacy.dlp.v2beta1.RelationalOperator result = com.google.privacy.dlp.v2beta1.RelationalOperator.valueOf(operator_); - return result == null ? com.google.privacy.dlp.v2beta1.RelationalOperator.UNRECOGNIZED : result; - } - - public static final int VALUE_FIELD_NUMBER = 4; - private com.google.privacy.dlp.v2beta1.Value value_; - /** - *
-     * Value to compare against. [Required, except for `EXISTS` tests.]
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public boolean hasValue() { - return value_ != null; - } - /** - *
-     * Value to compare against. [Required, except for `EXISTS` tests.]
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public com.google.privacy.dlp.v2beta1.Value getValue() { - return value_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : value_; - } - /** - *
-     * Value to compare against. [Required, except for `EXISTS` tests.]
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getValueOrBuilder() { - return getValue(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (field_ != null) { - output.writeMessage(1, getField()); - } - if (operator_ != com.google.privacy.dlp.v2beta1.RelationalOperator.RELATIONAL_OPERATOR_UNSPECIFIED.getNumber()) { - output.writeEnum(3, operator_); - } - if (value_ != null) { - output.writeMessage(4, getValue()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (field_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getField()); - } - if (operator_ != com.google.privacy.dlp.v2beta1.RelationalOperator.RELATIONAL_OPERATOR_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(3, operator_); - } - if (value_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, getValue()); - } - 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.privacy.dlp.v2beta1.RecordCondition.Condition)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RecordCondition.Condition other = (com.google.privacy.dlp.v2beta1.RecordCondition.Condition) obj; - - boolean result = true; - result = result && (hasField() == other.hasField()); - if (hasField()) { - result = result && getField() - .equals(other.getField()); - } - result = result && operator_ == other.operator_; - result = result && (hasValue() == other.hasValue()); - if (hasValue()) { - result = result && getValue() - .equals(other.getValue()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasField()) { - hash = (37 * hash) + FIELD_FIELD_NUMBER; - hash = (53 * hash) + getField().hashCode(); - } - hash = (37 * hash) + OPERATOR_FIELD_NUMBER; - hash = (53 * hash) + operator_; - if (hasValue()) { - hash = (37 * hash) + VALUE_FIELD_NUMBER; - hash = (53 * hash) + getValue().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RecordCondition.Condition parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Condition parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Condition parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Condition 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.privacy.dlp.v2beta1.RecordCondition.Condition parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Condition parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Condition parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Condition 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.privacy.dlp.v2beta1.RecordCondition.Condition parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Condition 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.privacy.dlp.v2beta1.RecordCondition.Condition parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Condition parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RecordCondition.Condition prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * The field type of `value` and `field` do not need to match to be
-     * considered equal, but not all comparisons are possible.
-     * A `value` of type:
-     * - `string` can be compared against all other types
-     * - `boolean` can only be compared against other booleans
-     * - `integer` can be compared against doubles or a string if the string value
-     * can be parsed as an integer.
-     * - `double` can be compared against integers or a string if the string can
-     * be parsed as a double.
-     * - `Timestamp` can be compared against strings in RFC 3339 date string
-     * format.
-     * - `TimeOfDay` can be compared against timestamps and strings in the format
-     * of 'HH:mm:ss'.
-     * If we fail to compare do to type mismatch, a warning will be given and
-     * the condition will evaluate to false.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordCondition.Condition} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RecordCondition.Condition) - com.google.privacy.dlp.v2beta1.RecordCondition.ConditionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Condition_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Condition_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordCondition.Condition.class, com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RecordCondition.Condition.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (fieldBuilder_ == null) { - field_ = null; - } else { - field_ = null; - fieldBuilder_ = null; - } - operator_ = 0; - - if (valueBuilder_ == null) { - value_ = null; - } else { - value_ = null; - valueBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Condition_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Condition getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RecordCondition.Condition.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Condition build() { - com.google.privacy.dlp.v2beta1.RecordCondition.Condition result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Condition buildPartial() { - com.google.privacy.dlp.v2beta1.RecordCondition.Condition result = new com.google.privacy.dlp.v2beta1.RecordCondition.Condition(this); - if (fieldBuilder_ == null) { - result.field_ = field_; - } else { - result.field_ = fieldBuilder_.build(); - } - result.operator_ = operator_; - if (valueBuilder_ == null) { - result.value_ = value_; - } else { - result.value_ = valueBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RecordCondition.Condition) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RecordCondition.Condition)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RecordCondition.Condition other) { - if (other == com.google.privacy.dlp.v2beta1.RecordCondition.Condition.getDefaultInstance()) return this; - if (other.hasField()) { - mergeField(other.getField()); - } - if (other.operator_ != 0) { - setOperatorValue(other.getOperatorValue()); - } - if (other.hasValue()) { - mergeValue(other.getValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RecordCondition.Condition parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RecordCondition.Condition) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.FieldId field_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> fieldBuilder_; - /** - *
-       * Field within the record this condition is evaluated against. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public boolean hasField() { - return fieldBuilder_ != null || field_ != null; - } - /** - *
-       * Field within the record this condition is evaluated against. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getField() { - if (fieldBuilder_ == null) { - return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } else { - return fieldBuilder_.getMessage(); - } - } - /** - *
-       * Field within the record this condition is evaluated against. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder setField(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - field_ = value; - onChanged(); - } else { - fieldBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Field within the record this condition is evaluated against. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder setField( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (fieldBuilder_ == null) { - field_ = builderForValue.build(); - onChanged(); - } else { - fieldBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Field within the record this condition is evaluated against. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder mergeField(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldBuilder_ == null) { - if (field_ != null) { - field_ = - com.google.privacy.dlp.v2beta1.FieldId.newBuilder(field_).mergeFrom(value).buildPartial(); - } else { - field_ = value; - } - onChanged(); - } else { - fieldBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Field within the record this condition is evaluated against. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public Builder clearField() { - if (fieldBuilder_ == null) { - field_ = null; - onChanged(); - } else { - field_ = null; - fieldBuilder_ = null; - } - - return this; - } - /** - *
-       * Field within the record this condition is evaluated against. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getFieldBuilder() { - - onChanged(); - return getFieldFieldBuilder().getBuilder(); - } - /** - *
-       * Field within the record this condition is evaluated against. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() { - if (fieldBuilder_ != null) { - return fieldBuilder_.getMessageOrBuilder(); - } else { - return field_ == null ? - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } - } - /** - *
-       * Field within the record this condition is evaluated against. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getFieldFieldBuilder() { - if (fieldBuilder_ == null) { - fieldBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - getField(), - getParentForChildren(), - isClean()); - field_ = null; - } - return fieldBuilder_; - } - - private int operator_ = 0; - /** - *
-       * Operator used to compare the field or info type to the value. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.RelationalOperator operator = 3; - */ - public int getOperatorValue() { - return operator_; - } - /** - *
-       * Operator used to compare the field or info type to the value. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.RelationalOperator operator = 3; - */ - public Builder setOperatorValue(int value) { - operator_ = value; - onChanged(); - return this; - } - /** - *
-       * Operator used to compare the field or info type to the value. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.RelationalOperator operator = 3; - */ - public com.google.privacy.dlp.v2beta1.RelationalOperator getOperator() { - com.google.privacy.dlp.v2beta1.RelationalOperator result = com.google.privacy.dlp.v2beta1.RelationalOperator.valueOf(operator_); - return result == null ? com.google.privacy.dlp.v2beta1.RelationalOperator.UNRECOGNIZED : result; - } - /** - *
-       * Operator used to compare the field or info type to the value. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.RelationalOperator operator = 3; - */ - public Builder setOperator(com.google.privacy.dlp.v2beta1.RelationalOperator value) { - if (value == null) { - throw new NullPointerException(); - } - - operator_ = value.getNumber(); - onChanged(); - return this; - } - /** - *
-       * Operator used to compare the field or info type to the value. [required]
-       * 
- * - * .google.privacy.dlp.v2beta1.RelationalOperator operator = 3; - */ - public Builder clearOperator() { - - operator_ = 0; - onChanged(); - return this; - } - - private com.google.privacy.dlp.v2beta1.Value value_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> valueBuilder_; - /** - *
-       * Value to compare against. [Required, except for `EXISTS` tests.]
-       * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public boolean hasValue() { - return valueBuilder_ != null || value_ != null; - } - /** - *
-       * Value to compare against. [Required, except for `EXISTS` tests.]
-       * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public com.google.privacy.dlp.v2beta1.Value getValue() { - if (valueBuilder_ == null) { - return value_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : value_; - } else { - return valueBuilder_.getMessage(); - } - } - /** - *
-       * Value to compare against. [Required, except for `EXISTS` tests.]
-       * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public Builder setValue(com.google.privacy.dlp.v2beta1.Value value) { - if (valueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - value_ = value; - onChanged(); - } else { - valueBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Value to compare against. [Required, except for `EXISTS` tests.]
-       * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public Builder setValue( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (valueBuilder_ == null) { - value_ = builderForValue.build(); - onChanged(); - } else { - valueBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Value to compare against. [Required, except for `EXISTS` tests.]
-       * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public Builder mergeValue(com.google.privacy.dlp.v2beta1.Value value) { - if (valueBuilder_ == null) { - if (value_ != null) { - value_ = - com.google.privacy.dlp.v2beta1.Value.newBuilder(value_).mergeFrom(value).buildPartial(); - } else { - value_ = value; - } - onChanged(); - } else { - valueBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Value to compare against. [Required, except for `EXISTS` tests.]
-       * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public Builder clearValue() { - if (valueBuilder_ == null) { - value_ = null; - onChanged(); - } else { - value_ = null; - valueBuilder_ = null; - } - - return this; - } - /** - *
-       * Value to compare against. [Required, except for `EXISTS` tests.]
-       * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getValueBuilder() { - - onChanged(); - return getValueFieldBuilder().getBuilder(); - } - /** - *
-       * Value to compare against. [Required, except for `EXISTS` tests.]
-       * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getValueOrBuilder() { - if (valueBuilder_ != null) { - return valueBuilder_.getMessageOrBuilder(); - } else { - return value_ == null ? - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : value_; - } - } - /** - *
-       * Value to compare against. [Required, except for `EXISTS` tests.]
-       * 
- * - * .google.privacy.dlp.v2beta1.Value value = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getValueFieldBuilder() { - if (valueBuilder_ == null) { - valueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - getValue(), - getParentForChildren(), - isClean()); - value_ = null; - } - return valueBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RecordCondition.Condition) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RecordCondition.Condition) - private static final com.google.privacy.dlp.v2beta1.RecordCondition.Condition DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RecordCondition.Condition(); - } - - public static com.google.privacy.dlp.v2beta1.RecordCondition.Condition getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Condition parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Condition(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Condition getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface ConditionsOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RecordCondition.Conditions) - com.google.protobuf.MessageOrBuilder { - - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - java.util.List - getConditionsList(); - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - com.google.privacy.dlp.v2beta1.RecordCondition.Condition getConditions(int index); - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - int getConditionsCount(); - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - java.util.List - getConditionsOrBuilderList(); - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - com.google.privacy.dlp.v2beta1.RecordCondition.ConditionOrBuilder getConditionsOrBuilder( - int index); - } - /** - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordCondition.Conditions} - */ - public static final class Conditions extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RecordCondition.Conditions) - ConditionsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Conditions.newBuilder() to construct. - private Conditions(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Conditions() { - conditions_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Conditions( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - conditions_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - conditions_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.RecordCondition.Condition.parser(), extensionRegistry)); - 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) == 0x00000001)) { - conditions_ = java.util.Collections.unmodifiableList(conditions_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Conditions_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Conditions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.class, com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.Builder.class); - } - - public static final int CONDITIONS_FIELD_NUMBER = 1; - private java.util.List conditions_; - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public java.util.List getConditionsList() { - return conditions_; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public java.util.List - getConditionsOrBuilderList() { - return conditions_; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public int getConditionsCount() { - return conditions_.size(); - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Condition getConditions(int index) { - return conditions_.get(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.ConditionOrBuilder getConditionsOrBuilder( - int index) { - return conditions_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < conditions_.size(); i++) { - output.writeMessage(1, conditions_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < conditions_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, conditions_.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.privacy.dlp.v2beta1.RecordCondition.Conditions)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions other = (com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) obj; - - boolean result = true; - result = result && getConditionsList() - .equals(other.getConditionsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getConditionsCount() > 0) { - hash = (37 * hash) + CONDITIONS_FIELD_NUMBER; - hash = (53 * hash) + getConditionsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RecordCondition.Conditions parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Conditions parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Conditions parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Conditions 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.privacy.dlp.v2beta1.RecordCondition.Conditions parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Conditions parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Conditions parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Conditions 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.privacy.dlp.v2beta1.RecordCondition.Conditions parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Conditions 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.privacy.dlp.v2beta1.RecordCondition.Conditions parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Conditions parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RecordCondition.Conditions prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordCondition.Conditions} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RecordCondition.Conditions) - com.google.privacy.dlp.v2beta1.RecordCondition.ConditionsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Conditions_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Conditions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.class, com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getConditionsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (conditionsBuilder_ == null) { - conditions_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - conditionsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Conditions_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Conditions getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Conditions build() { - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Conditions buildPartial() { - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions result = new com.google.privacy.dlp.v2beta1.RecordCondition.Conditions(this); - int from_bitField0_ = bitField0_; - if (conditionsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - conditions_ = java.util.Collections.unmodifiableList(conditions_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.conditions_ = conditions_; - } else { - result.conditions_ = conditionsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RecordCondition.Conditions)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RecordCondition.Conditions other) { - if (other == com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.getDefaultInstance()) return this; - if (conditionsBuilder_ == null) { - if (!other.conditions_.isEmpty()) { - if (conditions_.isEmpty()) { - conditions_ = other.conditions_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureConditionsIsMutable(); - conditions_.addAll(other.conditions_); - } - onChanged(); - } - } else { - if (!other.conditions_.isEmpty()) { - if (conditionsBuilder_.isEmpty()) { - conditionsBuilder_.dispose(); - conditionsBuilder_ = null; - conditions_ = other.conditions_; - bitField0_ = (bitField0_ & ~0x00000001); - conditionsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getConditionsFieldBuilder() : null; - } else { - conditionsBuilder_.addAllMessages(other.conditions_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List conditions_ = - java.util.Collections.emptyList(); - private void ensureConditionsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - conditions_ = new java.util.ArrayList(conditions_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition.Condition, com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder, com.google.privacy.dlp.v2beta1.RecordCondition.ConditionOrBuilder> conditionsBuilder_; - - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public java.util.List getConditionsList() { - if (conditionsBuilder_ == null) { - return java.util.Collections.unmodifiableList(conditions_); - } else { - return conditionsBuilder_.getMessageList(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public int getConditionsCount() { - if (conditionsBuilder_ == null) { - return conditions_.size(); - } else { - return conditionsBuilder_.getCount(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Condition getConditions(int index) { - if (conditionsBuilder_ == null) { - return conditions_.get(index); - } else { - return conditionsBuilder_.getMessage(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public Builder setConditions( - int index, com.google.privacy.dlp.v2beta1.RecordCondition.Condition value) { - if (conditionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureConditionsIsMutable(); - conditions_.set(index, value); - onChanged(); - } else { - conditionsBuilder_.setMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public Builder setConditions( - int index, com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder builderForValue) { - if (conditionsBuilder_ == null) { - ensureConditionsIsMutable(); - conditions_.set(index, builderForValue.build()); - onChanged(); - } else { - conditionsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public Builder addConditions(com.google.privacy.dlp.v2beta1.RecordCondition.Condition value) { - if (conditionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureConditionsIsMutable(); - conditions_.add(value); - onChanged(); - } else { - conditionsBuilder_.addMessage(value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public Builder addConditions( - int index, com.google.privacy.dlp.v2beta1.RecordCondition.Condition value) { - if (conditionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureConditionsIsMutable(); - conditions_.add(index, value); - onChanged(); - } else { - conditionsBuilder_.addMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public Builder addConditions( - com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder builderForValue) { - if (conditionsBuilder_ == null) { - ensureConditionsIsMutable(); - conditions_.add(builderForValue.build()); - onChanged(); - } else { - conditionsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public Builder addConditions( - int index, com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder builderForValue) { - if (conditionsBuilder_ == null) { - ensureConditionsIsMutable(); - conditions_.add(index, builderForValue.build()); - onChanged(); - } else { - conditionsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public Builder addAllConditions( - java.lang.Iterable values) { - if (conditionsBuilder_ == null) { - ensureConditionsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, conditions_); - onChanged(); - } else { - conditionsBuilder_.addAllMessages(values); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public Builder clearConditions() { - if (conditionsBuilder_ == null) { - conditions_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - conditionsBuilder_.clear(); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public Builder removeConditions(int index) { - if (conditionsBuilder_ == null) { - ensureConditionsIsMutable(); - conditions_.remove(index); - onChanged(); - } else { - conditionsBuilder_.remove(index); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder getConditionsBuilder( - int index) { - return getConditionsFieldBuilder().getBuilder(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.ConditionOrBuilder getConditionsOrBuilder( - int index) { - if (conditionsBuilder_ == null) { - return conditions_.get(index); } else { - return conditionsBuilder_.getMessageOrBuilder(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public java.util.List - getConditionsOrBuilderList() { - if (conditionsBuilder_ != null) { - return conditionsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(conditions_); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder addConditionsBuilder() { - return getConditionsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.RecordCondition.Condition.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder addConditionsBuilder( - int index) { - return getConditionsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.RecordCondition.Condition.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.RecordCondition.Condition conditions = 1; - */ - public java.util.List - getConditionsBuilderList() { - return getConditionsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition.Condition, com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder, com.google.privacy.dlp.v2beta1.RecordCondition.ConditionOrBuilder> - getConditionsFieldBuilder() { - if (conditionsBuilder_ == null) { - conditionsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition.Condition, com.google.privacy.dlp.v2beta1.RecordCondition.Condition.Builder, com.google.privacy.dlp.v2beta1.RecordCondition.ConditionOrBuilder>( - conditions_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - conditions_ = null; - } - return conditionsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RecordCondition.Conditions) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RecordCondition.Conditions) - private static final com.google.privacy.dlp.v2beta1.RecordCondition.Conditions DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RecordCondition.Conditions(); - } - - public static com.google.privacy.dlp.v2beta1.RecordCondition.Conditions getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Conditions parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Conditions(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Conditions getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface ExpressionsOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RecordCondition.Expressions) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * The operator to apply to the result of conditions. Default and currently
-     * only supported value is `AND`.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - */ - int getLogicalOperatorValue(); - /** - *
-     * The operator to apply to the result of conditions. Default and currently
-     * only supported value is `AND`.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - */ - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator getLogicalOperator(); - - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - boolean hasConditions(); - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions getConditions(); - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - com.google.privacy.dlp.v2beta1.RecordCondition.ConditionsOrBuilder getConditionsOrBuilder(); - - public com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.TypeCase getTypeCase(); - } - /** - *
-   * A collection of expressions
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordCondition.Expressions} - */ - public static final class Expressions extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RecordCondition.Expressions) - ExpressionsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Expressions.newBuilder() to construct. - private Expressions(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Expressions() { - logicalOperator_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Expressions( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - int rawValue = input.readEnum(); - - logicalOperator_ = rawValue; - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.Builder subBuilder = null; - if (typeCase_ == 3) { - subBuilder = ((com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 3; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Expressions_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Expressions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.class, com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.Builder.class); - } - - /** - * Protobuf enum {@code google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator} - */ - public enum LogicalOperator - implements com.google.protobuf.ProtocolMessageEnum { - /** - * LOGICAL_OPERATOR_UNSPECIFIED = 0; - */ - LOGICAL_OPERATOR_UNSPECIFIED(0), - /** - * AND = 1; - */ - AND(1), - UNRECOGNIZED(-1), - ; - - /** - * LOGICAL_OPERATOR_UNSPECIFIED = 0; - */ - public static final int LOGICAL_OPERATOR_UNSPECIFIED_VALUE = 0; - /** - * AND = 1; - */ - public static final int AND_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; - } - - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static LogicalOperator valueOf(int value) { - return forNumber(value); - } - - public static LogicalOperator forNumber(int value) { - switch (value) { - case 0: return LOGICAL_OPERATOR_UNSPECIFIED; - case 1: return AND; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - private static final com.google.protobuf.Internal.EnumLiteMap< - LogicalOperator> internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public LogicalOperator findValueByNumber(int number) { - return LogicalOperator.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - 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.privacy.dlp.v2beta1.RecordCondition.Expressions.getDescriptor().getEnumTypes().get(0); - } - - private static final LogicalOperator[] VALUES = values(); - - public static LogicalOperator 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 LogicalOperator(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator) - } - - private int typeCase_ = 0; - private java.lang.Object type_; - public enum TypeCase - implements com.google.protobuf.Internal.EnumLite { - CONDITIONS(3), - TYPE_NOT_SET(0); - private final int value; - private TypeCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TypeCase valueOf(int value) { - return forNumber(value); - } - - public static TypeCase forNumber(int value) { - switch (value) { - case 3: return CONDITIONS; - case 0: return TYPE_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public static final int LOGICAL_OPERATOR_FIELD_NUMBER = 1; - private int logicalOperator_; - /** - *
-     * The operator to apply to the result of conditions. Default and currently
-     * only supported value is `AND`.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - */ - public int getLogicalOperatorValue() { - return logicalOperator_; - } - /** - *
-     * The operator to apply to the result of conditions. Default and currently
-     * only supported value is `AND`.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator getLogicalOperator() { - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator result = com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator.valueOf(logicalOperator_); - return result == null ? com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator.UNRECOGNIZED : result; - } - - public static final int CONDITIONS_FIELD_NUMBER = 3; - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public boolean hasConditions() { - return typeCase_ == 3; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Conditions getConditions() { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) type_; - } - return com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.ConditionsOrBuilder getConditionsOrBuilder() { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) type_; - } - return com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (logicalOperator_ != com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator.LOGICAL_OPERATOR_UNSPECIFIED.getNumber()) { - output.writeEnum(1, logicalOperator_); - } - if (typeCase_ == 3) { - output.writeMessage(3, (com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) type_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (logicalOperator_ != com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator.LOGICAL_OPERATOR_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(1, logicalOperator_); - } - if (typeCase_ == 3) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, (com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) type_); - } - 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.privacy.dlp.v2beta1.RecordCondition.Expressions)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions other = (com.google.privacy.dlp.v2beta1.RecordCondition.Expressions) obj; - - boolean result = true; - result = result && logicalOperator_ == other.logicalOperator_; - result = result && getTypeCase().equals( - other.getTypeCase()); - if (!result) return false; - switch (typeCase_) { - case 3: - result = result && getConditions() - .equals(other.getConditions()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + LOGICAL_OPERATOR_FIELD_NUMBER; - hash = (53 * hash) + logicalOperator_; - switch (typeCase_) { - case 3: - hash = (37 * hash) + CONDITIONS_FIELD_NUMBER; - hash = (53 * hash) + getConditions().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RecordCondition.Expressions parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Expressions parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Expressions parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Expressions 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.privacy.dlp.v2beta1.RecordCondition.Expressions parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Expressions parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Expressions parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Expressions 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.privacy.dlp.v2beta1.RecordCondition.Expressions parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Expressions 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.privacy.dlp.v2beta1.RecordCondition.Expressions parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition.Expressions parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RecordCondition.Expressions prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-     * A collection of expressions
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordCondition.Expressions} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RecordCondition.Expressions) - com.google.privacy.dlp.v2beta1.RecordCondition.ExpressionsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Expressions_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Expressions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.class, com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - logicalOperator_ = 0; - - typeCase_ = 0; - type_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_Expressions_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Expressions getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Expressions build() { - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Expressions buildPartial() { - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions result = new com.google.privacy.dlp.v2beta1.RecordCondition.Expressions(this); - result.logicalOperator_ = logicalOperator_; - if (typeCase_ == 3) { - if (conditionsBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = conditionsBuilder_.build(); - } - } - result.typeCase_ = typeCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RecordCondition.Expressions) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RecordCondition.Expressions)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RecordCondition.Expressions other) { - if (other == com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.getDefaultInstance()) return this; - if (other.logicalOperator_ != 0) { - setLogicalOperatorValue(other.getLogicalOperatorValue()); - } - switch (other.getTypeCase()) { - case CONDITIONS: { - mergeConditions(other.getConditions()); - break; - } - case TYPE_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RecordCondition.Expressions) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int typeCase_ = 0; - private java.lang.Object type_; - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public Builder clearType() { - typeCase_ = 0; - type_ = null; - onChanged(); - return this; - } - - - private int logicalOperator_ = 0; - /** - *
-       * The operator to apply to the result of conditions. Default and currently
-       * only supported value is `AND`.
-       * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - */ - public int getLogicalOperatorValue() { - return logicalOperator_; - } - /** - *
-       * The operator to apply to the result of conditions. Default and currently
-       * only supported value is `AND`.
-       * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - */ - public Builder setLogicalOperatorValue(int value) { - logicalOperator_ = value; - onChanged(); - return this; - } - /** - *
-       * The operator to apply to the result of conditions. Default and currently
-       * only supported value is `AND`.
-       * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator getLogicalOperator() { - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator result = com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator.valueOf(logicalOperator_); - return result == null ? com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator.UNRECOGNIZED : result; - } - /** - *
-       * The operator to apply to the result of conditions. Default and currently
-       * only supported value is `AND`.
-       * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - */ - public Builder setLogicalOperator(com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator value) { - if (value == null) { - throw new NullPointerException(); - } - - logicalOperator_ = value.getNumber(); - onChanged(); - return this; - } - /** - *
-       * The operator to apply to the result of conditions. Default and currently
-       * only supported value is `AND`.
-       * 
- * - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions.LogicalOperator logical_operator = 1; - */ - public Builder clearLogicalOperator() { - - logicalOperator_ = 0; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions, com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.Builder, com.google.privacy.dlp.v2beta1.RecordCondition.ConditionsOrBuilder> conditionsBuilder_; - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public boolean hasConditions() { - return typeCase_ == 3; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Conditions getConditions() { - if (conditionsBuilder_ == null) { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) type_; - } - return com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.getDefaultInstance(); - } else { - if (typeCase_ == 3) { - return conditionsBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public Builder setConditions(com.google.privacy.dlp.v2beta1.RecordCondition.Conditions value) { - if (conditionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - conditionsBuilder_.setMessage(value); - } - typeCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public Builder setConditions( - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.Builder builderForValue) { - if (conditionsBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - conditionsBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public Builder mergeConditions(com.google.privacy.dlp.v2beta1.RecordCondition.Conditions value) { - if (conditionsBuilder_ == null) { - if (typeCase_ == 3 && - type_ != com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.newBuilder((com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 3) { - conditionsBuilder_.mergeFrom(value); - } - conditionsBuilder_.setMessage(value); - } - typeCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public Builder clearConditions() { - if (conditionsBuilder_ == null) { - if (typeCase_ == 3) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 3) { - typeCase_ = 0; - type_ = null; - } - conditionsBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.Builder getConditionsBuilder() { - return getConditionsFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.ConditionsOrBuilder getConditionsOrBuilder() { - if ((typeCase_ == 3) && (conditionsBuilder_ != null)) { - return conditionsBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) type_; - } - return com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Conditions conditions = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions, com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.Builder, com.google.privacy.dlp.v2beta1.RecordCondition.ConditionsOrBuilder> - getConditionsFieldBuilder() { - if (conditionsBuilder_ == null) { - if (!(typeCase_ == 3)) { - type_ = com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.getDefaultInstance(); - } - conditionsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition.Conditions, com.google.privacy.dlp.v2beta1.RecordCondition.Conditions.Builder, com.google.privacy.dlp.v2beta1.RecordCondition.ConditionsOrBuilder>( - (com.google.privacy.dlp.v2beta1.RecordCondition.Conditions) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 3; - onChanged();; - return conditionsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RecordCondition.Expressions) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RecordCondition.Expressions) - private static final com.google.privacy.dlp.v2beta1.RecordCondition.Expressions DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RecordCondition.Expressions(); - } - - public static com.google.privacy.dlp.v2beta1.RecordCondition.Expressions getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Expressions parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Expressions(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition.Expressions getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public static final int EXPRESSIONS_FIELD_NUMBER = 3; - private com.google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions_; - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public boolean hasExpressions() { - return expressions_ != null; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Expressions getExpressions() { - return expressions_ == null ? com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.getDefaultInstance() : expressions_; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.ExpressionsOrBuilder getExpressionsOrBuilder() { - return getExpressions(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (expressions_ != null) { - output.writeMessage(3, getExpressions()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (expressions_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, getExpressions()); - } - 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.privacy.dlp.v2beta1.RecordCondition)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RecordCondition other = (com.google.privacy.dlp.v2beta1.RecordCondition) obj; - - boolean result = true; - result = result && (hasExpressions() == other.hasExpressions()); - if (hasExpressions()) { - result = result && getExpressions() - .equals(other.getExpressions()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasExpressions()) { - hash = (37 * hash) + EXPRESSIONS_FIELD_NUMBER; - hash = (53 * hash) + getExpressions().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RecordCondition parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition 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.privacy.dlp.v2beta1.RecordCondition parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition 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.privacy.dlp.v2beta1.RecordCondition parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition 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.privacy.dlp.v2beta1.RecordCondition parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordCondition parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RecordCondition prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * A condition for determining whether a transformation should be applied to
-   * a field.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordCondition} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RecordCondition) - com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordCondition.class, com.google.privacy.dlp.v2beta1.RecordCondition.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RecordCondition.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (expressionsBuilder_ == null) { - expressions_ = null; - } else { - expressions_ = null; - expressionsBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordCondition_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RecordCondition.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RecordCondition build() { - com.google.privacy.dlp.v2beta1.RecordCondition result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition buildPartial() { - com.google.privacy.dlp.v2beta1.RecordCondition result = new com.google.privacy.dlp.v2beta1.RecordCondition(this); - if (expressionsBuilder_ == null) { - result.expressions_ = expressions_; - } else { - result.expressions_ = expressionsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RecordCondition) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RecordCondition)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RecordCondition other) { - if (other == com.google.privacy.dlp.v2beta1.RecordCondition.getDefaultInstance()) return this; - if (other.hasExpressions()) { - mergeExpressions(other.getExpressions()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RecordCondition parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RecordCondition) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions, com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.Builder, com.google.privacy.dlp.v2beta1.RecordCondition.ExpressionsOrBuilder> expressionsBuilder_; - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public boolean hasExpressions() { - return expressionsBuilder_ != null || expressions_ != null; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Expressions getExpressions() { - if (expressionsBuilder_ == null) { - return expressions_ == null ? com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.getDefaultInstance() : expressions_; - } else { - return expressionsBuilder_.getMessage(); - } - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public Builder setExpressions(com.google.privacy.dlp.v2beta1.RecordCondition.Expressions value) { - if (expressionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - expressions_ = value; - onChanged(); - } else { - expressionsBuilder_.setMessage(value); - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public Builder setExpressions( - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.Builder builderForValue) { - if (expressionsBuilder_ == null) { - expressions_ = builderForValue.build(); - onChanged(); - } else { - expressionsBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public Builder mergeExpressions(com.google.privacy.dlp.v2beta1.RecordCondition.Expressions value) { - if (expressionsBuilder_ == null) { - if (expressions_ != null) { - expressions_ = - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.newBuilder(expressions_).mergeFrom(value).buildPartial(); - } else { - expressions_ = value; - } - onChanged(); - } else { - expressionsBuilder_.mergeFrom(value); - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public Builder clearExpressions() { - if (expressionsBuilder_ == null) { - expressions_ = null; - onChanged(); - } else { - expressions_ = null; - expressionsBuilder_ = null; - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.Builder getExpressionsBuilder() { - - onChanged(); - return getExpressionsFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.ExpressionsOrBuilder getExpressionsOrBuilder() { - if (expressionsBuilder_ != null) { - return expressionsBuilder_.getMessageOrBuilder(); - } else { - return expressions_ == null ? - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.getDefaultInstance() : expressions_; - } - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions, com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.Builder, com.google.privacy.dlp.v2beta1.RecordCondition.ExpressionsOrBuilder> - getExpressionsFieldBuilder() { - if (expressionsBuilder_ == null) { - expressionsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions, com.google.privacy.dlp.v2beta1.RecordCondition.Expressions.Builder, com.google.privacy.dlp.v2beta1.RecordCondition.ExpressionsOrBuilder>( - getExpressions(), - getParentForChildren(), - isClean()); - expressions_ = null; - } - return expressionsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RecordCondition) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RecordCondition) - private static final com.google.privacy.dlp.v2beta1.RecordCondition DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RecordCondition(); - } - - public static com.google.privacy.dlp.v2beta1.RecordCondition getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public RecordCondition parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RecordCondition(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RecordCondition getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordConditionOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordConditionOrBuilder.java deleted file mode 100644 index f10caf61e360..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordConditionOrBuilder.java +++ /dev/null @@ -1,22 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface RecordConditionOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RecordCondition) - com.google.protobuf.MessageOrBuilder { - - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - boolean hasExpressions(); - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - com.google.privacy.dlp.v2beta1.RecordCondition.Expressions getExpressions(); - /** - * .google.privacy.dlp.v2beta1.RecordCondition.Expressions expressions = 3; - */ - com.google.privacy.dlp.v2beta1.RecordCondition.ExpressionsOrBuilder getExpressionsOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordKey.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordKey.java deleted file mode 100644 index e144c7be7420..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordKey.java +++ /dev/null @@ -1,873 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Message for a unique key indicating a record that contains a finding.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordKey} - */ -public final class RecordKey extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RecordKey) - RecordKeyOrBuilder { -private static final long serialVersionUID = 0L; - // Use RecordKey.newBuilder() to construct. - private RecordKey(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private RecordKey() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private RecordKey( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.CloudStorageKey.Builder subBuilder = null; - if (typeCase_ == 1) { - subBuilder = ((com.google.privacy.dlp.v2beta1.CloudStorageKey) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.CloudStorageKey.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.CloudStorageKey) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 1; - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.DatastoreKey.Builder subBuilder = null; - if (typeCase_ == 2) { - subBuilder = ((com.google.privacy.dlp.v2beta1.DatastoreKey) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.DatastoreKey.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.DatastoreKey) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 2; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_RecordKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_RecordKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordKey.class, com.google.privacy.dlp.v2beta1.RecordKey.Builder.class); - } - - private int typeCase_ = 0; - private java.lang.Object type_; - public enum TypeCase - implements com.google.protobuf.Internal.EnumLite { - CLOUD_STORAGE_KEY(1), - DATASTORE_KEY(2), - TYPE_NOT_SET(0); - private final int value; - private TypeCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TypeCase valueOf(int value) { - return forNumber(value); - } - - public static TypeCase forNumber(int value) { - switch (value) { - case 1: return CLOUD_STORAGE_KEY; - case 2: return DATASTORE_KEY; - case 0: return TYPE_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public static final int CLOUD_STORAGE_KEY_FIELD_NUMBER = 1; - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public boolean hasCloudStorageKey() { - return typeCase_ == 1; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageKey getCloudStorageKey() { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.CloudStorageKey) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStorageKey.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageKeyOrBuilder getCloudStorageKeyOrBuilder() { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.CloudStorageKey) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStorageKey.getDefaultInstance(); - } - - public static final int DATASTORE_KEY_FIELD_NUMBER = 2; - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public boolean hasDatastoreKey() { - return typeCase_ == 2; - } - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public com.google.privacy.dlp.v2beta1.DatastoreKey getDatastoreKey() { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.DatastoreKey) type_; - } - return com.google.privacy.dlp.v2beta1.DatastoreKey.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public com.google.privacy.dlp.v2beta1.DatastoreKeyOrBuilder getDatastoreKeyOrBuilder() { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.DatastoreKey) type_; - } - return com.google.privacy.dlp.v2beta1.DatastoreKey.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (typeCase_ == 1) { - output.writeMessage(1, (com.google.privacy.dlp.v2beta1.CloudStorageKey) type_); - } - if (typeCase_ == 2) { - output.writeMessage(2, (com.google.privacy.dlp.v2beta1.DatastoreKey) type_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (typeCase_ == 1) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, (com.google.privacy.dlp.v2beta1.CloudStorageKey) type_); - } - if (typeCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, (com.google.privacy.dlp.v2beta1.DatastoreKey) type_); - } - 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.privacy.dlp.v2beta1.RecordKey)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RecordKey other = (com.google.privacy.dlp.v2beta1.RecordKey) obj; - - boolean result = true; - result = result && getTypeCase().equals( - other.getTypeCase()); - if (!result) return false; - switch (typeCase_) { - case 1: - result = result && getCloudStorageKey() - .equals(other.getCloudStorageKey()); - break; - case 2: - result = result && getDatastoreKey() - .equals(other.getDatastoreKey()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (typeCase_) { - case 1: - hash = (37 * hash) + CLOUD_STORAGE_KEY_FIELD_NUMBER; - hash = (53 * hash) + getCloudStorageKey().hashCode(); - break; - case 2: - hash = (37 * hash) + DATASTORE_KEY_FIELD_NUMBER; - hash = (53 * hash) + getDatastoreKey().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RecordKey parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordKey parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordKey parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordKey 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.privacy.dlp.v2beta1.RecordKey parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordKey parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordKey parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordKey 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.privacy.dlp.v2beta1.RecordKey parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordKey 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.privacy.dlp.v2beta1.RecordKey parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordKey parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RecordKey prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Message for a unique key indicating a record that contains a finding.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordKey} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RecordKey) - com.google.privacy.dlp.v2beta1.RecordKeyOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_RecordKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_RecordKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordKey.class, com.google.privacy.dlp.v2beta1.RecordKey.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RecordKey.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - typeCase_ = 0; - type_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_RecordKey_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RecordKey getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RecordKey.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RecordKey build() { - com.google.privacy.dlp.v2beta1.RecordKey result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RecordKey buildPartial() { - com.google.privacy.dlp.v2beta1.RecordKey result = new com.google.privacy.dlp.v2beta1.RecordKey(this); - if (typeCase_ == 1) { - if (cloudStorageKeyBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = cloudStorageKeyBuilder_.build(); - } - } - if (typeCase_ == 2) { - if (datastoreKeyBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = datastoreKeyBuilder_.build(); - } - } - result.typeCase_ = typeCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RecordKey) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RecordKey)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RecordKey other) { - if (other == com.google.privacy.dlp.v2beta1.RecordKey.getDefaultInstance()) return this; - switch (other.getTypeCase()) { - case CLOUD_STORAGE_KEY: { - mergeCloudStorageKey(other.getCloudStorageKey()); - break; - } - case DATASTORE_KEY: { - mergeDatastoreKey(other.getDatastoreKey()); - break; - } - case TYPE_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RecordKey parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RecordKey) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int typeCase_ = 0; - private java.lang.Object type_; - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public Builder clearType() { - typeCase_ = 0; - type_ = null; - onChanged(); - return this; - } - - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStorageKey, com.google.privacy.dlp.v2beta1.CloudStorageKey.Builder, com.google.privacy.dlp.v2beta1.CloudStorageKeyOrBuilder> cloudStorageKeyBuilder_; - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public boolean hasCloudStorageKey() { - return typeCase_ == 1; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageKey getCloudStorageKey() { - if (cloudStorageKeyBuilder_ == null) { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.CloudStorageKey) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStorageKey.getDefaultInstance(); - } else { - if (typeCase_ == 1) { - return cloudStorageKeyBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.CloudStorageKey.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public Builder setCloudStorageKey(com.google.privacy.dlp.v2beta1.CloudStorageKey value) { - if (cloudStorageKeyBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - cloudStorageKeyBuilder_.setMessage(value); - } - typeCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public Builder setCloudStorageKey( - com.google.privacy.dlp.v2beta1.CloudStorageKey.Builder builderForValue) { - if (cloudStorageKeyBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - cloudStorageKeyBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public Builder mergeCloudStorageKey(com.google.privacy.dlp.v2beta1.CloudStorageKey value) { - if (cloudStorageKeyBuilder_ == null) { - if (typeCase_ == 1 && - type_ != com.google.privacy.dlp.v2beta1.CloudStorageKey.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.CloudStorageKey.newBuilder((com.google.privacy.dlp.v2beta1.CloudStorageKey) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 1) { - cloudStorageKeyBuilder_.mergeFrom(value); - } - cloudStorageKeyBuilder_.setMessage(value); - } - typeCase_ = 1; - return this; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public Builder clearCloudStorageKey() { - if (cloudStorageKeyBuilder_ == null) { - if (typeCase_ == 1) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 1) { - typeCase_ = 0; - type_ = null; - } - cloudStorageKeyBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageKey.Builder getCloudStorageKeyBuilder() { - return getCloudStorageKeyFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageKeyOrBuilder getCloudStorageKeyOrBuilder() { - if ((typeCase_ == 1) && (cloudStorageKeyBuilder_ != null)) { - return cloudStorageKeyBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.CloudStorageKey) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStorageKey.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStorageKey, com.google.privacy.dlp.v2beta1.CloudStorageKey.Builder, com.google.privacy.dlp.v2beta1.CloudStorageKeyOrBuilder> - getCloudStorageKeyFieldBuilder() { - if (cloudStorageKeyBuilder_ == null) { - if (!(typeCase_ == 1)) { - type_ = com.google.privacy.dlp.v2beta1.CloudStorageKey.getDefaultInstance(); - } - cloudStorageKeyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStorageKey, com.google.privacy.dlp.v2beta1.CloudStorageKey.Builder, com.google.privacy.dlp.v2beta1.CloudStorageKeyOrBuilder>( - (com.google.privacy.dlp.v2beta1.CloudStorageKey) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 1; - onChanged();; - return cloudStorageKeyBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DatastoreKey, com.google.privacy.dlp.v2beta1.DatastoreKey.Builder, com.google.privacy.dlp.v2beta1.DatastoreKeyOrBuilder> datastoreKeyBuilder_; - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public boolean hasDatastoreKey() { - return typeCase_ == 2; - } - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public com.google.privacy.dlp.v2beta1.DatastoreKey getDatastoreKey() { - if (datastoreKeyBuilder_ == null) { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.DatastoreKey) type_; - } - return com.google.privacy.dlp.v2beta1.DatastoreKey.getDefaultInstance(); - } else { - if (typeCase_ == 2) { - return datastoreKeyBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.DatastoreKey.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public Builder setDatastoreKey(com.google.privacy.dlp.v2beta1.DatastoreKey value) { - if (datastoreKeyBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - datastoreKeyBuilder_.setMessage(value); - } - typeCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public Builder setDatastoreKey( - com.google.privacy.dlp.v2beta1.DatastoreKey.Builder builderForValue) { - if (datastoreKeyBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - datastoreKeyBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public Builder mergeDatastoreKey(com.google.privacy.dlp.v2beta1.DatastoreKey value) { - if (datastoreKeyBuilder_ == null) { - if (typeCase_ == 2 && - type_ != com.google.privacy.dlp.v2beta1.DatastoreKey.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.DatastoreKey.newBuilder((com.google.privacy.dlp.v2beta1.DatastoreKey) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 2) { - datastoreKeyBuilder_.mergeFrom(value); - } - datastoreKeyBuilder_.setMessage(value); - } - typeCase_ = 2; - return this; - } - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public Builder clearDatastoreKey() { - if (datastoreKeyBuilder_ == null) { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - } - datastoreKeyBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public com.google.privacy.dlp.v2beta1.DatastoreKey.Builder getDatastoreKeyBuilder() { - return getDatastoreKeyFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - public com.google.privacy.dlp.v2beta1.DatastoreKeyOrBuilder getDatastoreKeyOrBuilder() { - if ((typeCase_ == 2) && (datastoreKeyBuilder_ != null)) { - return datastoreKeyBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.DatastoreKey) type_; - } - return com.google.privacy.dlp.v2beta1.DatastoreKey.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DatastoreKey, com.google.privacy.dlp.v2beta1.DatastoreKey.Builder, com.google.privacy.dlp.v2beta1.DatastoreKeyOrBuilder> - getDatastoreKeyFieldBuilder() { - if (datastoreKeyBuilder_ == null) { - if (!(typeCase_ == 2)) { - type_ = com.google.privacy.dlp.v2beta1.DatastoreKey.getDefaultInstance(); - } - datastoreKeyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DatastoreKey, com.google.privacy.dlp.v2beta1.DatastoreKey.Builder, com.google.privacy.dlp.v2beta1.DatastoreKeyOrBuilder>( - (com.google.privacy.dlp.v2beta1.DatastoreKey) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 2; - onChanged();; - return datastoreKeyBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RecordKey) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RecordKey) - private static final com.google.privacy.dlp.v2beta1.RecordKey DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RecordKey(); - } - - public static com.google.privacy.dlp.v2beta1.RecordKey getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public RecordKey parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RecordKey(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RecordKey getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordKeyOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordKeyOrBuilder.java deleted file mode 100644 index 06f4c0f266e1..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordKeyOrBuilder.java +++ /dev/null @@ -1,37 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface RecordKeyOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RecordKey) - com.google.protobuf.MessageOrBuilder { - - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - boolean hasCloudStorageKey(); - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - com.google.privacy.dlp.v2beta1.CloudStorageKey getCloudStorageKey(); - /** - * .google.privacy.dlp.v2beta1.CloudStorageKey cloud_storage_key = 1; - */ - com.google.privacy.dlp.v2beta1.CloudStorageKeyOrBuilder getCloudStorageKeyOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - boolean hasDatastoreKey(); - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - com.google.privacy.dlp.v2beta1.DatastoreKey getDatastoreKey(); - /** - * .google.privacy.dlp.v2beta1.DatastoreKey datastore_key = 2; - */ - com.google.privacy.dlp.v2beta1.DatastoreKeyOrBuilder getDatastoreKeyOrBuilder(); - - public com.google.privacy.dlp.v2beta1.RecordKey.TypeCase getTypeCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordSuppression.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordSuppression.java deleted file mode 100644 index b3e9a714feaa..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordSuppression.java +++ /dev/null @@ -1,580 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Configuration to suppress records whose suppression conditions evaluate to
- * true.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordSuppression} - */ -public final class RecordSuppression extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RecordSuppression) - RecordSuppressionOrBuilder { -private static final long serialVersionUID = 0L; - // Use RecordSuppression.newBuilder() to construct. - private RecordSuppression(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private RecordSuppression() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private RecordSuppression( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.RecordCondition.Builder subBuilder = null; - if (condition_ != null) { - subBuilder = condition_.toBuilder(); - } - condition_ = input.readMessage(com.google.privacy.dlp.v2beta1.RecordCondition.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(condition_); - condition_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordSuppression_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordSuppression_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordSuppression.class, com.google.privacy.dlp.v2beta1.RecordSuppression.Builder.class); - } - - public static final int CONDITION_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.RecordCondition condition_; - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public boolean hasCondition() { - return condition_ != null; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition getCondition() { - return condition_ == null ? com.google.privacy.dlp.v2beta1.RecordCondition.getDefaultInstance() : condition_; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder getConditionOrBuilder() { - return getCondition(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (condition_ != null) { - output.writeMessage(1, getCondition()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (condition_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getCondition()); - } - 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.privacy.dlp.v2beta1.RecordSuppression)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RecordSuppression other = (com.google.privacy.dlp.v2beta1.RecordSuppression) obj; - - boolean result = true; - result = result && (hasCondition() == other.hasCondition()); - if (hasCondition()) { - result = result && getCondition() - .equals(other.getCondition()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasCondition()) { - hash = (37 * hash) + CONDITION_FIELD_NUMBER; - hash = (53 * hash) + getCondition().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RecordSuppression parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordSuppression parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordSuppression parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordSuppression 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.privacy.dlp.v2beta1.RecordSuppression parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordSuppression parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordSuppression parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordSuppression 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.privacy.dlp.v2beta1.RecordSuppression parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordSuppression 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.privacy.dlp.v2beta1.RecordSuppression parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordSuppression parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RecordSuppression prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Configuration to suppress records whose suppression conditions evaluate to
-   * true.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordSuppression} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RecordSuppression) - com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordSuppression_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordSuppression_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordSuppression.class, com.google.privacy.dlp.v2beta1.RecordSuppression.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RecordSuppression.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (conditionBuilder_ == null) { - condition_ = null; - } else { - condition_ = null; - conditionBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordSuppression_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RecordSuppression getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RecordSuppression.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RecordSuppression build() { - com.google.privacy.dlp.v2beta1.RecordSuppression result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RecordSuppression buildPartial() { - com.google.privacy.dlp.v2beta1.RecordSuppression result = new com.google.privacy.dlp.v2beta1.RecordSuppression(this); - if (conditionBuilder_ == null) { - result.condition_ = condition_; - } else { - result.condition_ = conditionBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RecordSuppression) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RecordSuppression)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RecordSuppression other) { - if (other == com.google.privacy.dlp.v2beta1.RecordSuppression.getDefaultInstance()) return this; - if (other.hasCondition()) { - mergeCondition(other.getCondition()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RecordSuppression parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RecordSuppression) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.RecordCondition condition_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition, com.google.privacy.dlp.v2beta1.RecordCondition.Builder, com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder> conditionBuilder_; - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public boolean hasCondition() { - return conditionBuilder_ != null || condition_ != null; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition getCondition() { - if (conditionBuilder_ == null) { - return condition_ == null ? com.google.privacy.dlp.v2beta1.RecordCondition.getDefaultInstance() : condition_; - } else { - return conditionBuilder_.getMessage(); - } - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public Builder setCondition(com.google.privacy.dlp.v2beta1.RecordCondition value) { - if (conditionBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - condition_ = value; - onChanged(); - } else { - conditionBuilder_.setMessage(value); - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public Builder setCondition( - com.google.privacy.dlp.v2beta1.RecordCondition.Builder builderForValue) { - if (conditionBuilder_ == null) { - condition_ = builderForValue.build(); - onChanged(); - } else { - conditionBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public Builder mergeCondition(com.google.privacy.dlp.v2beta1.RecordCondition value) { - if (conditionBuilder_ == null) { - if (condition_ != null) { - condition_ = - com.google.privacy.dlp.v2beta1.RecordCondition.newBuilder(condition_).mergeFrom(value).buildPartial(); - } else { - condition_ = value; - } - onChanged(); - } else { - conditionBuilder_.mergeFrom(value); - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public Builder clearCondition() { - if (conditionBuilder_ == null) { - condition_ = null; - onChanged(); - } else { - condition_ = null; - conditionBuilder_ = null; - } - - return this; - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordCondition.Builder getConditionBuilder() { - - onChanged(); - return getConditionFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - public com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder getConditionOrBuilder() { - if (conditionBuilder_ != null) { - return conditionBuilder_.getMessageOrBuilder(); - } else { - return condition_ == null ? - com.google.privacy.dlp.v2beta1.RecordCondition.getDefaultInstance() : condition_; - } - } - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition, com.google.privacy.dlp.v2beta1.RecordCondition.Builder, com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder> - getConditionFieldBuilder() { - if (conditionBuilder_ == null) { - conditionBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordCondition, com.google.privacy.dlp.v2beta1.RecordCondition.Builder, com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder>( - getCondition(), - getParentForChildren(), - isClean()); - condition_ = null; - } - return conditionBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RecordSuppression) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RecordSuppression) - private static final com.google.privacy.dlp.v2beta1.RecordSuppression DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RecordSuppression(); - } - - public static com.google.privacy.dlp.v2beta1.RecordSuppression getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public RecordSuppression parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RecordSuppression(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RecordSuppression getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordSuppressionOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordSuppressionOrBuilder.java deleted file mode 100644 index 2e93d3546b82..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordSuppressionOrBuilder.java +++ /dev/null @@ -1,22 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface RecordSuppressionOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RecordSuppression) - com.google.protobuf.MessageOrBuilder { - - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - boolean hasCondition(); - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - com.google.privacy.dlp.v2beta1.RecordCondition getCondition(); - /** - * .google.privacy.dlp.v2beta1.RecordCondition condition = 1; - */ - com.google.privacy.dlp.v2beta1.RecordConditionOrBuilder getConditionOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordTransformations.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordTransformations.java deleted file mode 100644 index d14fb510f3d2..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordTransformations.java +++ /dev/null @@ -1,1294 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * A type of transformation that is applied over structured data such as a
- * table.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordTransformations} - */ -public final class RecordTransformations extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RecordTransformations) - RecordTransformationsOrBuilder { -private static final long serialVersionUID = 0L; - // Use RecordTransformations.newBuilder() to construct. - private RecordTransformations(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private RecordTransformations() { - fieldTransformations_ = java.util.Collections.emptyList(); - recordSuppressions_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private RecordTransformations( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - fieldTransformations_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - fieldTransformations_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.FieldTransformation.parser(), extensionRegistry)); - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - recordSuppressions_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - recordSuppressions_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.RecordSuppression.parser(), extensionRegistry)); - 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) == 0x00000001)) { - fieldTransformations_ = java.util.Collections.unmodifiableList(fieldTransformations_); - } - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - recordSuppressions_ = java.util.Collections.unmodifiableList(recordSuppressions_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordTransformations_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordTransformations_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordTransformations.class, com.google.privacy.dlp.v2beta1.RecordTransformations.Builder.class); - } - - public static final int FIELD_TRANSFORMATIONS_FIELD_NUMBER = 1; - private java.util.List fieldTransformations_; - /** - *
-   * Transform the record by applying various field transformations.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public java.util.List getFieldTransformationsList() { - return fieldTransformations_; - } - /** - *
-   * Transform the record by applying various field transformations.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public java.util.List - getFieldTransformationsOrBuilderList() { - return fieldTransformations_; - } - /** - *
-   * Transform the record by applying various field transformations.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public int getFieldTransformationsCount() { - return fieldTransformations_.size(); - } - /** - *
-   * Transform the record by applying various field transformations.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformation getFieldTransformations(int index) { - return fieldTransformations_.get(index); - } - /** - *
-   * Transform the record by applying various field transformations.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder getFieldTransformationsOrBuilder( - int index) { - return fieldTransformations_.get(index); - } - - public static final int RECORD_SUPPRESSIONS_FIELD_NUMBER = 2; - private java.util.List recordSuppressions_; - /** - *
-   * Configuration defining which records get suppressed entirely. Records that
-   * match any suppression rule are omitted from the output [optional].
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public java.util.List getRecordSuppressionsList() { - return recordSuppressions_; - } - /** - *
-   * Configuration defining which records get suppressed entirely. Records that
-   * match any suppression rule are omitted from the output [optional].
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public java.util.List - getRecordSuppressionsOrBuilderList() { - return recordSuppressions_; - } - /** - *
-   * Configuration defining which records get suppressed entirely. Records that
-   * match any suppression rule are omitted from the output [optional].
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public int getRecordSuppressionsCount() { - return recordSuppressions_.size(); - } - /** - *
-   * Configuration defining which records get suppressed entirely. Records that
-   * match any suppression rule are omitted from the output [optional].
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppression getRecordSuppressions(int index) { - return recordSuppressions_.get(index); - } - /** - *
-   * Configuration defining which records get suppressed entirely. Records that
-   * match any suppression rule are omitted from the output [optional].
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder getRecordSuppressionsOrBuilder( - int index) { - return recordSuppressions_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < fieldTransformations_.size(); i++) { - output.writeMessage(1, fieldTransformations_.get(i)); - } - for (int i = 0; i < recordSuppressions_.size(); i++) { - output.writeMessage(2, recordSuppressions_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < fieldTransformations_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, fieldTransformations_.get(i)); - } - for (int i = 0; i < recordSuppressions_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, recordSuppressions_.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.privacy.dlp.v2beta1.RecordTransformations)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RecordTransformations other = (com.google.privacy.dlp.v2beta1.RecordTransformations) obj; - - boolean result = true; - result = result && getFieldTransformationsList() - .equals(other.getFieldTransformationsList()); - result = result && getRecordSuppressionsList() - .equals(other.getRecordSuppressionsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getFieldTransformationsCount() > 0) { - hash = (37 * hash) + FIELD_TRANSFORMATIONS_FIELD_NUMBER; - hash = (53 * hash) + getFieldTransformationsList().hashCode(); - } - if (getRecordSuppressionsCount() > 0) { - hash = (37 * hash) + RECORD_SUPPRESSIONS_FIELD_NUMBER; - hash = (53 * hash) + getRecordSuppressionsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RecordTransformations parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordTransformations parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordTransformations parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordTransformations 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.privacy.dlp.v2beta1.RecordTransformations parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RecordTransformations parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RecordTransformations parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordTransformations 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.privacy.dlp.v2beta1.RecordTransformations parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordTransformations 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.privacy.dlp.v2beta1.RecordTransformations parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RecordTransformations parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RecordTransformations prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * A type of transformation that is applied over structured data such as a
-   * table.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RecordTransformations} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RecordTransformations) - com.google.privacy.dlp.v2beta1.RecordTransformationsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordTransformations_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordTransformations_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RecordTransformations.class, com.google.privacy.dlp.v2beta1.RecordTransformations.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RecordTransformations.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getFieldTransformationsFieldBuilder(); - getRecordSuppressionsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (fieldTransformationsBuilder_ == null) { - fieldTransformations_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - fieldTransformationsBuilder_.clear(); - } - if (recordSuppressionsBuilder_ == null) { - recordSuppressions_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - recordSuppressionsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RecordTransformations_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RecordTransformations getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RecordTransformations.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RecordTransformations build() { - com.google.privacy.dlp.v2beta1.RecordTransformations result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RecordTransformations buildPartial() { - com.google.privacy.dlp.v2beta1.RecordTransformations result = new com.google.privacy.dlp.v2beta1.RecordTransformations(this); - int from_bitField0_ = bitField0_; - if (fieldTransformationsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - fieldTransformations_ = java.util.Collections.unmodifiableList(fieldTransformations_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.fieldTransformations_ = fieldTransformations_; - } else { - result.fieldTransformations_ = fieldTransformationsBuilder_.build(); - } - if (recordSuppressionsBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - recordSuppressions_ = java.util.Collections.unmodifiableList(recordSuppressions_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.recordSuppressions_ = recordSuppressions_; - } else { - result.recordSuppressions_ = recordSuppressionsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RecordTransformations) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RecordTransformations)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RecordTransformations other) { - if (other == com.google.privacy.dlp.v2beta1.RecordTransformations.getDefaultInstance()) return this; - if (fieldTransformationsBuilder_ == null) { - if (!other.fieldTransformations_.isEmpty()) { - if (fieldTransformations_.isEmpty()) { - fieldTransformations_ = other.fieldTransformations_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureFieldTransformationsIsMutable(); - fieldTransformations_.addAll(other.fieldTransformations_); - } - onChanged(); - } - } else { - if (!other.fieldTransformations_.isEmpty()) { - if (fieldTransformationsBuilder_.isEmpty()) { - fieldTransformationsBuilder_.dispose(); - fieldTransformationsBuilder_ = null; - fieldTransformations_ = other.fieldTransformations_; - bitField0_ = (bitField0_ & ~0x00000001); - fieldTransformationsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getFieldTransformationsFieldBuilder() : null; - } else { - fieldTransformationsBuilder_.addAllMessages(other.fieldTransformations_); - } - } - } - if (recordSuppressionsBuilder_ == null) { - if (!other.recordSuppressions_.isEmpty()) { - if (recordSuppressions_.isEmpty()) { - recordSuppressions_ = other.recordSuppressions_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureRecordSuppressionsIsMutable(); - recordSuppressions_.addAll(other.recordSuppressions_); - } - onChanged(); - } - } else { - if (!other.recordSuppressions_.isEmpty()) { - if (recordSuppressionsBuilder_.isEmpty()) { - recordSuppressionsBuilder_.dispose(); - recordSuppressionsBuilder_ = null; - recordSuppressions_ = other.recordSuppressions_; - bitField0_ = (bitField0_ & ~0x00000002); - recordSuppressionsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getRecordSuppressionsFieldBuilder() : null; - } else { - recordSuppressionsBuilder_.addAllMessages(other.recordSuppressions_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RecordTransformations parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RecordTransformations) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List fieldTransformations_ = - java.util.Collections.emptyList(); - private void ensureFieldTransformationsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - fieldTransformations_ = new java.util.ArrayList(fieldTransformations_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldTransformation, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder, com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder> fieldTransformationsBuilder_; - - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public java.util.List getFieldTransformationsList() { - if (fieldTransformationsBuilder_ == null) { - return java.util.Collections.unmodifiableList(fieldTransformations_); - } else { - return fieldTransformationsBuilder_.getMessageList(); - } - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public int getFieldTransformationsCount() { - if (fieldTransformationsBuilder_ == null) { - return fieldTransformations_.size(); - } else { - return fieldTransformationsBuilder_.getCount(); - } - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformation getFieldTransformations(int index) { - if (fieldTransformationsBuilder_ == null) { - return fieldTransformations_.get(index); - } else { - return fieldTransformationsBuilder_.getMessage(index); - } - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public Builder setFieldTransformations( - int index, com.google.privacy.dlp.v2beta1.FieldTransformation value) { - if (fieldTransformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldTransformationsIsMutable(); - fieldTransformations_.set(index, value); - onChanged(); - } else { - fieldTransformationsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public Builder setFieldTransformations( - int index, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder builderForValue) { - if (fieldTransformationsBuilder_ == null) { - ensureFieldTransformationsIsMutable(); - fieldTransformations_.set(index, builderForValue.build()); - onChanged(); - } else { - fieldTransformationsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public Builder addFieldTransformations(com.google.privacy.dlp.v2beta1.FieldTransformation value) { - if (fieldTransformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldTransformationsIsMutable(); - fieldTransformations_.add(value); - onChanged(); - } else { - fieldTransformationsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public Builder addFieldTransformations( - int index, com.google.privacy.dlp.v2beta1.FieldTransformation value) { - if (fieldTransformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldTransformationsIsMutable(); - fieldTransformations_.add(index, value); - onChanged(); - } else { - fieldTransformationsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public Builder addFieldTransformations( - com.google.privacy.dlp.v2beta1.FieldTransformation.Builder builderForValue) { - if (fieldTransformationsBuilder_ == null) { - ensureFieldTransformationsIsMutable(); - fieldTransformations_.add(builderForValue.build()); - onChanged(); - } else { - fieldTransformationsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public Builder addFieldTransformations( - int index, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder builderForValue) { - if (fieldTransformationsBuilder_ == null) { - ensureFieldTransformationsIsMutable(); - fieldTransformations_.add(index, builderForValue.build()); - onChanged(); - } else { - fieldTransformationsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public Builder addAllFieldTransformations( - java.lang.Iterable values) { - if (fieldTransformationsBuilder_ == null) { - ensureFieldTransformationsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, fieldTransformations_); - onChanged(); - } else { - fieldTransformationsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public Builder clearFieldTransformations() { - if (fieldTransformationsBuilder_ == null) { - fieldTransformations_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - fieldTransformationsBuilder_.clear(); - } - return this; - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public Builder removeFieldTransformations(int index) { - if (fieldTransformationsBuilder_ == null) { - ensureFieldTransformationsIsMutable(); - fieldTransformations_.remove(index); - onChanged(); - } else { - fieldTransformationsBuilder_.remove(index); - } - return this; - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformation.Builder getFieldTransformationsBuilder( - int index) { - return getFieldTransformationsFieldBuilder().getBuilder(index); - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder getFieldTransformationsOrBuilder( - int index) { - if (fieldTransformationsBuilder_ == null) { - return fieldTransformations_.get(index); } else { - return fieldTransformationsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public java.util.List - getFieldTransformationsOrBuilderList() { - if (fieldTransformationsBuilder_ != null) { - return fieldTransformationsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(fieldTransformations_); - } - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformation.Builder addFieldTransformationsBuilder() { - return getFieldTransformationsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.FieldTransformation.getDefaultInstance()); - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformation.Builder addFieldTransformationsBuilder( - int index) { - return getFieldTransformationsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.FieldTransformation.getDefaultInstance()); - } - /** - *
-     * Transform the record by applying various field transformations.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - public java.util.List - getFieldTransformationsBuilderList() { - return getFieldTransformationsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldTransformation, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder, com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder> - getFieldTransformationsFieldBuilder() { - if (fieldTransformationsBuilder_ == null) { - fieldTransformationsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldTransformation, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder, com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder>( - fieldTransformations_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - fieldTransformations_ = null; - } - return fieldTransformationsBuilder_; - } - - private java.util.List recordSuppressions_ = - java.util.Collections.emptyList(); - private void ensureRecordSuppressionsIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - recordSuppressions_ = new java.util.ArrayList(recordSuppressions_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordSuppression, com.google.privacy.dlp.v2beta1.RecordSuppression.Builder, com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder> recordSuppressionsBuilder_; - - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public java.util.List getRecordSuppressionsList() { - if (recordSuppressionsBuilder_ == null) { - return java.util.Collections.unmodifiableList(recordSuppressions_); - } else { - return recordSuppressionsBuilder_.getMessageList(); - } - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public int getRecordSuppressionsCount() { - if (recordSuppressionsBuilder_ == null) { - return recordSuppressions_.size(); - } else { - return recordSuppressionsBuilder_.getCount(); - } - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppression getRecordSuppressions(int index) { - if (recordSuppressionsBuilder_ == null) { - return recordSuppressions_.get(index); - } else { - return recordSuppressionsBuilder_.getMessage(index); - } - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public Builder setRecordSuppressions( - int index, com.google.privacy.dlp.v2beta1.RecordSuppression value) { - if (recordSuppressionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRecordSuppressionsIsMutable(); - recordSuppressions_.set(index, value); - onChanged(); - } else { - recordSuppressionsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public Builder setRecordSuppressions( - int index, com.google.privacy.dlp.v2beta1.RecordSuppression.Builder builderForValue) { - if (recordSuppressionsBuilder_ == null) { - ensureRecordSuppressionsIsMutable(); - recordSuppressions_.set(index, builderForValue.build()); - onChanged(); - } else { - recordSuppressionsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public Builder addRecordSuppressions(com.google.privacy.dlp.v2beta1.RecordSuppression value) { - if (recordSuppressionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRecordSuppressionsIsMutable(); - recordSuppressions_.add(value); - onChanged(); - } else { - recordSuppressionsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public Builder addRecordSuppressions( - int index, com.google.privacy.dlp.v2beta1.RecordSuppression value) { - if (recordSuppressionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRecordSuppressionsIsMutable(); - recordSuppressions_.add(index, value); - onChanged(); - } else { - recordSuppressionsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public Builder addRecordSuppressions( - com.google.privacy.dlp.v2beta1.RecordSuppression.Builder builderForValue) { - if (recordSuppressionsBuilder_ == null) { - ensureRecordSuppressionsIsMutable(); - recordSuppressions_.add(builderForValue.build()); - onChanged(); - } else { - recordSuppressionsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public Builder addRecordSuppressions( - int index, com.google.privacy.dlp.v2beta1.RecordSuppression.Builder builderForValue) { - if (recordSuppressionsBuilder_ == null) { - ensureRecordSuppressionsIsMutable(); - recordSuppressions_.add(index, builderForValue.build()); - onChanged(); - } else { - recordSuppressionsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public Builder addAllRecordSuppressions( - java.lang.Iterable values) { - if (recordSuppressionsBuilder_ == null) { - ensureRecordSuppressionsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, recordSuppressions_); - onChanged(); - } else { - recordSuppressionsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public Builder clearRecordSuppressions() { - if (recordSuppressionsBuilder_ == null) { - recordSuppressions_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - recordSuppressionsBuilder_.clear(); - } - return this; - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public Builder removeRecordSuppressions(int index) { - if (recordSuppressionsBuilder_ == null) { - ensureRecordSuppressionsIsMutable(); - recordSuppressions_.remove(index); - onChanged(); - } else { - recordSuppressionsBuilder_.remove(index); - } - return this; - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppression.Builder getRecordSuppressionsBuilder( - int index) { - return getRecordSuppressionsFieldBuilder().getBuilder(index); - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder getRecordSuppressionsOrBuilder( - int index) { - if (recordSuppressionsBuilder_ == null) { - return recordSuppressions_.get(index); } else { - return recordSuppressionsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public java.util.List - getRecordSuppressionsOrBuilderList() { - if (recordSuppressionsBuilder_ != null) { - return recordSuppressionsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(recordSuppressions_); - } - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppression.Builder addRecordSuppressionsBuilder() { - return getRecordSuppressionsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.RecordSuppression.getDefaultInstance()); - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppression.Builder addRecordSuppressionsBuilder( - int index) { - return getRecordSuppressionsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.RecordSuppression.getDefaultInstance()); - } - /** - *
-     * Configuration defining which records get suppressed entirely. Records that
-     * match any suppression rule are omitted from the output [optional].
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - public java.util.List - getRecordSuppressionsBuilderList() { - return getRecordSuppressionsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordSuppression, com.google.privacy.dlp.v2beta1.RecordSuppression.Builder, com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder> - getRecordSuppressionsFieldBuilder() { - if (recordSuppressionsBuilder_ == null) { - recordSuppressionsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordSuppression, com.google.privacy.dlp.v2beta1.RecordSuppression.Builder, com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder>( - recordSuppressions_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - recordSuppressions_ = null; - } - return recordSuppressionsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RecordTransformations) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RecordTransformations) - private static final com.google.privacy.dlp.v2beta1.RecordTransformations DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RecordTransformations(); - } - - public static com.google.privacy.dlp.v2beta1.RecordTransformations getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public RecordTransformations parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RecordTransformations(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RecordTransformations getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordTransformationsOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordTransformationsOrBuilder.java deleted file mode 100644 index 6dd33b94b428..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RecordTransformationsOrBuilder.java +++ /dev/null @@ -1,102 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface RecordTransformationsOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RecordTransformations) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Transform the record by applying various field transformations.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - java.util.List - getFieldTransformationsList(); - /** - *
-   * Transform the record by applying various field transformations.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - com.google.privacy.dlp.v2beta1.FieldTransformation getFieldTransformations(int index); - /** - *
-   * Transform the record by applying various field transformations.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - int getFieldTransformationsCount(); - /** - *
-   * Transform the record by applying various field transformations.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - java.util.List - getFieldTransformationsOrBuilderList(); - /** - *
-   * Transform the record by applying various field transformations.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 1; - */ - com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder getFieldTransformationsOrBuilder( - int index); - - /** - *
-   * Configuration defining which records get suppressed entirely. Records that
-   * match any suppression rule are omitted from the output [optional].
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - java.util.List - getRecordSuppressionsList(); - /** - *
-   * Configuration defining which records get suppressed entirely. Records that
-   * match any suppression rule are omitted from the output [optional].
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - com.google.privacy.dlp.v2beta1.RecordSuppression getRecordSuppressions(int index); - /** - *
-   * Configuration defining which records get suppressed entirely. Records that
-   * match any suppression rule are omitted from the output [optional].
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - int getRecordSuppressionsCount(); - /** - *
-   * Configuration defining which records get suppressed entirely. Records that
-   * match any suppression rule are omitted from the output [optional].
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - java.util.List - getRecordSuppressionsOrBuilderList(); - /** - *
-   * Configuration defining which records get suppressed entirely. Records that
-   * match any suppression rule are omitted from the output [optional].
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RecordSuppression record_suppressions = 2; - */ - com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder getRecordSuppressionsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactConfig.java deleted file mode 100644 index dee5d52dddf5..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactConfig.java +++ /dev/null @@ -1,400 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Redact a given value. For example, if used with an `InfoTypeTransformation`
- * transforming PHONE_NUMBER, and input 'My phone number is 206-555-0123', the
- * output would be 'My phone number is '.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RedactConfig} - */ -public final class RedactConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RedactConfig) - RedactConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use RedactConfig.newBuilder() to construct. - private RedactConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private RedactConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private RedactConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownFieldProto3( - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RedactConfig.class, com.google.privacy.dlp.v2beta1.RedactConfig.Builder.class); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - 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.privacy.dlp.v2beta1.RedactConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RedactConfig other = (com.google.privacy.dlp.v2beta1.RedactConfig) obj; - - boolean result = true; - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RedactConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RedactConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactConfig 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.privacy.dlp.v2beta1.RedactConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RedactConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactConfig 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.privacy.dlp.v2beta1.RedactConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactConfig 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.privacy.dlp.v2beta1.RedactConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RedactConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Redact a given value. For example, if used with an `InfoTypeTransformation`
-   * transforming PHONE_NUMBER, and input 'My phone number is 206-555-0123', the
-   * output would be 'My phone number is '.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RedactConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RedactConfig) - com.google.privacy.dlp.v2beta1.RedactConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RedactConfig.class, com.google.privacy.dlp.v2beta1.RedactConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RedactConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RedactConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RedactConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RedactConfig build() { - com.google.privacy.dlp.v2beta1.RedactConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RedactConfig buildPartial() { - com.google.privacy.dlp.v2beta1.RedactConfig result = new com.google.privacy.dlp.v2beta1.RedactConfig(this); - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RedactConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RedactConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RedactConfig other) { - if (other == com.google.privacy.dlp.v2beta1.RedactConfig.getDefaultInstance()) return this; - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RedactConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RedactConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RedactConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RedactConfig) - private static final com.google.privacy.dlp.v2beta1.RedactConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RedactConfig(); - } - - public static com.google.privacy.dlp.v2beta1.RedactConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public RedactConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RedactConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RedactConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactConfigOrBuilder.java deleted file mode 100644 index 8ce19c3d2f77..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactConfigOrBuilder.java +++ /dev/null @@ -1,9 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface RedactConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RedactConfig) - com.google.protobuf.MessageOrBuilder { -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentRequest.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentRequest.java deleted file mode 100644 index 11a298cc984b..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentRequest.java +++ /dev/null @@ -1,3981 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Request to search for potentially sensitive info in a list of items
- * and replace it with a default or provided content.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RedactContentRequest} - */ -public final class RedactContentRequest extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RedactContentRequest) - RedactContentRequestOrBuilder { -private static final long serialVersionUID = 0L; - // Use RedactContentRequest.newBuilder() to construct. - private RedactContentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private RedactContentRequest() { - items_ = java.util.Collections.emptyList(); - replaceConfigs_ = java.util.Collections.emptyList(); - imageRedactionConfigs_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private RedactContentRequest( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InspectConfig.Builder subBuilder = null; - if (inspectConfig_ != null) { - subBuilder = inspectConfig_.toBuilder(); - } - inspectConfig_ = input.readMessage(com.google.privacy.dlp.v2beta1.InspectConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(inspectConfig_); - inspectConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - items_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - items_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.ContentItem.parser(), extensionRegistry)); - break; - } - case 26: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { - replaceConfigs_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000004; - } - replaceConfigs_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.parser(), extensionRegistry)); - break; - } - case 34: { - if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - imageRedactionConfigs_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - imageRedactionConfigs_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.parser(), extensionRegistry)); - 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_ & 0x00000002) == 0x00000002)) { - items_ = java.util.Collections.unmodifiableList(items_); - } - if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) { - replaceConfigs_ = java.util.Collections.unmodifiableList(replaceConfigs_); - } - if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - imageRedactionConfigs_ = java.util.Collections.unmodifiableList(imageRedactionConfigs_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RedactContentRequest.class, com.google.privacy.dlp.v2beta1.RedactContentRequest.Builder.class); - } - - public interface ReplaceConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Type of information to replace. Only one ReplaceConfig per info_type
-     * should be provided. If ReplaceConfig does not have an info_type, the DLP
-     * API matches it against all info_types that are found but not specified in
-     * another ReplaceConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - boolean hasInfoType(); - /** - *
-     * Type of information to replace. Only one ReplaceConfig per info_type
-     * should be provided. If ReplaceConfig does not have an info_type, the DLP
-     * API matches it against all info_types that are found but not specified in
-     * another ReplaceConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoType getInfoType(); - /** - *
-     * Type of information to replace. Only one ReplaceConfig per info_type
-     * should be provided. If ReplaceConfig does not have an info_type, the DLP
-     * API matches it against all info_types that are found but not specified in
-     * another ReplaceConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder(); - - /** - *
-     * Content replacing sensitive information of given type. Max 256 chars.
-     * 
- * - * string replace_with = 2; - */ - java.lang.String getReplaceWith(); - /** - *
-     * Content replacing sensitive information of given type. Max 256 chars.
-     * 
- * - * string replace_with = 2; - */ - com.google.protobuf.ByteString - getReplaceWithBytes(); - } - /** - * Protobuf type {@code google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig} - */ - public static final class ReplaceConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig) - ReplaceConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use ReplaceConfig.newBuilder() to construct. - private ReplaceConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ReplaceConfig() { - replaceWith_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ReplaceConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InfoType.Builder subBuilder = null; - if (infoType_ != null) { - subBuilder = infoType_.toBuilder(); - } - infoType_ = input.readMessage(com.google.privacy.dlp.v2beta1.InfoType.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(infoType_); - infoType_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - replaceWith_ = s; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ReplaceConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ReplaceConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.class, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder.class); - } - - public static final int INFO_TYPE_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.InfoType infoType_; - /** - *
-     * Type of information to replace. Only one ReplaceConfig per info_type
-     * should be provided. If ReplaceConfig does not have an info_type, the DLP
-     * API matches it against all info_types that are found but not specified in
-     * another ReplaceConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return infoType_ != null; - } - /** - *
-     * Type of information to replace. Only one ReplaceConfig per info_type
-     * should be provided. If ReplaceConfig does not have an info_type, the DLP
-     * API matches it against all info_types that are found but not specified in
-     * another ReplaceConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - /** - *
-     * Type of information to replace. Only one ReplaceConfig per info_type
-     * should be provided. If ReplaceConfig does not have an info_type, the DLP
-     * API matches it against all info_types that are found but not specified in
-     * another ReplaceConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - return getInfoType(); - } - - public static final int REPLACE_WITH_FIELD_NUMBER = 2; - private volatile java.lang.Object replaceWith_; - /** - *
-     * Content replacing sensitive information of given type. Max 256 chars.
-     * 
- * - * string replace_with = 2; - */ - public java.lang.String getReplaceWith() { - java.lang.Object ref = replaceWith_; - 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(); - replaceWith_ = s; - return s; - } - } - /** - *
-     * Content replacing sensitive information of given type. Max 256 chars.
-     * 
- * - * string replace_with = 2; - */ - public com.google.protobuf.ByteString - getReplaceWithBytes() { - java.lang.Object ref = replaceWith_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - replaceWith_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (infoType_ != null) { - output.writeMessage(1, getInfoType()); - } - if (!getReplaceWithBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, replaceWith_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (infoType_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getInfoType()); - } - if (!getReplaceWithBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, replaceWith_); - } - 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.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig other = (com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig) obj; - - boolean result = true; - result = result && (hasInfoType() == other.hasInfoType()); - if (hasInfoType()) { - result = result && getInfoType() - .equals(other.getInfoType()); - } - result = result && getReplaceWith() - .equals(other.getReplaceWith()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasInfoType()) { - hash = (37 * hash) + INFO_TYPE_FIELD_NUMBER; - hash = (53 * hash) + getInfoType().hashCode(); - } - hash = (37 * hash) + REPLACE_WITH_FIELD_NUMBER; - hash = (53 * hash) + getReplaceWith().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig 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.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig 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.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig 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.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - * Protobuf type {@code google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig) - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ReplaceConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ReplaceConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.class, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (infoTypeBuilder_ == null) { - infoType_ = null; - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - replaceWith_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ReplaceConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig build() { - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig buildPartial() { - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig result = new com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig(this); - if (infoTypeBuilder_ == null) { - result.infoType_ = infoType_; - } else { - result.infoType_ = infoTypeBuilder_.build(); - } - result.replaceWith_ = replaceWith_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig other) { - if (other == com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.getDefaultInstance()) return this; - if (other.hasInfoType()) { - mergeInfoType(other.getInfoType()); - } - if (!other.getReplaceWith().isEmpty()) { - replaceWith_ = other.replaceWith_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.InfoType infoType_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> infoTypeBuilder_; - /** - *
-       * Type of information to replace. Only one ReplaceConfig per info_type
-       * should be provided. If ReplaceConfig does not have an info_type, the DLP
-       * API matches it against all info_types that are found but not specified in
-       * another ReplaceConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return infoTypeBuilder_ != null || infoType_ != null; - } - /** - *
-       * Type of information to replace. Only one ReplaceConfig per info_type
-       * should be provided. If ReplaceConfig does not have an info_type, the DLP
-       * API matches it against all info_types that are found but not specified in
-       * another ReplaceConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - if (infoTypeBuilder_ == null) { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } else { - return infoTypeBuilder_.getMessage(); - } - } - /** - *
-       * Type of information to replace. Only one ReplaceConfig per info_type
-       * should be provided. If ReplaceConfig does not have an info_type, the DLP
-       * API matches it against all info_types that are found but not specified in
-       * another ReplaceConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - infoType_ = value; - onChanged(); - } else { - infoTypeBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Type of information to replace. Only one ReplaceConfig per info_type
-       * should be provided. If ReplaceConfig does not have an info_type, the DLP
-       * API matches it against all info_types that are found but not specified in
-       * another ReplaceConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType( - com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypeBuilder_ == null) { - infoType_ = builderForValue.build(); - onChanged(); - } else { - infoTypeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Type of information to replace. Only one ReplaceConfig per info_type
-       * should be provided. If ReplaceConfig does not have an info_type, the DLP
-       * API matches it against all info_types that are found but not specified in
-       * another ReplaceConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder mergeInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (infoType_ != null) { - infoType_ = - com.google.privacy.dlp.v2beta1.InfoType.newBuilder(infoType_).mergeFrom(value).buildPartial(); - } else { - infoType_ = value; - } - onChanged(); - } else { - infoTypeBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Type of information to replace. Only one ReplaceConfig per info_type
-       * should be provided. If ReplaceConfig does not have an info_type, the DLP
-       * API matches it against all info_types that are found but not specified in
-       * another ReplaceConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder clearInfoType() { - if (infoTypeBuilder_ == null) { - infoType_ = null; - onChanged(); - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - - return this; - } - /** - *
-       * Type of information to replace. Only one ReplaceConfig per info_type
-       * should be provided. If ReplaceConfig does not have an info_type, the DLP
-       * API matches it against all info_types that are found but not specified in
-       * another ReplaceConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder getInfoTypeBuilder() { - - onChanged(); - return getInfoTypeFieldBuilder().getBuilder(); - } - /** - *
-       * Type of information to replace. Only one ReplaceConfig per info_type
-       * should be provided. If ReplaceConfig does not have an info_type, the DLP
-       * API matches it against all info_types that are found but not specified in
-       * another ReplaceConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - if (infoTypeBuilder_ != null) { - return infoTypeBuilder_.getMessageOrBuilder(); - } else { - return infoType_ == null ? - com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - } - /** - *
-       * Type of information to replace. Only one ReplaceConfig per info_type
-       * should be provided. If ReplaceConfig does not have an info_type, the DLP
-       * API matches it against all info_types that are found but not specified in
-       * another ReplaceConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> - getInfoTypeFieldBuilder() { - if (infoTypeBuilder_ == null) { - infoTypeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder>( - getInfoType(), - getParentForChildren(), - isClean()); - infoType_ = null; - } - return infoTypeBuilder_; - } - - private java.lang.Object replaceWith_ = ""; - /** - *
-       * Content replacing sensitive information of given type. Max 256 chars.
-       * 
- * - * string replace_with = 2; - */ - public java.lang.String getReplaceWith() { - java.lang.Object ref = replaceWith_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - replaceWith_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-       * Content replacing sensitive information of given type. Max 256 chars.
-       * 
- * - * string replace_with = 2; - */ - public com.google.protobuf.ByteString - getReplaceWithBytes() { - java.lang.Object ref = replaceWith_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - replaceWith_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-       * Content replacing sensitive information of given type. Max 256 chars.
-       * 
- * - * string replace_with = 2; - */ - public Builder setReplaceWith( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - replaceWith_ = value; - onChanged(); - return this; - } - /** - *
-       * Content replacing sensitive information of given type. Max 256 chars.
-       * 
- * - * string replace_with = 2; - */ - public Builder clearReplaceWith() { - - replaceWith_ = getDefaultInstance().getReplaceWith(); - onChanged(); - return this; - } - /** - *
-       * Content replacing sensitive information of given type. Max 256 chars.
-       * 
- * - * string replace_with = 2; - */ - public Builder setReplaceWithBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - replaceWith_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig) - private static final com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig(); - } - - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ReplaceConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ReplaceConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface ImageRedactionConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Only one per info_type should be provided per request. If not
-     * specified, and redact_all_text is false, the DLP API will redact all
-     * text that it matches against all info_types that are found, but not
-     * specified in another ImageRedactionConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - boolean hasInfoType(); - /** - *
-     * Only one per info_type should be provided per request. If not
-     * specified, and redact_all_text is false, the DLP API will redact all
-     * text that it matches against all info_types that are found, but not
-     * specified in another ImageRedactionConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoType getInfoType(); - /** - *
-     * Only one per info_type should be provided per request. If not
-     * specified, and redact_all_text is false, the DLP API will redact all
-     * text that it matches against all info_types that are found, but not
-     * specified in another ImageRedactionConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder(); - - /** - *
-     * If true, all text found in the image, regardless whether it matches an
-     * info_type, is redacted.
-     * 
- * - * bool redact_all_text = 2; - */ - boolean getRedactAllText(); - - /** - *
-     * The color to use when redacting content from an image. If not specified,
-     * the default is black.
-     * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - boolean hasRedactionColor(); - /** - *
-     * The color to use when redacting content from an image. If not specified,
-     * the default is black.
-     * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - com.google.privacy.dlp.v2beta1.Color getRedactionColor(); - /** - *
-     * The color to use when redacting content from an image. If not specified,
-     * the default is black.
-     * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - com.google.privacy.dlp.v2beta1.ColorOrBuilder getRedactionColorOrBuilder(); - - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.TargetCase getTargetCase(); - } - /** - *
-   * Configuration for determining how redaction of images should occur.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig} - */ - public static final class ImageRedactionConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig) - ImageRedactionConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use ImageRedactionConfig.newBuilder() to construct. - private ImageRedactionConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ImageRedactionConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ImageRedactionConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InfoType.Builder subBuilder = null; - if (targetCase_ == 1) { - subBuilder = ((com.google.privacy.dlp.v2beta1.InfoType) target_).toBuilder(); - } - target_ = - input.readMessage(com.google.privacy.dlp.v2beta1.InfoType.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.InfoType) target_); - target_ = subBuilder.buildPartial(); - } - targetCase_ = 1; - break; - } - case 16: { - targetCase_ = 2; - target_ = input.readBool(); - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.Color.Builder subBuilder = null; - if (redactionColor_ != null) { - subBuilder = redactionColor_.toBuilder(); - } - redactionColor_ = input.readMessage(com.google.privacy.dlp.v2beta1.Color.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(redactionColor_); - redactionColor_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ImageRedactionConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ImageRedactionConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.class, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder.class); - } - - private int targetCase_ = 0; - private java.lang.Object target_; - public enum TargetCase - implements com.google.protobuf.Internal.EnumLite { - INFO_TYPE(1), - REDACT_ALL_TEXT(2), - TARGET_NOT_SET(0); - private final int value; - private TargetCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TargetCase valueOf(int value) { - return forNumber(value); - } - - public static TargetCase forNumber(int value) { - switch (value) { - case 1: return INFO_TYPE; - case 2: return REDACT_ALL_TEXT; - case 0: return TARGET_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TargetCase - getTargetCase() { - return TargetCase.forNumber( - targetCase_); - } - - public static final int INFO_TYPE_FIELD_NUMBER = 1; - /** - *
-     * Only one per info_type should be provided per request. If not
-     * specified, and redact_all_text is false, the DLP API will redact all
-     * text that it matches against all info_types that are found, but not
-     * specified in another ImageRedactionConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return targetCase_ == 1; - } - /** - *
-     * Only one per info_type should be provided per request. If not
-     * specified, and redact_all_text is false, the DLP API will redact all
-     * text that it matches against all info_types that are found, but not
-     * specified in another ImageRedactionConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - if (targetCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.InfoType) target_; - } - return com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance(); - } - /** - *
-     * Only one per info_type should be provided per request. If not
-     * specified, and redact_all_text is false, the DLP API will redact all
-     * text that it matches against all info_types that are found, but not
-     * specified in another ImageRedactionConfig.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - if (targetCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.InfoType) target_; - } - return com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance(); - } - - public static final int REDACT_ALL_TEXT_FIELD_NUMBER = 2; - /** - *
-     * If true, all text found in the image, regardless whether it matches an
-     * info_type, is redacted.
-     * 
- * - * bool redact_all_text = 2; - */ - public boolean getRedactAllText() { - if (targetCase_ == 2) { - return (java.lang.Boolean) target_; - } - return false; - } - - public static final int REDACTION_COLOR_FIELD_NUMBER = 3; - private com.google.privacy.dlp.v2beta1.Color redactionColor_; - /** - *
-     * The color to use when redacting content from an image. If not specified,
-     * the default is black.
-     * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public boolean hasRedactionColor() { - return redactionColor_ != null; - } - /** - *
-     * The color to use when redacting content from an image. If not specified,
-     * the default is black.
-     * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public com.google.privacy.dlp.v2beta1.Color getRedactionColor() { - return redactionColor_ == null ? com.google.privacy.dlp.v2beta1.Color.getDefaultInstance() : redactionColor_; - } - /** - *
-     * The color to use when redacting content from an image. If not specified,
-     * the default is black.
-     * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public com.google.privacy.dlp.v2beta1.ColorOrBuilder getRedactionColorOrBuilder() { - return getRedactionColor(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (targetCase_ == 1) { - output.writeMessage(1, (com.google.privacy.dlp.v2beta1.InfoType) target_); - } - if (targetCase_ == 2) { - output.writeBool( - 2, (boolean)((java.lang.Boolean) target_)); - } - if (redactionColor_ != null) { - output.writeMessage(3, getRedactionColor()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (targetCase_ == 1) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, (com.google.privacy.dlp.v2beta1.InfoType) target_); - } - if (targetCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize( - 2, (boolean)((java.lang.Boolean) target_)); - } - if (redactionColor_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, getRedactionColor()); - } - 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.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig other = (com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig) obj; - - boolean result = true; - result = result && (hasRedactionColor() == other.hasRedactionColor()); - if (hasRedactionColor()) { - result = result && getRedactionColor() - .equals(other.getRedactionColor()); - } - result = result && getTargetCase().equals( - other.getTargetCase()); - if (!result) return false; - switch (targetCase_) { - case 1: - result = result && getInfoType() - .equals(other.getInfoType()); - break; - case 2: - result = result && (getRedactAllText() - == other.getRedactAllText()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasRedactionColor()) { - hash = (37 * hash) + REDACTION_COLOR_FIELD_NUMBER; - hash = (53 * hash) + getRedactionColor().hashCode(); - } - switch (targetCase_) { - case 1: - hash = (37 * hash) + INFO_TYPE_FIELD_NUMBER; - hash = (53 * hash) + getInfoType().hashCode(); - break; - case 2: - hash = (37 * hash) + REDACT_ALL_TEXT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getRedactAllText()); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig 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.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig 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.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig 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.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-     * Configuration for determining how redaction of images should occur.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig) - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ImageRedactionConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ImageRedactionConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.class, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (redactionColorBuilder_ == null) { - redactionColor_ = null; - } else { - redactionColor_ = null; - redactionColorBuilder_ = null; - } - targetCase_ = 0; - target_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_ImageRedactionConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig build() { - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig buildPartial() { - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig result = new com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig(this); - if (targetCase_ == 1) { - if (infoTypeBuilder_ == null) { - result.target_ = target_; - } else { - result.target_ = infoTypeBuilder_.build(); - } - } - if (targetCase_ == 2) { - result.target_ = target_; - } - if (redactionColorBuilder_ == null) { - result.redactionColor_ = redactionColor_; - } else { - result.redactionColor_ = redactionColorBuilder_.build(); - } - result.targetCase_ = targetCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig other) { - if (other == com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.getDefaultInstance()) return this; - if (other.hasRedactionColor()) { - mergeRedactionColor(other.getRedactionColor()); - } - switch (other.getTargetCase()) { - case INFO_TYPE: { - mergeInfoType(other.getInfoType()); - break; - } - case REDACT_ALL_TEXT: { - setRedactAllText(other.getRedactAllText()); - break; - } - case TARGET_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int targetCase_ = 0; - private java.lang.Object target_; - public TargetCase - getTargetCase() { - return TargetCase.forNumber( - targetCase_); - } - - public Builder clearTarget() { - targetCase_ = 0; - target_ = null; - onChanged(); - return this; - } - - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> infoTypeBuilder_; - /** - *
-       * Only one per info_type should be provided per request. If not
-       * specified, and redact_all_text is false, the DLP API will redact all
-       * text that it matches against all info_types that are found, but not
-       * specified in another ImageRedactionConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return targetCase_ == 1; - } - /** - *
-       * Only one per info_type should be provided per request. If not
-       * specified, and redact_all_text is false, the DLP API will redact all
-       * text that it matches against all info_types that are found, but not
-       * specified in another ImageRedactionConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - if (infoTypeBuilder_ == null) { - if (targetCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.InfoType) target_; - } - return com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance(); - } else { - if (targetCase_ == 1) { - return infoTypeBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance(); - } - } - /** - *
-       * Only one per info_type should be provided per request. If not
-       * specified, and redact_all_text is false, the DLP API will redact all
-       * text that it matches against all info_types that are found, but not
-       * specified in another ImageRedactionConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - target_ = value; - onChanged(); - } else { - infoTypeBuilder_.setMessage(value); - } - targetCase_ = 1; - return this; - } - /** - *
-       * Only one per info_type should be provided per request. If not
-       * specified, and redact_all_text is false, the DLP API will redact all
-       * text that it matches against all info_types that are found, but not
-       * specified in another ImageRedactionConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType( - com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypeBuilder_ == null) { - target_ = builderForValue.build(); - onChanged(); - } else { - infoTypeBuilder_.setMessage(builderForValue.build()); - } - targetCase_ = 1; - return this; - } - /** - *
-       * Only one per info_type should be provided per request. If not
-       * specified, and redact_all_text is false, the DLP API will redact all
-       * text that it matches against all info_types that are found, but not
-       * specified in another ImageRedactionConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder mergeInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (targetCase_ == 1 && - target_ != com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance()) { - target_ = com.google.privacy.dlp.v2beta1.InfoType.newBuilder((com.google.privacy.dlp.v2beta1.InfoType) target_) - .mergeFrom(value).buildPartial(); - } else { - target_ = value; - } - onChanged(); - } else { - if (targetCase_ == 1) { - infoTypeBuilder_.mergeFrom(value); - } - infoTypeBuilder_.setMessage(value); - } - targetCase_ = 1; - return this; - } - /** - *
-       * Only one per info_type should be provided per request. If not
-       * specified, and redact_all_text is false, the DLP API will redact all
-       * text that it matches against all info_types that are found, but not
-       * specified in another ImageRedactionConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder clearInfoType() { - if (infoTypeBuilder_ == null) { - if (targetCase_ == 1) { - targetCase_ = 0; - target_ = null; - onChanged(); - } - } else { - if (targetCase_ == 1) { - targetCase_ = 0; - target_ = null; - } - infoTypeBuilder_.clear(); - } - return this; - } - /** - *
-       * Only one per info_type should be provided per request. If not
-       * specified, and redact_all_text is false, the DLP API will redact all
-       * text that it matches against all info_types that are found, but not
-       * specified in another ImageRedactionConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder getInfoTypeBuilder() { - return getInfoTypeFieldBuilder().getBuilder(); - } - /** - *
-       * Only one per info_type should be provided per request. If not
-       * specified, and redact_all_text is false, the DLP API will redact all
-       * text that it matches against all info_types that are found, but not
-       * specified in another ImageRedactionConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - if ((targetCase_ == 1) && (infoTypeBuilder_ != null)) { - return infoTypeBuilder_.getMessageOrBuilder(); - } else { - if (targetCase_ == 1) { - return (com.google.privacy.dlp.v2beta1.InfoType) target_; - } - return com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance(); - } - } - /** - *
-       * Only one per info_type should be provided per request. If not
-       * specified, and redact_all_text is false, the DLP API will redact all
-       * text that it matches against all info_types that are found, but not
-       * specified in another ImageRedactionConfig.
-       * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> - getInfoTypeFieldBuilder() { - if (infoTypeBuilder_ == null) { - if (!(targetCase_ == 1)) { - target_ = com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance(); - } - infoTypeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder>( - (com.google.privacy.dlp.v2beta1.InfoType) target_, - getParentForChildren(), - isClean()); - target_ = null; - } - targetCase_ = 1; - onChanged();; - return infoTypeBuilder_; - } - - /** - *
-       * If true, all text found in the image, regardless whether it matches an
-       * info_type, is redacted.
-       * 
- * - * bool redact_all_text = 2; - */ - public boolean getRedactAllText() { - if (targetCase_ == 2) { - return (java.lang.Boolean) target_; - } - return false; - } - /** - *
-       * If true, all text found in the image, regardless whether it matches an
-       * info_type, is redacted.
-       * 
- * - * bool redact_all_text = 2; - */ - public Builder setRedactAllText(boolean value) { - targetCase_ = 2; - target_ = value; - onChanged(); - return this; - } - /** - *
-       * If true, all text found in the image, regardless whether it matches an
-       * info_type, is redacted.
-       * 
- * - * bool redact_all_text = 2; - */ - public Builder clearRedactAllText() { - if (targetCase_ == 2) { - targetCase_ = 0; - target_ = null; - onChanged(); - } - return this; - } - - private com.google.privacy.dlp.v2beta1.Color redactionColor_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Color, com.google.privacy.dlp.v2beta1.Color.Builder, com.google.privacy.dlp.v2beta1.ColorOrBuilder> redactionColorBuilder_; - /** - *
-       * The color to use when redacting content from an image. If not specified,
-       * the default is black.
-       * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public boolean hasRedactionColor() { - return redactionColorBuilder_ != null || redactionColor_ != null; - } - /** - *
-       * The color to use when redacting content from an image. If not specified,
-       * the default is black.
-       * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public com.google.privacy.dlp.v2beta1.Color getRedactionColor() { - if (redactionColorBuilder_ == null) { - return redactionColor_ == null ? com.google.privacy.dlp.v2beta1.Color.getDefaultInstance() : redactionColor_; - } else { - return redactionColorBuilder_.getMessage(); - } - } - /** - *
-       * The color to use when redacting content from an image. If not specified,
-       * the default is black.
-       * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public Builder setRedactionColor(com.google.privacy.dlp.v2beta1.Color value) { - if (redactionColorBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - redactionColor_ = value; - onChanged(); - } else { - redactionColorBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * The color to use when redacting content from an image. If not specified,
-       * the default is black.
-       * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public Builder setRedactionColor( - com.google.privacy.dlp.v2beta1.Color.Builder builderForValue) { - if (redactionColorBuilder_ == null) { - redactionColor_ = builderForValue.build(); - onChanged(); - } else { - redactionColorBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * The color to use when redacting content from an image. If not specified,
-       * the default is black.
-       * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public Builder mergeRedactionColor(com.google.privacy.dlp.v2beta1.Color value) { - if (redactionColorBuilder_ == null) { - if (redactionColor_ != null) { - redactionColor_ = - com.google.privacy.dlp.v2beta1.Color.newBuilder(redactionColor_).mergeFrom(value).buildPartial(); - } else { - redactionColor_ = value; - } - onChanged(); - } else { - redactionColorBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * The color to use when redacting content from an image. If not specified,
-       * the default is black.
-       * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public Builder clearRedactionColor() { - if (redactionColorBuilder_ == null) { - redactionColor_ = null; - onChanged(); - } else { - redactionColor_ = null; - redactionColorBuilder_ = null; - } - - return this; - } - /** - *
-       * The color to use when redacting content from an image. If not specified,
-       * the default is black.
-       * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public com.google.privacy.dlp.v2beta1.Color.Builder getRedactionColorBuilder() { - - onChanged(); - return getRedactionColorFieldBuilder().getBuilder(); - } - /** - *
-       * The color to use when redacting content from an image. If not specified,
-       * the default is black.
-       * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - public com.google.privacy.dlp.v2beta1.ColorOrBuilder getRedactionColorOrBuilder() { - if (redactionColorBuilder_ != null) { - return redactionColorBuilder_.getMessageOrBuilder(); - } else { - return redactionColor_ == null ? - com.google.privacy.dlp.v2beta1.Color.getDefaultInstance() : redactionColor_; - } - } - /** - *
-       * The color to use when redacting content from an image. If not specified,
-       * the default is black.
-       * 
- * - * .google.privacy.dlp.v2beta1.Color redaction_color = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Color, com.google.privacy.dlp.v2beta1.Color.Builder, com.google.privacy.dlp.v2beta1.ColorOrBuilder> - getRedactionColorFieldBuilder() { - if (redactionColorBuilder_ == null) { - redactionColorBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Color, com.google.privacy.dlp.v2beta1.Color.Builder, com.google.privacy.dlp.v2beta1.ColorOrBuilder>( - getRedactionColor(), - getParentForChildren(), - isClean()); - redactionColor_ = null; - } - return redactionColorBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig) - private static final com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig(); - } - - public static com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ImageRedactionConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ImageRedactionConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int bitField0_; - public static final int INSPECT_CONFIG_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.InspectConfig inspectConfig_; - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public boolean hasInspectConfig() { - return inspectConfig_ != null; - } - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig() { - return inspectConfig_ == null ? com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder() { - return getInspectConfig(); - } - - public static final int ITEMS_FIELD_NUMBER = 2; - private java.util.List items_; - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public java.util.List getItemsList() { - return items_; - } - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public java.util.List - getItemsOrBuilderList() { - return items_; - } - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public int getItemsCount() { - return items_.size(); - } - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItem getItems(int index) { - return items_.get(index); - } - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index) { - return items_.get(index); - } - - public static final int REPLACE_CONFIGS_FIELD_NUMBER = 3; - private java.util.List replaceConfigs_; - /** - *
-   * The strings to replace findings text findings with. Must specify at least
-   * one of these or one ImageRedactionConfig if redacting images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public java.util.List getReplaceConfigsList() { - return replaceConfigs_; - } - /** - *
-   * The strings to replace findings text findings with. Must specify at least
-   * one of these or one ImageRedactionConfig if redacting images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public java.util.List - getReplaceConfigsOrBuilderList() { - return replaceConfigs_; - } - /** - *
-   * The strings to replace findings text findings with. Must specify at least
-   * one of these or one ImageRedactionConfig if redacting images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public int getReplaceConfigsCount() { - return replaceConfigs_.size(); - } - /** - *
-   * The strings to replace findings text findings with. Must specify at least
-   * one of these or one ImageRedactionConfig if redacting images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig getReplaceConfigs(int index) { - return replaceConfigs_.get(index); - } - /** - *
-   * The strings to replace findings text findings with. Must specify at least
-   * one of these or one ImageRedactionConfig if redacting images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfigOrBuilder getReplaceConfigsOrBuilder( - int index) { - return replaceConfigs_.get(index); - } - - public static final int IMAGE_REDACTION_CONFIGS_FIELD_NUMBER = 4; - private java.util.List imageRedactionConfigs_; - /** - *
-   * The configuration for specifying what content to redact from images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public java.util.List getImageRedactionConfigsList() { - return imageRedactionConfigs_; - } - /** - *
-   * The configuration for specifying what content to redact from images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public java.util.List - getImageRedactionConfigsOrBuilderList() { - return imageRedactionConfigs_; - } - /** - *
-   * The configuration for specifying what content to redact from images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public int getImageRedactionConfigsCount() { - return imageRedactionConfigs_.size(); - } - /** - *
-   * The configuration for specifying what content to redact from images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig getImageRedactionConfigs(int index) { - return imageRedactionConfigs_.get(index); - } - /** - *
-   * The configuration for specifying what content to redact from images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfigOrBuilder getImageRedactionConfigsOrBuilder( - int index) { - return imageRedactionConfigs_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (inspectConfig_ != null) { - output.writeMessage(1, getInspectConfig()); - } - for (int i = 0; i < items_.size(); i++) { - output.writeMessage(2, items_.get(i)); - } - for (int i = 0; i < replaceConfigs_.size(); i++) { - output.writeMessage(3, replaceConfigs_.get(i)); - } - for (int i = 0; i < imageRedactionConfigs_.size(); i++) { - output.writeMessage(4, imageRedactionConfigs_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (inspectConfig_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getInspectConfig()); - } - for (int i = 0; i < items_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, items_.get(i)); - } - for (int i = 0; i < replaceConfigs_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, replaceConfigs_.get(i)); - } - for (int i = 0; i < imageRedactionConfigs_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, imageRedactionConfigs_.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.privacy.dlp.v2beta1.RedactContentRequest)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RedactContentRequest other = (com.google.privacy.dlp.v2beta1.RedactContentRequest) obj; - - boolean result = true; - result = result && (hasInspectConfig() == other.hasInspectConfig()); - if (hasInspectConfig()) { - result = result && getInspectConfig() - .equals(other.getInspectConfig()); - } - result = result && getItemsList() - .equals(other.getItemsList()); - result = result && getReplaceConfigsList() - .equals(other.getReplaceConfigsList()); - result = result && getImageRedactionConfigsList() - .equals(other.getImageRedactionConfigsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasInspectConfig()) { - hash = (37 * hash) + INSPECT_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getInspectConfig().hashCode(); - } - if (getItemsCount() > 0) { - hash = (37 * hash) + ITEMS_FIELD_NUMBER; - hash = (53 * hash) + getItemsList().hashCode(); - } - if (getReplaceConfigsCount() > 0) { - hash = (37 * hash) + REPLACE_CONFIGS_FIELD_NUMBER; - hash = (53 * hash) + getReplaceConfigsList().hashCode(); - } - if (getImageRedactionConfigsCount() > 0) { - hash = (37 * hash) + IMAGE_REDACTION_CONFIGS_FIELD_NUMBER; - hash = (53 * hash) + getImageRedactionConfigsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RedactContentRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest 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.privacy.dlp.v2beta1.RedactContentRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest 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.privacy.dlp.v2beta1.RedactContentRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest 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.privacy.dlp.v2beta1.RedactContentRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RedactContentRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Request to search for potentially sensitive info in a list of items
-   * and replace it with a default or provided content.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RedactContentRequest} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RedactContentRequest) - com.google.privacy.dlp.v2beta1.RedactContentRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RedactContentRequest.class, com.google.privacy.dlp.v2beta1.RedactContentRequest.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RedactContentRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getItemsFieldBuilder(); - getReplaceConfigsFieldBuilder(); - getImageRedactionConfigsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (inspectConfigBuilder_ == null) { - inspectConfig_ = null; - } else { - inspectConfig_ = null; - inspectConfigBuilder_ = null; - } - if (itemsBuilder_ == null) { - items_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - itemsBuilder_.clear(); - } - if (replaceConfigsBuilder_ == null) { - replaceConfigs_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - } else { - replaceConfigsBuilder_.clear(); - } - if (imageRedactionConfigsBuilder_ == null) { - imageRedactionConfigs_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - imageRedactionConfigsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentRequest_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RedactContentRequest.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest build() { - com.google.privacy.dlp.v2beta1.RedactContentRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest buildPartial() { - com.google.privacy.dlp.v2beta1.RedactContentRequest result = new com.google.privacy.dlp.v2beta1.RedactContentRequest(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (inspectConfigBuilder_ == null) { - result.inspectConfig_ = inspectConfig_; - } else { - result.inspectConfig_ = inspectConfigBuilder_.build(); - } - if (itemsBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - items_ = java.util.Collections.unmodifiableList(items_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.items_ = items_; - } else { - result.items_ = itemsBuilder_.build(); - } - if (replaceConfigsBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { - replaceConfigs_ = java.util.Collections.unmodifiableList(replaceConfigs_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.replaceConfigs_ = replaceConfigs_; - } else { - result.replaceConfigs_ = replaceConfigsBuilder_.build(); - } - if (imageRedactionConfigsBuilder_ == null) { - if (((bitField0_ & 0x00000008) == 0x00000008)) { - imageRedactionConfigs_ = java.util.Collections.unmodifiableList(imageRedactionConfigs_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.imageRedactionConfigs_ = imageRedactionConfigs_; - } else { - result.imageRedactionConfigs_ = imageRedactionConfigsBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RedactContentRequest) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RedactContentRequest)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RedactContentRequest other) { - if (other == com.google.privacy.dlp.v2beta1.RedactContentRequest.getDefaultInstance()) return this; - if (other.hasInspectConfig()) { - mergeInspectConfig(other.getInspectConfig()); - } - if (itemsBuilder_ == null) { - if (!other.items_.isEmpty()) { - if (items_.isEmpty()) { - items_ = other.items_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureItemsIsMutable(); - items_.addAll(other.items_); - } - onChanged(); - } - } else { - if (!other.items_.isEmpty()) { - if (itemsBuilder_.isEmpty()) { - itemsBuilder_.dispose(); - itemsBuilder_ = null; - items_ = other.items_; - bitField0_ = (bitField0_ & ~0x00000002); - itemsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getItemsFieldBuilder() : null; - } else { - itemsBuilder_.addAllMessages(other.items_); - } - } - } - if (replaceConfigsBuilder_ == null) { - if (!other.replaceConfigs_.isEmpty()) { - if (replaceConfigs_.isEmpty()) { - replaceConfigs_ = other.replaceConfigs_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureReplaceConfigsIsMutable(); - replaceConfigs_.addAll(other.replaceConfigs_); - } - onChanged(); - } - } else { - if (!other.replaceConfigs_.isEmpty()) { - if (replaceConfigsBuilder_.isEmpty()) { - replaceConfigsBuilder_.dispose(); - replaceConfigsBuilder_ = null; - replaceConfigs_ = other.replaceConfigs_; - bitField0_ = (bitField0_ & ~0x00000004); - replaceConfigsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getReplaceConfigsFieldBuilder() : null; - } else { - replaceConfigsBuilder_.addAllMessages(other.replaceConfigs_); - } - } - } - if (imageRedactionConfigsBuilder_ == null) { - if (!other.imageRedactionConfigs_.isEmpty()) { - if (imageRedactionConfigs_.isEmpty()) { - imageRedactionConfigs_ = other.imageRedactionConfigs_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureImageRedactionConfigsIsMutable(); - imageRedactionConfigs_.addAll(other.imageRedactionConfigs_); - } - onChanged(); - } - } else { - if (!other.imageRedactionConfigs_.isEmpty()) { - if (imageRedactionConfigsBuilder_.isEmpty()) { - imageRedactionConfigsBuilder_.dispose(); - imageRedactionConfigsBuilder_ = null; - imageRedactionConfigs_ = other.imageRedactionConfigs_; - bitField0_ = (bitField0_ & ~0x00000008); - imageRedactionConfigsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getImageRedactionConfigsFieldBuilder() : null; - } else { - imageRedactionConfigsBuilder_.addAllMessages(other.imageRedactionConfigs_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RedactContentRequest parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RedactContentRequest) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private com.google.privacy.dlp.v2beta1.InspectConfig inspectConfig_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder> inspectConfigBuilder_; - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public boolean hasInspectConfig() { - return inspectConfigBuilder_ != null || inspectConfig_ != null; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig() { - if (inspectConfigBuilder_ == null) { - return inspectConfig_ == null ? com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } else { - return inspectConfigBuilder_.getMessage(); - } - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder setInspectConfig(com.google.privacy.dlp.v2beta1.InspectConfig value) { - if (inspectConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - inspectConfig_ = value; - onChanged(); - } else { - inspectConfigBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder setInspectConfig( - com.google.privacy.dlp.v2beta1.InspectConfig.Builder builderForValue) { - if (inspectConfigBuilder_ == null) { - inspectConfig_ = builderForValue.build(); - onChanged(); - } else { - inspectConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder mergeInspectConfig(com.google.privacy.dlp.v2beta1.InspectConfig value) { - if (inspectConfigBuilder_ == null) { - if (inspectConfig_ != null) { - inspectConfig_ = - com.google.privacy.dlp.v2beta1.InspectConfig.newBuilder(inspectConfig_).mergeFrom(value).buildPartial(); - } else { - inspectConfig_ = value; - } - onChanged(); - } else { - inspectConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public Builder clearInspectConfig() { - if (inspectConfigBuilder_ == null) { - inspectConfig_ = null; - onChanged(); - } else { - inspectConfig_ = null; - inspectConfigBuilder_ = null; - } - - return this; - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfig.Builder getInspectConfigBuilder() { - - onChanged(); - return getInspectConfigFieldBuilder().getBuilder(); - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - public com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder() { - if (inspectConfigBuilder_ != null) { - return inspectConfigBuilder_.getMessageOrBuilder(); - } else { - return inspectConfig_ == null ? - com.google.privacy.dlp.v2beta1.InspectConfig.getDefaultInstance() : inspectConfig_; - } - } - /** - *
-     * Configuration for the inspector.
-     * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder> - getInspectConfigFieldBuilder() { - if (inspectConfigBuilder_ == null) { - inspectConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InspectConfig, com.google.privacy.dlp.v2beta1.InspectConfig.Builder, com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder>( - getInspectConfig(), - getParentForChildren(), - isClean()); - inspectConfig_ = null; - } - return inspectConfigBuilder_; - } - - private java.util.List items_ = - java.util.Collections.emptyList(); - private void ensureItemsIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - items_ = new java.util.ArrayList(items_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder> itemsBuilder_; - - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public java.util.List getItemsList() { - if (itemsBuilder_ == null) { - return java.util.Collections.unmodifiableList(items_); - } else { - return itemsBuilder_.getMessageList(); - } - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public int getItemsCount() { - if (itemsBuilder_ == null) { - return items_.size(); - } else { - return itemsBuilder_.getCount(); - } - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItem getItems(int index) { - if (itemsBuilder_ == null) { - return items_.get(index); - } else { - return itemsBuilder_.getMessage(index); - } - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder setItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.set(index, value); - onChanged(); - } else { - itemsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder setItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.set(index, builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder addItems(com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.add(value); - onChanged(); - } else { - itemsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder addItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.add(index, value); - onChanged(); - } else { - itemsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder addItems( - com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.add(builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder addItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.add(index, builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder addAllItems( - java.lang.Iterable values) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, items_); - onChanged(); - } else { - itemsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder clearItems() { - if (itemsBuilder_ == null) { - items_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - itemsBuilder_.clear(); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public Builder removeItems(int index) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.remove(index); - onChanged(); - } else { - itemsBuilder_.remove(index); - } - return this; - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder getItemsBuilder( - int index) { - return getItemsFieldBuilder().getBuilder(index); - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index) { - if (itemsBuilder_ == null) { - return items_.get(index); } else { - return itemsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public java.util.List - getItemsOrBuilderList() { - if (itemsBuilder_ != null) { - return itemsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(items_); - } - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder addItemsBuilder() { - return getItemsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()); - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder addItemsBuilder( - int index) { - return getItemsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()); - } - /** - *
-     * The list of items to inspect. Up to 100 are allowed per request.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - public java.util.List - getItemsBuilderList() { - return getItemsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder> - getItemsFieldBuilder() { - if (itemsBuilder_ == null) { - itemsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder>( - items_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - items_ = null; - } - return itemsBuilder_; - } - - private java.util.List replaceConfigs_ = - java.util.Collections.emptyList(); - private void ensureReplaceConfigsIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { - replaceConfigs_ = new java.util.ArrayList(replaceConfigs_); - bitField0_ |= 0x00000004; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfigOrBuilder> replaceConfigsBuilder_; - - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public java.util.List getReplaceConfigsList() { - if (replaceConfigsBuilder_ == null) { - return java.util.Collections.unmodifiableList(replaceConfigs_); - } else { - return replaceConfigsBuilder_.getMessageList(); - } - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public int getReplaceConfigsCount() { - if (replaceConfigsBuilder_ == null) { - return replaceConfigs_.size(); - } else { - return replaceConfigsBuilder_.getCount(); - } - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig getReplaceConfigs(int index) { - if (replaceConfigsBuilder_ == null) { - return replaceConfigs_.get(index); - } else { - return replaceConfigsBuilder_.getMessage(index); - } - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public Builder setReplaceConfigs( - int index, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig value) { - if (replaceConfigsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureReplaceConfigsIsMutable(); - replaceConfigs_.set(index, value); - onChanged(); - } else { - replaceConfigsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public Builder setReplaceConfigs( - int index, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder builderForValue) { - if (replaceConfigsBuilder_ == null) { - ensureReplaceConfigsIsMutable(); - replaceConfigs_.set(index, builderForValue.build()); - onChanged(); - } else { - replaceConfigsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public Builder addReplaceConfigs(com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig value) { - if (replaceConfigsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureReplaceConfigsIsMutable(); - replaceConfigs_.add(value); - onChanged(); - } else { - replaceConfigsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public Builder addReplaceConfigs( - int index, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig value) { - if (replaceConfigsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureReplaceConfigsIsMutable(); - replaceConfigs_.add(index, value); - onChanged(); - } else { - replaceConfigsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public Builder addReplaceConfigs( - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder builderForValue) { - if (replaceConfigsBuilder_ == null) { - ensureReplaceConfigsIsMutable(); - replaceConfigs_.add(builderForValue.build()); - onChanged(); - } else { - replaceConfigsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public Builder addReplaceConfigs( - int index, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder builderForValue) { - if (replaceConfigsBuilder_ == null) { - ensureReplaceConfigsIsMutable(); - replaceConfigs_.add(index, builderForValue.build()); - onChanged(); - } else { - replaceConfigsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public Builder addAllReplaceConfigs( - java.lang.Iterable values) { - if (replaceConfigsBuilder_ == null) { - ensureReplaceConfigsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, replaceConfigs_); - onChanged(); - } else { - replaceConfigsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public Builder clearReplaceConfigs() { - if (replaceConfigsBuilder_ == null) { - replaceConfigs_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - } else { - replaceConfigsBuilder_.clear(); - } - return this; - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public Builder removeReplaceConfigs(int index) { - if (replaceConfigsBuilder_ == null) { - ensureReplaceConfigsIsMutable(); - replaceConfigs_.remove(index); - onChanged(); - } else { - replaceConfigsBuilder_.remove(index); - } - return this; - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder getReplaceConfigsBuilder( - int index) { - return getReplaceConfigsFieldBuilder().getBuilder(index); - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfigOrBuilder getReplaceConfigsOrBuilder( - int index) { - if (replaceConfigsBuilder_ == null) { - return replaceConfigs_.get(index); } else { - return replaceConfigsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public java.util.List - getReplaceConfigsOrBuilderList() { - if (replaceConfigsBuilder_ != null) { - return replaceConfigsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(replaceConfigs_); - } - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder addReplaceConfigsBuilder() { - return getReplaceConfigsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.getDefaultInstance()); - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder addReplaceConfigsBuilder( - int index) { - return getReplaceConfigsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.getDefaultInstance()); - } - /** - *
-     * The strings to replace findings text findings with. Must specify at least
-     * one of these or one ImageRedactionConfig if redacting images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - public java.util.List - getReplaceConfigsBuilderList() { - return getReplaceConfigsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfigOrBuilder> - getReplaceConfigsFieldBuilder() { - if (replaceConfigsBuilder_ == null) { - replaceConfigsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig.Builder, com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfigOrBuilder>( - replaceConfigs_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); - replaceConfigs_ = null; - } - return replaceConfigsBuilder_; - } - - private java.util.List imageRedactionConfigs_ = - java.util.Collections.emptyList(); - private void ensureImageRedactionConfigsIsMutable() { - if (!((bitField0_ & 0x00000008) == 0x00000008)) { - imageRedactionConfigs_ = new java.util.ArrayList(imageRedactionConfigs_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfigOrBuilder> imageRedactionConfigsBuilder_; - - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public java.util.List getImageRedactionConfigsList() { - if (imageRedactionConfigsBuilder_ == null) { - return java.util.Collections.unmodifiableList(imageRedactionConfigs_); - } else { - return imageRedactionConfigsBuilder_.getMessageList(); - } - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public int getImageRedactionConfigsCount() { - if (imageRedactionConfigsBuilder_ == null) { - return imageRedactionConfigs_.size(); - } else { - return imageRedactionConfigsBuilder_.getCount(); - } - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig getImageRedactionConfigs(int index) { - if (imageRedactionConfigsBuilder_ == null) { - return imageRedactionConfigs_.get(index); - } else { - return imageRedactionConfigsBuilder_.getMessage(index); - } - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public Builder setImageRedactionConfigs( - int index, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig value) { - if (imageRedactionConfigsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureImageRedactionConfigsIsMutable(); - imageRedactionConfigs_.set(index, value); - onChanged(); - } else { - imageRedactionConfigsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public Builder setImageRedactionConfigs( - int index, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder builderForValue) { - if (imageRedactionConfigsBuilder_ == null) { - ensureImageRedactionConfigsIsMutable(); - imageRedactionConfigs_.set(index, builderForValue.build()); - onChanged(); - } else { - imageRedactionConfigsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public Builder addImageRedactionConfigs(com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig value) { - if (imageRedactionConfigsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureImageRedactionConfigsIsMutable(); - imageRedactionConfigs_.add(value); - onChanged(); - } else { - imageRedactionConfigsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public Builder addImageRedactionConfigs( - int index, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig value) { - if (imageRedactionConfigsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureImageRedactionConfigsIsMutable(); - imageRedactionConfigs_.add(index, value); - onChanged(); - } else { - imageRedactionConfigsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public Builder addImageRedactionConfigs( - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder builderForValue) { - if (imageRedactionConfigsBuilder_ == null) { - ensureImageRedactionConfigsIsMutable(); - imageRedactionConfigs_.add(builderForValue.build()); - onChanged(); - } else { - imageRedactionConfigsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public Builder addImageRedactionConfigs( - int index, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder builderForValue) { - if (imageRedactionConfigsBuilder_ == null) { - ensureImageRedactionConfigsIsMutable(); - imageRedactionConfigs_.add(index, builderForValue.build()); - onChanged(); - } else { - imageRedactionConfigsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public Builder addAllImageRedactionConfigs( - java.lang.Iterable values) { - if (imageRedactionConfigsBuilder_ == null) { - ensureImageRedactionConfigsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, imageRedactionConfigs_); - onChanged(); - } else { - imageRedactionConfigsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public Builder clearImageRedactionConfigs() { - if (imageRedactionConfigsBuilder_ == null) { - imageRedactionConfigs_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - imageRedactionConfigsBuilder_.clear(); - } - return this; - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public Builder removeImageRedactionConfigs(int index) { - if (imageRedactionConfigsBuilder_ == null) { - ensureImageRedactionConfigsIsMutable(); - imageRedactionConfigs_.remove(index); - onChanged(); - } else { - imageRedactionConfigsBuilder_.remove(index); - } - return this; - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder getImageRedactionConfigsBuilder( - int index) { - return getImageRedactionConfigsFieldBuilder().getBuilder(index); - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfigOrBuilder getImageRedactionConfigsOrBuilder( - int index) { - if (imageRedactionConfigsBuilder_ == null) { - return imageRedactionConfigs_.get(index); } else { - return imageRedactionConfigsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public java.util.List - getImageRedactionConfigsOrBuilderList() { - if (imageRedactionConfigsBuilder_ != null) { - return imageRedactionConfigsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(imageRedactionConfigs_); - } - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder addImageRedactionConfigsBuilder() { - return getImageRedactionConfigsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.getDefaultInstance()); - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder addImageRedactionConfigsBuilder( - int index) { - return getImageRedactionConfigsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.getDefaultInstance()); - } - /** - *
-     * The configuration for specifying what content to redact from images.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - public java.util.List - getImageRedactionConfigsBuilderList() { - return getImageRedactionConfigsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfigOrBuilder> - getImageRedactionConfigsFieldBuilder() { - if (imageRedactionConfigsBuilder_ == null) { - imageRedactionConfigsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig.Builder, com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfigOrBuilder>( - imageRedactionConfigs_, - ((bitField0_ & 0x00000008) == 0x00000008), - getParentForChildren(), - isClean()); - imageRedactionConfigs_ = null; - } - return imageRedactionConfigsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RedactContentRequest) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RedactContentRequest) - private static final com.google.privacy.dlp.v2beta1.RedactContentRequest DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RedactContentRequest(); - } - - public static com.google.privacy.dlp.v2beta1.RedactContentRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public RedactContentRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RedactContentRequest(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RedactContentRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentRequestOrBuilder.java deleted file mode 100644 index fff95fbfe115..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentRequestOrBuilder.java +++ /dev/null @@ -1,171 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface RedactContentRequestOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RedactContentRequest) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - boolean hasInspectConfig(); - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - com.google.privacy.dlp.v2beta1.InspectConfig getInspectConfig(); - /** - *
-   * Configuration for the inspector.
-   * 
- * - * .google.privacy.dlp.v2beta1.InspectConfig inspect_config = 1; - */ - com.google.privacy.dlp.v2beta1.InspectConfigOrBuilder getInspectConfigOrBuilder(); - - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - java.util.List - getItemsList(); - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - com.google.privacy.dlp.v2beta1.ContentItem getItems(int index); - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - int getItemsCount(); - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - java.util.List - getItemsOrBuilderList(); - /** - *
-   * The list of items to inspect. Up to 100 are allowed per request.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 2; - */ - com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index); - - /** - *
-   * The strings to replace findings text findings with. Must specify at least
-   * one of these or one ImageRedactionConfig if redacting images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - java.util.List - getReplaceConfigsList(); - /** - *
-   * The strings to replace findings text findings with. Must specify at least
-   * one of these or one ImageRedactionConfig if redacting images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig getReplaceConfigs(int index); - /** - *
-   * The strings to replace findings text findings with. Must specify at least
-   * one of these or one ImageRedactionConfig if redacting images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - int getReplaceConfigsCount(); - /** - *
-   * The strings to replace findings text findings with. Must specify at least
-   * one of these or one ImageRedactionConfig if redacting images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - java.util.List - getReplaceConfigsOrBuilderList(); - /** - *
-   * The strings to replace findings text findings with. Must specify at least
-   * one of these or one ImageRedactionConfig if redacting images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfig replace_configs = 3; - */ - com.google.privacy.dlp.v2beta1.RedactContentRequest.ReplaceConfigOrBuilder getReplaceConfigsOrBuilder( - int index); - - /** - *
-   * The configuration for specifying what content to redact from images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - java.util.List - getImageRedactionConfigsList(); - /** - *
-   * The configuration for specifying what content to redact from images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig getImageRedactionConfigs(int index); - /** - *
-   * The configuration for specifying what content to redact from images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - int getImageRedactionConfigsCount(); - /** - *
-   * The configuration for specifying what content to redact from images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - java.util.List - getImageRedactionConfigsOrBuilderList(); - /** - *
-   * The configuration for specifying what content to redact from images.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfig image_redaction_configs = 4; - */ - com.google.privacy.dlp.v2beta1.RedactContentRequest.ImageRedactionConfigOrBuilder getImageRedactionConfigsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentResponse.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentResponse.java deleted file mode 100644 index 9a6cf06368b3..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentResponse.java +++ /dev/null @@ -1,834 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Results of redacting a list of items.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RedactContentResponse} - */ -public final class RedactContentResponse extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RedactContentResponse) - RedactContentResponseOrBuilder { -private static final long serialVersionUID = 0L; - // Use RedactContentResponse.newBuilder() to construct. - private RedactContentResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private RedactContentResponse() { - items_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private RedactContentResponse( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - items_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - items_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.ContentItem.parser(), extensionRegistry)); - 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) == 0x00000001)) { - items_ = java.util.Collections.unmodifiableList(items_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RedactContentResponse.class, com.google.privacy.dlp.v2beta1.RedactContentResponse.Builder.class); - } - - public static final int ITEMS_FIELD_NUMBER = 1; - private java.util.List items_; - /** - *
-   * The redacted content.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public java.util.List getItemsList() { - return items_; - } - /** - *
-   * The redacted content.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public java.util.List - getItemsOrBuilderList() { - return items_; - } - /** - *
-   * The redacted content.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public int getItemsCount() { - return items_.size(); - } - /** - *
-   * The redacted content.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItem getItems(int index) { - return items_.get(index); - } - /** - *
-   * The redacted content.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index) { - return items_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < items_.size(); i++) { - output.writeMessage(1, items_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < items_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, items_.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.privacy.dlp.v2beta1.RedactContentResponse)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RedactContentResponse other = (com.google.privacy.dlp.v2beta1.RedactContentResponse) obj; - - boolean result = true; - result = result && getItemsList() - .equals(other.getItemsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getItemsCount() > 0) { - hash = (37 * hash) + ITEMS_FIELD_NUMBER; - hash = (53 * hash) + getItemsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RedactContentResponse parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RedactContentResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentResponse 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.privacy.dlp.v2beta1.RedactContentResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RedactContentResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RedactContentResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentResponse 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.privacy.dlp.v2beta1.RedactContentResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentResponse 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.privacy.dlp.v2beta1.RedactContentResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RedactContentResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RedactContentResponse prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Results of redacting a list of items.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RedactContentResponse} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RedactContentResponse) - com.google.privacy.dlp.v2beta1.RedactContentResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RedactContentResponse.class, com.google.privacy.dlp.v2beta1.RedactContentResponse.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RedactContentResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getItemsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (itemsBuilder_ == null) { - items_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - itemsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RedactContentResponse_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RedactContentResponse getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RedactContentResponse.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RedactContentResponse build() { - com.google.privacy.dlp.v2beta1.RedactContentResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RedactContentResponse buildPartial() { - com.google.privacy.dlp.v2beta1.RedactContentResponse result = new com.google.privacy.dlp.v2beta1.RedactContentResponse(this); - int from_bitField0_ = bitField0_; - if (itemsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - items_ = java.util.Collections.unmodifiableList(items_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.items_ = items_; - } else { - result.items_ = itemsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RedactContentResponse) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RedactContentResponse)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RedactContentResponse other) { - if (other == com.google.privacy.dlp.v2beta1.RedactContentResponse.getDefaultInstance()) return this; - if (itemsBuilder_ == null) { - if (!other.items_.isEmpty()) { - if (items_.isEmpty()) { - items_ = other.items_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureItemsIsMutable(); - items_.addAll(other.items_); - } - onChanged(); - } - } else { - if (!other.items_.isEmpty()) { - if (itemsBuilder_.isEmpty()) { - itemsBuilder_.dispose(); - itemsBuilder_ = null; - items_ = other.items_; - bitField0_ = (bitField0_ & ~0x00000001); - itemsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getItemsFieldBuilder() : null; - } else { - itemsBuilder_.addAllMessages(other.items_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RedactContentResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RedactContentResponse) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List items_ = - java.util.Collections.emptyList(); - private void ensureItemsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - items_ = new java.util.ArrayList(items_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder> itemsBuilder_; - - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public java.util.List getItemsList() { - if (itemsBuilder_ == null) { - return java.util.Collections.unmodifiableList(items_); - } else { - return itemsBuilder_.getMessageList(); - } - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public int getItemsCount() { - if (itemsBuilder_ == null) { - return items_.size(); - } else { - return itemsBuilder_.getCount(); - } - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItem getItems(int index) { - if (itemsBuilder_ == null) { - return items_.get(index); - } else { - return itemsBuilder_.getMessage(index); - } - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder setItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.set(index, value); - onChanged(); - } else { - itemsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder setItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.set(index, builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder addItems(com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.add(value); - onChanged(); - } else { - itemsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder addItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem value) { - if (itemsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureItemsIsMutable(); - items_.add(index, value); - onChanged(); - } else { - itemsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder addItems( - com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.add(builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder addItems( - int index, com.google.privacy.dlp.v2beta1.ContentItem.Builder builderForValue) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.add(index, builderForValue.build()); - onChanged(); - } else { - itemsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder addAllItems( - java.lang.Iterable values) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, items_); - onChanged(); - } else { - itemsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder clearItems() { - if (itemsBuilder_ == null) { - items_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - itemsBuilder_.clear(); - } - return this; - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public Builder removeItems(int index) { - if (itemsBuilder_ == null) { - ensureItemsIsMutable(); - items_.remove(index); - onChanged(); - } else { - itemsBuilder_.remove(index); - } - return this; - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder getItemsBuilder( - int index) { - return getItemsFieldBuilder().getBuilder(index); - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index) { - if (itemsBuilder_ == null) { - return items_.get(index); } else { - return itemsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public java.util.List - getItemsOrBuilderList() { - if (itemsBuilder_ != null) { - return itemsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(items_); - } - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder addItemsBuilder() { - return getItemsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()); - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public com.google.privacy.dlp.v2beta1.ContentItem.Builder addItemsBuilder( - int index) { - return getItemsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.ContentItem.getDefaultInstance()); - } - /** - *
-     * The redacted content.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - public java.util.List - getItemsBuilderList() { - return getItemsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder> - getItemsFieldBuilder() { - if (itemsBuilder_ == null) { - itemsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ContentItem, com.google.privacy.dlp.v2beta1.ContentItem.Builder, com.google.privacy.dlp.v2beta1.ContentItemOrBuilder>( - items_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - items_ = null; - } - return itemsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RedactContentResponse) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RedactContentResponse) - private static final com.google.privacy.dlp.v2beta1.RedactContentResponse DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RedactContentResponse(); - } - - public static com.google.privacy.dlp.v2beta1.RedactContentResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public RedactContentResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RedactContentResponse(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RedactContentResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentResponseOrBuilder.java deleted file mode 100644 index cdd233ea15f5..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RedactContentResponseOrBuilder.java +++ /dev/null @@ -1,53 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface RedactContentResponseOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RedactContentResponse) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The redacted content.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - java.util.List - getItemsList(); - /** - *
-   * The redacted content.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - com.google.privacy.dlp.v2beta1.ContentItem getItems(int index); - /** - *
-   * The redacted content.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - int getItemsCount(); - /** - *
-   * The redacted content.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - java.util.List - getItemsOrBuilderList(); - /** - *
-   * The redacted content.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.ContentItem items = 1; - */ - com.google.privacy.dlp.v2beta1.ContentItemOrBuilder getItemsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RelationalOperator.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RelationalOperator.java deleted file mode 100644 index 05e068e665f9..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RelationalOperator.java +++ /dev/null @@ -1,217 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Operators available for comparing the value of fields.
- * 
- * - * Protobuf enum {@code google.privacy.dlp.v2beta1.RelationalOperator} - */ -public enum RelationalOperator - implements com.google.protobuf.ProtocolMessageEnum { - /** - * RELATIONAL_OPERATOR_UNSPECIFIED = 0; - */ - RELATIONAL_OPERATOR_UNSPECIFIED(0), - /** - *
-   * Equal.
-   * 
- * - * EQUAL_TO = 1; - */ - EQUAL_TO(1), - /** - *
-   * Not equal to.
-   * 
- * - * NOT_EQUAL_TO = 2; - */ - NOT_EQUAL_TO(2), - /** - *
-   * Greater than.
-   * 
- * - * GREATER_THAN = 3; - */ - GREATER_THAN(3), - /** - *
-   * Less than.
-   * 
- * - * LESS_THAN = 4; - */ - LESS_THAN(4), - /** - *
-   * Greater than or equals.
-   * 
- * - * GREATER_THAN_OR_EQUALS = 5; - */ - GREATER_THAN_OR_EQUALS(5), - /** - *
-   * Less than or equals.
-   * 
- * - * LESS_THAN_OR_EQUALS = 6; - */ - LESS_THAN_OR_EQUALS(6), - /** - *
-   * Exists
-   * 
- * - * EXISTS = 7; - */ - EXISTS(7), - UNRECOGNIZED(-1), - ; - - /** - * RELATIONAL_OPERATOR_UNSPECIFIED = 0; - */ - public static final int RELATIONAL_OPERATOR_UNSPECIFIED_VALUE = 0; - /** - *
-   * Equal.
-   * 
- * - * EQUAL_TO = 1; - */ - public static final int EQUAL_TO_VALUE = 1; - /** - *
-   * Not equal to.
-   * 
- * - * NOT_EQUAL_TO = 2; - */ - public static final int NOT_EQUAL_TO_VALUE = 2; - /** - *
-   * Greater than.
-   * 
- * - * GREATER_THAN = 3; - */ - public static final int GREATER_THAN_VALUE = 3; - /** - *
-   * Less than.
-   * 
- * - * LESS_THAN = 4; - */ - public static final int LESS_THAN_VALUE = 4; - /** - *
-   * Greater than or equals.
-   * 
- * - * GREATER_THAN_OR_EQUALS = 5; - */ - public static final int GREATER_THAN_OR_EQUALS_VALUE = 5; - /** - *
-   * Less than or equals.
-   * 
- * - * LESS_THAN_OR_EQUALS = 6; - */ - public static final int LESS_THAN_OR_EQUALS_VALUE = 6; - /** - *
-   * Exists
-   * 
- * - * EXISTS = 7; - */ - public static final int EXISTS_VALUE = 7; - - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static RelationalOperator valueOf(int value) { - return forNumber(value); - } - - public static RelationalOperator forNumber(int value) { - switch (value) { - case 0: return RELATIONAL_OPERATOR_UNSPECIFIED; - case 1: return EQUAL_TO; - case 2: return NOT_EQUAL_TO; - case 3: return GREATER_THAN; - case 4: return LESS_THAN; - case 5: return GREATER_THAN_OR_EQUALS; - case 6: return LESS_THAN_OR_EQUALS; - case 7: return EXISTS; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - private static final com.google.protobuf.Internal.EnumLiteMap< - RelationalOperator> internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public RelationalOperator findValueByNumber(int number) { - return RelationalOperator.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - 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.privacy.dlp.v2beta1.DlpProto.getDescriptor().getEnumTypes().get(1); - } - - private static final RelationalOperator[] VALUES = values(); - - public static RelationalOperator 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 RelationalOperator(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.privacy.dlp.v2beta1.RelationalOperator) -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceValueConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceValueConfig.java deleted file mode 100644 index a3713de644c4..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceValueConfig.java +++ /dev/null @@ -1,626 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Replace each input value with a given `Value`.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ReplaceValueConfig} - */ -public final class ReplaceValueConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ReplaceValueConfig) - ReplaceValueConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use ReplaceValueConfig.newBuilder() to construct. - private ReplaceValueConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ReplaceValueConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ReplaceValueConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.Value.Builder subBuilder = null; - if (newValue_ != null) { - subBuilder = newValue_.toBuilder(); - } - newValue_ = input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(newValue_); - newValue_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ReplaceValueConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ReplaceValueConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ReplaceValueConfig.class, com.google.privacy.dlp.v2beta1.ReplaceValueConfig.Builder.class); - } - - public static final int NEW_VALUE_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.Value newValue_; - /** - *
-   * Value to replace it with.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public boolean hasNewValue() { - return newValue_ != null; - } - /** - *
-   * Value to replace it with.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getNewValue() { - return newValue_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : newValue_; - } - /** - *
-   * Value to replace it with.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getNewValueOrBuilder() { - return getNewValue(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (newValue_ != null) { - output.writeMessage(1, getNewValue()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (newValue_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getNewValue()); - } - 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.privacy.dlp.v2beta1.ReplaceValueConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ReplaceValueConfig other = (com.google.privacy.dlp.v2beta1.ReplaceValueConfig) obj; - - boolean result = true; - result = result && (hasNewValue() == other.hasNewValue()); - if (hasNewValue()) { - result = result && getNewValue() - .equals(other.getNewValue()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasNewValue()) { - hash = (37 * hash) + NEW_VALUE_FIELD_NUMBER; - hash = (53 * hash) + getNewValue().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.ReplaceValueConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ReplaceValueConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ReplaceValueConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ReplaceValueConfig 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.privacy.dlp.v2beta1.ReplaceValueConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ReplaceValueConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ReplaceValueConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ReplaceValueConfig 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.privacy.dlp.v2beta1.ReplaceValueConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ReplaceValueConfig 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.privacy.dlp.v2beta1.ReplaceValueConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ReplaceValueConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ReplaceValueConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Replace each input value with a given `Value`.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ReplaceValueConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ReplaceValueConfig) - com.google.privacy.dlp.v2beta1.ReplaceValueConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ReplaceValueConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ReplaceValueConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ReplaceValueConfig.class, com.google.privacy.dlp.v2beta1.ReplaceValueConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ReplaceValueConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (newValueBuilder_ == null) { - newValue_ = null; - } else { - newValue_ = null; - newValueBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ReplaceValueConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ReplaceValueConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ReplaceValueConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ReplaceValueConfig build() { - com.google.privacy.dlp.v2beta1.ReplaceValueConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ReplaceValueConfig buildPartial() { - com.google.privacy.dlp.v2beta1.ReplaceValueConfig result = new com.google.privacy.dlp.v2beta1.ReplaceValueConfig(this); - if (newValueBuilder_ == null) { - result.newValue_ = newValue_; - } else { - result.newValue_ = newValueBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ReplaceValueConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ReplaceValueConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ReplaceValueConfig other) { - if (other == com.google.privacy.dlp.v2beta1.ReplaceValueConfig.getDefaultInstance()) return this; - if (other.hasNewValue()) { - mergeNewValue(other.getNewValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ReplaceValueConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ReplaceValueConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.Value newValue_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> newValueBuilder_; - /** - *
-     * Value to replace it with.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public boolean hasNewValue() { - return newValueBuilder_ != null || newValue_ != null; - } - /** - *
-     * Value to replace it with.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getNewValue() { - if (newValueBuilder_ == null) { - return newValue_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : newValue_; - } else { - return newValueBuilder_.getMessage(); - } - } - /** - *
-     * Value to replace it with.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public Builder setNewValue(com.google.privacy.dlp.v2beta1.Value value) { - if (newValueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - newValue_ = value; - onChanged(); - } else { - newValueBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Value to replace it with.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public Builder setNewValue( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (newValueBuilder_ == null) { - newValue_ = builderForValue.build(); - onChanged(); - } else { - newValueBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Value to replace it with.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public Builder mergeNewValue(com.google.privacy.dlp.v2beta1.Value value) { - if (newValueBuilder_ == null) { - if (newValue_ != null) { - newValue_ = - com.google.privacy.dlp.v2beta1.Value.newBuilder(newValue_).mergeFrom(value).buildPartial(); - } else { - newValue_ = value; - } - onChanged(); - } else { - newValueBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Value to replace it with.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public Builder clearNewValue() { - if (newValueBuilder_ == null) { - newValue_ = null; - onChanged(); - } else { - newValue_ = null; - newValueBuilder_ = null; - } - - return this; - } - /** - *
-     * Value to replace it with.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getNewValueBuilder() { - - onChanged(); - return getNewValueFieldBuilder().getBuilder(); - } - /** - *
-     * Value to replace it with.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getNewValueOrBuilder() { - if (newValueBuilder_ != null) { - return newValueBuilder_.getMessageOrBuilder(); - } else { - return newValue_ == null ? - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : newValue_; - } - } - /** - *
-     * Value to replace it with.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getNewValueFieldBuilder() { - if (newValueBuilder_ == null) { - newValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - getNewValue(), - getParentForChildren(), - isClean()); - newValue_ = null; - } - return newValueBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ReplaceValueConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ReplaceValueConfig) - private static final com.google.privacy.dlp.v2beta1.ReplaceValueConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ReplaceValueConfig(); - } - - public static com.google.privacy.dlp.v2beta1.ReplaceValueConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ReplaceValueConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ReplaceValueConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ReplaceValueConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceValueConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceValueConfigOrBuilder.java deleted file mode 100644 index 619c9ad52229..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceValueConfigOrBuilder.java +++ /dev/null @@ -1,34 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ReplaceValueConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ReplaceValueConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Value to replace it with.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - boolean hasNewValue(); - /** - *
-   * Value to replace it with.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - com.google.privacy.dlp.v2beta1.Value getNewValue(); - /** - *
-   * Value to replace it with.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value new_value = 1; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getNewValueOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceWithInfoTypeConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceWithInfoTypeConfig.java deleted file mode 100644 index 176348a83f5f..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceWithInfoTypeConfig.java +++ /dev/null @@ -1,396 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Replace each matching finding with the name of the info_type.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig} - */ -public final class ReplaceWithInfoTypeConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) - ReplaceWithInfoTypeConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use ReplaceWithInfoTypeConfig.newBuilder() to construct. - private ReplaceWithInfoTypeConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ReplaceWithInfoTypeConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ReplaceWithInfoTypeConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownFieldProto3( - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ReplaceWithInfoTypeConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ReplaceWithInfoTypeConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.class, com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.Builder.class); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - 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.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig other = (com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) obj; - - boolean result = true; - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig 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.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig 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.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig 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.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Replace each matching finding with the name of the info_type.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ReplaceWithInfoTypeConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ReplaceWithInfoTypeConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.class, com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ReplaceWithInfoTypeConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig build() { - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig buildPartial() { - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig result = new com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig(this); - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig other) { - if (other == com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig.getDefaultInstance()) return this; - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) - private static final com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig(); - } - - public static com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ReplaceWithInfoTypeConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ReplaceWithInfoTypeConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceWithInfoTypeConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceWithInfoTypeConfigOrBuilder.java deleted file mode 100644 index 8b48aec8b452..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ReplaceWithInfoTypeConfigOrBuilder.java +++ /dev/null @@ -1,9 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ReplaceWithInfoTypeConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ReplaceWithInfoTypeConfig) - com.google.protobuf.MessageOrBuilder { -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ResultName.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ResultName.java deleted file mode 100644 index f071b54b57fa..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ResultName.java +++ /dev/null @@ -1,175 +0,0 @@ -/* - * Copyright 2018 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except - * in compliance with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software distributed under the License - * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express - * or implied. See the License for the specific language governing permissions and limitations under - * the License. - */ - -package com.google.privacy.dlp.v2beta1; - -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.api.resourcenames.ResourceNameType; -import java.util.Map; -import java.util.ArrayList; -import java.util.List; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -@javax.annotation.Generated("by GAPIC protoc plugin") -public class ResultName implements ResourceName { - - private static final PathTemplate PATH_TEMPLATE = - PathTemplate.createWithoutUrlEncoding("inspect/results/{result}"); - - private volatile Map fieldValuesMap; - - private final String result; - - public String getResult() { - return result; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - private ResultName(Builder builder) { - result = Preconditions.checkNotNull(builder.getResult()); - } - - public static ResultName of(String result) { - return newBuilder() - .setResult(result) - .build(); - } - - public static String format(String result) { - return newBuilder() - .setResult(result) - .build() - .toString(); - } - - public static ResultName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PATH_TEMPLATE.validatedMatch(formattedString, "ResultName.parse: formattedString not in valid format"); - return of(matchMap.get("result")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList(values.size()); - for (ResultName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PATH_TEMPLATE.matches(formattedString); - } - - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - fieldMapBuilder.put("result", result); - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - /** - * @deprecated This method is only present to satisfy the ResourceName interface. - */ - @Deprecated - public ResourceNameType getType() { - throw new UnsupportedOperationException("ResultName.getType() not supported"); - } - - @Override - public String toString() { - return PATH_TEMPLATE.instantiate("result", result); - } - - /** Builder for ResultName. */ - public static class Builder { - - private String result; - - public String getResult() { - return result; - } - - public Builder setResult(String result) { - this.result = result; - return this; - } - - private Builder() { - } - - private Builder(ResultName resultName) { - result = resultName.result; - } - - public ResultName build() { - return new ResultName(this); - } - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o instanceof ResultName) { - ResultName that = (ResultName) o; - return (this.result.equals(that.result)); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= result.hashCode(); - return h; - } -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationMetadata.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationMetadata.java deleted file mode 100644 index 52b4b99bf306..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationMetadata.java +++ /dev/null @@ -1,1088 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Metadata returned within the
- * [`riskAnalysis.operations.get`](/dlp/docs/reference/rest/v2beta1/riskAnalysis.operations/get)
- * for risk analysis.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata} - */ -public final class RiskAnalysisOperationMetadata extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata) - RiskAnalysisOperationMetadataOrBuilder { -private static final long serialVersionUID = 0L; - // Use RiskAnalysisOperationMetadata.newBuilder() to construct. - private RiskAnalysisOperationMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private RiskAnalysisOperationMetadata() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private RiskAnalysisOperationMetadata( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - 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.privacy.dlp.v2beta1.PrivacyMetric.Builder subBuilder = null; - if (requestedPrivacyMetric_ != null) { - subBuilder = requestedPrivacyMetric_.toBuilder(); - } - requestedPrivacyMetric_ = input.readMessage(com.google.privacy.dlp.v2beta1.PrivacyMetric.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestedPrivacyMetric_); - requestedPrivacyMetric_ = subBuilder.buildPartial(); - } - - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.BigQueryTable.Builder subBuilder = null; - if (requestedSourceTable_ != null) { - subBuilder = requestedSourceTable_.toBuilder(); - } - requestedSourceTable_ = input.readMessage(com.google.privacy.dlp.v2beta1.BigQueryTable.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestedSourceTable_); - requestedSourceTable_ = subBuilder.buildPartial(); - } - - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationMetadata_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata.Builder.class); - } - - public static final int CREATE_TIME_FIELD_NUMBER = 1; - private com.google.protobuf.Timestamp createTime_; - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int REQUESTED_PRIVACY_METRIC_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.PrivacyMetric requestedPrivacyMetric_; - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public boolean hasRequestedPrivacyMetric() { - return requestedPrivacyMetric_ != null; - } - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric getRequestedPrivacyMetric() { - return requestedPrivacyMetric_ == null ? com.google.privacy.dlp.v2beta1.PrivacyMetric.getDefaultInstance() : requestedPrivacyMetric_; - } - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder getRequestedPrivacyMetricOrBuilder() { - return getRequestedPrivacyMetric(); - } - - public static final int REQUESTED_SOURCE_TABLE_FIELD_NUMBER = 3; - private com.google.privacy.dlp.v2beta1.BigQueryTable requestedSourceTable_; - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public boolean hasRequestedSourceTable() { - return requestedSourceTable_ != null; - } - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable getRequestedSourceTable() { - return requestedSourceTable_ == null ? com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance() : requestedSourceTable_; - } - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getRequestedSourceTableOrBuilder() { - return getRequestedSourceTable(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (createTime_ != null) { - output.writeMessage(1, getCreateTime()); - } - if (requestedPrivacyMetric_ != null) { - output.writeMessage(2, getRequestedPrivacyMetric()); - } - if (requestedSourceTable_ != null) { - output.writeMessage(3, getRequestedSourceTable()); - } - unknownFields.writeTo(output); - } - - 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 (requestedPrivacyMetric_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getRequestedPrivacyMetric()); - } - if (requestedSourceTable_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, getRequestedSourceTable()); - } - 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.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata) obj; - - boolean result = true; - result = result && (hasCreateTime() == other.hasCreateTime()); - if (hasCreateTime()) { - result = result && getCreateTime() - .equals(other.getCreateTime()); - } - result = result && (hasRequestedPrivacyMetric() == other.hasRequestedPrivacyMetric()); - if (hasRequestedPrivacyMetric()) { - result = result && getRequestedPrivacyMetric() - .equals(other.getRequestedPrivacyMetric()); - } - result = result && (hasRequestedSourceTable() == other.hasRequestedSourceTable()); - if (hasRequestedSourceTable()) { - result = result && getRequestedSourceTable() - .equals(other.getRequestedSourceTable()); - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @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 (hasRequestedPrivacyMetric()) { - hash = (37 * hash) + REQUESTED_PRIVACY_METRIC_FIELD_NUMBER; - hash = (53 * hash) + getRequestedPrivacyMetric().hashCode(); - } - if (hasRequestedSourceTable()) { - hash = (37 * hash) + REQUESTED_SOURCE_TABLE_FIELD_NUMBER; - hash = (53 * hash) + getRequestedSourceTable().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata 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.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata 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.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata 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.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Metadata returned within the
-   * [`riskAnalysis.operations.get`](/dlp/docs/reference/rest/v2beta1/riskAnalysis.operations/get)
-   * for risk analysis.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadataOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationMetadata_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (requestedPrivacyMetricBuilder_ == null) { - requestedPrivacyMetric_ = null; - } else { - requestedPrivacyMetric_ = null; - requestedPrivacyMetricBuilder_ = null; - } - if (requestedSourceTableBuilder_ == null) { - requestedSourceTable_ = null; - } else { - requestedSourceTable_ = null; - requestedSourceTableBuilder_ = null; - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationMetadata_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata(this); - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (requestedPrivacyMetricBuilder_ == null) { - result.requestedPrivacyMetric_ = requestedPrivacyMetric_; - } else { - result.requestedPrivacyMetric_ = requestedPrivacyMetricBuilder_.build(); - } - if (requestedSourceTableBuilder_ == null) { - result.requestedSourceTable_ = requestedSourceTable_; - } else { - result.requestedSourceTable_ = requestedSourceTableBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata.getDefaultInstance()) return this; - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasRequestedPrivacyMetric()) { - mergeRequestedPrivacyMetric(other.getRequestedPrivacyMetric()); - } - if (other.hasRequestedSourceTable()) { - mergeRequestedSourceTable(other.getRequestedSourceTable()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.protobuf.Timestamp createTime_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; - /** - *
-     * The time which this request was started.
-     * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .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; - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .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; - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .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; - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .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_; - } - } - /** - *
-     * The time which this request was started.
-     * 
- * - * .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.privacy.dlp.v2beta1.PrivacyMetric requestedPrivacyMetric_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric, com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder> requestedPrivacyMetricBuilder_; - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public boolean hasRequestedPrivacyMetric() { - return requestedPrivacyMetricBuilder_ != null || requestedPrivacyMetric_ != null; - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric getRequestedPrivacyMetric() { - if (requestedPrivacyMetricBuilder_ == null) { - return requestedPrivacyMetric_ == null ? com.google.privacy.dlp.v2beta1.PrivacyMetric.getDefaultInstance() : requestedPrivacyMetric_; - } else { - return requestedPrivacyMetricBuilder_.getMessage(); - } - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public Builder setRequestedPrivacyMetric(com.google.privacy.dlp.v2beta1.PrivacyMetric value) { - if (requestedPrivacyMetricBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - requestedPrivacyMetric_ = value; - onChanged(); - } else { - requestedPrivacyMetricBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public Builder setRequestedPrivacyMetric( - com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder builderForValue) { - if (requestedPrivacyMetricBuilder_ == null) { - requestedPrivacyMetric_ = builderForValue.build(); - onChanged(); - } else { - requestedPrivacyMetricBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public Builder mergeRequestedPrivacyMetric(com.google.privacy.dlp.v2beta1.PrivacyMetric value) { - if (requestedPrivacyMetricBuilder_ == null) { - if (requestedPrivacyMetric_ != null) { - requestedPrivacyMetric_ = - com.google.privacy.dlp.v2beta1.PrivacyMetric.newBuilder(requestedPrivacyMetric_).mergeFrom(value).buildPartial(); - } else { - requestedPrivacyMetric_ = value; - } - onChanged(); - } else { - requestedPrivacyMetricBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public Builder clearRequestedPrivacyMetric() { - if (requestedPrivacyMetricBuilder_ == null) { - requestedPrivacyMetric_ = null; - onChanged(); - } else { - requestedPrivacyMetric_ = null; - requestedPrivacyMetricBuilder_ = null; - } - - return this; - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder getRequestedPrivacyMetricBuilder() { - - onChanged(); - return getRequestedPrivacyMetricFieldBuilder().getBuilder(); - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - public com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder getRequestedPrivacyMetricOrBuilder() { - if (requestedPrivacyMetricBuilder_ != null) { - return requestedPrivacyMetricBuilder_.getMessageOrBuilder(); - } else { - return requestedPrivacyMetric_ == null ? - com.google.privacy.dlp.v2beta1.PrivacyMetric.getDefaultInstance() : requestedPrivacyMetric_; - } - } - /** - *
-     * Privacy metric to compute.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric, com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder> - getRequestedPrivacyMetricFieldBuilder() { - if (requestedPrivacyMetricBuilder_ == null) { - requestedPrivacyMetricBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrivacyMetric, com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder>( - getRequestedPrivacyMetric(), - getParentForChildren(), - isClean()); - requestedPrivacyMetric_ = null; - } - return requestedPrivacyMetricBuilder_; - } - - private com.google.privacy.dlp.v2beta1.BigQueryTable requestedSourceTable_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder> requestedSourceTableBuilder_; - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public boolean hasRequestedSourceTable() { - return requestedSourceTableBuilder_ != null || requestedSourceTable_ != null; - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable getRequestedSourceTable() { - if (requestedSourceTableBuilder_ == null) { - return requestedSourceTable_ == null ? com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance() : requestedSourceTable_; - } else { - return requestedSourceTableBuilder_.getMessage(); - } - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public Builder setRequestedSourceTable(com.google.privacy.dlp.v2beta1.BigQueryTable value) { - if (requestedSourceTableBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - requestedSourceTable_ = value; - onChanged(); - } else { - requestedSourceTableBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public Builder setRequestedSourceTable( - com.google.privacy.dlp.v2beta1.BigQueryTable.Builder builderForValue) { - if (requestedSourceTableBuilder_ == null) { - requestedSourceTable_ = builderForValue.build(); - onChanged(); - } else { - requestedSourceTableBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public Builder mergeRequestedSourceTable(com.google.privacy.dlp.v2beta1.BigQueryTable value) { - if (requestedSourceTableBuilder_ == null) { - if (requestedSourceTable_ != null) { - requestedSourceTable_ = - com.google.privacy.dlp.v2beta1.BigQueryTable.newBuilder(requestedSourceTable_).mergeFrom(value).buildPartial(); - } else { - requestedSourceTable_ = value; - } - onChanged(); - } else { - requestedSourceTableBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public Builder clearRequestedSourceTable() { - if (requestedSourceTableBuilder_ == null) { - requestedSourceTable_ = null; - onChanged(); - } else { - requestedSourceTable_ = null; - requestedSourceTableBuilder_ = null; - } - - return this; - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTable.Builder getRequestedSourceTableBuilder() { - - onChanged(); - return getRequestedSourceTableFieldBuilder().getBuilder(); - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - public com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getRequestedSourceTableOrBuilder() { - if (requestedSourceTableBuilder_ != null) { - return requestedSourceTableBuilder_.getMessageOrBuilder(); - } else { - return requestedSourceTable_ == null ? - com.google.privacy.dlp.v2beta1.BigQueryTable.getDefaultInstance() : requestedSourceTable_; - } - } - /** - *
-     * Input dataset to compute metrics over.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder> - getRequestedSourceTableFieldBuilder() { - if (requestedSourceTableBuilder_ == null) { - requestedSourceTableBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryTable, com.google.privacy.dlp.v2beta1.BigQueryTable.Builder, com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder>( - getRequestedSourceTable(), - getParentForChildren(), - isClean()); - requestedSourceTable_ = null; - } - return requestedSourceTableBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public RiskAnalysisOperationMetadata parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RiskAnalysisOperationMetadata(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationMetadataOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationMetadataOrBuilder.java deleted file mode 100644 index 488b7b2984ad..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationMetadataOrBuilder.java +++ /dev/null @@ -1,84 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface RiskAnalysisOperationMetadataOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - boolean hasCreateTime(); - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - *
-   * The time which this request was started.
-   * 
- * - * .google.protobuf.Timestamp create_time = 1; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - boolean hasRequestedPrivacyMetric(); - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetric getRequestedPrivacyMetric(); - /** - *
-   * Privacy metric to compute.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrivacyMetric requested_privacy_metric = 2; - */ - com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder getRequestedPrivacyMetricOrBuilder(); - - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - boolean hasRequestedSourceTable(); - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - com.google.privacy.dlp.v2beta1.BigQueryTable getRequestedSourceTable(); - /** - *
-   * Input dataset to compute metrics over.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryTable requested_source_table = 3; - */ - com.google.privacy.dlp.v2beta1.BigQueryTableOrBuilder getRequestedSourceTableOrBuilder(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationResult.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationResult.java deleted file mode 100644 index 120662947824..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationResult.java +++ /dev/null @@ -1,11402 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Result of a risk analysis
- * [`Operation`](/dlp/docs/reference/rest/v2beta1/inspect.operations)
- * request.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult} - */ -public final class RiskAnalysisOperationResult extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult) - RiskAnalysisOperationResultOrBuilder { -private static final long serialVersionUID = 0L; - // Use RiskAnalysisOperationResult.newBuilder() to construct. - private RiskAnalysisOperationResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private RiskAnalysisOperationResult() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private RiskAnalysisOperationResult( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.Builder subBuilder = null; - if (resultCase_ == 3) { - subBuilder = ((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) result_).toBuilder(); - } - result_ = - input.readMessage(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) result_); - result_ = subBuilder.buildPartial(); - } - resultCase_ = 3; - break; - } - case 34: { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.Builder subBuilder = null; - if (resultCase_ == 4) { - subBuilder = ((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) result_).toBuilder(); - } - result_ = - input.readMessage(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) result_); - result_ = subBuilder.buildPartial(); - } - resultCase_ = 4; - break; - } - case 42: { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.Builder subBuilder = null; - if (resultCase_ == 5) { - subBuilder = ((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) result_).toBuilder(); - } - result_ = - input.readMessage(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) result_); - result_ = subBuilder.buildPartial(); - } - resultCase_ = 5; - break; - } - case 50: { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.Builder subBuilder = null; - if (resultCase_ == 6) { - subBuilder = ((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) result_).toBuilder(); - } - result_ = - input.readMessage(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) result_); - result_ = subBuilder.buildPartial(); - } - resultCase_ = 6; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.Builder.class); - } - - public interface NumericalStatsResultOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Minimum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - boolean hasMinValue(); - /** - *
-     * Minimum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - com.google.privacy.dlp.v2beta1.Value getMinValue(); - /** - *
-     * Minimum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getMinValueOrBuilder(); - - /** - *
-     * Maximum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - boolean hasMaxValue(); - /** - *
-     * Maximum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - com.google.privacy.dlp.v2beta1.Value getMaxValue(); - /** - *
-     * Maximum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getMaxValueOrBuilder(); - - /** - *
-     * List of 99 values that partition the set of field values into 100 equal
-     * sized buckets.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - java.util.List - getQuantileValuesList(); - /** - *
-     * List of 99 values that partition the set of field values into 100 equal
-     * sized buckets.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - com.google.privacy.dlp.v2beta1.Value getQuantileValues(int index); - /** - *
-     * List of 99 values that partition the set of field values into 100 equal
-     * sized buckets.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - int getQuantileValuesCount(); - /** - *
-     * List of 99 values that partition the set of field values into 100 equal
-     * sized buckets.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - java.util.List - getQuantileValuesOrBuilderList(); - /** - *
-     * List of 99 values that partition the set of field values into 100 equal
-     * sized buckets.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getQuantileValuesOrBuilder( - int index); - } - /** - *
-   * Result of the numerical stats computation.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult} - */ - public static final class NumericalStatsResult extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) - NumericalStatsResultOrBuilder { - private static final long serialVersionUID = 0L; - // Use NumericalStatsResult.newBuilder() to construct. - private NumericalStatsResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private NumericalStatsResult() { - quantileValues_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private NumericalStatsResult( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.Value.Builder subBuilder = null; - if (minValue_ != null) { - subBuilder = minValue_.toBuilder(); - } - minValue_ = input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(minValue_); - minValue_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.Value.Builder subBuilder = null; - if (maxValue_ != null) { - subBuilder = maxValue_.toBuilder(); - } - maxValue_ = input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(maxValue_); - maxValue_ = subBuilder.buildPartial(); - } - - break; - } - case 34: { - if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) { - quantileValues_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000004; - } - quantileValues_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry)); - 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_ & 0x00000004) == 0x00000004)) { - quantileValues_ = java.util.Collections.unmodifiableList(quantileValues_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_NumericalStatsResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_NumericalStatsResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.Builder.class); - } - - private int bitField0_; - public static final int MIN_VALUE_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.Value minValue_; - /** - *
-     * Minimum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public boolean hasMinValue() { - return minValue_ != null; - } - /** - *
-     * Minimum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getMinValue() { - return minValue_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : minValue_; - } - /** - *
-     * Minimum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getMinValueOrBuilder() { - return getMinValue(); - } - - public static final int MAX_VALUE_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.Value maxValue_; - /** - *
-     * Maximum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public boolean hasMaxValue() { - return maxValue_ != null; - } - /** - *
-     * Maximum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public com.google.privacy.dlp.v2beta1.Value getMaxValue() { - return maxValue_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : maxValue_; - } - /** - *
-     * Maximum value appearing in the column.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getMaxValueOrBuilder() { - return getMaxValue(); - } - - public static final int QUANTILE_VALUES_FIELD_NUMBER = 4; - private java.util.List quantileValues_; - /** - *
-     * List of 99 values that partition the set of field values into 100 equal
-     * sized buckets.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public java.util.List getQuantileValuesList() { - return quantileValues_; - } - /** - *
-     * List of 99 values that partition the set of field values into 100 equal
-     * sized buckets.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public java.util.List - getQuantileValuesOrBuilderList() { - return quantileValues_; - } - /** - *
-     * List of 99 values that partition the set of field values into 100 equal
-     * sized buckets.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public int getQuantileValuesCount() { - return quantileValues_.size(); - } - /** - *
-     * List of 99 values that partition the set of field values into 100 equal
-     * sized buckets.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public com.google.privacy.dlp.v2beta1.Value getQuantileValues(int index) { - return quantileValues_.get(index); - } - /** - *
-     * List of 99 values that partition the set of field values into 100 equal
-     * sized buckets.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getQuantileValuesOrBuilder( - int index) { - return quantileValues_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (minValue_ != null) { - output.writeMessage(1, getMinValue()); - } - if (maxValue_ != null) { - output.writeMessage(2, getMaxValue()); - } - for (int i = 0; i < quantileValues_.size(); i++) { - output.writeMessage(4, quantileValues_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (minValue_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getMinValue()); - } - if (maxValue_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getMaxValue()); - } - for (int i = 0; i < quantileValues_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, quantileValues_.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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) obj; - - boolean result = true; - result = result && (hasMinValue() == other.hasMinValue()); - if (hasMinValue()) { - result = result && getMinValue() - .equals(other.getMinValue()); - } - result = result && (hasMaxValue() == other.hasMaxValue()); - if (hasMaxValue()) { - result = result && getMaxValue() - .equals(other.getMaxValue()); - } - result = result && getQuantileValuesList() - .equals(other.getQuantileValuesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasMinValue()) { - hash = (37 * hash) + MIN_VALUE_FIELD_NUMBER; - hash = (53 * hash) + getMinValue().hashCode(); - } - if (hasMaxValue()) { - hash = (37 * hash) + MAX_VALUE_FIELD_NUMBER; - hash = (53 * hash) + getMaxValue().hashCode(); - } - if (getQuantileValuesCount() > 0) { - hash = (37 * hash) + QUANTILE_VALUES_FIELD_NUMBER; - hash = (53 * hash) + getQuantileValuesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * Result of the numerical stats computation.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResultOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_NumericalStatsResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_NumericalStatsResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getQuantileValuesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (minValueBuilder_ == null) { - minValue_ = null; - } else { - minValue_ = null; - minValueBuilder_ = null; - } - if (maxValueBuilder_ == null) { - maxValue_ = null; - } else { - maxValue_ = null; - maxValueBuilder_ = null; - } - if (quantileValuesBuilder_ == null) { - quantileValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - } else { - quantileValuesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_NumericalStatsResult_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (minValueBuilder_ == null) { - result.minValue_ = minValue_; - } else { - result.minValue_ = minValueBuilder_.build(); - } - if (maxValueBuilder_ == null) { - result.maxValue_ = maxValue_; - } else { - result.maxValue_ = maxValueBuilder_.build(); - } - if (quantileValuesBuilder_ == null) { - if (((bitField0_ & 0x00000004) == 0x00000004)) { - quantileValues_ = java.util.Collections.unmodifiableList(quantileValues_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.quantileValues_ = quantileValues_; - } else { - result.quantileValues_ = quantileValuesBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.getDefaultInstance()) return this; - if (other.hasMinValue()) { - mergeMinValue(other.getMinValue()); - } - if (other.hasMaxValue()) { - mergeMaxValue(other.getMaxValue()); - } - if (quantileValuesBuilder_ == null) { - if (!other.quantileValues_.isEmpty()) { - if (quantileValues_.isEmpty()) { - quantileValues_ = other.quantileValues_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureQuantileValuesIsMutable(); - quantileValues_.addAll(other.quantileValues_); - } - onChanged(); - } - } else { - if (!other.quantileValues_.isEmpty()) { - if (quantileValuesBuilder_.isEmpty()) { - quantileValuesBuilder_.dispose(); - quantileValuesBuilder_ = null; - quantileValues_ = other.quantileValues_; - bitField0_ = (bitField0_ & ~0x00000004); - quantileValuesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getQuantileValuesFieldBuilder() : null; - } else { - quantileValuesBuilder_.addAllMessages(other.quantileValues_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private com.google.privacy.dlp.v2beta1.Value minValue_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> minValueBuilder_; - /** - *
-       * Minimum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public boolean hasMinValue() { - return minValueBuilder_ != null || minValue_ != null; - } - /** - *
-       * Minimum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getMinValue() { - if (minValueBuilder_ == null) { - return minValue_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : minValue_; - } else { - return minValueBuilder_.getMessage(); - } - } - /** - *
-       * Minimum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public Builder setMinValue(com.google.privacy.dlp.v2beta1.Value value) { - if (minValueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - minValue_ = value; - onChanged(); - } else { - minValueBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Minimum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public Builder setMinValue( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (minValueBuilder_ == null) { - minValue_ = builderForValue.build(); - onChanged(); - } else { - minValueBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Minimum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public Builder mergeMinValue(com.google.privacy.dlp.v2beta1.Value value) { - if (minValueBuilder_ == null) { - if (minValue_ != null) { - minValue_ = - com.google.privacy.dlp.v2beta1.Value.newBuilder(minValue_).mergeFrom(value).buildPartial(); - } else { - minValue_ = value; - } - onChanged(); - } else { - minValueBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Minimum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public Builder clearMinValue() { - if (minValueBuilder_ == null) { - minValue_ = null; - onChanged(); - } else { - minValue_ = null; - minValueBuilder_ = null; - } - - return this; - } - /** - *
-       * Minimum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getMinValueBuilder() { - - onChanged(); - return getMinValueFieldBuilder().getBuilder(); - } - /** - *
-       * Minimum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getMinValueOrBuilder() { - if (minValueBuilder_ != null) { - return minValueBuilder_.getMessageOrBuilder(); - } else { - return minValue_ == null ? - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : minValue_; - } - } - /** - *
-       * Minimum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value min_value = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getMinValueFieldBuilder() { - if (minValueBuilder_ == null) { - minValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - getMinValue(), - getParentForChildren(), - isClean()); - minValue_ = null; - } - return minValueBuilder_; - } - - private com.google.privacy.dlp.v2beta1.Value maxValue_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> maxValueBuilder_; - /** - *
-       * Maximum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public boolean hasMaxValue() { - return maxValueBuilder_ != null || maxValue_ != null; - } - /** - *
-       * Maximum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public com.google.privacy.dlp.v2beta1.Value getMaxValue() { - if (maxValueBuilder_ == null) { - return maxValue_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : maxValue_; - } else { - return maxValueBuilder_.getMessage(); - } - } - /** - *
-       * Maximum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public Builder setMaxValue(com.google.privacy.dlp.v2beta1.Value value) { - if (maxValueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - maxValue_ = value; - onChanged(); - } else { - maxValueBuilder_.setMessage(value); - } - - return this; - } - /** - *
-       * Maximum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public Builder setMaxValue( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (maxValueBuilder_ == null) { - maxValue_ = builderForValue.build(); - onChanged(); - } else { - maxValueBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-       * Maximum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public Builder mergeMaxValue(com.google.privacy.dlp.v2beta1.Value value) { - if (maxValueBuilder_ == null) { - if (maxValue_ != null) { - maxValue_ = - com.google.privacy.dlp.v2beta1.Value.newBuilder(maxValue_).mergeFrom(value).buildPartial(); - } else { - maxValue_ = value; - } - onChanged(); - } else { - maxValueBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-       * Maximum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public Builder clearMaxValue() { - if (maxValueBuilder_ == null) { - maxValue_ = null; - onChanged(); - } else { - maxValue_ = null; - maxValueBuilder_ = null; - } - - return this; - } - /** - *
-       * Maximum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getMaxValueBuilder() { - - onChanged(); - return getMaxValueFieldBuilder().getBuilder(); - } - /** - *
-       * Maximum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getMaxValueOrBuilder() { - if (maxValueBuilder_ != null) { - return maxValueBuilder_.getMessageOrBuilder(); - } else { - return maxValue_ == null ? - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : maxValue_; - } - } - /** - *
-       * Maximum value appearing in the column.
-       * 
- * - * .google.privacy.dlp.v2beta1.Value max_value = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getMaxValueFieldBuilder() { - if (maxValueBuilder_ == null) { - maxValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - getMaxValue(), - getParentForChildren(), - isClean()); - maxValue_ = null; - } - return maxValueBuilder_; - } - - private java.util.List quantileValues_ = - java.util.Collections.emptyList(); - private void ensureQuantileValuesIsMutable() { - if (!((bitField0_ & 0x00000004) == 0x00000004)) { - quantileValues_ = new java.util.ArrayList(quantileValues_); - bitField0_ |= 0x00000004; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> quantileValuesBuilder_; - - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public java.util.List getQuantileValuesList() { - if (quantileValuesBuilder_ == null) { - return java.util.Collections.unmodifiableList(quantileValues_); - } else { - return quantileValuesBuilder_.getMessageList(); - } - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public int getQuantileValuesCount() { - if (quantileValuesBuilder_ == null) { - return quantileValues_.size(); - } else { - return quantileValuesBuilder_.getCount(); - } - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public com.google.privacy.dlp.v2beta1.Value getQuantileValues(int index) { - if (quantileValuesBuilder_ == null) { - return quantileValues_.get(index); - } else { - return quantileValuesBuilder_.getMessage(index); - } - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public Builder setQuantileValues( - int index, com.google.privacy.dlp.v2beta1.Value value) { - if (quantileValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuantileValuesIsMutable(); - quantileValues_.set(index, value); - onChanged(); - } else { - quantileValuesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public Builder setQuantileValues( - int index, com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (quantileValuesBuilder_ == null) { - ensureQuantileValuesIsMutable(); - quantileValues_.set(index, builderForValue.build()); - onChanged(); - } else { - quantileValuesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public Builder addQuantileValues(com.google.privacy.dlp.v2beta1.Value value) { - if (quantileValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuantileValuesIsMutable(); - quantileValues_.add(value); - onChanged(); - } else { - quantileValuesBuilder_.addMessage(value); - } - return this; - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public Builder addQuantileValues( - int index, com.google.privacy.dlp.v2beta1.Value value) { - if (quantileValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuantileValuesIsMutable(); - quantileValues_.add(index, value); - onChanged(); - } else { - quantileValuesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public Builder addQuantileValues( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (quantileValuesBuilder_ == null) { - ensureQuantileValuesIsMutable(); - quantileValues_.add(builderForValue.build()); - onChanged(); - } else { - quantileValuesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public Builder addQuantileValues( - int index, com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (quantileValuesBuilder_ == null) { - ensureQuantileValuesIsMutable(); - quantileValues_.add(index, builderForValue.build()); - onChanged(); - } else { - quantileValuesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public Builder addAllQuantileValues( - java.lang.Iterable values) { - if (quantileValuesBuilder_ == null) { - ensureQuantileValuesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, quantileValues_); - onChanged(); - } else { - quantileValuesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public Builder clearQuantileValues() { - if (quantileValuesBuilder_ == null) { - quantileValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - } else { - quantileValuesBuilder_.clear(); - } - return this; - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public Builder removeQuantileValues(int index) { - if (quantileValuesBuilder_ == null) { - ensureQuantileValuesIsMutable(); - quantileValues_.remove(index); - onChanged(); - } else { - quantileValuesBuilder_.remove(index); - } - return this; - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getQuantileValuesBuilder( - int index) { - return getQuantileValuesFieldBuilder().getBuilder(index); - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getQuantileValuesOrBuilder( - int index) { - if (quantileValuesBuilder_ == null) { - return quantileValues_.get(index); } else { - return quantileValuesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public java.util.List - getQuantileValuesOrBuilderList() { - if (quantileValuesBuilder_ != null) { - return quantileValuesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(quantileValues_); - } - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder addQuantileValuesBuilder() { - return getQuantileValuesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance()); - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder addQuantileValuesBuilder( - int index) { - return getQuantileValuesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.Value.getDefaultInstance()); - } - /** - *
-       * List of 99 values that partition the set of field values into 100 equal
-       * sized buckets.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quantile_values = 4; - */ - public java.util.List - getQuantileValuesBuilderList() { - return getQuantileValuesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getQuantileValuesFieldBuilder() { - if (quantileValuesBuilder_ == null) { - quantileValuesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - quantileValues_, - ((bitField0_ & 0x00000004) == 0x00000004), - getParentForChildren(), - isClean()); - quantileValues_ = null; - } - return quantileValuesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public NumericalStatsResult parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new NumericalStatsResult(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface CategoricalStatsResultOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Histogram of value frequencies in the column.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - java.util.List - getValueFrequencyHistogramBucketsList(); - /** - *
-     * Histogram of value frequencies in the column.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket getValueFrequencyHistogramBuckets(int index); - /** - *
-     * Histogram of value frequencies in the column.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - int getValueFrequencyHistogramBucketsCount(); - /** - *
-     * Histogram of value frequencies in the column.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - java.util.List - getValueFrequencyHistogramBucketsOrBuilderList(); - /** - *
-     * Histogram of value frequencies in the column.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucketOrBuilder getValueFrequencyHistogramBucketsOrBuilder( - int index); - } - /** - *
-   * Result of the categorical stats computation.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult} - */ - public static final class CategoricalStatsResult extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) - CategoricalStatsResultOrBuilder { - private static final long serialVersionUID = 0L; - // Use CategoricalStatsResult.newBuilder() to construct. - private CategoricalStatsResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CategoricalStatsResult() { - valueFrequencyHistogramBuckets_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CategoricalStatsResult( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 42: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - valueFrequencyHistogramBuckets_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - valueFrequencyHistogramBuckets_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.parser(), extensionRegistry)); - 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) == 0x00000001)) { - valueFrequencyHistogramBuckets_ = java.util.Collections.unmodifiableList(valueFrequencyHistogramBuckets_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.Builder.class); - } - - public interface CategoricalStatsHistogramBucketOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket) - com.google.protobuf.MessageOrBuilder { - - /** - *
-       * Lower bound on the value frequency of the values in this bucket.
-       * 
- * - * int64 value_frequency_lower_bound = 1; - */ - long getValueFrequencyLowerBound(); - - /** - *
-       * Upper bound on the value frequency of the values in this bucket.
-       * 
- * - * int64 value_frequency_upper_bound = 2; - */ - long getValueFrequencyUpperBound(); - - /** - *
-       * Total number of records in this bucket.
-       * 
- * - * int64 bucket_size = 3; - */ - long getBucketSize(); - - /** - *
-       * Sample of value frequencies in this bucket. The total number of
-       * values returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - java.util.List - getBucketValuesList(); - /** - *
-       * Sample of value frequencies in this bucket. The total number of
-       * values returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - com.google.privacy.dlp.v2beta1.ValueFrequency getBucketValues(int index); - /** - *
-       * Sample of value frequencies in this bucket. The total number of
-       * values returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - int getBucketValuesCount(); - /** - *
-       * Sample of value frequencies in this bucket. The total number of
-       * values returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - java.util.List - getBucketValuesOrBuilderList(); - /** - *
-       * Sample of value frequencies in this bucket. The total number of
-       * values returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder getBucketValuesOrBuilder( - int index); - } - /** - *
-     * Histogram bucket of value frequencies in the column.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket} - */ - public static final class CategoricalStatsHistogramBucket extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket) - CategoricalStatsHistogramBucketOrBuilder { - private static final long serialVersionUID = 0L; - // Use CategoricalStatsHistogramBucket.newBuilder() to construct. - private CategoricalStatsHistogramBucket(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private CategoricalStatsHistogramBucket() { - valueFrequencyLowerBound_ = 0L; - valueFrequencyUpperBound_ = 0L; - bucketSize_ = 0L; - bucketValues_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private CategoricalStatsHistogramBucket( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - - valueFrequencyLowerBound_ = input.readInt64(); - break; - } - case 16: { - - valueFrequencyUpperBound_ = input.readInt64(); - break; - } - case 24: { - - bucketSize_ = input.readInt64(); - break; - } - case 34: { - if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - bucketValues_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - bucketValues_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.ValueFrequency.parser(), extensionRegistry)); - 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_ & 0x00000008) == 0x00000008)) { - bucketValues_ = java.util.Collections.unmodifiableList(bucketValues_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_CategoricalStatsHistogramBucket_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_CategoricalStatsHistogramBucket_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder.class); - } - - private int bitField0_; - public static final int VALUE_FREQUENCY_LOWER_BOUND_FIELD_NUMBER = 1; - private long valueFrequencyLowerBound_; - /** - *
-       * Lower bound on the value frequency of the values in this bucket.
-       * 
- * - * int64 value_frequency_lower_bound = 1; - */ - public long getValueFrequencyLowerBound() { - return valueFrequencyLowerBound_; - } - - public static final int VALUE_FREQUENCY_UPPER_BOUND_FIELD_NUMBER = 2; - private long valueFrequencyUpperBound_; - /** - *
-       * Upper bound on the value frequency of the values in this bucket.
-       * 
- * - * int64 value_frequency_upper_bound = 2; - */ - public long getValueFrequencyUpperBound() { - return valueFrequencyUpperBound_; - } - - public static final int BUCKET_SIZE_FIELD_NUMBER = 3; - private long bucketSize_; - /** - *
-       * Total number of records in this bucket.
-       * 
- * - * int64 bucket_size = 3; - */ - public long getBucketSize() { - return bucketSize_; - } - - public static final int BUCKET_VALUES_FIELD_NUMBER = 4; - private java.util.List bucketValues_; - /** - *
-       * Sample of value frequencies in this bucket. The total number of
-       * values returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public java.util.List getBucketValuesList() { - return bucketValues_; - } - /** - *
-       * Sample of value frequencies in this bucket. The total number of
-       * values returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public java.util.List - getBucketValuesOrBuilderList() { - return bucketValues_; - } - /** - *
-       * Sample of value frequencies in this bucket. The total number of
-       * values returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public int getBucketValuesCount() { - return bucketValues_.size(); - } - /** - *
-       * Sample of value frequencies in this bucket. The total number of
-       * values returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequency getBucketValues(int index) { - return bucketValues_.get(index); - } - /** - *
-       * Sample of value frequencies in this bucket. The total number of
-       * values returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder getBucketValuesOrBuilder( - int index) { - return bucketValues_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (valueFrequencyLowerBound_ != 0L) { - output.writeInt64(1, valueFrequencyLowerBound_); - } - if (valueFrequencyUpperBound_ != 0L) { - output.writeInt64(2, valueFrequencyUpperBound_); - } - if (bucketSize_ != 0L) { - output.writeInt64(3, bucketSize_); - } - for (int i = 0; i < bucketValues_.size(); i++) { - output.writeMessage(4, bucketValues_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (valueFrequencyLowerBound_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(1, valueFrequencyLowerBound_); - } - if (valueFrequencyUpperBound_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(2, valueFrequencyUpperBound_); - } - if (bucketSize_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(3, bucketSize_); - } - for (int i = 0; i < bucketValues_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, bucketValues_.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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket) obj; - - boolean result = true; - result = result && (getValueFrequencyLowerBound() - == other.getValueFrequencyLowerBound()); - result = result && (getValueFrequencyUpperBound() - == other.getValueFrequencyUpperBound()); - result = result && (getBucketSize() - == other.getBucketSize()); - result = result && getBucketValuesList() - .equals(other.getBucketValuesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + VALUE_FREQUENCY_LOWER_BOUND_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getValueFrequencyLowerBound()); - hash = (37 * hash) + VALUE_FREQUENCY_UPPER_BOUND_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getValueFrequencyUpperBound()); - hash = (37 * hash) + BUCKET_SIZE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getBucketSize()); - if (getBucketValuesCount() > 0) { - hash = (37 * hash) + BUCKET_VALUES_FIELD_NUMBER; - hash = (53 * hash) + getBucketValuesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-       * Histogram bucket of value frequencies in the column.
-       * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucketOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_CategoricalStatsHistogramBucket_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_CategoricalStatsHistogramBucket_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getBucketValuesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - valueFrequencyLowerBound_ = 0L; - - valueFrequencyUpperBound_ = 0L; - - bucketSize_ = 0L; - - if (bucketValuesBuilder_ == null) { - bucketValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - bucketValuesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_CategoricalStatsHistogramBucket_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.valueFrequencyLowerBound_ = valueFrequencyLowerBound_; - result.valueFrequencyUpperBound_ = valueFrequencyUpperBound_; - result.bucketSize_ = bucketSize_; - if (bucketValuesBuilder_ == null) { - if (((bitField0_ & 0x00000008) == 0x00000008)) { - bucketValues_ = java.util.Collections.unmodifiableList(bucketValues_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.bucketValues_ = bucketValues_; - } else { - result.bucketValues_ = bucketValuesBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.getDefaultInstance()) return this; - if (other.getValueFrequencyLowerBound() != 0L) { - setValueFrequencyLowerBound(other.getValueFrequencyLowerBound()); - } - if (other.getValueFrequencyUpperBound() != 0L) { - setValueFrequencyUpperBound(other.getValueFrequencyUpperBound()); - } - if (other.getBucketSize() != 0L) { - setBucketSize(other.getBucketSize()); - } - if (bucketValuesBuilder_ == null) { - if (!other.bucketValues_.isEmpty()) { - if (bucketValues_.isEmpty()) { - bucketValues_ = other.bucketValues_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureBucketValuesIsMutable(); - bucketValues_.addAll(other.bucketValues_); - } - onChanged(); - } - } else { - if (!other.bucketValues_.isEmpty()) { - if (bucketValuesBuilder_.isEmpty()) { - bucketValuesBuilder_.dispose(); - bucketValuesBuilder_ = null; - bucketValues_ = other.bucketValues_; - bitField0_ = (bitField0_ & ~0x00000008); - bucketValuesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getBucketValuesFieldBuilder() : null; - } else { - bucketValuesBuilder_.addAllMessages(other.bucketValues_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private long valueFrequencyLowerBound_ ; - /** - *
-         * Lower bound on the value frequency of the values in this bucket.
-         * 
- * - * int64 value_frequency_lower_bound = 1; - */ - public long getValueFrequencyLowerBound() { - return valueFrequencyLowerBound_; - } - /** - *
-         * Lower bound on the value frequency of the values in this bucket.
-         * 
- * - * int64 value_frequency_lower_bound = 1; - */ - public Builder setValueFrequencyLowerBound(long value) { - - valueFrequencyLowerBound_ = value; - onChanged(); - return this; - } - /** - *
-         * Lower bound on the value frequency of the values in this bucket.
-         * 
- * - * int64 value_frequency_lower_bound = 1; - */ - public Builder clearValueFrequencyLowerBound() { - - valueFrequencyLowerBound_ = 0L; - onChanged(); - return this; - } - - private long valueFrequencyUpperBound_ ; - /** - *
-         * Upper bound on the value frequency of the values in this bucket.
-         * 
- * - * int64 value_frequency_upper_bound = 2; - */ - public long getValueFrequencyUpperBound() { - return valueFrequencyUpperBound_; - } - /** - *
-         * Upper bound on the value frequency of the values in this bucket.
-         * 
- * - * int64 value_frequency_upper_bound = 2; - */ - public Builder setValueFrequencyUpperBound(long value) { - - valueFrequencyUpperBound_ = value; - onChanged(); - return this; - } - /** - *
-         * Upper bound on the value frequency of the values in this bucket.
-         * 
- * - * int64 value_frequency_upper_bound = 2; - */ - public Builder clearValueFrequencyUpperBound() { - - valueFrequencyUpperBound_ = 0L; - onChanged(); - return this; - } - - private long bucketSize_ ; - /** - *
-         * Total number of records in this bucket.
-         * 
- * - * int64 bucket_size = 3; - */ - public long getBucketSize() { - return bucketSize_; - } - /** - *
-         * Total number of records in this bucket.
-         * 
- * - * int64 bucket_size = 3; - */ - public Builder setBucketSize(long value) { - - bucketSize_ = value; - onChanged(); - return this; - } - /** - *
-         * Total number of records in this bucket.
-         * 
- * - * int64 bucket_size = 3; - */ - public Builder clearBucketSize() { - - bucketSize_ = 0L; - onChanged(); - return this; - } - - private java.util.List bucketValues_ = - java.util.Collections.emptyList(); - private void ensureBucketValuesIsMutable() { - if (!((bitField0_ & 0x00000008) == 0x00000008)) { - bucketValues_ = new java.util.ArrayList(bucketValues_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ValueFrequency, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder, com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder> bucketValuesBuilder_; - - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public java.util.List getBucketValuesList() { - if (bucketValuesBuilder_ == null) { - return java.util.Collections.unmodifiableList(bucketValues_); - } else { - return bucketValuesBuilder_.getMessageList(); - } - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public int getBucketValuesCount() { - if (bucketValuesBuilder_ == null) { - return bucketValues_.size(); - } else { - return bucketValuesBuilder_.getCount(); - } - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequency getBucketValues(int index) { - if (bucketValuesBuilder_ == null) { - return bucketValues_.get(index); - } else { - return bucketValuesBuilder_.getMessage(index); - } - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public Builder setBucketValues( - int index, com.google.privacy.dlp.v2beta1.ValueFrequency value) { - if (bucketValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketValuesIsMutable(); - bucketValues_.set(index, value); - onChanged(); - } else { - bucketValuesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public Builder setBucketValues( - int index, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder builderForValue) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.set(index, builderForValue.build()); - onChanged(); - } else { - bucketValuesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public Builder addBucketValues(com.google.privacy.dlp.v2beta1.ValueFrequency value) { - if (bucketValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketValuesIsMutable(); - bucketValues_.add(value); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(value); - } - return this; - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public Builder addBucketValues( - int index, com.google.privacy.dlp.v2beta1.ValueFrequency value) { - if (bucketValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketValuesIsMutable(); - bucketValues_.add(index, value); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public Builder addBucketValues( - com.google.privacy.dlp.v2beta1.ValueFrequency.Builder builderForValue) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.add(builderForValue.build()); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public Builder addBucketValues( - int index, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder builderForValue) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.add(index, builderForValue.build()); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public Builder addAllBucketValues( - java.lang.Iterable values) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, bucketValues_); - onChanged(); - } else { - bucketValuesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public Builder clearBucketValues() { - if (bucketValuesBuilder_ == null) { - bucketValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - bucketValuesBuilder_.clear(); - } - return this; - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public Builder removeBucketValues(int index) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.remove(index); - onChanged(); - } else { - bucketValuesBuilder_.remove(index); - } - return this; - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequency.Builder getBucketValuesBuilder( - int index) { - return getBucketValuesFieldBuilder().getBuilder(index); - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder getBucketValuesOrBuilder( - int index) { - if (bucketValuesBuilder_ == null) { - return bucketValues_.get(index); } else { - return bucketValuesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public java.util.List - getBucketValuesOrBuilderList() { - if (bucketValuesBuilder_ != null) { - return bucketValuesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(bucketValues_); - } - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequency.Builder addBucketValuesBuilder() { - return getBucketValuesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.ValueFrequency.getDefaultInstance()); - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequency.Builder addBucketValuesBuilder( - int index) { - return getBucketValuesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.ValueFrequency.getDefaultInstance()); - } - /** - *
-         * Sample of value frequencies in this bucket. The total number of
-         * values returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency bucket_values = 4; - */ - public java.util.List - getBucketValuesBuilderList() { - return getBucketValuesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ValueFrequency, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder, com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder> - getBucketValuesFieldBuilder() { - if (bucketValuesBuilder_ == null) { - bucketValuesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ValueFrequency, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder, com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder>( - bucketValues_, - ((bitField0_ & 0x00000008) == 0x00000008), - getParentForChildren(), - isClean()); - bucketValues_ = null; - } - return bucketValuesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CategoricalStatsHistogramBucket parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CategoricalStatsHistogramBucket(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public static final int VALUE_FREQUENCY_HISTOGRAM_BUCKETS_FIELD_NUMBER = 5; - private java.util.List valueFrequencyHistogramBuckets_; - /** - *
-     * Histogram of value frequencies in the column.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public java.util.List getValueFrequencyHistogramBucketsList() { - return valueFrequencyHistogramBuckets_; - } - /** - *
-     * Histogram of value frequencies in the column.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public java.util.List - getValueFrequencyHistogramBucketsOrBuilderList() { - return valueFrequencyHistogramBuckets_; - } - /** - *
-     * Histogram of value frequencies in the column.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public int getValueFrequencyHistogramBucketsCount() { - return valueFrequencyHistogramBuckets_.size(); - } - /** - *
-     * Histogram of value frequencies in the column.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket getValueFrequencyHistogramBuckets(int index) { - return valueFrequencyHistogramBuckets_.get(index); - } - /** - *
-     * Histogram of value frequencies in the column.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucketOrBuilder getValueFrequencyHistogramBucketsOrBuilder( - int index) { - return valueFrequencyHistogramBuckets_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < valueFrequencyHistogramBuckets_.size(); i++) { - output.writeMessage(5, valueFrequencyHistogramBuckets_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < valueFrequencyHistogramBuckets_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, valueFrequencyHistogramBuckets_.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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) obj; - - boolean result = true; - result = result && getValueFrequencyHistogramBucketsList() - .equals(other.getValueFrequencyHistogramBucketsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getValueFrequencyHistogramBucketsCount() > 0) { - hash = (37 * hash) + VALUE_FREQUENCY_HISTOGRAM_BUCKETS_FIELD_NUMBER; - hash = (53 * hash) + getValueFrequencyHistogramBucketsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * Result of the categorical stats computation.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResultOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getValueFrequencyHistogramBucketsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (valueFrequencyHistogramBucketsBuilder_ == null) { - valueFrequencyHistogramBuckets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - valueFrequencyHistogramBucketsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_CategoricalStatsResult_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult(this); - int from_bitField0_ = bitField0_; - if (valueFrequencyHistogramBucketsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - valueFrequencyHistogramBuckets_ = java.util.Collections.unmodifiableList(valueFrequencyHistogramBuckets_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.valueFrequencyHistogramBuckets_ = valueFrequencyHistogramBuckets_; - } else { - result.valueFrequencyHistogramBuckets_ = valueFrequencyHistogramBucketsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.getDefaultInstance()) return this; - if (valueFrequencyHistogramBucketsBuilder_ == null) { - if (!other.valueFrequencyHistogramBuckets_.isEmpty()) { - if (valueFrequencyHistogramBuckets_.isEmpty()) { - valueFrequencyHistogramBuckets_ = other.valueFrequencyHistogramBuckets_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureValueFrequencyHistogramBucketsIsMutable(); - valueFrequencyHistogramBuckets_.addAll(other.valueFrequencyHistogramBuckets_); - } - onChanged(); - } - } else { - if (!other.valueFrequencyHistogramBuckets_.isEmpty()) { - if (valueFrequencyHistogramBucketsBuilder_.isEmpty()) { - valueFrequencyHistogramBucketsBuilder_.dispose(); - valueFrequencyHistogramBucketsBuilder_ = null; - valueFrequencyHistogramBuckets_ = other.valueFrequencyHistogramBuckets_; - bitField0_ = (bitField0_ & ~0x00000001); - valueFrequencyHistogramBucketsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getValueFrequencyHistogramBucketsFieldBuilder() : null; - } else { - valueFrequencyHistogramBucketsBuilder_.addAllMessages(other.valueFrequencyHistogramBuckets_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List valueFrequencyHistogramBuckets_ = - java.util.Collections.emptyList(); - private void ensureValueFrequencyHistogramBucketsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - valueFrequencyHistogramBuckets_ = new java.util.ArrayList(valueFrequencyHistogramBuckets_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucketOrBuilder> valueFrequencyHistogramBucketsBuilder_; - - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public java.util.List getValueFrequencyHistogramBucketsList() { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - return java.util.Collections.unmodifiableList(valueFrequencyHistogramBuckets_); - } else { - return valueFrequencyHistogramBucketsBuilder_.getMessageList(); - } - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public int getValueFrequencyHistogramBucketsCount() { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - return valueFrequencyHistogramBuckets_.size(); - } else { - return valueFrequencyHistogramBucketsBuilder_.getCount(); - } - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket getValueFrequencyHistogramBuckets(int index) { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - return valueFrequencyHistogramBuckets_.get(index); - } else { - return valueFrequencyHistogramBucketsBuilder_.getMessage(index); - } - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public Builder setValueFrequencyHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value) { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureValueFrequencyHistogramBucketsIsMutable(); - valueFrequencyHistogramBuckets_.set(index, value); - onChanged(); - } else { - valueFrequencyHistogramBucketsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public Builder setValueFrequencyHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder builderForValue) { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - ensureValueFrequencyHistogramBucketsIsMutable(); - valueFrequencyHistogramBuckets_.set(index, builderForValue.build()); - onChanged(); - } else { - valueFrequencyHistogramBucketsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public Builder addValueFrequencyHistogramBuckets(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value) { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureValueFrequencyHistogramBucketsIsMutable(); - valueFrequencyHistogramBuckets_.add(value); - onChanged(); - } else { - valueFrequencyHistogramBucketsBuilder_.addMessage(value); - } - return this; - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public Builder addValueFrequencyHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value) { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureValueFrequencyHistogramBucketsIsMutable(); - valueFrequencyHistogramBuckets_.add(index, value); - onChanged(); - } else { - valueFrequencyHistogramBucketsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public Builder addValueFrequencyHistogramBuckets( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder builderForValue) { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - ensureValueFrequencyHistogramBucketsIsMutable(); - valueFrequencyHistogramBuckets_.add(builderForValue.build()); - onChanged(); - } else { - valueFrequencyHistogramBucketsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public Builder addValueFrequencyHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder builderForValue) { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - ensureValueFrequencyHistogramBucketsIsMutable(); - valueFrequencyHistogramBuckets_.add(index, builderForValue.build()); - onChanged(); - } else { - valueFrequencyHistogramBucketsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public Builder addAllValueFrequencyHistogramBuckets( - java.lang.Iterable values) { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - ensureValueFrequencyHistogramBucketsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, valueFrequencyHistogramBuckets_); - onChanged(); - } else { - valueFrequencyHistogramBucketsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public Builder clearValueFrequencyHistogramBuckets() { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - valueFrequencyHistogramBuckets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - valueFrequencyHistogramBucketsBuilder_.clear(); - } - return this; - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public Builder removeValueFrequencyHistogramBuckets(int index) { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - ensureValueFrequencyHistogramBucketsIsMutable(); - valueFrequencyHistogramBuckets_.remove(index); - onChanged(); - } else { - valueFrequencyHistogramBucketsBuilder_.remove(index); - } - return this; - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder getValueFrequencyHistogramBucketsBuilder( - int index) { - return getValueFrequencyHistogramBucketsFieldBuilder().getBuilder(index); - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucketOrBuilder getValueFrequencyHistogramBucketsOrBuilder( - int index) { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - return valueFrequencyHistogramBuckets_.get(index); } else { - return valueFrequencyHistogramBucketsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public java.util.List - getValueFrequencyHistogramBucketsOrBuilderList() { - if (valueFrequencyHistogramBucketsBuilder_ != null) { - return valueFrequencyHistogramBucketsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(valueFrequencyHistogramBuckets_); - } - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder addValueFrequencyHistogramBucketsBuilder() { - return getValueFrequencyHistogramBucketsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.getDefaultInstance()); - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder addValueFrequencyHistogramBucketsBuilder( - int index) { - return getValueFrequencyHistogramBucketsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.getDefaultInstance()); - } - /** - *
-       * Histogram of value frequencies in the column.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - */ - public java.util.List - getValueFrequencyHistogramBucketsBuilderList() { - return getValueFrequencyHistogramBucketsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucketOrBuilder> - getValueFrequencyHistogramBucketsFieldBuilder() { - if (valueFrequencyHistogramBucketsBuilder_ == null) { - valueFrequencyHistogramBucketsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucket.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.CategoricalStatsHistogramBucketOrBuilder>( - valueFrequencyHistogramBuckets_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - valueFrequencyHistogramBuckets_ = null; - } - return valueFrequencyHistogramBucketsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CategoricalStatsResult parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new CategoricalStatsResult(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface KAnonymityResultOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Histogram of k-anonymity equivalence classes.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - java.util.List - getEquivalenceClassHistogramBucketsList(); - /** - *
-     * Histogram of k-anonymity equivalence classes.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket getEquivalenceClassHistogramBuckets(int index); - /** - *
-     * Histogram of k-anonymity equivalence classes.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - int getEquivalenceClassHistogramBucketsCount(); - /** - *
-     * Histogram of k-anonymity equivalence classes.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - java.util.List - getEquivalenceClassHistogramBucketsOrBuilderList(); - /** - *
-     * Histogram of k-anonymity equivalence classes.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucketOrBuilder getEquivalenceClassHistogramBucketsOrBuilder( - int index); - } - /** - *
-   * Result of the k-anonymity computation.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult} - */ - public static final class KAnonymityResult extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) - KAnonymityResultOrBuilder { - private static final long serialVersionUID = 0L; - // Use KAnonymityResult.newBuilder() to construct. - private KAnonymityResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private KAnonymityResult() { - equivalenceClassHistogramBuckets_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private KAnonymityResult( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 42: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - equivalenceClassHistogramBuckets_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - equivalenceClassHistogramBuckets_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.parser(), extensionRegistry)); - 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) == 0x00000001)) { - equivalenceClassHistogramBuckets_ = java.util.Collections.unmodifiableList(equivalenceClassHistogramBuckets_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.Builder.class); - } - - public interface KAnonymityEquivalenceClassOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass) - com.google.protobuf.MessageOrBuilder { - - /** - *
-       * Set of values defining the equivalence class. One value per
-       * quasi-identifier column in the original KAnonymity metric message.
-       * The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - java.util.List - getQuasiIdsValuesList(); - /** - *
-       * Set of values defining the equivalence class. One value per
-       * quasi-identifier column in the original KAnonymity metric message.
-       * The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - com.google.privacy.dlp.v2beta1.Value getQuasiIdsValues(int index); - /** - *
-       * Set of values defining the equivalence class. One value per
-       * quasi-identifier column in the original KAnonymity metric message.
-       * The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - int getQuasiIdsValuesCount(); - /** - *
-       * Set of values defining the equivalence class. One value per
-       * quasi-identifier column in the original KAnonymity metric message.
-       * The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - java.util.List - getQuasiIdsValuesOrBuilderList(); - /** - *
-       * Set of values defining the equivalence class. One value per
-       * quasi-identifier column in the original KAnonymity metric message.
-       * The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getQuasiIdsValuesOrBuilder( - int index); - - /** - *
-       * Size of the equivalence class, for example number of rows with the
-       * above set of values.
-       * 
- * - * int64 equivalence_class_size = 2; - */ - long getEquivalenceClassSize(); - } - /** - *
-     * The set of columns' values that share the same k-anonymity value.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass} - */ - public static final class KAnonymityEquivalenceClass extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass) - KAnonymityEquivalenceClassOrBuilder { - private static final long serialVersionUID = 0L; - // Use KAnonymityEquivalenceClass.newBuilder() to construct. - private KAnonymityEquivalenceClass(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private KAnonymityEquivalenceClass() { - quasiIdsValues_ = java.util.Collections.emptyList(); - equivalenceClassSize_ = 0L; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private KAnonymityEquivalenceClass( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - quasiIdsValues_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - quasiIdsValues_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry)); - break; - } - case 16: { - - equivalenceClassSize_ = input.readInt64(); - 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) == 0x00000001)) { - quasiIdsValues_ = java.util.Collections.unmodifiableList(quasiIdsValues_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityEquivalenceClass_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityEquivalenceClass_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder.class); - } - - private int bitField0_; - public static final int QUASI_IDS_VALUES_FIELD_NUMBER = 1; - private java.util.List quasiIdsValues_; - /** - *
-       * Set of values defining the equivalence class. One value per
-       * quasi-identifier column in the original KAnonymity metric message.
-       * The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public java.util.List getQuasiIdsValuesList() { - return quasiIdsValues_; - } - /** - *
-       * Set of values defining the equivalence class. One value per
-       * quasi-identifier column in the original KAnonymity metric message.
-       * The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public java.util.List - getQuasiIdsValuesOrBuilderList() { - return quasiIdsValues_; - } - /** - *
-       * Set of values defining the equivalence class. One value per
-       * quasi-identifier column in the original KAnonymity metric message.
-       * The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public int getQuasiIdsValuesCount() { - return quasiIdsValues_.size(); - } - /** - *
-       * Set of values defining the equivalence class. One value per
-       * quasi-identifier column in the original KAnonymity metric message.
-       * The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getQuasiIdsValues(int index) { - return quasiIdsValues_.get(index); - } - /** - *
-       * Set of values defining the equivalence class. One value per
-       * quasi-identifier column in the original KAnonymity metric message.
-       * The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getQuasiIdsValuesOrBuilder( - int index) { - return quasiIdsValues_.get(index); - } - - public static final int EQUIVALENCE_CLASS_SIZE_FIELD_NUMBER = 2; - private long equivalenceClassSize_; - /** - *
-       * Size of the equivalence class, for example number of rows with the
-       * above set of values.
-       * 
- * - * int64 equivalence_class_size = 2; - */ - public long getEquivalenceClassSize() { - return equivalenceClassSize_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < quasiIdsValues_.size(); i++) { - output.writeMessage(1, quasiIdsValues_.get(i)); - } - if (equivalenceClassSize_ != 0L) { - output.writeInt64(2, equivalenceClassSize_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < quasiIdsValues_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, quasiIdsValues_.get(i)); - } - if (equivalenceClassSize_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(2, equivalenceClassSize_); - } - 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass) obj; - - boolean result = true; - result = result && getQuasiIdsValuesList() - .equals(other.getQuasiIdsValuesList()); - result = result && (getEquivalenceClassSize() - == other.getEquivalenceClassSize()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getQuasiIdsValuesCount() > 0) { - hash = (37 * hash) + QUASI_IDS_VALUES_FIELD_NUMBER; - hash = (53 * hash) + getQuasiIdsValuesList().hashCode(); - } - hash = (37 * hash) + EQUIVALENCE_CLASS_SIZE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getEquivalenceClassSize()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-       * The set of columns' values that share the same k-anonymity value.
-       * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClassOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityEquivalenceClass_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityEquivalenceClass_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getQuasiIdsValuesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (quasiIdsValuesBuilder_ == null) { - quasiIdsValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - quasiIdsValuesBuilder_.clear(); - } - equivalenceClassSize_ = 0L; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityEquivalenceClass_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (quasiIdsValuesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - quasiIdsValues_ = java.util.Collections.unmodifiableList(quasiIdsValues_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.quasiIdsValues_ = quasiIdsValues_; - } else { - result.quasiIdsValues_ = quasiIdsValuesBuilder_.build(); - } - result.equivalenceClassSize_ = equivalenceClassSize_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.getDefaultInstance()) return this; - if (quasiIdsValuesBuilder_ == null) { - if (!other.quasiIdsValues_.isEmpty()) { - if (quasiIdsValues_.isEmpty()) { - quasiIdsValues_ = other.quasiIdsValues_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.addAll(other.quasiIdsValues_); - } - onChanged(); - } - } else { - if (!other.quasiIdsValues_.isEmpty()) { - if (quasiIdsValuesBuilder_.isEmpty()) { - quasiIdsValuesBuilder_.dispose(); - quasiIdsValuesBuilder_ = null; - quasiIdsValues_ = other.quasiIdsValues_; - bitField0_ = (bitField0_ & ~0x00000001); - quasiIdsValuesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getQuasiIdsValuesFieldBuilder() : null; - } else { - quasiIdsValuesBuilder_.addAllMessages(other.quasiIdsValues_); - } - } - } - if (other.getEquivalenceClassSize() != 0L) { - setEquivalenceClassSize(other.getEquivalenceClassSize()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List quasiIdsValues_ = - java.util.Collections.emptyList(); - private void ensureQuasiIdsValuesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - quasiIdsValues_ = new java.util.ArrayList(quasiIdsValues_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> quasiIdsValuesBuilder_; - - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public java.util.List getQuasiIdsValuesList() { - if (quasiIdsValuesBuilder_ == null) { - return java.util.Collections.unmodifiableList(quasiIdsValues_); - } else { - return quasiIdsValuesBuilder_.getMessageList(); - } - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public int getQuasiIdsValuesCount() { - if (quasiIdsValuesBuilder_ == null) { - return quasiIdsValues_.size(); - } else { - return quasiIdsValuesBuilder_.getCount(); - } - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getQuasiIdsValues(int index) { - if (quasiIdsValuesBuilder_ == null) { - return quasiIdsValues_.get(index); - } else { - return quasiIdsValuesBuilder_.getMessage(index); - } - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder setQuasiIdsValues( - int index, com.google.privacy.dlp.v2beta1.Value value) { - if (quasiIdsValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.set(index, value); - onChanged(); - } else { - quasiIdsValuesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder setQuasiIdsValues( - int index, com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (quasiIdsValuesBuilder_ == null) { - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.set(index, builderForValue.build()); - onChanged(); - } else { - quasiIdsValuesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder addQuasiIdsValues(com.google.privacy.dlp.v2beta1.Value value) { - if (quasiIdsValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.add(value); - onChanged(); - } else { - quasiIdsValuesBuilder_.addMessage(value); - } - return this; - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder addQuasiIdsValues( - int index, com.google.privacy.dlp.v2beta1.Value value) { - if (quasiIdsValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.add(index, value); - onChanged(); - } else { - quasiIdsValuesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder addQuasiIdsValues( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (quasiIdsValuesBuilder_ == null) { - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.add(builderForValue.build()); - onChanged(); - } else { - quasiIdsValuesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder addQuasiIdsValues( - int index, com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (quasiIdsValuesBuilder_ == null) { - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.add(index, builderForValue.build()); - onChanged(); - } else { - quasiIdsValuesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder addAllQuasiIdsValues( - java.lang.Iterable values) { - if (quasiIdsValuesBuilder_ == null) { - ensureQuasiIdsValuesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, quasiIdsValues_); - onChanged(); - } else { - quasiIdsValuesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder clearQuasiIdsValues() { - if (quasiIdsValuesBuilder_ == null) { - quasiIdsValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - quasiIdsValuesBuilder_.clear(); - } - return this; - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder removeQuasiIdsValues(int index) { - if (quasiIdsValuesBuilder_ == null) { - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.remove(index); - onChanged(); - } else { - quasiIdsValuesBuilder_.remove(index); - } - return this; - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getQuasiIdsValuesBuilder( - int index) { - return getQuasiIdsValuesFieldBuilder().getBuilder(index); - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getQuasiIdsValuesOrBuilder( - int index) { - if (quasiIdsValuesBuilder_ == null) { - return quasiIdsValues_.get(index); } else { - return quasiIdsValuesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public java.util.List - getQuasiIdsValuesOrBuilderList() { - if (quasiIdsValuesBuilder_ != null) { - return quasiIdsValuesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(quasiIdsValues_); - } - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder addQuasiIdsValuesBuilder() { - return getQuasiIdsValuesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance()); - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder addQuasiIdsValuesBuilder( - int index) { - return getQuasiIdsValuesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.Value.getDefaultInstance()); - } - /** - *
-         * Set of values defining the equivalence class. One value per
-         * quasi-identifier column in the original KAnonymity metric message.
-         * The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public java.util.List - getQuasiIdsValuesBuilderList() { - return getQuasiIdsValuesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getQuasiIdsValuesFieldBuilder() { - if (quasiIdsValuesBuilder_ == null) { - quasiIdsValuesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - quasiIdsValues_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - quasiIdsValues_ = null; - } - return quasiIdsValuesBuilder_; - } - - private long equivalenceClassSize_ ; - /** - *
-         * Size of the equivalence class, for example number of rows with the
-         * above set of values.
-         * 
- * - * int64 equivalence_class_size = 2; - */ - public long getEquivalenceClassSize() { - return equivalenceClassSize_; - } - /** - *
-         * Size of the equivalence class, for example number of rows with the
-         * above set of values.
-         * 
- * - * int64 equivalence_class_size = 2; - */ - public Builder setEquivalenceClassSize(long value) { - - equivalenceClassSize_ = value; - onChanged(); - return this; - } - /** - *
-         * Size of the equivalence class, for example number of rows with the
-         * above set of values.
-         * 
- * - * int64 equivalence_class_size = 2; - */ - public Builder clearEquivalenceClassSize() { - - equivalenceClassSize_ = 0L; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public KAnonymityEquivalenceClass parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new KAnonymityEquivalenceClass(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface KAnonymityHistogramBucketOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket) - com.google.protobuf.MessageOrBuilder { - - /** - *
-       * Lower bound on the size of the equivalence classes in this bucket.
-       * 
- * - * int64 equivalence_class_size_lower_bound = 1; - */ - long getEquivalenceClassSizeLowerBound(); - - /** - *
-       * Upper bound on the size of the equivalence classes in this bucket.
-       * 
- * - * int64 equivalence_class_size_upper_bound = 2; - */ - long getEquivalenceClassSizeUpperBound(); - - /** - *
-       * Total number of records in this bucket.
-       * 
- * - * int64 bucket_size = 3; - */ - long getBucketSize(); - - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - java.util.List - getBucketValuesList(); - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass getBucketValues(int index); - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - int getBucketValuesCount(); - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - java.util.List - getBucketValuesOrBuilderList(); - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClassOrBuilder getBucketValuesOrBuilder( - int index); - } - /** - *
-     * Histogram bucket of equivalence class sizes in the table.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket} - */ - public static final class KAnonymityHistogramBucket extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket) - KAnonymityHistogramBucketOrBuilder { - private static final long serialVersionUID = 0L; - // Use KAnonymityHistogramBucket.newBuilder() to construct. - private KAnonymityHistogramBucket(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private KAnonymityHistogramBucket() { - equivalenceClassSizeLowerBound_ = 0L; - equivalenceClassSizeUpperBound_ = 0L; - bucketSize_ = 0L; - bucketValues_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private KAnonymityHistogramBucket( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - - equivalenceClassSizeLowerBound_ = input.readInt64(); - break; - } - case 16: { - - equivalenceClassSizeUpperBound_ = input.readInt64(); - break; - } - case 24: { - - bucketSize_ = input.readInt64(); - break; - } - case 34: { - if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - bucketValues_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - bucketValues_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.parser(), extensionRegistry)); - 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_ & 0x00000008) == 0x00000008)) { - bucketValues_ = java.util.Collections.unmodifiableList(bucketValues_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityHistogramBucket_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityHistogramBucket_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder.class); - } - - private int bitField0_; - public static final int EQUIVALENCE_CLASS_SIZE_LOWER_BOUND_FIELD_NUMBER = 1; - private long equivalenceClassSizeLowerBound_; - /** - *
-       * Lower bound on the size of the equivalence classes in this bucket.
-       * 
- * - * int64 equivalence_class_size_lower_bound = 1; - */ - public long getEquivalenceClassSizeLowerBound() { - return equivalenceClassSizeLowerBound_; - } - - public static final int EQUIVALENCE_CLASS_SIZE_UPPER_BOUND_FIELD_NUMBER = 2; - private long equivalenceClassSizeUpperBound_; - /** - *
-       * Upper bound on the size of the equivalence classes in this bucket.
-       * 
- * - * int64 equivalence_class_size_upper_bound = 2; - */ - public long getEquivalenceClassSizeUpperBound() { - return equivalenceClassSizeUpperBound_; - } - - public static final int BUCKET_SIZE_FIELD_NUMBER = 3; - private long bucketSize_; - /** - *
-       * Total number of records in this bucket.
-       * 
- * - * int64 bucket_size = 3; - */ - public long getBucketSize() { - return bucketSize_; - } - - public static final int BUCKET_VALUES_FIELD_NUMBER = 4; - private java.util.List bucketValues_; - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public java.util.List getBucketValuesList() { - return bucketValues_; - } - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public java.util.List - getBucketValuesOrBuilderList() { - return bucketValues_; - } - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public int getBucketValuesCount() { - return bucketValues_.size(); - } - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass getBucketValues(int index) { - return bucketValues_.get(index); - } - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClassOrBuilder getBucketValuesOrBuilder( - int index) { - return bucketValues_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (equivalenceClassSizeLowerBound_ != 0L) { - output.writeInt64(1, equivalenceClassSizeLowerBound_); - } - if (equivalenceClassSizeUpperBound_ != 0L) { - output.writeInt64(2, equivalenceClassSizeUpperBound_); - } - if (bucketSize_ != 0L) { - output.writeInt64(3, bucketSize_); - } - for (int i = 0; i < bucketValues_.size(); i++) { - output.writeMessage(4, bucketValues_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (equivalenceClassSizeLowerBound_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(1, equivalenceClassSizeLowerBound_); - } - if (equivalenceClassSizeUpperBound_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(2, equivalenceClassSizeUpperBound_); - } - if (bucketSize_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(3, bucketSize_); - } - for (int i = 0; i < bucketValues_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, bucketValues_.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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket) obj; - - boolean result = true; - result = result && (getEquivalenceClassSizeLowerBound() - == other.getEquivalenceClassSizeLowerBound()); - result = result && (getEquivalenceClassSizeUpperBound() - == other.getEquivalenceClassSizeUpperBound()); - result = result && (getBucketSize() - == other.getBucketSize()); - result = result && getBucketValuesList() - .equals(other.getBucketValuesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + EQUIVALENCE_CLASS_SIZE_LOWER_BOUND_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getEquivalenceClassSizeLowerBound()); - hash = (37 * hash) + EQUIVALENCE_CLASS_SIZE_UPPER_BOUND_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getEquivalenceClassSizeUpperBound()); - hash = (37 * hash) + BUCKET_SIZE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getBucketSize()); - if (getBucketValuesCount() > 0) { - hash = (37 * hash) + BUCKET_VALUES_FIELD_NUMBER; - hash = (53 * hash) + getBucketValuesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-       * Histogram bucket of equivalence class sizes in the table.
-       * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucketOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityHistogramBucket_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityHistogramBucket_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getBucketValuesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - equivalenceClassSizeLowerBound_ = 0L; - - equivalenceClassSizeUpperBound_ = 0L; - - bucketSize_ = 0L; - - if (bucketValuesBuilder_ == null) { - bucketValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - bucketValuesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_KAnonymityHistogramBucket_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.equivalenceClassSizeLowerBound_ = equivalenceClassSizeLowerBound_; - result.equivalenceClassSizeUpperBound_ = equivalenceClassSizeUpperBound_; - result.bucketSize_ = bucketSize_; - if (bucketValuesBuilder_ == null) { - if (((bitField0_ & 0x00000008) == 0x00000008)) { - bucketValues_ = java.util.Collections.unmodifiableList(bucketValues_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.bucketValues_ = bucketValues_; - } else { - result.bucketValues_ = bucketValuesBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.getDefaultInstance()) return this; - if (other.getEquivalenceClassSizeLowerBound() != 0L) { - setEquivalenceClassSizeLowerBound(other.getEquivalenceClassSizeLowerBound()); - } - if (other.getEquivalenceClassSizeUpperBound() != 0L) { - setEquivalenceClassSizeUpperBound(other.getEquivalenceClassSizeUpperBound()); - } - if (other.getBucketSize() != 0L) { - setBucketSize(other.getBucketSize()); - } - if (bucketValuesBuilder_ == null) { - if (!other.bucketValues_.isEmpty()) { - if (bucketValues_.isEmpty()) { - bucketValues_ = other.bucketValues_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureBucketValuesIsMutable(); - bucketValues_.addAll(other.bucketValues_); - } - onChanged(); - } - } else { - if (!other.bucketValues_.isEmpty()) { - if (bucketValuesBuilder_.isEmpty()) { - bucketValuesBuilder_.dispose(); - bucketValuesBuilder_ = null; - bucketValues_ = other.bucketValues_; - bitField0_ = (bitField0_ & ~0x00000008); - bucketValuesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getBucketValuesFieldBuilder() : null; - } else { - bucketValuesBuilder_.addAllMessages(other.bucketValues_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private long equivalenceClassSizeLowerBound_ ; - /** - *
-         * Lower bound on the size of the equivalence classes in this bucket.
-         * 
- * - * int64 equivalence_class_size_lower_bound = 1; - */ - public long getEquivalenceClassSizeLowerBound() { - return equivalenceClassSizeLowerBound_; - } - /** - *
-         * Lower bound on the size of the equivalence classes in this bucket.
-         * 
- * - * int64 equivalence_class_size_lower_bound = 1; - */ - public Builder setEquivalenceClassSizeLowerBound(long value) { - - equivalenceClassSizeLowerBound_ = value; - onChanged(); - return this; - } - /** - *
-         * Lower bound on the size of the equivalence classes in this bucket.
-         * 
- * - * int64 equivalence_class_size_lower_bound = 1; - */ - public Builder clearEquivalenceClassSizeLowerBound() { - - equivalenceClassSizeLowerBound_ = 0L; - onChanged(); - return this; - } - - private long equivalenceClassSizeUpperBound_ ; - /** - *
-         * Upper bound on the size of the equivalence classes in this bucket.
-         * 
- * - * int64 equivalence_class_size_upper_bound = 2; - */ - public long getEquivalenceClassSizeUpperBound() { - return equivalenceClassSizeUpperBound_; - } - /** - *
-         * Upper bound on the size of the equivalence classes in this bucket.
-         * 
- * - * int64 equivalence_class_size_upper_bound = 2; - */ - public Builder setEquivalenceClassSizeUpperBound(long value) { - - equivalenceClassSizeUpperBound_ = value; - onChanged(); - return this; - } - /** - *
-         * Upper bound on the size of the equivalence classes in this bucket.
-         * 
- * - * int64 equivalence_class_size_upper_bound = 2; - */ - public Builder clearEquivalenceClassSizeUpperBound() { - - equivalenceClassSizeUpperBound_ = 0L; - onChanged(); - return this; - } - - private long bucketSize_ ; - /** - *
-         * Total number of records in this bucket.
-         * 
- * - * int64 bucket_size = 3; - */ - public long getBucketSize() { - return bucketSize_; - } - /** - *
-         * Total number of records in this bucket.
-         * 
- * - * int64 bucket_size = 3; - */ - public Builder setBucketSize(long value) { - - bucketSize_ = value; - onChanged(); - return this; - } - /** - *
-         * Total number of records in this bucket.
-         * 
- * - * int64 bucket_size = 3; - */ - public Builder clearBucketSize() { - - bucketSize_ = 0L; - onChanged(); - return this; - } - - private java.util.List bucketValues_ = - java.util.Collections.emptyList(); - private void ensureBucketValuesIsMutable() { - if (!((bitField0_ & 0x00000008) == 0x00000008)) { - bucketValues_ = new java.util.ArrayList(bucketValues_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClassOrBuilder> bucketValuesBuilder_; - - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public java.util.List getBucketValuesList() { - if (bucketValuesBuilder_ == null) { - return java.util.Collections.unmodifiableList(bucketValues_); - } else { - return bucketValuesBuilder_.getMessageList(); - } - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public int getBucketValuesCount() { - if (bucketValuesBuilder_ == null) { - return bucketValues_.size(); - } else { - return bucketValuesBuilder_.getCount(); - } - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass getBucketValues(int index) { - if (bucketValuesBuilder_ == null) { - return bucketValues_.get(index); - } else { - return bucketValuesBuilder_.getMessage(index); - } - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public Builder setBucketValues( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass value) { - if (bucketValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketValuesIsMutable(); - bucketValues_.set(index, value); - onChanged(); - } else { - bucketValuesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public Builder setBucketValues( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder builderForValue) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.set(index, builderForValue.build()); - onChanged(); - } else { - bucketValuesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public Builder addBucketValues(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass value) { - if (bucketValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketValuesIsMutable(); - bucketValues_.add(value); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(value); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public Builder addBucketValues( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass value) { - if (bucketValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketValuesIsMutable(); - bucketValues_.add(index, value); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public Builder addBucketValues( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder builderForValue) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.add(builderForValue.build()); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public Builder addBucketValues( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder builderForValue) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.add(index, builderForValue.build()); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public Builder addAllBucketValues( - java.lang.Iterable values) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, bucketValues_); - onChanged(); - } else { - bucketValuesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public Builder clearBucketValues() { - if (bucketValuesBuilder_ == null) { - bucketValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - bucketValuesBuilder_.clear(); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public Builder removeBucketValues(int index) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.remove(index); - onChanged(); - } else { - bucketValuesBuilder_.remove(index); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder getBucketValuesBuilder( - int index) { - return getBucketValuesFieldBuilder().getBuilder(index); - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClassOrBuilder getBucketValuesOrBuilder( - int index) { - if (bucketValuesBuilder_ == null) { - return bucketValues_.get(index); } else { - return bucketValuesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public java.util.List - getBucketValuesOrBuilderList() { - if (bucketValuesBuilder_ != null) { - return bucketValuesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(bucketValues_); - } - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder addBucketValuesBuilder() { - return getBucketValuesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.getDefaultInstance()); - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder addBucketValuesBuilder( - int index) { - return getBucketValuesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.getDefaultInstance()); - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass bucket_values = 4; - */ - public java.util.List - getBucketValuesBuilderList() { - return getBucketValuesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClassOrBuilder> - getBucketValuesFieldBuilder() { - if (bucketValuesBuilder_ == null) { - bucketValuesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClass.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityEquivalenceClassOrBuilder>( - bucketValues_, - ((bitField0_ & 0x00000008) == 0x00000008), - getParentForChildren(), - isClean()); - bucketValues_ = null; - } - return bucketValuesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public KAnonymityHistogramBucket parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new KAnonymityHistogramBucket(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public static final int EQUIVALENCE_CLASS_HISTOGRAM_BUCKETS_FIELD_NUMBER = 5; - private java.util.List equivalenceClassHistogramBuckets_; - /** - *
-     * Histogram of k-anonymity equivalence classes.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public java.util.List getEquivalenceClassHistogramBucketsList() { - return equivalenceClassHistogramBuckets_; - } - /** - *
-     * Histogram of k-anonymity equivalence classes.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public java.util.List - getEquivalenceClassHistogramBucketsOrBuilderList() { - return equivalenceClassHistogramBuckets_; - } - /** - *
-     * Histogram of k-anonymity equivalence classes.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public int getEquivalenceClassHistogramBucketsCount() { - return equivalenceClassHistogramBuckets_.size(); - } - /** - *
-     * Histogram of k-anonymity equivalence classes.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket getEquivalenceClassHistogramBuckets(int index) { - return equivalenceClassHistogramBuckets_.get(index); - } - /** - *
-     * Histogram of k-anonymity equivalence classes.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucketOrBuilder getEquivalenceClassHistogramBucketsOrBuilder( - int index) { - return equivalenceClassHistogramBuckets_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < equivalenceClassHistogramBuckets_.size(); i++) { - output.writeMessage(5, equivalenceClassHistogramBuckets_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < equivalenceClassHistogramBuckets_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, equivalenceClassHistogramBuckets_.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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) obj; - - boolean result = true; - result = result && getEquivalenceClassHistogramBucketsList() - .equals(other.getEquivalenceClassHistogramBucketsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getEquivalenceClassHistogramBucketsCount() > 0) { - hash = (37 * hash) + EQUIVALENCE_CLASS_HISTOGRAM_BUCKETS_FIELD_NUMBER; - hash = (53 * hash) + getEquivalenceClassHistogramBucketsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * Result of the k-anonymity computation.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResultOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getEquivalenceClassHistogramBucketsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (equivalenceClassHistogramBucketsBuilder_ == null) { - equivalenceClassHistogramBuckets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - equivalenceClassHistogramBucketsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_KAnonymityResult_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult(this); - int from_bitField0_ = bitField0_; - if (equivalenceClassHistogramBucketsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - equivalenceClassHistogramBuckets_ = java.util.Collections.unmodifiableList(equivalenceClassHistogramBuckets_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.equivalenceClassHistogramBuckets_ = equivalenceClassHistogramBuckets_; - } else { - result.equivalenceClassHistogramBuckets_ = equivalenceClassHistogramBucketsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.getDefaultInstance()) return this; - if (equivalenceClassHistogramBucketsBuilder_ == null) { - if (!other.equivalenceClassHistogramBuckets_.isEmpty()) { - if (equivalenceClassHistogramBuckets_.isEmpty()) { - equivalenceClassHistogramBuckets_ = other.equivalenceClassHistogramBuckets_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureEquivalenceClassHistogramBucketsIsMutable(); - equivalenceClassHistogramBuckets_.addAll(other.equivalenceClassHistogramBuckets_); - } - onChanged(); - } - } else { - if (!other.equivalenceClassHistogramBuckets_.isEmpty()) { - if (equivalenceClassHistogramBucketsBuilder_.isEmpty()) { - equivalenceClassHistogramBucketsBuilder_.dispose(); - equivalenceClassHistogramBucketsBuilder_ = null; - equivalenceClassHistogramBuckets_ = other.equivalenceClassHistogramBuckets_; - bitField0_ = (bitField0_ & ~0x00000001); - equivalenceClassHistogramBucketsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getEquivalenceClassHistogramBucketsFieldBuilder() : null; - } else { - equivalenceClassHistogramBucketsBuilder_.addAllMessages(other.equivalenceClassHistogramBuckets_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List equivalenceClassHistogramBuckets_ = - java.util.Collections.emptyList(); - private void ensureEquivalenceClassHistogramBucketsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - equivalenceClassHistogramBuckets_ = new java.util.ArrayList(equivalenceClassHistogramBuckets_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucketOrBuilder> equivalenceClassHistogramBucketsBuilder_; - - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public java.util.List getEquivalenceClassHistogramBucketsList() { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - return java.util.Collections.unmodifiableList(equivalenceClassHistogramBuckets_); - } else { - return equivalenceClassHistogramBucketsBuilder_.getMessageList(); - } - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public int getEquivalenceClassHistogramBucketsCount() { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - return equivalenceClassHistogramBuckets_.size(); - } else { - return equivalenceClassHistogramBucketsBuilder_.getCount(); - } - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket getEquivalenceClassHistogramBuckets(int index) { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - return equivalenceClassHistogramBuckets_.get(index); - } else { - return equivalenceClassHistogramBucketsBuilder_.getMessage(index); - } - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public Builder setEquivalenceClassHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket value) { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureEquivalenceClassHistogramBucketsIsMutable(); - equivalenceClassHistogramBuckets_.set(index, value); - onChanged(); - } else { - equivalenceClassHistogramBucketsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public Builder setEquivalenceClassHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder builderForValue) { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - ensureEquivalenceClassHistogramBucketsIsMutable(); - equivalenceClassHistogramBuckets_.set(index, builderForValue.build()); - onChanged(); - } else { - equivalenceClassHistogramBucketsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public Builder addEquivalenceClassHistogramBuckets(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket value) { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureEquivalenceClassHistogramBucketsIsMutable(); - equivalenceClassHistogramBuckets_.add(value); - onChanged(); - } else { - equivalenceClassHistogramBucketsBuilder_.addMessage(value); - } - return this; - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public Builder addEquivalenceClassHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket value) { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureEquivalenceClassHistogramBucketsIsMutable(); - equivalenceClassHistogramBuckets_.add(index, value); - onChanged(); - } else { - equivalenceClassHistogramBucketsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public Builder addEquivalenceClassHistogramBuckets( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder builderForValue) { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - ensureEquivalenceClassHistogramBucketsIsMutable(); - equivalenceClassHistogramBuckets_.add(builderForValue.build()); - onChanged(); - } else { - equivalenceClassHistogramBucketsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public Builder addEquivalenceClassHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder builderForValue) { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - ensureEquivalenceClassHistogramBucketsIsMutable(); - equivalenceClassHistogramBuckets_.add(index, builderForValue.build()); - onChanged(); - } else { - equivalenceClassHistogramBucketsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public Builder addAllEquivalenceClassHistogramBuckets( - java.lang.Iterable values) { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - ensureEquivalenceClassHistogramBucketsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, equivalenceClassHistogramBuckets_); - onChanged(); - } else { - equivalenceClassHistogramBucketsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public Builder clearEquivalenceClassHistogramBuckets() { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - equivalenceClassHistogramBuckets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - equivalenceClassHistogramBucketsBuilder_.clear(); - } - return this; - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public Builder removeEquivalenceClassHistogramBuckets(int index) { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - ensureEquivalenceClassHistogramBucketsIsMutable(); - equivalenceClassHistogramBuckets_.remove(index); - onChanged(); - } else { - equivalenceClassHistogramBucketsBuilder_.remove(index); - } - return this; - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder getEquivalenceClassHistogramBucketsBuilder( - int index) { - return getEquivalenceClassHistogramBucketsFieldBuilder().getBuilder(index); - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucketOrBuilder getEquivalenceClassHistogramBucketsOrBuilder( - int index) { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - return equivalenceClassHistogramBuckets_.get(index); } else { - return equivalenceClassHistogramBucketsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public java.util.List - getEquivalenceClassHistogramBucketsOrBuilderList() { - if (equivalenceClassHistogramBucketsBuilder_ != null) { - return equivalenceClassHistogramBucketsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(equivalenceClassHistogramBuckets_); - } - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder addEquivalenceClassHistogramBucketsBuilder() { - return getEquivalenceClassHistogramBucketsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.getDefaultInstance()); - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder addEquivalenceClassHistogramBucketsBuilder( - int index) { - return getEquivalenceClassHistogramBucketsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.getDefaultInstance()); - } - /** - *
-       * Histogram of k-anonymity equivalence classes.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - */ - public java.util.List - getEquivalenceClassHistogramBucketsBuilderList() { - return getEquivalenceClassHistogramBucketsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucketOrBuilder> - getEquivalenceClassHistogramBucketsFieldBuilder() { - if (equivalenceClassHistogramBucketsBuilder_ == null) { - equivalenceClassHistogramBucketsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucket.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.KAnonymityHistogramBucketOrBuilder>( - equivalenceClassHistogramBuckets_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - equivalenceClassHistogramBuckets_ = null; - } - return equivalenceClassHistogramBucketsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public KAnonymityResult parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new KAnonymityResult(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface LDiversityResultOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) - com.google.protobuf.MessageOrBuilder { - - /** - *
-     * Histogram of l-diversity equivalence class sensitive value frequencies.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - java.util.List - getSensitiveValueFrequencyHistogramBucketsList(); - /** - *
-     * Histogram of l-diversity equivalence class sensitive value frequencies.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket getSensitiveValueFrequencyHistogramBuckets(int index); - /** - *
-     * Histogram of l-diversity equivalence class sensitive value frequencies.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - int getSensitiveValueFrequencyHistogramBucketsCount(); - /** - *
-     * Histogram of l-diversity equivalence class sensitive value frequencies.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - java.util.List - getSensitiveValueFrequencyHistogramBucketsOrBuilderList(); - /** - *
-     * Histogram of l-diversity equivalence class sensitive value frequencies.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucketOrBuilder getSensitiveValueFrequencyHistogramBucketsOrBuilder( - int index); - } - /** - *
-   * Result of the l-diversity computation.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult} - */ - public static final class LDiversityResult extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) - LDiversityResultOrBuilder { - private static final long serialVersionUID = 0L; - // Use LDiversityResult.newBuilder() to construct. - private LDiversityResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private LDiversityResult() { - sensitiveValueFrequencyHistogramBuckets_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private LDiversityResult( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 42: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - sensitiveValueFrequencyHistogramBuckets_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - sensitiveValueFrequencyHistogramBuckets_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.parser(), extensionRegistry)); - 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) == 0x00000001)) { - sensitiveValueFrequencyHistogramBuckets_ = java.util.Collections.unmodifiableList(sensitiveValueFrequencyHistogramBuckets_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.Builder.class); - } - - public interface LDiversityEquivalenceClassOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass) - com.google.protobuf.MessageOrBuilder { - - /** - *
-       * Quasi-identifier values defining the k-anonymity equivalence
-       * class. The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - java.util.List - getQuasiIdsValuesList(); - /** - *
-       * Quasi-identifier values defining the k-anonymity equivalence
-       * class. The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - com.google.privacy.dlp.v2beta1.Value getQuasiIdsValues(int index); - /** - *
-       * Quasi-identifier values defining the k-anonymity equivalence
-       * class. The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - int getQuasiIdsValuesCount(); - /** - *
-       * Quasi-identifier values defining the k-anonymity equivalence
-       * class. The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - java.util.List - getQuasiIdsValuesOrBuilderList(); - /** - *
-       * Quasi-identifier values defining the k-anonymity equivalence
-       * class. The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getQuasiIdsValuesOrBuilder( - int index); - - /** - *
-       * Size of the k-anonymity equivalence class.
-       * 
- * - * int64 equivalence_class_size = 2; - */ - long getEquivalenceClassSize(); - - /** - *
-       * Number of distinct sensitive values in this equivalence class.
-       * 
- * - * int64 num_distinct_sensitive_values = 3; - */ - long getNumDistinctSensitiveValues(); - - /** - *
-       * Estimated frequencies of top sensitive values.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - java.util.List - getTopSensitiveValuesList(); - /** - *
-       * Estimated frequencies of top sensitive values.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - com.google.privacy.dlp.v2beta1.ValueFrequency getTopSensitiveValues(int index); - /** - *
-       * Estimated frequencies of top sensitive values.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - int getTopSensitiveValuesCount(); - /** - *
-       * Estimated frequencies of top sensitive values.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - java.util.List - getTopSensitiveValuesOrBuilderList(); - /** - *
-       * Estimated frequencies of top sensitive values.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder getTopSensitiveValuesOrBuilder( - int index); - } - /** - *
-     * The set of columns' values that share the same l-diversity value.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass} - */ - public static final class LDiversityEquivalenceClass extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass) - LDiversityEquivalenceClassOrBuilder { - private static final long serialVersionUID = 0L; - // Use LDiversityEquivalenceClass.newBuilder() to construct. - private LDiversityEquivalenceClass(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private LDiversityEquivalenceClass() { - quasiIdsValues_ = java.util.Collections.emptyList(); - equivalenceClassSize_ = 0L; - numDistinctSensitiveValues_ = 0L; - topSensitiveValues_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private LDiversityEquivalenceClass( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - quasiIdsValues_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - quasiIdsValues_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry)); - break; - } - case 16: { - - equivalenceClassSize_ = input.readInt64(); - break; - } - case 24: { - - numDistinctSensitiveValues_ = input.readInt64(); - break; - } - case 34: { - if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - topSensitiveValues_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - topSensitiveValues_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.ValueFrequency.parser(), extensionRegistry)); - 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) == 0x00000001)) { - quasiIdsValues_ = java.util.Collections.unmodifiableList(quasiIdsValues_); - } - if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - topSensitiveValues_ = java.util.Collections.unmodifiableList(topSensitiveValues_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityEquivalenceClass_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityEquivalenceClass_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder.class); - } - - private int bitField0_; - public static final int QUASI_IDS_VALUES_FIELD_NUMBER = 1; - private java.util.List quasiIdsValues_; - /** - *
-       * Quasi-identifier values defining the k-anonymity equivalence
-       * class. The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public java.util.List getQuasiIdsValuesList() { - return quasiIdsValues_; - } - /** - *
-       * Quasi-identifier values defining the k-anonymity equivalence
-       * class. The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public java.util.List - getQuasiIdsValuesOrBuilderList() { - return quasiIdsValues_; - } - /** - *
-       * Quasi-identifier values defining the k-anonymity equivalence
-       * class. The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public int getQuasiIdsValuesCount() { - return quasiIdsValues_.size(); - } - /** - *
-       * Quasi-identifier values defining the k-anonymity equivalence
-       * class. The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getQuasiIdsValues(int index) { - return quasiIdsValues_.get(index); - } - /** - *
-       * Quasi-identifier values defining the k-anonymity equivalence
-       * class. The order is always the same as the original request.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getQuasiIdsValuesOrBuilder( - int index) { - return quasiIdsValues_.get(index); - } - - public static final int EQUIVALENCE_CLASS_SIZE_FIELD_NUMBER = 2; - private long equivalenceClassSize_; - /** - *
-       * Size of the k-anonymity equivalence class.
-       * 
- * - * int64 equivalence_class_size = 2; - */ - public long getEquivalenceClassSize() { - return equivalenceClassSize_; - } - - public static final int NUM_DISTINCT_SENSITIVE_VALUES_FIELD_NUMBER = 3; - private long numDistinctSensitiveValues_; - /** - *
-       * Number of distinct sensitive values in this equivalence class.
-       * 
- * - * int64 num_distinct_sensitive_values = 3; - */ - public long getNumDistinctSensitiveValues() { - return numDistinctSensitiveValues_; - } - - public static final int TOP_SENSITIVE_VALUES_FIELD_NUMBER = 4; - private java.util.List topSensitiveValues_; - /** - *
-       * Estimated frequencies of top sensitive values.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public java.util.List getTopSensitiveValuesList() { - return topSensitiveValues_; - } - /** - *
-       * Estimated frequencies of top sensitive values.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public java.util.List - getTopSensitiveValuesOrBuilderList() { - return topSensitiveValues_; - } - /** - *
-       * Estimated frequencies of top sensitive values.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public int getTopSensitiveValuesCount() { - return topSensitiveValues_.size(); - } - /** - *
-       * Estimated frequencies of top sensitive values.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequency getTopSensitiveValues(int index) { - return topSensitiveValues_.get(index); - } - /** - *
-       * Estimated frequencies of top sensitive values.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder getTopSensitiveValuesOrBuilder( - int index) { - return topSensitiveValues_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < quasiIdsValues_.size(); i++) { - output.writeMessage(1, quasiIdsValues_.get(i)); - } - if (equivalenceClassSize_ != 0L) { - output.writeInt64(2, equivalenceClassSize_); - } - if (numDistinctSensitiveValues_ != 0L) { - output.writeInt64(3, numDistinctSensitiveValues_); - } - for (int i = 0; i < topSensitiveValues_.size(); i++) { - output.writeMessage(4, topSensitiveValues_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < quasiIdsValues_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, quasiIdsValues_.get(i)); - } - if (equivalenceClassSize_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(2, equivalenceClassSize_); - } - if (numDistinctSensitiveValues_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(3, numDistinctSensitiveValues_); - } - for (int i = 0; i < topSensitiveValues_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, topSensitiveValues_.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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass) obj; - - boolean result = true; - result = result && getQuasiIdsValuesList() - .equals(other.getQuasiIdsValuesList()); - result = result && (getEquivalenceClassSize() - == other.getEquivalenceClassSize()); - result = result && (getNumDistinctSensitiveValues() - == other.getNumDistinctSensitiveValues()); - result = result && getTopSensitiveValuesList() - .equals(other.getTopSensitiveValuesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getQuasiIdsValuesCount() > 0) { - hash = (37 * hash) + QUASI_IDS_VALUES_FIELD_NUMBER; - hash = (53 * hash) + getQuasiIdsValuesList().hashCode(); - } - hash = (37 * hash) + EQUIVALENCE_CLASS_SIZE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getEquivalenceClassSize()); - hash = (37 * hash) + NUM_DISTINCT_SENSITIVE_VALUES_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getNumDistinctSensitiveValues()); - if (getTopSensitiveValuesCount() > 0) { - hash = (37 * hash) + TOP_SENSITIVE_VALUES_FIELD_NUMBER; - hash = (53 * hash) + getTopSensitiveValuesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-       * The set of columns' values that share the same l-diversity value.
-       * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClassOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityEquivalenceClass_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityEquivalenceClass_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getQuasiIdsValuesFieldBuilder(); - getTopSensitiveValuesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (quasiIdsValuesBuilder_ == null) { - quasiIdsValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - quasiIdsValuesBuilder_.clear(); - } - equivalenceClassSize_ = 0L; - - numDistinctSensitiveValues_ = 0L; - - if (topSensitiveValuesBuilder_ == null) { - topSensitiveValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - topSensitiveValuesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityEquivalenceClass_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (quasiIdsValuesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - quasiIdsValues_ = java.util.Collections.unmodifiableList(quasiIdsValues_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.quasiIdsValues_ = quasiIdsValues_; - } else { - result.quasiIdsValues_ = quasiIdsValuesBuilder_.build(); - } - result.equivalenceClassSize_ = equivalenceClassSize_; - result.numDistinctSensitiveValues_ = numDistinctSensitiveValues_; - if (topSensitiveValuesBuilder_ == null) { - if (((bitField0_ & 0x00000008) == 0x00000008)) { - topSensitiveValues_ = java.util.Collections.unmodifiableList(topSensitiveValues_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.topSensitiveValues_ = topSensitiveValues_; - } else { - result.topSensitiveValues_ = topSensitiveValuesBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.getDefaultInstance()) return this; - if (quasiIdsValuesBuilder_ == null) { - if (!other.quasiIdsValues_.isEmpty()) { - if (quasiIdsValues_.isEmpty()) { - quasiIdsValues_ = other.quasiIdsValues_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.addAll(other.quasiIdsValues_); - } - onChanged(); - } - } else { - if (!other.quasiIdsValues_.isEmpty()) { - if (quasiIdsValuesBuilder_.isEmpty()) { - quasiIdsValuesBuilder_.dispose(); - quasiIdsValuesBuilder_ = null; - quasiIdsValues_ = other.quasiIdsValues_; - bitField0_ = (bitField0_ & ~0x00000001); - quasiIdsValuesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getQuasiIdsValuesFieldBuilder() : null; - } else { - quasiIdsValuesBuilder_.addAllMessages(other.quasiIdsValues_); - } - } - } - if (other.getEquivalenceClassSize() != 0L) { - setEquivalenceClassSize(other.getEquivalenceClassSize()); - } - if (other.getNumDistinctSensitiveValues() != 0L) { - setNumDistinctSensitiveValues(other.getNumDistinctSensitiveValues()); - } - if (topSensitiveValuesBuilder_ == null) { - if (!other.topSensitiveValues_.isEmpty()) { - if (topSensitiveValues_.isEmpty()) { - topSensitiveValues_ = other.topSensitiveValues_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureTopSensitiveValuesIsMutable(); - topSensitiveValues_.addAll(other.topSensitiveValues_); - } - onChanged(); - } - } else { - if (!other.topSensitiveValues_.isEmpty()) { - if (topSensitiveValuesBuilder_.isEmpty()) { - topSensitiveValuesBuilder_.dispose(); - topSensitiveValuesBuilder_ = null; - topSensitiveValues_ = other.topSensitiveValues_; - bitField0_ = (bitField0_ & ~0x00000008); - topSensitiveValuesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getTopSensitiveValuesFieldBuilder() : null; - } else { - topSensitiveValuesBuilder_.addAllMessages(other.topSensitiveValues_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List quasiIdsValues_ = - java.util.Collections.emptyList(); - private void ensureQuasiIdsValuesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - quasiIdsValues_ = new java.util.ArrayList(quasiIdsValues_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> quasiIdsValuesBuilder_; - - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public java.util.List getQuasiIdsValuesList() { - if (quasiIdsValuesBuilder_ == null) { - return java.util.Collections.unmodifiableList(quasiIdsValues_); - } else { - return quasiIdsValuesBuilder_.getMessageList(); - } - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public int getQuasiIdsValuesCount() { - if (quasiIdsValuesBuilder_ == null) { - return quasiIdsValues_.size(); - } else { - return quasiIdsValuesBuilder_.getCount(); - } - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getQuasiIdsValues(int index) { - if (quasiIdsValuesBuilder_ == null) { - return quasiIdsValues_.get(index); - } else { - return quasiIdsValuesBuilder_.getMessage(index); - } - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder setQuasiIdsValues( - int index, com.google.privacy.dlp.v2beta1.Value value) { - if (quasiIdsValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.set(index, value); - onChanged(); - } else { - quasiIdsValuesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder setQuasiIdsValues( - int index, com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (quasiIdsValuesBuilder_ == null) { - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.set(index, builderForValue.build()); - onChanged(); - } else { - quasiIdsValuesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder addQuasiIdsValues(com.google.privacy.dlp.v2beta1.Value value) { - if (quasiIdsValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.add(value); - onChanged(); - } else { - quasiIdsValuesBuilder_.addMessage(value); - } - return this; - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder addQuasiIdsValues( - int index, com.google.privacy.dlp.v2beta1.Value value) { - if (quasiIdsValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.add(index, value); - onChanged(); - } else { - quasiIdsValuesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder addQuasiIdsValues( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (quasiIdsValuesBuilder_ == null) { - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.add(builderForValue.build()); - onChanged(); - } else { - quasiIdsValuesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder addQuasiIdsValues( - int index, com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (quasiIdsValuesBuilder_ == null) { - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.add(index, builderForValue.build()); - onChanged(); - } else { - quasiIdsValuesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder addAllQuasiIdsValues( - java.lang.Iterable values) { - if (quasiIdsValuesBuilder_ == null) { - ensureQuasiIdsValuesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, quasiIdsValues_); - onChanged(); - } else { - quasiIdsValuesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder clearQuasiIdsValues() { - if (quasiIdsValuesBuilder_ == null) { - quasiIdsValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - quasiIdsValuesBuilder_.clear(); - } - return this; - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public Builder removeQuasiIdsValues(int index) { - if (quasiIdsValuesBuilder_ == null) { - ensureQuasiIdsValuesIsMutable(); - quasiIdsValues_.remove(index); - onChanged(); - } else { - quasiIdsValuesBuilder_.remove(index); - } - return this; - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getQuasiIdsValuesBuilder( - int index) { - return getQuasiIdsValuesFieldBuilder().getBuilder(index); - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getQuasiIdsValuesOrBuilder( - int index) { - if (quasiIdsValuesBuilder_ == null) { - return quasiIdsValues_.get(index); } else { - return quasiIdsValuesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public java.util.List - getQuasiIdsValuesOrBuilderList() { - if (quasiIdsValuesBuilder_ != null) { - return quasiIdsValuesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(quasiIdsValues_); - } - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder addQuasiIdsValuesBuilder() { - return getQuasiIdsValuesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance()); - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder addQuasiIdsValuesBuilder( - int index) { - return getQuasiIdsValuesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.Value.getDefaultInstance()); - } - /** - *
-         * Quasi-identifier values defining the k-anonymity equivalence
-         * class. The order is always the same as the original request.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.Value quasi_ids_values = 1; - */ - public java.util.List - getQuasiIdsValuesBuilderList() { - return getQuasiIdsValuesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getQuasiIdsValuesFieldBuilder() { - if (quasiIdsValuesBuilder_ == null) { - quasiIdsValuesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - quasiIdsValues_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - quasiIdsValues_ = null; - } - return quasiIdsValuesBuilder_; - } - - private long equivalenceClassSize_ ; - /** - *
-         * Size of the k-anonymity equivalence class.
-         * 
- * - * int64 equivalence_class_size = 2; - */ - public long getEquivalenceClassSize() { - return equivalenceClassSize_; - } - /** - *
-         * Size of the k-anonymity equivalence class.
-         * 
- * - * int64 equivalence_class_size = 2; - */ - public Builder setEquivalenceClassSize(long value) { - - equivalenceClassSize_ = value; - onChanged(); - return this; - } - /** - *
-         * Size of the k-anonymity equivalence class.
-         * 
- * - * int64 equivalence_class_size = 2; - */ - public Builder clearEquivalenceClassSize() { - - equivalenceClassSize_ = 0L; - onChanged(); - return this; - } - - private long numDistinctSensitiveValues_ ; - /** - *
-         * Number of distinct sensitive values in this equivalence class.
-         * 
- * - * int64 num_distinct_sensitive_values = 3; - */ - public long getNumDistinctSensitiveValues() { - return numDistinctSensitiveValues_; - } - /** - *
-         * Number of distinct sensitive values in this equivalence class.
-         * 
- * - * int64 num_distinct_sensitive_values = 3; - */ - public Builder setNumDistinctSensitiveValues(long value) { - - numDistinctSensitiveValues_ = value; - onChanged(); - return this; - } - /** - *
-         * Number of distinct sensitive values in this equivalence class.
-         * 
- * - * int64 num_distinct_sensitive_values = 3; - */ - public Builder clearNumDistinctSensitiveValues() { - - numDistinctSensitiveValues_ = 0L; - onChanged(); - return this; - } - - private java.util.List topSensitiveValues_ = - java.util.Collections.emptyList(); - private void ensureTopSensitiveValuesIsMutable() { - if (!((bitField0_ & 0x00000008) == 0x00000008)) { - topSensitiveValues_ = new java.util.ArrayList(topSensitiveValues_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ValueFrequency, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder, com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder> topSensitiveValuesBuilder_; - - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public java.util.List getTopSensitiveValuesList() { - if (topSensitiveValuesBuilder_ == null) { - return java.util.Collections.unmodifiableList(topSensitiveValues_); - } else { - return topSensitiveValuesBuilder_.getMessageList(); - } - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public int getTopSensitiveValuesCount() { - if (topSensitiveValuesBuilder_ == null) { - return topSensitiveValues_.size(); - } else { - return topSensitiveValuesBuilder_.getCount(); - } - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequency getTopSensitiveValues(int index) { - if (topSensitiveValuesBuilder_ == null) { - return topSensitiveValues_.get(index); - } else { - return topSensitiveValuesBuilder_.getMessage(index); - } - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public Builder setTopSensitiveValues( - int index, com.google.privacy.dlp.v2beta1.ValueFrequency value) { - if (topSensitiveValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTopSensitiveValuesIsMutable(); - topSensitiveValues_.set(index, value); - onChanged(); - } else { - topSensitiveValuesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public Builder setTopSensitiveValues( - int index, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder builderForValue) { - if (topSensitiveValuesBuilder_ == null) { - ensureTopSensitiveValuesIsMutable(); - topSensitiveValues_.set(index, builderForValue.build()); - onChanged(); - } else { - topSensitiveValuesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public Builder addTopSensitiveValues(com.google.privacy.dlp.v2beta1.ValueFrequency value) { - if (topSensitiveValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTopSensitiveValuesIsMutable(); - topSensitiveValues_.add(value); - onChanged(); - } else { - topSensitiveValuesBuilder_.addMessage(value); - } - return this; - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public Builder addTopSensitiveValues( - int index, com.google.privacy.dlp.v2beta1.ValueFrequency value) { - if (topSensitiveValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTopSensitiveValuesIsMutable(); - topSensitiveValues_.add(index, value); - onChanged(); - } else { - topSensitiveValuesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public Builder addTopSensitiveValues( - com.google.privacy.dlp.v2beta1.ValueFrequency.Builder builderForValue) { - if (topSensitiveValuesBuilder_ == null) { - ensureTopSensitiveValuesIsMutable(); - topSensitiveValues_.add(builderForValue.build()); - onChanged(); - } else { - topSensitiveValuesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public Builder addTopSensitiveValues( - int index, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder builderForValue) { - if (topSensitiveValuesBuilder_ == null) { - ensureTopSensitiveValuesIsMutable(); - topSensitiveValues_.add(index, builderForValue.build()); - onChanged(); - } else { - topSensitiveValuesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public Builder addAllTopSensitiveValues( - java.lang.Iterable values) { - if (topSensitiveValuesBuilder_ == null) { - ensureTopSensitiveValuesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, topSensitiveValues_); - onChanged(); - } else { - topSensitiveValuesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public Builder clearTopSensitiveValues() { - if (topSensitiveValuesBuilder_ == null) { - topSensitiveValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - topSensitiveValuesBuilder_.clear(); - } - return this; - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public Builder removeTopSensitiveValues(int index) { - if (topSensitiveValuesBuilder_ == null) { - ensureTopSensitiveValuesIsMutable(); - topSensitiveValues_.remove(index); - onChanged(); - } else { - topSensitiveValuesBuilder_.remove(index); - } - return this; - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequency.Builder getTopSensitiveValuesBuilder( - int index) { - return getTopSensitiveValuesFieldBuilder().getBuilder(index); - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder getTopSensitiveValuesOrBuilder( - int index) { - if (topSensitiveValuesBuilder_ == null) { - return topSensitiveValues_.get(index); } else { - return topSensitiveValuesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public java.util.List - getTopSensitiveValuesOrBuilderList() { - if (topSensitiveValuesBuilder_ != null) { - return topSensitiveValuesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(topSensitiveValues_); - } - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequency.Builder addTopSensitiveValuesBuilder() { - return getTopSensitiveValuesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.ValueFrequency.getDefaultInstance()); - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public com.google.privacy.dlp.v2beta1.ValueFrequency.Builder addTopSensitiveValuesBuilder( - int index) { - return getTopSensitiveValuesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.ValueFrequency.getDefaultInstance()); - } - /** - *
-         * Estimated frequencies of top sensitive values.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.ValueFrequency top_sensitive_values = 4; - */ - public java.util.List - getTopSensitiveValuesBuilderList() { - return getTopSensitiveValuesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ValueFrequency, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder, com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder> - getTopSensitiveValuesFieldBuilder() { - if (topSensitiveValuesBuilder_ == null) { - topSensitiveValuesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.ValueFrequency, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder, com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder>( - topSensitiveValues_, - ((bitField0_ & 0x00000008) == 0x00000008), - getParentForChildren(), - isClean()); - topSensitiveValues_ = null; - } - return topSensitiveValuesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public LDiversityEquivalenceClass parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new LDiversityEquivalenceClass(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public interface LDiversityHistogramBucketOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket) - com.google.protobuf.MessageOrBuilder { - - /** - *
-       * Lower bound on the sensitive value frequencies of the equivalence
-       * classes in this bucket.
-       * 
- * - * int64 sensitive_value_frequency_lower_bound = 1; - */ - long getSensitiveValueFrequencyLowerBound(); - - /** - *
-       * Upper bound on the sensitive value frequencies of the equivalence
-       * classes in this bucket.
-       * 
- * - * int64 sensitive_value_frequency_upper_bound = 2; - */ - long getSensitiveValueFrequencyUpperBound(); - - /** - *
-       * Total number of records in this bucket.
-       * 
- * - * int64 bucket_size = 3; - */ - long getBucketSize(); - - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - java.util.List - getBucketValuesList(); - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass getBucketValues(int index); - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - int getBucketValuesCount(); - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - java.util.List - getBucketValuesOrBuilderList(); - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClassOrBuilder getBucketValuesOrBuilder( - int index); - } - /** - *
-     * Histogram bucket of sensitive value frequencies in the table.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket} - */ - public static final class LDiversityHistogramBucket extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket) - LDiversityHistogramBucketOrBuilder { - private static final long serialVersionUID = 0L; - // Use LDiversityHistogramBucket.newBuilder() to construct. - private LDiversityHistogramBucket(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private LDiversityHistogramBucket() { - sensitiveValueFrequencyLowerBound_ = 0L; - sensitiveValueFrequencyUpperBound_ = 0L; - bucketSize_ = 0L; - bucketValues_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private LDiversityHistogramBucket( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - - sensitiveValueFrequencyLowerBound_ = input.readInt64(); - break; - } - case 16: { - - sensitiveValueFrequencyUpperBound_ = input.readInt64(); - break; - } - case 24: { - - bucketSize_ = input.readInt64(); - break; - } - case 34: { - if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - bucketValues_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - bucketValues_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.parser(), extensionRegistry)); - 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_ & 0x00000008) == 0x00000008)) { - bucketValues_ = java.util.Collections.unmodifiableList(bucketValues_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityHistogramBucket_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityHistogramBucket_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder.class); - } - - private int bitField0_; - public static final int SENSITIVE_VALUE_FREQUENCY_LOWER_BOUND_FIELD_NUMBER = 1; - private long sensitiveValueFrequencyLowerBound_; - /** - *
-       * Lower bound on the sensitive value frequencies of the equivalence
-       * classes in this bucket.
-       * 
- * - * int64 sensitive_value_frequency_lower_bound = 1; - */ - public long getSensitiveValueFrequencyLowerBound() { - return sensitiveValueFrequencyLowerBound_; - } - - public static final int SENSITIVE_VALUE_FREQUENCY_UPPER_BOUND_FIELD_NUMBER = 2; - private long sensitiveValueFrequencyUpperBound_; - /** - *
-       * Upper bound on the sensitive value frequencies of the equivalence
-       * classes in this bucket.
-       * 
- * - * int64 sensitive_value_frequency_upper_bound = 2; - */ - public long getSensitiveValueFrequencyUpperBound() { - return sensitiveValueFrequencyUpperBound_; - } - - public static final int BUCKET_SIZE_FIELD_NUMBER = 3; - private long bucketSize_; - /** - *
-       * Total number of records in this bucket.
-       * 
- * - * int64 bucket_size = 3; - */ - public long getBucketSize() { - return bucketSize_; - } - - public static final int BUCKET_VALUES_FIELD_NUMBER = 4; - private java.util.List bucketValues_; - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public java.util.List getBucketValuesList() { - return bucketValues_; - } - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public java.util.List - getBucketValuesOrBuilderList() { - return bucketValues_; - } - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public int getBucketValuesCount() { - return bucketValues_.size(); - } - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass getBucketValues(int index) { - return bucketValues_.get(index); - } - /** - *
-       * Sample of equivalence classes in this bucket. The total number of
-       * classes returned per bucket is capped at 20.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClassOrBuilder getBucketValuesOrBuilder( - int index) { - return bucketValues_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (sensitiveValueFrequencyLowerBound_ != 0L) { - output.writeInt64(1, sensitiveValueFrequencyLowerBound_); - } - if (sensitiveValueFrequencyUpperBound_ != 0L) { - output.writeInt64(2, sensitiveValueFrequencyUpperBound_); - } - if (bucketSize_ != 0L) { - output.writeInt64(3, bucketSize_); - } - for (int i = 0; i < bucketValues_.size(); i++) { - output.writeMessage(4, bucketValues_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (sensitiveValueFrequencyLowerBound_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(1, sensitiveValueFrequencyLowerBound_); - } - if (sensitiveValueFrequencyUpperBound_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(2, sensitiveValueFrequencyUpperBound_); - } - if (bucketSize_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(3, bucketSize_); - } - for (int i = 0; i < bucketValues_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, bucketValues_.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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket) obj; - - boolean result = true; - result = result && (getSensitiveValueFrequencyLowerBound() - == other.getSensitiveValueFrequencyLowerBound()); - result = result && (getSensitiveValueFrequencyUpperBound() - == other.getSensitiveValueFrequencyUpperBound()); - result = result && (getBucketSize() - == other.getBucketSize()); - result = result && getBucketValuesList() - .equals(other.getBucketValuesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + SENSITIVE_VALUE_FREQUENCY_LOWER_BOUND_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getSensitiveValueFrequencyLowerBound()); - hash = (37 * hash) + SENSITIVE_VALUE_FREQUENCY_UPPER_BOUND_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getSensitiveValueFrequencyUpperBound()); - hash = (37 * hash) + BUCKET_SIZE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getBucketSize()); - if (getBucketValuesCount() > 0) { - hash = (37 * hash) + BUCKET_VALUES_FIELD_NUMBER; - hash = (53 * hash) + getBucketValuesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-       * Histogram bucket of sensitive value frequencies in the table.
-       * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucketOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityHistogramBucket_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityHistogramBucket_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getBucketValuesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - sensitiveValueFrequencyLowerBound_ = 0L; - - sensitiveValueFrequencyUpperBound_ = 0L; - - bucketSize_ = 0L; - - if (bucketValuesBuilder_ == null) { - bucketValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - bucketValuesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_LDiversityHistogramBucket_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - result.sensitiveValueFrequencyLowerBound_ = sensitiveValueFrequencyLowerBound_; - result.sensitiveValueFrequencyUpperBound_ = sensitiveValueFrequencyUpperBound_; - result.bucketSize_ = bucketSize_; - if (bucketValuesBuilder_ == null) { - if (((bitField0_ & 0x00000008) == 0x00000008)) { - bucketValues_ = java.util.Collections.unmodifiableList(bucketValues_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.bucketValues_ = bucketValues_; - } else { - result.bucketValues_ = bucketValuesBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.getDefaultInstance()) return this; - if (other.getSensitiveValueFrequencyLowerBound() != 0L) { - setSensitiveValueFrequencyLowerBound(other.getSensitiveValueFrequencyLowerBound()); - } - if (other.getSensitiveValueFrequencyUpperBound() != 0L) { - setSensitiveValueFrequencyUpperBound(other.getSensitiveValueFrequencyUpperBound()); - } - if (other.getBucketSize() != 0L) { - setBucketSize(other.getBucketSize()); - } - if (bucketValuesBuilder_ == null) { - if (!other.bucketValues_.isEmpty()) { - if (bucketValues_.isEmpty()) { - bucketValues_ = other.bucketValues_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureBucketValuesIsMutable(); - bucketValues_.addAll(other.bucketValues_); - } - onChanged(); - } - } else { - if (!other.bucketValues_.isEmpty()) { - if (bucketValuesBuilder_.isEmpty()) { - bucketValuesBuilder_.dispose(); - bucketValuesBuilder_ = null; - bucketValues_ = other.bucketValues_; - bitField0_ = (bitField0_ & ~0x00000008); - bucketValuesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getBucketValuesFieldBuilder() : null; - } else { - bucketValuesBuilder_.addAllMessages(other.bucketValues_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private long sensitiveValueFrequencyLowerBound_ ; - /** - *
-         * Lower bound on the sensitive value frequencies of the equivalence
-         * classes in this bucket.
-         * 
- * - * int64 sensitive_value_frequency_lower_bound = 1; - */ - public long getSensitiveValueFrequencyLowerBound() { - return sensitiveValueFrequencyLowerBound_; - } - /** - *
-         * Lower bound on the sensitive value frequencies of the equivalence
-         * classes in this bucket.
-         * 
- * - * int64 sensitive_value_frequency_lower_bound = 1; - */ - public Builder setSensitiveValueFrequencyLowerBound(long value) { - - sensitiveValueFrequencyLowerBound_ = value; - onChanged(); - return this; - } - /** - *
-         * Lower bound on the sensitive value frequencies of the equivalence
-         * classes in this bucket.
-         * 
- * - * int64 sensitive_value_frequency_lower_bound = 1; - */ - public Builder clearSensitiveValueFrequencyLowerBound() { - - sensitiveValueFrequencyLowerBound_ = 0L; - onChanged(); - return this; - } - - private long sensitiveValueFrequencyUpperBound_ ; - /** - *
-         * Upper bound on the sensitive value frequencies of the equivalence
-         * classes in this bucket.
-         * 
- * - * int64 sensitive_value_frequency_upper_bound = 2; - */ - public long getSensitiveValueFrequencyUpperBound() { - return sensitiveValueFrequencyUpperBound_; - } - /** - *
-         * Upper bound on the sensitive value frequencies of the equivalence
-         * classes in this bucket.
-         * 
- * - * int64 sensitive_value_frequency_upper_bound = 2; - */ - public Builder setSensitiveValueFrequencyUpperBound(long value) { - - sensitiveValueFrequencyUpperBound_ = value; - onChanged(); - return this; - } - /** - *
-         * Upper bound on the sensitive value frequencies of the equivalence
-         * classes in this bucket.
-         * 
- * - * int64 sensitive_value_frequency_upper_bound = 2; - */ - public Builder clearSensitiveValueFrequencyUpperBound() { - - sensitiveValueFrequencyUpperBound_ = 0L; - onChanged(); - return this; - } - - private long bucketSize_ ; - /** - *
-         * Total number of records in this bucket.
-         * 
- * - * int64 bucket_size = 3; - */ - public long getBucketSize() { - return bucketSize_; - } - /** - *
-         * Total number of records in this bucket.
-         * 
- * - * int64 bucket_size = 3; - */ - public Builder setBucketSize(long value) { - - bucketSize_ = value; - onChanged(); - return this; - } - /** - *
-         * Total number of records in this bucket.
-         * 
- * - * int64 bucket_size = 3; - */ - public Builder clearBucketSize() { - - bucketSize_ = 0L; - onChanged(); - return this; - } - - private java.util.List bucketValues_ = - java.util.Collections.emptyList(); - private void ensureBucketValuesIsMutable() { - if (!((bitField0_ & 0x00000008) == 0x00000008)) { - bucketValues_ = new java.util.ArrayList(bucketValues_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClassOrBuilder> bucketValuesBuilder_; - - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public java.util.List getBucketValuesList() { - if (bucketValuesBuilder_ == null) { - return java.util.Collections.unmodifiableList(bucketValues_); - } else { - return bucketValuesBuilder_.getMessageList(); - } - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public int getBucketValuesCount() { - if (bucketValuesBuilder_ == null) { - return bucketValues_.size(); - } else { - return bucketValuesBuilder_.getCount(); - } - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass getBucketValues(int index) { - if (bucketValuesBuilder_ == null) { - return bucketValues_.get(index); - } else { - return bucketValuesBuilder_.getMessage(index); - } - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public Builder setBucketValues( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass value) { - if (bucketValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketValuesIsMutable(); - bucketValues_.set(index, value); - onChanged(); - } else { - bucketValuesBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public Builder setBucketValues( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder builderForValue) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.set(index, builderForValue.build()); - onChanged(); - } else { - bucketValuesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public Builder addBucketValues(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass value) { - if (bucketValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketValuesIsMutable(); - bucketValues_.add(value); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(value); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public Builder addBucketValues( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass value) { - if (bucketValuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBucketValuesIsMutable(); - bucketValues_.add(index, value); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public Builder addBucketValues( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder builderForValue) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.add(builderForValue.build()); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public Builder addBucketValues( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder builderForValue) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.add(index, builderForValue.build()); - onChanged(); - } else { - bucketValuesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public Builder addAllBucketValues( - java.lang.Iterable values) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, bucketValues_); - onChanged(); - } else { - bucketValuesBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public Builder clearBucketValues() { - if (bucketValuesBuilder_ == null) { - bucketValues_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - bucketValuesBuilder_.clear(); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public Builder removeBucketValues(int index) { - if (bucketValuesBuilder_ == null) { - ensureBucketValuesIsMutable(); - bucketValues_.remove(index); - onChanged(); - } else { - bucketValuesBuilder_.remove(index); - } - return this; - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder getBucketValuesBuilder( - int index) { - return getBucketValuesFieldBuilder().getBuilder(index); - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClassOrBuilder getBucketValuesOrBuilder( - int index) { - if (bucketValuesBuilder_ == null) { - return bucketValues_.get(index); } else { - return bucketValuesBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public java.util.List - getBucketValuesOrBuilderList() { - if (bucketValuesBuilder_ != null) { - return bucketValuesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(bucketValues_); - } - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder addBucketValuesBuilder() { - return getBucketValuesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.getDefaultInstance()); - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder addBucketValuesBuilder( - int index) { - return getBucketValuesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.getDefaultInstance()); - } - /** - *
-         * Sample of equivalence classes in this bucket. The total number of
-         * classes returned per bucket is capped at 20.
-         * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass bucket_values = 4; - */ - public java.util.List - getBucketValuesBuilderList() { - return getBucketValuesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClassOrBuilder> - getBucketValuesFieldBuilder() { - if (bucketValuesBuilder_ == null) { - bucketValuesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClass.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityEquivalenceClassOrBuilder>( - bucketValues_, - ((bitField0_ & 0x00000008) == 0x00000008), - getParentForChildren(), - isClean()); - bucketValues_ = null; - } - return bucketValuesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public LDiversityHistogramBucket parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new LDiversityHistogramBucket(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public static final int SENSITIVE_VALUE_FREQUENCY_HISTOGRAM_BUCKETS_FIELD_NUMBER = 5; - private java.util.List sensitiveValueFrequencyHistogramBuckets_; - /** - *
-     * Histogram of l-diversity equivalence class sensitive value frequencies.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public java.util.List getSensitiveValueFrequencyHistogramBucketsList() { - return sensitiveValueFrequencyHistogramBuckets_; - } - /** - *
-     * Histogram of l-diversity equivalence class sensitive value frequencies.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public java.util.List - getSensitiveValueFrequencyHistogramBucketsOrBuilderList() { - return sensitiveValueFrequencyHistogramBuckets_; - } - /** - *
-     * Histogram of l-diversity equivalence class sensitive value frequencies.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public int getSensitiveValueFrequencyHistogramBucketsCount() { - return sensitiveValueFrequencyHistogramBuckets_.size(); - } - /** - *
-     * Histogram of l-diversity equivalence class sensitive value frequencies.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket getSensitiveValueFrequencyHistogramBuckets(int index) { - return sensitiveValueFrequencyHistogramBuckets_.get(index); - } - /** - *
-     * Histogram of l-diversity equivalence class sensitive value frequencies.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucketOrBuilder getSensitiveValueFrequencyHistogramBucketsOrBuilder( - int index) { - return sensitiveValueFrequencyHistogramBuckets_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < sensitiveValueFrequencyHistogramBuckets_.size(); i++) { - output.writeMessage(5, sensitiveValueFrequencyHistogramBuckets_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < sensitiveValueFrequencyHistogramBuckets_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, sensitiveValueFrequencyHistogramBuckets_.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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) obj; - - boolean result = true; - result = result && getSensitiveValueFrequencyHistogramBucketsList() - .equals(other.getSensitiveValueFrequencyHistogramBucketsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getSensitiveValueFrequencyHistogramBucketsCount() > 0) { - hash = (37 * hash) + SENSITIVE_VALUE_FREQUENCY_HISTOGRAM_BUCKETS_FIELD_NUMBER; - hash = (53 * hash) + getSensitiveValueFrequencyHistogramBucketsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-     * Result of the l-diversity computation.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResultOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getSensitiveValueFrequencyHistogramBucketsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - sensitiveValueFrequencyHistogramBuckets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_LDiversityResult_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult(this); - int from_bitField0_ = bitField0_; - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - sensitiveValueFrequencyHistogramBuckets_ = java.util.Collections.unmodifiableList(sensitiveValueFrequencyHistogramBuckets_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.sensitiveValueFrequencyHistogramBuckets_ = sensitiveValueFrequencyHistogramBuckets_; - } else { - result.sensitiveValueFrequencyHistogramBuckets_ = sensitiveValueFrequencyHistogramBucketsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.getDefaultInstance()) return this; - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - if (!other.sensitiveValueFrequencyHistogramBuckets_.isEmpty()) { - if (sensitiveValueFrequencyHistogramBuckets_.isEmpty()) { - sensitiveValueFrequencyHistogramBuckets_ = other.sensitiveValueFrequencyHistogramBuckets_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureSensitiveValueFrequencyHistogramBucketsIsMutable(); - sensitiveValueFrequencyHistogramBuckets_.addAll(other.sensitiveValueFrequencyHistogramBuckets_); - } - onChanged(); - } - } else { - if (!other.sensitiveValueFrequencyHistogramBuckets_.isEmpty()) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_.isEmpty()) { - sensitiveValueFrequencyHistogramBucketsBuilder_.dispose(); - sensitiveValueFrequencyHistogramBucketsBuilder_ = null; - sensitiveValueFrequencyHistogramBuckets_ = other.sensitiveValueFrequencyHistogramBuckets_; - bitField0_ = (bitField0_ & ~0x00000001); - sensitiveValueFrequencyHistogramBucketsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getSensitiveValueFrequencyHistogramBucketsFieldBuilder() : null; - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.addAllMessages(other.sensitiveValueFrequencyHistogramBuckets_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List sensitiveValueFrequencyHistogramBuckets_ = - java.util.Collections.emptyList(); - private void ensureSensitiveValueFrequencyHistogramBucketsIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - sensitiveValueFrequencyHistogramBuckets_ = new java.util.ArrayList(sensitiveValueFrequencyHistogramBuckets_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucketOrBuilder> sensitiveValueFrequencyHistogramBucketsBuilder_; - - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public java.util.List getSensitiveValueFrequencyHistogramBucketsList() { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - return java.util.Collections.unmodifiableList(sensitiveValueFrequencyHistogramBuckets_); - } else { - return sensitiveValueFrequencyHistogramBucketsBuilder_.getMessageList(); - } - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public int getSensitiveValueFrequencyHistogramBucketsCount() { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - return sensitiveValueFrequencyHistogramBuckets_.size(); - } else { - return sensitiveValueFrequencyHistogramBucketsBuilder_.getCount(); - } - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket getSensitiveValueFrequencyHistogramBuckets(int index) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - return sensitiveValueFrequencyHistogramBuckets_.get(index); - } else { - return sensitiveValueFrequencyHistogramBucketsBuilder_.getMessage(index); - } - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public Builder setSensitiveValueFrequencyHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket value) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSensitiveValueFrequencyHistogramBucketsIsMutable(); - sensitiveValueFrequencyHistogramBuckets_.set(index, value); - onChanged(); - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public Builder setSensitiveValueFrequencyHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder builderForValue) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - ensureSensitiveValueFrequencyHistogramBucketsIsMutable(); - sensitiveValueFrequencyHistogramBuckets_.set(index, builderForValue.build()); - onChanged(); - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public Builder addSensitiveValueFrequencyHistogramBuckets(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket value) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSensitiveValueFrequencyHistogramBucketsIsMutable(); - sensitiveValueFrequencyHistogramBuckets_.add(value); - onChanged(); - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.addMessage(value); - } - return this; - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public Builder addSensitiveValueFrequencyHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket value) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSensitiveValueFrequencyHistogramBucketsIsMutable(); - sensitiveValueFrequencyHistogramBuckets_.add(index, value); - onChanged(); - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public Builder addSensitiveValueFrequencyHistogramBuckets( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder builderForValue) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - ensureSensitiveValueFrequencyHistogramBucketsIsMutable(); - sensitiveValueFrequencyHistogramBuckets_.add(builderForValue.build()); - onChanged(); - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public Builder addSensitiveValueFrequencyHistogramBuckets( - int index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder builderForValue) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - ensureSensitiveValueFrequencyHistogramBucketsIsMutable(); - sensitiveValueFrequencyHistogramBuckets_.add(index, builderForValue.build()); - onChanged(); - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public Builder addAllSensitiveValueFrequencyHistogramBuckets( - java.lang.Iterable values) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - ensureSensitiveValueFrequencyHistogramBucketsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, sensitiveValueFrequencyHistogramBuckets_); - onChanged(); - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public Builder clearSensitiveValueFrequencyHistogramBuckets() { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - sensitiveValueFrequencyHistogramBuckets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.clear(); - } - return this; - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public Builder removeSensitiveValueFrequencyHistogramBuckets(int index) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - ensureSensitiveValueFrequencyHistogramBucketsIsMutable(); - sensitiveValueFrequencyHistogramBuckets_.remove(index); - onChanged(); - } else { - sensitiveValueFrequencyHistogramBucketsBuilder_.remove(index); - } - return this; - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder getSensitiveValueFrequencyHistogramBucketsBuilder( - int index) { - return getSensitiveValueFrequencyHistogramBucketsFieldBuilder().getBuilder(index); - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucketOrBuilder getSensitiveValueFrequencyHistogramBucketsOrBuilder( - int index) { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - return sensitiveValueFrequencyHistogramBuckets_.get(index); } else { - return sensitiveValueFrequencyHistogramBucketsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public java.util.List - getSensitiveValueFrequencyHistogramBucketsOrBuilderList() { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ != null) { - return sensitiveValueFrequencyHistogramBucketsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(sensitiveValueFrequencyHistogramBuckets_); - } - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder addSensitiveValueFrequencyHistogramBucketsBuilder() { - return getSensitiveValueFrequencyHistogramBucketsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.getDefaultInstance()); - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder addSensitiveValueFrequencyHistogramBucketsBuilder( - int index) { - return getSensitiveValueFrequencyHistogramBucketsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.getDefaultInstance()); - } - /** - *
-       * Histogram of l-diversity equivalence class sensitive value frequencies.
-       * 
- * - * repeated .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - */ - public java.util.List - getSensitiveValueFrequencyHistogramBucketsBuilderList() { - return getSensitiveValueFrequencyHistogramBucketsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucketOrBuilder> - getSensitiveValueFrequencyHistogramBucketsFieldBuilder() { - if (sensitiveValueFrequencyHistogramBucketsBuilder_ == null) { - sensitiveValueFrequencyHistogramBucketsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucket.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.LDiversityHistogramBucketOrBuilder>( - sensitiveValueFrequencyHistogramBuckets_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - sensitiveValueFrequencyHistogramBuckets_ = null; - } - return sensitiveValueFrequencyHistogramBucketsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public LDiversityResult parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new LDiversityResult(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int resultCase_ = 0; - private java.lang.Object result_; - public enum ResultCase - implements com.google.protobuf.Internal.EnumLite { - NUMERICAL_STATS_RESULT(3), - CATEGORICAL_STATS_RESULT(4), - K_ANONYMITY_RESULT(5), - L_DIVERSITY_RESULT(6), - RESULT_NOT_SET(0); - private final int value; - private ResultCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static ResultCase valueOf(int value) { - return forNumber(value); - } - - public static ResultCase forNumber(int value) { - switch (value) { - case 3: return NUMERICAL_STATS_RESULT; - case 4: return CATEGORICAL_STATS_RESULT; - case 5: return K_ANONYMITY_RESULT; - case 6: return L_DIVERSITY_RESULT; - case 0: return RESULT_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public ResultCase - getResultCase() { - return ResultCase.forNumber( - resultCase_); - } - - public static final int NUMERICAL_STATS_RESULT_FIELD_NUMBER = 3; - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public boolean hasNumericalStatsResult() { - return resultCase_ == 3; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult getNumericalStatsResult() { - if (resultCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResultOrBuilder getNumericalStatsResultOrBuilder() { - if (resultCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.getDefaultInstance(); - } - - public static final int CATEGORICAL_STATS_RESULT_FIELD_NUMBER = 4; - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public boolean hasCategoricalStatsResult() { - return resultCase_ == 4; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult getCategoricalStatsResult() { - if (resultCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResultOrBuilder getCategoricalStatsResultOrBuilder() { - if (resultCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.getDefaultInstance(); - } - - public static final int K_ANONYMITY_RESULT_FIELD_NUMBER = 5; - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public boolean hasKAnonymityResult() { - return resultCase_ == 5; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult getKAnonymityResult() { - if (resultCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResultOrBuilder getKAnonymityResultOrBuilder() { - if (resultCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.getDefaultInstance(); - } - - public static final int L_DIVERSITY_RESULT_FIELD_NUMBER = 6; - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public boolean hasLDiversityResult() { - return resultCase_ == 6; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult getLDiversityResult() { - if (resultCase_ == 6) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.getDefaultInstance(); - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResultOrBuilder getLDiversityResultOrBuilder() { - if (resultCase_ == 6) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (resultCase_ == 3) { - output.writeMessage(3, (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) result_); - } - if (resultCase_ == 4) { - output.writeMessage(4, (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) result_); - } - if (resultCase_ == 5) { - output.writeMessage(5, (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) result_); - } - if (resultCase_ == 6) { - output.writeMessage(6, (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) result_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (resultCase_ == 3) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) result_); - } - if (resultCase_ == 4) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) result_); - } - if (resultCase_ == 5) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) result_); - } - if (resultCase_ == 6) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) result_); - } - 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult other = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult) obj; - - boolean result = true; - result = result && getResultCase().equals( - other.getResultCase()); - if (!result) return false; - switch (resultCase_) { - case 3: - result = result && getNumericalStatsResult() - .equals(other.getNumericalStatsResult()); - break; - case 4: - result = result && getCategoricalStatsResult() - .equals(other.getCategoricalStatsResult()); - break; - case 5: - result = result && getKAnonymityResult() - .equals(other.getKAnonymityResult()); - break; - case 6: - result = result && getLDiversityResult() - .equals(other.getLDiversityResult()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (resultCase_) { - case 3: - hash = (37 * hash) + NUMERICAL_STATS_RESULT_FIELD_NUMBER; - hash = (53 * hash) + getNumericalStatsResult().hashCode(); - break; - case 4: - hash = (37 * hash) + CATEGORICAL_STATS_RESULT_FIELD_NUMBER; - hash = (53 * hash) + getCategoricalStatsResult().hashCode(); - break; - case 5: - hash = (37 * hash) + K_ANONYMITY_RESULT_FIELD_NUMBER; - hash = (53 * hash) + getKAnonymityResult().hashCode(); - break; - case 6: - hash = (37 * hash) + L_DIVERSITY_RESULT_FIELD_NUMBER; - hash = (53 * hash) + getLDiversityResult().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult 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.privacy.dlp.v2beta1.RiskAnalysisOperationResult parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Result of a risk analysis
-   * [`Operation`](/dlp/docs/reference/rest/v2beta1/inspect.operations)
-   * request.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.RiskAnalysisOperationResult} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult) - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResultOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.class, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - resultCase_ = 0; - result_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_RiskAnalysisOperationResult_descriptor; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult build() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult buildPartial() { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult result = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult(this); - if (resultCase_ == 3) { - if (numericalStatsResultBuilder_ == null) { - result.result_ = result_; - } else { - result.result_ = numericalStatsResultBuilder_.build(); - } - } - if (resultCase_ == 4) { - if (categoricalStatsResultBuilder_ == null) { - result.result_ = result_; - } else { - result.result_ = categoricalStatsResultBuilder_.build(); - } - } - if (resultCase_ == 5) { - if (kAnonymityResultBuilder_ == null) { - result.result_ = result_; - } else { - result.result_ = kAnonymityResultBuilder_.build(); - } - } - if (resultCase_ == 6) { - if (lDiversityResultBuilder_ == null) { - result.result_ = result_; - } else { - result.result_ = lDiversityResultBuilder_.build(); - } - } - result.resultCase_ = resultCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult) { - return mergeFrom((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult other) { - if (other == com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.getDefaultInstance()) return this; - switch (other.getResultCase()) { - case NUMERICAL_STATS_RESULT: { - mergeNumericalStatsResult(other.getNumericalStatsResult()); - break; - } - case CATEGORICAL_STATS_RESULT: { - mergeCategoricalStatsResult(other.getCategoricalStatsResult()); - break; - } - case K_ANONYMITY_RESULT: { - mergeKAnonymityResult(other.getKAnonymityResult()); - break; - } - case L_DIVERSITY_RESULT: { - mergeLDiversityResult(other.getLDiversityResult()); - break; - } - case RESULT_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int resultCase_ = 0; - private java.lang.Object result_; - public ResultCase - getResultCase() { - return ResultCase.forNumber( - resultCase_); - } - - public Builder clearResult() { - resultCase_ = 0; - result_ = null; - onChanged(); - return this; - } - - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResultOrBuilder> numericalStatsResultBuilder_; - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public boolean hasNumericalStatsResult() { - return resultCase_ == 3; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult getNumericalStatsResult() { - if (numericalStatsResultBuilder_ == null) { - if (resultCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.getDefaultInstance(); - } else { - if (resultCase_ == 3) { - return numericalStatsResultBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public Builder setNumericalStatsResult(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult value) { - if (numericalStatsResultBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - result_ = value; - onChanged(); - } else { - numericalStatsResultBuilder_.setMessage(value); - } - resultCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public Builder setNumericalStatsResult( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.Builder builderForValue) { - if (numericalStatsResultBuilder_ == null) { - result_ = builderForValue.build(); - onChanged(); - } else { - numericalStatsResultBuilder_.setMessage(builderForValue.build()); - } - resultCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public Builder mergeNumericalStatsResult(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult value) { - if (numericalStatsResultBuilder_ == null) { - if (resultCase_ == 3 && - result_ != com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.getDefaultInstance()) { - result_ = com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.newBuilder((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) result_) - .mergeFrom(value).buildPartial(); - } else { - result_ = value; - } - onChanged(); - } else { - if (resultCase_ == 3) { - numericalStatsResultBuilder_.mergeFrom(value); - } - numericalStatsResultBuilder_.setMessage(value); - } - resultCase_ = 3; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public Builder clearNumericalStatsResult() { - if (numericalStatsResultBuilder_ == null) { - if (resultCase_ == 3) { - resultCase_ = 0; - result_ = null; - onChanged(); - } - } else { - if (resultCase_ == 3) { - resultCase_ = 0; - result_ = null; - } - numericalStatsResultBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.Builder getNumericalStatsResultBuilder() { - return getNumericalStatsResultFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResultOrBuilder getNumericalStatsResultOrBuilder() { - if ((resultCase_ == 3) && (numericalStatsResultBuilder_ != null)) { - return numericalStatsResultBuilder_.getMessageOrBuilder(); - } else { - if (resultCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResultOrBuilder> - getNumericalStatsResultFieldBuilder() { - if (numericalStatsResultBuilder_ == null) { - if (!(resultCase_ == 3)) { - result_ = com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.getDefaultInstance(); - } - numericalStatsResultBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResultOrBuilder>( - (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult) result_, - getParentForChildren(), - isClean()); - result_ = null; - } - resultCase_ = 3; - onChanged();; - return numericalStatsResultBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResultOrBuilder> categoricalStatsResultBuilder_; - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public boolean hasCategoricalStatsResult() { - return resultCase_ == 4; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult getCategoricalStatsResult() { - if (categoricalStatsResultBuilder_ == null) { - if (resultCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.getDefaultInstance(); - } else { - if (resultCase_ == 4) { - return categoricalStatsResultBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public Builder setCategoricalStatsResult(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult value) { - if (categoricalStatsResultBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - result_ = value; - onChanged(); - } else { - categoricalStatsResultBuilder_.setMessage(value); - } - resultCase_ = 4; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public Builder setCategoricalStatsResult( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.Builder builderForValue) { - if (categoricalStatsResultBuilder_ == null) { - result_ = builderForValue.build(); - onChanged(); - } else { - categoricalStatsResultBuilder_.setMessage(builderForValue.build()); - } - resultCase_ = 4; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public Builder mergeCategoricalStatsResult(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult value) { - if (categoricalStatsResultBuilder_ == null) { - if (resultCase_ == 4 && - result_ != com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.getDefaultInstance()) { - result_ = com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.newBuilder((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) result_) - .mergeFrom(value).buildPartial(); - } else { - result_ = value; - } - onChanged(); - } else { - if (resultCase_ == 4) { - categoricalStatsResultBuilder_.mergeFrom(value); - } - categoricalStatsResultBuilder_.setMessage(value); - } - resultCase_ = 4; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public Builder clearCategoricalStatsResult() { - if (categoricalStatsResultBuilder_ == null) { - if (resultCase_ == 4) { - resultCase_ = 0; - result_ = null; - onChanged(); - } - } else { - if (resultCase_ == 4) { - resultCase_ = 0; - result_ = null; - } - categoricalStatsResultBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.Builder getCategoricalStatsResultBuilder() { - return getCategoricalStatsResultFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResultOrBuilder getCategoricalStatsResultOrBuilder() { - if ((resultCase_ == 4) && (categoricalStatsResultBuilder_ != null)) { - return categoricalStatsResultBuilder_.getMessageOrBuilder(); - } else { - if (resultCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResultOrBuilder> - getCategoricalStatsResultFieldBuilder() { - if (categoricalStatsResultBuilder_ == null) { - if (!(resultCase_ == 4)) { - result_ = com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.getDefaultInstance(); - } - categoricalStatsResultBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResultOrBuilder>( - (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult) result_, - getParentForChildren(), - isClean()); - result_ = null; - } - resultCase_ = 4; - onChanged();; - return categoricalStatsResultBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResultOrBuilder> kAnonymityResultBuilder_; - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public boolean hasKAnonymityResult() { - return resultCase_ == 5; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult getKAnonymityResult() { - if (kAnonymityResultBuilder_ == null) { - if (resultCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.getDefaultInstance(); - } else { - if (resultCase_ == 5) { - return kAnonymityResultBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public Builder setKAnonymityResult(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult value) { - if (kAnonymityResultBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - result_ = value; - onChanged(); - } else { - kAnonymityResultBuilder_.setMessage(value); - } - resultCase_ = 5; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public Builder setKAnonymityResult( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.Builder builderForValue) { - if (kAnonymityResultBuilder_ == null) { - result_ = builderForValue.build(); - onChanged(); - } else { - kAnonymityResultBuilder_.setMessage(builderForValue.build()); - } - resultCase_ = 5; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public Builder mergeKAnonymityResult(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult value) { - if (kAnonymityResultBuilder_ == null) { - if (resultCase_ == 5 && - result_ != com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.getDefaultInstance()) { - result_ = com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.newBuilder((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) result_) - .mergeFrom(value).buildPartial(); - } else { - result_ = value; - } - onChanged(); - } else { - if (resultCase_ == 5) { - kAnonymityResultBuilder_.mergeFrom(value); - } - kAnonymityResultBuilder_.setMessage(value); - } - resultCase_ = 5; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public Builder clearKAnonymityResult() { - if (kAnonymityResultBuilder_ == null) { - if (resultCase_ == 5) { - resultCase_ = 0; - result_ = null; - onChanged(); - } - } else { - if (resultCase_ == 5) { - resultCase_ = 0; - result_ = null; - } - kAnonymityResultBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.Builder getKAnonymityResultBuilder() { - return getKAnonymityResultFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResultOrBuilder getKAnonymityResultOrBuilder() { - if ((resultCase_ == 5) && (kAnonymityResultBuilder_ != null)) { - return kAnonymityResultBuilder_.getMessageOrBuilder(); - } else { - if (resultCase_ == 5) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResultOrBuilder> - getKAnonymityResultFieldBuilder() { - if (kAnonymityResultBuilder_ == null) { - if (!(resultCase_ == 5)) { - result_ = com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.getDefaultInstance(); - } - kAnonymityResultBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResultOrBuilder>( - (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult) result_, - getParentForChildren(), - isClean()); - result_ = null; - } - resultCase_ = 5; - onChanged();; - return kAnonymityResultBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResultOrBuilder> lDiversityResultBuilder_; - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public boolean hasLDiversityResult() { - return resultCase_ == 6; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult getLDiversityResult() { - if (lDiversityResultBuilder_ == null) { - if (resultCase_ == 6) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.getDefaultInstance(); - } else { - if (resultCase_ == 6) { - return lDiversityResultBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public Builder setLDiversityResult(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult value) { - if (lDiversityResultBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - result_ = value; - onChanged(); - } else { - lDiversityResultBuilder_.setMessage(value); - } - resultCase_ = 6; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public Builder setLDiversityResult( - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.Builder builderForValue) { - if (lDiversityResultBuilder_ == null) { - result_ = builderForValue.build(); - onChanged(); - } else { - lDiversityResultBuilder_.setMessage(builderForValue.build()); - } - resultCase_ = 6; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public Builder mergeLDiversityResult(com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult value) { - if (lDiversityResultBuilder_ == null) { - if (resultCase_ == 6 && - result_ != com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.getDefaultInstance()) { - result_ = com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.newBuilder((com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) result_) - .mergeFrom(value).buildPartial(); - } else { - result_ = value; - } - onChanged(); - } else { - if (resultCase_ == 6) { - lDiversityResultBuilder_.mergeFrom(value); - } - lDiversityResultBuilder_.setMessage(value); - } - resultCase_ = 6; - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public Builder clearLDiversityResult() { - if (lDiversityResultBuilder_ == null) { - if (resultCase_ == 6) { - resultCase_ = 0; - result_ = null; - onChanged(); - } - } else { - if (resultCase_ == 6) { - resultCase_ = 0; - result_ = null; - } - lDiversityResultBuilder_.clear(); - } - return this; - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.Builder getLDiversityResultBuilder() { - return getLDiversityResultFieldBuilder().getBuilder(); - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResultOrBuilder getLDiversityResultOrBuilder() { - if ((resultCase_ == 6) && (lDiversityResultBuilder_ != null)) { - return lDiversityResultBuilder_.getMessageOrBuilder(); - } else { - if (resultCase_ == 6) { - return (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) result_; - } - return com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.getDefaultInstance(); - } - } - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResultOrBuilder> - getLDiversityResultFieldBuilder() { - if (lDiversityResultBuilder_ == null) { - if (!(resultCase_ == 6)) { - result_ = com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.getDefaultInstance(); - } - lDiversityResultBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult.Builder, com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResultOrBuilder>( - (com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult) result_, - getParentForChildren(), - isClean()); - result_ = null; - } - resultCase_ = 6; - onChanged();; - return lDiversityResultBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult) - private static final com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult(); - } - - public static com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public RiskAnalysisOperationResult parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new RiskAnalysisOperationResult(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationResultOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationResultOrBuilder.java deleted file mode 100644 index 2d2e02b5fae2..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/RiskAnalysisOperationResultOrBuilder.java +++ /dev/null @@ -1,63 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface RiskAnalysisOperationResultOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.RiskAnalysisOperationResult) - com.google.protobuf.MessageOrBuilder { - - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - boolean hasNumericalStatsResult(); - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult getNumericalStatsResult(); - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResult numerical_stats_result = 3; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.NumericalStatsResultOrBuilder getNumericalStatsResultOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - boolean hasCategoricalStatsResult(); - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult getCategoricalStatsResult(); - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResult categorical_stats_result = 4; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.CategoricalStatsResultOrBuilder getCategoricalStatsResultOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - boolean hasKAnonymityResult(); - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult getKAnonymityResult(); - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResult k_anonymity_result = 5; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.KAnonymityResultOrBuilder getKAnonymityResultOrBuilder(); - - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - boolean hasLDiversityResult(); - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult getLDiversityResult(); - /** - * .google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResult l_diversity_result = 6; - */ - com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.LDiversityResultOrBuilder getLDiversityResultOrBuilder(); - - public com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult.ResultCase getResultCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/StorageConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/StorageConfig.java deleted file mode 100644 index 10b6a5044e1d..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/StorageConfig.java +++ /dev/null @@ -1,1221 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Shared message indicating Cloud storage type.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.StorageConfig} - */ -public final class StorageConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.StorageConfig) - StorageConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use StorageConfig.newBuilder() to construct. - private StorageConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private StorageConfig() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private StorageConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.DatastoreOptions.Builder subBuilder = null; - if (typeCase_ == 2) { - subBuilder = ((com.google.privacy.dlp.v2beta1.DatastoreOptions) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.DatastoreOptions.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.DatastoreOptions) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 2; - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.CloudStorageOptions.Builder subBuilder = null; - if (typeCase_ == 3) { - subBuilder = ((com.google.privacy.dlp.v2beta1.CloudStorageOptions) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.CloudStorageOptions.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.CloudStorageOptions) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 3; - break; - } - case 34: { - com.google.privacy.dlp.v2beta1.BigQueryOptions.Builder subBuilder = null; - if (typeCase_ == 4) { - subBuilder = ((com.google.privacy.dlp.v2beta1.BigQueryOptions) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.privacy.dlp.v2beta1.BigQueryOptions.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.BigQueryOptions) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 4; - 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.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_StorageConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_StorageConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.StorageConfig.class, com.google.privacy.dlp.v2beta1.StorageConfig.Builder.class); - } - - private int typeCase_ = 0; - private java.lang.Object type_; - public enum TypeCase - implements com.google.protobuf.Internal.EnumLite { - DATASTORE_OPTIONS(2), - CLOUD_STORAGE_OPTIONS(3), - BIG_QUERY_OPTIONS(4), - TYPE_NOT_SET(0); - private final int value; - private TypeCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TypeCase valueOf(int value) { - return forNumber(value); - } - - public static TypeCase forNumber(int value) { - switch (value) { - case 2: return DATASTORE_OPTIONS; - case 3: return CLOUD_STORAGE_OPTIONS; - case 4: return BIG_QUERY_OPTIONS; - case 0: return TYPE_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public static final int DATASTORE_OPTIONS_FIELD_NUMBER = 2; - /** - *
-   * Google Cloud Datastore options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public boolean hasDatastoreOptions() { - return typeCase_ == 2; - } - /** - *
-   * Google Cloud Datastore options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public com.google.privacy.dlp.v2beta1.DatastoreOptions getDatastoreOptions() { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.DatastoreOptions) type_; - } - return com.google.privacy.dlp.v2beta1.DatastoreOptions.getDefaultInstance(); - } - /** - *
-   * Google Cloud Datastore options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public com.google.privacy.dlp.v2beta1.DatastoreOptionsOrBuilder getDatastoreOptionsOrBuilder() { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.DatastoreOptions) type_; - } - return com.google.privacy.dlp.v2beta1.DatastoreOptions.getDefaultInstance(); - } - - public static final int CLOUD_STORAGE_OPTIONS_FIELD_NUMBER = 3; - /** - *
-   * Google Cloud Storage options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public boolean hasCloudStorageOptions() { - return typeCase_ == 3; - } - /** - *
-   * Google Cloud Storage options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageOptions getCloudStorageOptions() { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.CloudStorageOptions) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStorageOptions.getDefaultInstance(); - } - /** - *
-   * Google Cloud Storage options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageOptionsOrBuilder getCloudStorageOptionsOrBuilder() { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.CloudStorageOptions) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStorageOptions.getDefaultInstance(); - } - - public static final int BIG_QUERY_OPTIONS_FIELD_NUMBER = 4; - /** - *
-   * BigQuery options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public boolean hasBigQueryOptions() { - return typeCase_ == 4; - } - /** - *
-   * BigQuery options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public com.google.privacy.dlp.v2beta1.BigQueryOptions getBigQueryOptions() { - if (typeCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.BigQueryOptions) type_; - } - return com.google.privacy.dlp.v2beta1.BigQueryOptions.getDefaultInstance(); - } - /** - *
-   * BigQuery options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public com.google.privacy.dlp.v2beta1.BigQueryOptionsOrBuilder getBigQueryOptionsOrBuilder() { - if (typeCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.BigQueryOptions) type_; - } - return com.google.privacy.dlp.v2beta1.BigQueryOptions.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (typeCase_ == 2) { - output.writeMessage(2, (com.google.privacy.dlp.v2beta1.DatastoreOptions) type_); - } - if (typeCase_ == 3) { - output.writeMessage(3, (com.google.privacy.dlp.v2beta1.CloudStorageOptions) type_); - } - if (typeCase_ == 4) { - output.writeMessage(4, (com.google.privacy.dlp.v2beta1.BigQueryOptions) type_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (typeCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, (com.google.privacy.dlp.v2beta1.DatastoreOptions) type_); - } - if (typeCase_ == 3) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, (com.google.privacy.dlp.v2beta1.CloudStorageOptions) type_); - } - if (typeCase_ == 4) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, (com.google.privacy.dlp.v2beta1.BigQueryOptions) type_); - } - 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.privacy.dlp.v2beta1.StorageConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.StorageConfig other = (com.google.privacy.dlp.v2beta1.StorageConfig) obj; - - boolean result = true; - result = result && getTypeCase().equals( - other.getTypeCase()); - if (!result) return false; - switch (typeCase_) { - case 2: - result = result && getDatastoreOptions() - .equals(other.getDatastoreOptions()); - break; - case 3: - result = result && getCloudStorageOptions() - .equals(other.getCloudStorageOptions()); - break; - case 4: - result = result && getBigQueryOptions() - .equals(other.getBigQueryOptions()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (typeCase_) { - case 2: - hash = (37 * hash) + DATASTORE_OPTIONS_FIELD_NUMBER; - hash = (53 * hash) + getDatastoreOptions().hashCode(); - break; - case 3: - hash = (37 * hash) + CLOUD_STORAGE_OPTIONS_FIELD_NUMBER; - hash = (53 * hash) + getCloudStorageOptions().hashCode(); - break; - case 4: - hash = (37 * hash) + BIG_QUERY_OPTIONS_FIELD_NUMBER; - hash = (53 * hash) + getBigQueryOptions().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.StorageConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.StorageConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.StorageConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.StorageConfig 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.privacy.dlp.v2beta1.StorageConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.StorageConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.StorageConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.StorageConfig 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.privacy.dlp.v2beta1.StorageConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.StorageConfig 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.privacy.dlp.v2beta1.StorageConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.StorageConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.StorageConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Shared message indicating Cloud storage type.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.StorageConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.StorageConfig) - com.google.privacy.dlp.v2beta1.StorageConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_StorageConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_StorageConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.StorageConfig.class, com.google.privacy.dlp.v2beta1.StorageConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.StorageConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - typeCase_ = 0; - type_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_StorageConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.StorageConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.StorageConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.StorageConfig build() { - com.google.privacy.dlp.v2beta1.StorageConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.StorageConfig buildPartial() { - com.google.privacy.dlp.v2beta1.StorageConfig result = new com.google.privacy.dlp.v2beta1.StorageConfig(this); - if (typeCase_ == 2) { - if (datastoreOptionsBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = datastoreOptionsBuilder_.build(); - } - } - if (typeCase_ == 3) { - if (cloudStorageOptionsBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = cloudStorageOptionsBuilder_.build(); - } - } - if (typeCase_ == 4) { - if (bigQueryOptionsBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = bigQueryOptionsBuilder_.build(); - } - } - result.typeCase_ = typeCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.StorageConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.StorageConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.StorageConfig other) { - if (other == com.google.privacy.dlp.v2beta1.StorageConfig.getDefaultInstance()) return this; - switch (other.getTypeCase()) { - case DATASTORE_OPTIONS: { - mergeDatastoreOptions(other.getDatastoreOptions()); - break; - } - case CLOUD_STORAGE_OPTIONS: { - mergeCloudStorageOptions(other.getCloudStorageOptions()); - break; - } - case BIG_QUERY_OPTIONS: { - mergeBigQueryOptions(other.getBigQueryOptions()); - break; - } - case TYPE_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.StorageConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.StorageConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int typeCase_ = 0; - private java.lang.Object type_; - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public Builder clearType() { - typeCase_ = 0; - type_ = null; - onChanged(); - return this; - } - - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DatastoreOptions, com.google.privacy.dlp.v2beta1.DatastoreOptions.Builder, com.google.privacy.dlp.v2beta1.DatastoreOptionsOrBuilder> datastoreOptionsBuilder_; - /** - *
-     * Google Cloud Datastore options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public boolean hasDatastoreOptions() { - return typeCase_ == 2; - } - /** - *
-     * Google Cloud Datastore options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public com.google.privacy.dlp.v2beta1.DatastoreOptions getDatastoreOptions() { - if (datastoreOptionsBuilder_ == null) { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.DatastoreOptions) type_; - } - return com.google.privacy.dlp.v2beta1.DatastoreOptions.getDefaultInstance(); - } else { - if (typeCase_ == 2) { - return datastoreOptionsBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.DatastoreOptions.getDefaultInstance(); - } - } - /** - *
-     * Google Cloud Datastore options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public Builder setDatastoreOptions(com.google.privacy.dlp.v2beta1.DatastoreOptions value) { - if (datastoreOptionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - datastoreOptionsBuilder_.setMessage(value); - } - typeCase_ = 2; - return this; - } - /** - *
-     * Google Cloud Datastore options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public Builder setDatastoreOptions( - com.google.privacy.dlp.v2beta1.DatastoreOptions.Builder builderForValue) { - if (datastoreOptionsBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - datastoreOptionsBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 2; - return this; - } - /** - *
-     * Google Cloud Datastore options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public Builder mergeDatastoreOptions(com.google.privacy.dlp.v2beta1.DatastoreOptions value) { - if (datastoreOptionsBuilder_ == null) { - if (typeCase_ == 2 && - type_ != com.google.privacy.dlp.v2beta1.DatastoreOptions.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.DatastoreOptions.newBuilder((com.google.privacy.dlp.v2beta1.DatastoreOptions) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 2) { - datastoreOptionsBuilder_.mergeFrom(value); - } - datastoreOptionsBuilder_.setMessage(value); - } - typeCase_ = 2; - return this; - } - /** - *
-     * Google Cloud Datastore options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public Builder clearDatastoreOptions() { - if (datastoreOptionsBuilder_ == null) { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - } - datastoreOptionsBuilder_.clear(); - } - return this; - } - /** - *
-     * Google Cloud Datastore options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public com.google.privacy.dlp.v2beta1.DatastoreOptions.Builder getDatastoreOptionsBuilder() { - return getDatastoreOptionsFieldBuilder().getBuilder(); - } - /** - *
-     * Google Cloud Datastore options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - public com.google.privacy.dlp.v2beta1.DatastoreOptionsOrBuilder getDatastoreOptionsOrBuilder() { - if ((typeCase_ == 2) && (datastoreOptionsBuilder_ != null)) { - return datastoreOptionsBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 2) { - return (com.google.privacy.dlp.v2beta1.DatastoreOptions) type_; - } - return com.google.privacy.dlp.v2beta1.DatastoreOptions.getDefaultInstance(); - } - } - /** - *
-     * Google Cloud Datastore options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DatastoreOptions, com.google.privacy.dlp.v2beta1.DatastoreOptions.Builder, com.google.privacy.dlp.v2beta1.DatastoreOptionsOrBuilder> - getDatastoreOptionsFieldBuilder() { - if (datastoreOptionsBuilder_ == null) { - if (!(typeCase_ == 2)) { - type_ = com.google.privacy.dlp.v2beta1.DatastoreOptions.getDefaultInstance(); - } - datastoreOptionsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.DatastoreOptions, com.google.privacy.dlp.v2beta1.DatastoreOptions.Builder, com.google.privacy.dlp.v2beta1.DatastoreOptionsOrBuilder>( - (com.google.privacy.dlp.v2beta1.DatastoreOptions) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 2; - onChanged();; - return datastoreOptionsBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStorageOptions, com.google.privacy.dlp.v2beta1.CloudStorageOptions.Builder, com.google.privacy.dlp.v2beta1.CloudStorageOptionsOrBuilder> cloudStorageOptionsBuilder_; - /** - *
-     * Google Cloud Storage options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public boolean hasCloudStorageOptions() { - return typeCase_ == 3; - } - /** - *
-     * Google Cloud Storage options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageOptions getCloudStorageOptions() { - if (cloudStorageOptionsBuilder_ == null) { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.CloudStorageOptions) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStorageOptions.getDefaultInstance(); - } else { - if (typeCase_ == 3) { - return cloudStorageOptionsBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.CloudStorageOptions.getDefaultInstance(); - } - } - /** - *
-     * Google Cloud Storage options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public Builder setCloudStorageOptions(com.google.privacy.dlp.v2beta1.CloudStorageOptions value) { - if (cloudStorageOptionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - cloudStorageOptionsBuilder_.setMessage(value); - } - typeCase_ = 3; - return this; - } - /** - *
-     * Google Cloud Storage options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public Builder setCloudStorageOptions( - com.google.privacy.dlp.v2beta1.CloudStorageOptions.Builder builderForValue) { - if (cloudStorageOptionsBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - cloudStorageOptionsBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 3; - return this; - } - /** - *
-     * Google Cloud Storage options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public Builder mergeCloudStorageOptions(com.google.privacy.dlp.v2beta1.CloudStorageOptions value) { - if (cloudStorageOptionsBuilder_ == null) { - if (typeCase_ == 3 && - type_ != com.google.privacy.dlp.v2beta1.CloudStorageOptions.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.CloudStorageOptions.newBuilder((com.google.privacy.dlp.v2beta1.CloudStorageOptions) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 3) { - cloudStorageOptionsBuilder_.mergeFrom(value); - } - cloudStorageOptionsBuilder_.setMessage(value); - } - typeCase_ = 3; - return this; - } - /** - *
-     * Google Cloud Storage options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public Builder clearCloudStorageOptions() { - if (cloudStorageOptionsBuilder_ == null) { - if (typeCase_ == 3) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 3) { - typeCase_ = 0; - type_ = null; - } - cloudStorageOptionsBuilder_.clear(); - } - return this; - } - /** - *
-     * Google Cloud Storage options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageOptions.Builder getCloudStorageOptionsBuilder() { - return getCloudStorageOptionsFieldBuilder().getBuilder(); - } - /** - *
-     * Google Cloud Storage options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - public com.google.privacy.dlp.v2beta1.CloudStorageOptionsOrBuilder getCloudStorageOptionsOrBuilder() { - if ((typeCase_ == 3) && (cloudStorageOptionsBuilder_ != null)) { - return cloudStorageOptionsBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 3) { - return (com.google.privacy.dlp.v2beta1.CloudStorageOptions) type_; - } - return com.google.privacy.dlp.v2beta1.CloudStorageOptions.getDefaultInstance(); - } - } - /** - *
-     * Google Cloud Storage options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStorageOptions, com.google.privacy.dlp.v2beta1.CloudStorageOptions.Builder, com.google.privacy.dlp.v2beta1.CloudStorageOptionsOrBuilder> - getCloudStorageOptionsFieldBuilder() { - if (cloudStorageOptionsBuilder_ == null) { - if (!(typeCase_ == 3)) { - type_ = com.google.privacy.dlp.v2beta1.CloudStorageOptions.getDefaultInstance(); - } - cloudStorageOptionsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.CloudStorageOptions, com.google.privacy.dlp.v2beta1.CloudStorageOptions.Builder, com.google.privacy.dlp.v2beta1.CloudStorageOptionsOrBuilder>( - (com.google.privacy.dlp.v2beta1.CloudStorageOptions) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 3; - onChanged();; - return cloudStorageOptionsBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryOptions, com.google.privacy.dlp.v2beta1.BigQueryOptions.Builder, com.google.privacy.dlp.v2beta1.BigQueryOptionsOrBuilder> bigQueryOptionsBuilder_; - /** - *
-     * BigQuery options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public boolean hasBigQueryOptions() { - return typeCase_ == 4; - } - /** - *
-     * BigQuery options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public com.google.privacy.dlp.v2beta1.BigQueryOptions getBigQueryOptions() { - if (bigQueryOptionsBuilder_ == null) { - if (typeCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.BigQueryOptions) type_; - } - return com.google.privacy.dlp.v2beta1.BigQueryOptions.getDefaultInstance(); - } else { - if (typeCase_ == 4) { - return bigQueryOptionsBuilder_.getMessage(); - } - return com.google.privacy.dlp.v2beta1.BigQueryOptions.getDefaultInstance(); - } - } - /** - *
-     * BigQuery options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public Builder setBigQueryOptions(com.google.privacy.dlp.v2beta1.BigQueryOptions value) { - if (bigQueryOptionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - bigQueryOptionsBuilder_.setMessage(value); - } - typeCase_ = 4; - return this; - } - /** - *
-     * BigQuery options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public Builder setBigQueryOptions( - com.google.privacy.dlp.v2beta1.BigQueryOptions.Builder builderForValue) { - if (bigQueryOptionsBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - bigQueryOptionsBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 4; - return this; - } - /** - *
-     * BigQuery options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public Builder mergeBigQueryOptions(com.google.privacy.dlp.v2beta1.BigQueryOptions value) { - if (bigQueryOptionsBuilder_ == null) { - if (typeCase_ == 4 && - type_ != com.google.privacy.dlp.v2beta1.BigQueryOptions.getDefaultInstance()) { - type_ = com.google.privacy.dlp.v2beta1.BigQueryOptions.newBuilder((com.google.privacy.dlp.v2beta1.BigQueryOptions) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 4) { - bigQueryOptionsBuilder_.mergeFrom(value); - } - bigQueryOptionsBuilder_.setMessage(value); - } - typeCase_ = 4; - return this; - } - /** - *
-     * BigQuery options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public Builder clearBigQueryOptions() { - if (bigQueryOptionsBuilder_ == null) { - if (typeCase_ == 4) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 4) { - typeCase_ = 0; - type_ = null; - } - bigQueryOptionsBuilder_.clear(); - } - return this; - } - /** - *
-     * BigQuery options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public com.google.privacy.dlp.v2beta1.BigQueryOptions.Builder getBigQueryOptionsBuilder() { - return getBigQueryOptionsFieldBuilder().getBuilder(); - } - /** - *
-     * BigQuery options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - public com.google.privacy.dlp.v2beta1.BigQueryOptionsOrBuilder getBigQueryOptionsOrBuilder() { - if ((typeCase_ == 4) && (bigQueryOptionsBuilder_ != null)) { - return bigQueryOptionsBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 4) { - return (com.google.privacy.dlp.v2beta1.BigQueryOptions) type_; - } - return com.google.privacy.dlp.v2beta1.BigQueryOptions.getDefaultInstance(); - } - } - /** - *
-     * BigQuery options specification.
-     * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryOptions, com.google.privacy.dlp.v2beta1.BigQueryOptions.Builder, com.google.privacy.dlp.v2beta1.BigQueryOptionsOrBuilder> - getBigQueryOptionsFieldBuilder() { - if (bigQueryOptionsBuilder_ == null) { - if (!(typeCase_ == 4)) { - type_ = com.google.privacy.dlp.v2beta1.BigQueryOptions.getDefaultInstance(); - } - bigQueryOptionsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.BigQueryOptions, com.google.privacy.dlp.v2beta1.BigQueryOptions.Builder, com.google.privacy.dlp.v2beta1.BigQueryOptionsOrBuilder>( - (com.google.privacy.dlp.v2beta1.BigQueryOptions) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 4; - onChanged();; - return bigQueryOptionsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.StorageConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.StorageConfig) - private static final com.google.privacy.dlp.v2beta1.StorageConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.StorageConfig(); - } - - public static com.google.privacy.dlp.v2beta1.StorageConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public StorageConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new StorageConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.StorageConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/StorageConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/StorageConfigOrBuilder.java deleted file mode 100644 index 53f9479228b9..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/StorageConfigOrBuilder.java +++ /dev/null @@ -1,86 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto - -package com.google.privacy.dlp.v2beta1; - -public interface StorageConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.StorageConfig) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Google Cloud Datastore options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - boolean hasDatastoreOptions(); - /** - *
-   * Google Cloud Datastore options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - com.google.privacy.dlp.v2beta1.DatastoreOptions getDatastoreOptions(); - /** - *
-   * Google Cloud Datastore options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.DatastoreOptions datastore_options = 2; - */ - com.google.privacy.dlp.v2beta1.DatastoreOptionsOrBuilder getDatastoreOptionsOrBuilder(); - - /** - *
-   * Google Cloud Storage options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - boolean hasCloudStorageOptions(); - /** - *
-   * Google Cloud Storage options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - com.google.privacy.dlp.v2beta1.CloudStorageOptions getCloudStorageOptions(); - /** - *
-   * Google Cloud Storage options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.CloudStorageOptions cloud_storage_options = 3; - */ - com.google.privacy.dlp.v2beta1.CloudStorageOptionsOrBuilder getCloudStorageOptionsOrBuilder(); - - /** - *
-   * BigQuery options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - boolean hasBigQueryOptions(); - /** - *
-   * BigQuery options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - com.google.privacy.dlp.v2beta1.BigQueryOptions getBigQueryOptions(); - /** - *
-   * BigQuery options specification.
-   * 
- * - * .google.privacy.dlp.v2beta1.BigQueryOptions big_query_options = 4; - */ - com.google.privacy.dlp.v2beta1.BigQueryOptionsOrBuilder getBigQueryOptionsOrBuilder(); - - public com.google.privacy.dlp.v2beta1.StorageConfig.TypeCase getTypeCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Table.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Table.java deleted file mode 100644 index cf0e775e57ac..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Table.java +++ /dev/null @@ -1,1842 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Structured content to inspect. Up to 50,000 `Value`s per request allowed.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Table} - */ -public final class Table extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.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() { - headers_ = java.util.Collections.emptyList(); - rows_ = java.util.Collections.emptyList(); - } - - @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(); - } - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - headers_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - headers_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry)); - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - rows_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - rows_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.Table.Row.parser(), extensionRegistry)); - 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) == 0x00000001)) { - headers_ = java.util.Collections.unmodifiableList(headers_); - } - if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { - rows_ = java.util.Collections.unmodifiableList(rows_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Table_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Table_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Table.class, com.google.privacy.dlp.v2beta1.Table.Builder.class); - } - - public interface RowOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.Table.Row) - com.google.protobuf.MessageOrBuilder { - - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - java.util.List - getValuesList(); - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - com.google.privacy.dlp.v2beta1.Value getValues(int index); - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - int getValuesCount(); - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - java.util.List - getValuesOrBuilderList(); - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getValuesOrBuilder( - int index); - } - /** - * Protobuf type {@code google.privacy.dlp.v2beta1.Table.Row} - */ - public static final class Row extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.Table.Row) - RowOrBuilder { - private static final long serialVersionUID = 0L; - // Use Row.newBuilder() to construct. - private Row(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Row() { - values_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Row( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - values_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - values_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry)); - 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) == 0x00000001)) { - values_ = java.util.Collections.unmodifiableList(values_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Table_Row_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Table_Row_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Table.Row.class, com.google.privacy.dlp.v2beta1.Table.Row.Builder.class); - } - - public static final int VALUES_FIELD_NUMBER = 1; - private java.util.List values_; - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public java.util.List getValuesList() { - return values_; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public java.util.List - getValuesOrBuilderList() { - return values_; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public int getValuesCount() { - return values_.size(); - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getValues(int index) { - return values_.get(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getValuesOrBuilder( - int index) { - return values_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < values_.size(); i++) { - output.writeMessage(1, values_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < values_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, values_.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.privacy.dlp.v2beta1.Table.Row)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.Table.Row other = (com.google.privacy.dlp.v2beta1.Table.Row) obj; - - boolean result = true; - result = result && getValuesList() - .equals(other.getValuesList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getValuesCount() > 0) { - hash = (37 * hash) + VALUES_FIELD_NUMBER; - hash = (53 * hash) + getValuesList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.Table.Row parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Table.Row parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Table.Row parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Table.Row 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.privacy.dlp.v2beta1.Table.Row parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Table.Row parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Table.Row parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Table.Row 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.privacy.dlp.v2beta1.Table.Row parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Table.Row 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.privacy.dlp.v2beta1.Table.Row parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Table.Row parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.Table.Row prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - * Protobuf type {@code google.privacy.dlp.v2beta1.Table.Row} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.Table.Row) - com.google.privacy.dlp.v2beta1.Table.RowOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Table_Row_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Table_Row_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Table.Row.class, com.google.privacy.dlp.v2beta1.Table.Row.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.Table.Row.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getValuesFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (valuesBuilder_ == null) { - values_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - valuesBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Table_Row_descriptor; - } - - public com.google.privacy.dlp.v2beta1.Table.Row getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.Table.Row.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.Table.Row build() { - com.google.privacy.dlp.v2beta1.Table.Row result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.Table.Row buildPartial() { - com.google.privacy.dlp.v2beta1.Table.Row result = new com.google.privacy.dlp.v2beta1.Table.Row(this); - int from_bitField0_ = bitField0_; - if (valuesBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - values_ = java.util.Collections.unmodifiableList(values_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.values_ = values_; - } else { - result.values_ = valuesBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.Table.Row) { - return mergeFrom((com.google.privacy.dlp.v2beta1.Table.Row)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.Table.Row other) { - if (other == com.google.privacy.dlp.v2beta1.Table.Row.getDefaultInstance()) return this; - if (valuesBuilder_ == null) { - if (!other.values_.isEmpty()) { - if (values_.isEmpty()) { - values_ = other.values_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureValuesIsMutable(); - values_.addAll(other.values_); - } - onChanged(); - } - } else { - if (!other.values_.isEmpty()) { - if (valuesBuilder_.isEmpty()) { - valuesBuilder_.dispose(); - valuesBuilder_ = null; - values_ = other.values_; - bitField0_ = (bitField0_ & ~0x00000001); - valuesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getValuesFieldBuilder() : null; - } else { - valuesBuilder_.addAllMessages(other.values_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.Table.Row parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.Table.Row) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List values_ = - java.util.Collections.emptyList(); - private void ensureValuesIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - values_ = new java.util.ArrayList(values_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> valuesBuilder_; - - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public java.util.List getValuesList() { - if (valuesBuilder_ == null) { - return java.util.Collections.unmodifiableList(values_); - } else { - return valuesBuilder_.getMessageList(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public int getValuesCount() { - if (valuesBuilder_ == null) { - return values_.size(); - } else { - return valuesBuilder_.getCount(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getValues(int index) { - if (valuesBuilder_ == null) { - return values_.get(index); - } else { - return valuesBuilder_.getMessage(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public Builder setValues( - int index, com.google.privacy.dlp.v2beta1.Value value) { - if (valuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureValuesIsMutable(); - values_.set(index, value); - onChanged(); - } else { - valuesBuilder_.setMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public Builder setValues( - int index, com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (valuesBuilder_ == null) { - ensureValuesIsMutable(); - values_.set(index, builderForValue.build()); - onChanged(); - } else { - valuesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public Builder addValues(com.google.privacy.dlp.v2beta1.Value value) { - if (valuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureValuesIsMutable(); - values_.add(value); - onChanged(); - } else { - valuesBuilder_.addMessage(value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public Builder addValues( - int index, com.google.privacy.dlp.v2beta1.Value value) { - if (valuesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureValuesIsMutable(); - values_.add(index, value); - onChanged(); - } else { - valuesBuilder_.addMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public Builder addValues( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (valuesBuilder_ == null) { - ensureValuesIsMutable(); - values_.add(builderForValue.build()); - onChanged(); - } else { - valuesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public Builder addValues( - int index, com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (valuesBuilder_ == null) { - ensureValuesIsMutable(); - values_.add(index, builderForValue.build()); - onChanged(); - } else { - valuesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public Builder addAllValues( - java.lang.Iterable values) { - if (valuesBuilder_ == null) { - ensureValuesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, values_); - onChanged(); - } else { - valuesBuilder_.addAllMessages(values); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public Builder clearValues() { - if (valuesBuilder_ == null) { - values_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - valuesBuilder_.clear(); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public Builder removeValues(int index) { - if (valuesBuilder_ == null) { - ensureValuesIsMutable(); - values_.remove(index); - onChanged(); - } else { - valuesBuilder_.remove(index); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getValuesBuilder( - int index) { - return getValuesFieldBuilder().getBuilder(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getValuesOrBuilder( - int index) { - if (valuesBuilder_ == null) { - return values_.get(index); } else { - return valuesBuilder_.getMessageOrBuilder(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public java.util.List - getValuesOrBuilderList() { - if (valuesBuilder_ != null) { - return valuesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(values_); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder addValuesBuilder() { - return getValuesFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder addValuesBuilder( - int index) { - return getValuesFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.Value.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.Value values = 1; - */ - public java.util.List - getValuesBuilderList() { - return getValuesFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getValuesFieldBuilder() { - if (valuesBuilder_ == null) { - valuesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - values_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - values_ = null; - } - return valuesBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.Table.Row) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.Table.Row) - private static final com.google.privacy.dlp.v2beta1.Table.Row DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.Table.Row(); - } - - public static com.google.privacy.dlp.v2beta1.Table.Row getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Row parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Row(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.Table.Row getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - public static final int HEADERS_FIELD_NUMBER = 1; - private java.util.List headers_; - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public java.util.List getHeadersList() { - return headers_; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public java.util.List - getHeadersOrBuilderList() { - return headers_; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public int getHeadersCount() { - return headers_.size(); - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getHeaders(int index) { - return headers_.get(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getHeadersOrBuilder( - int index) { - return headers_.get(index); - } - - public static final int ROWS_FIELD_NUMBER = 2; - private java.util.List rows_; - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public java.util.List getRowsList() { - return rows_; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public java.util.List - getRowsOrBuilderList() { - return rows_; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public int getRowsCount() { - return rows_.size(); - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public com.google.privacy.dlp.v2beta1.Table.Row getRows(int index) { - return rows_.get(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public com.google.privacy.dlp.v2beta1.Table.RowOrBuilder getRowsOrBuilder( - int index) { - return rows_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - for (int i = 0; i < headers_.size(); i++) { - output.writeMessage(1, headers_.get(i)); - } - for (int i = 0; i < rows_.size(); i++) { - output.writeMessage(2, rows_.get(i)); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < headers_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, headers_.get(i)); - } - for (int i = 0; i < rows_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, rows_.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.privacy.dlp.v2beta1.Table)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.Table other = (com.google.privacy.dlp.v2beta1.Table) obj; - - boolean result = true; - result = result && getHeadersList() - .equals(other.getHeadersList()); - result = result && getRowsList() - .equals(other.getRowsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getHeadersCount() > 0) { - hash = (37 * hash) + HEADERS_FIELD_NUMBER; - hash = (53 * hash) + getHeadersList().hashCode(); - } - if (getRowsCount() > 0) { - hash = (37 * hash) + ROWS_FIELD_NUMBER; - hash = (53 * hash) + getRowsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.Table parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.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.privacy.dlp.v2beta1.Table parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.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.privacy.dlp.v2beta1.Table parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Table parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Table parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.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.privacy.dlp.v2beta1.Table parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.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.privacy.dlp.v2beta1.Table parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.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); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.Table prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Structured content to inspect. Up to 50,000 `Value`s per request allowed.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Table} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.Table) - com.google.privacy.dlp.v2beta1.TableOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Table_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Table_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Table.class, com.google.privacy.dlp.v2beta1.Table.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.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) { - getHeadersFieldBuilder(); - getRowsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (headersBuilder_ == null) { - headers_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - headersBuilder_.clear(); - } - if (rowsBuilder_ == null) { - rows_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - } else { - rowsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Table_descriptor; - } - - public com.google.privacy.dlp.v2beta1.Table getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.Table.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.Table build() { - com.google.privacy.dlp.v2beta1.Table result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.Table buildPartial() { - com.google.privacy.dlp.v2beta1.Table result = new com.google.privacy.dlp.v2beta1.Table(this); - int from_bitField0_ = bitField0_; - if (headersBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - headers_ = java.util.Collections.unmodifiableList(headers_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.headers_ = headers_; - } else { - result.headers_ = headersBuilder_.build(); - } - if (rowsBuilder_ == null) { - if (((bitField0_ & 0x00000002) == 0x00000002)) { - rows_ = java.util.Collections.unmodifiableList(rows_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.rows_ = rows_; - } else { - result.rows_ = rowsBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.Table) { - return mergeFrom((com.google.privacy.dlp.v2beta1.Table)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.Table other) { - if (other == com.google.privacy.dlp.v2beta1.Table.getDefaultInstance()) return this; - if (headersBuilder_ == null) { - if (!other.headers_.isEmpty()) { - if (headers_.isEmpty()) { - headers_ = other.headers_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureHeadersIsMutable(); - headers_.addAll(other.headers_); - } - onChanged(); - } - } else { - if (!other.headers_.isEmpty()) { - if (headersBuilder_.isEmpty()) { - headersBuilder_.dispose(); - headersBuilder_ = null; - headers_ = other.headers_; - bitField0_ = (bitField0_ & ~0x00000001); - headersBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getHeadersFieldBuilder() : null; - } else { - headersBuilder_.addAllMessages(other.headers_); - } - } - } - if (rowsBuilder_ == null) { - if (!other.rows_.isEmpty()) { - if (rows_.isEmpty()) { - rows_ = other.rows_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureRowsIsMutable(); - rows_.addAll(other.rows_); - } - onChanged(); - } - } else { - if (!other.rows_.isEmpty()) { - if (rowsBuilder_.isEmpty()) { - rowsBuilder_.dispose(); - rowsBuilder_ = null; - rows_ = other.rows_; - bitField0_ = (bitField0_ & ~0x00000002); - rowsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getRowsFieldBuilder() : null; - } else { - rowsBuilder_.addAllMessages(other.rows_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.Table parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.Table) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private java.util.List headers_ = - java.util.Collections.emptyList(); - private void ensureHeadersIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - headers_ = new java.util.ArrayList(headers_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> headersBuilder_; - - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public java.util.List getHeadersList() { - if (headersBuilder_ == null) { - return java.util.Collections.unmodifiableList(headers_); - } else { - return headersBuilder_.getMessageList(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public int getHeadersCount() { - if (headersBuilder_ == null) { - return headers_.size(); - } else { - return headersBuilder_.getCount(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId getHeaders(int index) { - if (headersBuilder_ == null) { - return headers_.get(index); - } else { - return headersBuilder_.getMessage(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public Builder setHeaders( - int index, com.google.privacy.dlp.v2beta1.FieldId value) { - if (headersBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureHeadersIsMutable(); - headers_.set(index, value); - onChanged(); - } else { - headersBuilder_.setMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public Builder setHeaders( - int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (headersBuilder_ == null) { - ensureHeadersIsMutable(); - headers_.set(index, builderForValue.build()); - onChanged(); - } else { - headersBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public Builder addHeaders(com.google.privacy.dlp.v2beta1.FieldId value) { - if (headersBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureHeadersIsMutable(); - headers_.add(value); - onChanged(); - } else { - headersBuilder_.addMessage(value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public Builder addHeaders( - int index, com.google.privacy.dlp.v2beta1.FieldId value) { - if (headersBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureHeadersIsMutable(); - headers_.add(index, value); - onChanged(); - } else { - headersBuilder_.addMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public Builder addHeaders( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (headersBuilder_ == null) { - ensureHeadersIsMutable(); - headers_.add(builderForValue.build()); - onChanged(); - } else { - headersBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public Builder addHeaders( - int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (headersBuilder_ == null) { - ensureHeadersIsMutable(); - headers_.add(index, builderForValue.build()); - onChanged(); - } else { - headersBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public Builder addAllHeaders( - java.lang.Iterable values) { - if (headersBuilder_ == null) { - ensureHeadersIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, headers_); - onChanged(); - } else { - headersBuilder_.addAllMessages(values); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public Builder clearHeaders() { - if (headersBuilder_ == null) { - headers_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - headersBuilder_.clear(); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public Builder removeHeaders(int index) { - if (headersBuilder_ == null) { - ensureHeadersIsMutable(); - headers_.remove(index); - onChanged(); - } else { - headersBuilder_.remove(index); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getHeadersBuilder( - int index) { - return getHeadersFieldBuilder().getBuilder(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getHeadersOrBuilder( - int index) { - if (headersBuilder_ == null) { - return headers_.get(index); } else { - return headersBuilder_.getMessageOrBuilder(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public java.util.List - getHeadersOrBuilderList() { - if (headersBuilder_ != null) { - return headersBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(headers_); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder addHeadersBuilder() { - return getHeadersFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder addHeadersBuilder( - int index) { - return getHeadersFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - public java.util.List - getHeadersBuilderList() { - return getHeadersFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getHeadersFieldBuilder() { - if (headersBuilder_ == null) { - headersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - headers_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - headers_ = null; - } - return headersBuilder_; - } - - private java.util.List rows_ = - java.util.Collections.emptyList(); - private void ensureRowsIsMutable() { - if (!((bitField0_ & 0x00000002) == 0x00000002)) { - rows_ = new java.util.ArrayList(rows_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Table.Row, com.google.privacy.dlp.v2beta1.Table.Row.Builder, com.google.privacy.dlp.v2beta1.Table.RowOrBuilder> rowsBuilder_; - - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public java.util.List getRowsList() { - if (rowsBuilder_ == null) { - return java.util.Collections.unmodifiableList(rows_); - } else { - return rowsBuilder_.getMessageList(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public int getRowsCount() { - if (rowsBuilder_ == null) { - return rows_.size(); - } else { - return rowsBuilder_.getCount(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public com.google.privacy.dlp.v2beta1.Table.Row getRows(int index) { - if (rowsBuilder_ == null) { - return rows_.get(index); - } else { - return rowsBuilder_.getMessage(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public Builder setRows( - int index, com.google.privacy.dlp.v2beta1.Table.Row value) { - if (rowsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRowsIsMutable(); - rows_.set(index, value); - onChanged(); - } else { - rowsBuilder_.setMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public Builder setRows( - int index, com.google.privacy.dlp.v2beta1.Table.Row.Builder builderForValue) { - if (rowsBuilder_ == null) { - ensureRowsIsMutable(); - rows_.set(index, builderForValue.build()); - onChanged(); - } else { - rowsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public Builder addRows(com.google.privacy.dlp.v2beta1.Table.Row value) { - if (rowsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRowsIsMutable(); - rows_.add(value); - onChanged(); - } else { - rowsBuilder_.addMessage(value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public Builder addRows( - int index, com.google.privacy.dlp.v2beta1.Table.Row value) { - if (rowsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureRowsIsMutable(); - rows_.add(index, value); - onChanged(); - } else { - rowsBuilder_.addMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public Builder addRows( - com.google.privacy.dlp.v2beta1.Table.Row.Builder builderForValue) { - if (rowsBuilder_ == null) { - ensureRowsIsMutable(); - rows_.add(builderForValue.build()); - onChanged(); - } else { - rowsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public Builder addRows( - int index, com.google.privacy.dlp.v2beta1.Table.Row.Builder builderForValue) { - if (rowsBuilder_ == null) { - ensureRowsIsMutable(); - rows_.add(index, builderForValue.build()); - onChanged(); - } else { - rowsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public Builder addAllRows( - java.lang.Iterable values) { - if (rowsBuilder_ == null) { - ensureRowsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, rows_); - onChanged(); - } else { - rowsBuilder_.addAllMessages(values); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public Builder clearRows() { - if (rowsBuilder_ == null) { - rows_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - rowsBuilder_.clear(); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public Builder removeRows(int index) { - if (rowsBuilder_ == null) { - ensureRowsIsMutable(); - rows_.remove(index); - onChanged(); - } else { - rowsBuilder_.remove(index); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public com.google.privacy.dlp.v2beta1.Table.Row.Builder getRowsBuilder( - int index) { - return getRowsFieldBuilder().getBuilder(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public com.google.privacy.dlp.v2beta1.Table.RowOrBuilder getRowsOrBuilder( - int index) { - if (rowsBuilder_ == null) { - return rows_.get(index); } else { - return rowsBuilder_.getMessageOrBuilder(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public java.util.List - getRowsOrBuilderList() { - if (rowsBuilder_ != null) { - return rowsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(rows_); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public com.google.privacy.dlp.v2beta1.Table.Row.Builder addRowsBuilder() { - return getRowsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.Table.Row.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public com.google.privacy.dlp.v2beta1.Table.Row.Builder addRowsBuilder( - int index) { - return getRowsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.Table.Row.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - public java.util.List - getRowsBuilderList() { - return getRowsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Table.Row, com.google.privacy.dlp.v2beta1.Table.Row.Builder, com.google.privacy.dlp.v2beta1.Table.RowOrBuilder> - getRowsFieldBuilder() { - if (rowsBuilder_ == null) { - rowsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Table.Row, com.google.privacy.dlp.v2beta1.Table.Row.Builder, com.google.privacy.dlp.v2beta1.Table.RowOrBuilder>( - rows_, - ((bitField0_ & 0x00000002) == 0x00000002), - getParentForChildren(), - isClean()); - rows_ = null; - } - return rowsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.Table) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.Table) - private static final com.google.privacy.dlp.v2beta1.Table DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.Table(); - } - - public static com.google.privacy.dlp.v2beta1.Table getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser
() { - 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; - } - - public com.google.privacy.dlp.v2beta1.Table getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TableLocation.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TableLocation.java deleted file mode 100644 index 2cff7e41e7a0..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TableLocation.java +++ /dev/null @@ -1,472 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Location of a finding within a `ContentItem.Table`.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.TableLocation} - */ -public final class TableLocation extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.TableLocation) - TableLocationOrBuilder { -private static final long serialVersionUID = 0L; - // Use TableLocation.newBuilder() to construct. - private TableLocation(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private TableLocation() { - rowIndex_ = 0L; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private TableLocation( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - - rowIndex_ = input.readInt64(); - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TableLocation_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TableLocation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.TableLocation.class, com.google.privacy.dlp.v2beta1.TableLocation.Builder.class); - } - - public static final int ROW_INDEX_FIELD_NUMBER = 1; - private long rowIndex_; - /** - *
-   * The zero-based index of the row where the finding is located.
-   * 
- * - * int64 row_index = 1; - */ - public long getRowIndex() { - return rowIndex_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (rowIndex_ != 0L) { - output.writeInt64(1, rowIndex_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (rowIndex_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(1, rowIndex_); - } - 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.privacy.dlp.v2beta1.TableLocation)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.TableLocation other = (com.google.privacy.dlp.v2beta1.TableLocation) obj; - - boolean result = true; - result = result && (getRowIndex() - == other.getRowIndex()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + ROW_INDEX_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getRowIndex()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.TableLocation parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TableLocation parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.TableLocation parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TableLocation 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.privacy.dlp.v2beta1.TableLocation parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TableLocation parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.TableLocation parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TableLocation 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.privacy.dlp.v2beta1.TableLocation parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TableLocation 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.privacy.dlp.v2beta1.TableLocation parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TableLocation parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.TableLocation prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * Location of a finding within a `ContentItem.Table`.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.TableLocation} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.TableLocation) - com.google.privacy.dlp.v2beta1.TableLocationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TableLocation_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TableLocation_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.TableLocation.class, com.google.privacy.dlp.v2beta1.TableLocation.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.TableLocation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - rowIndex_ = 0L; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TableLocation_descriptor; - } - - public com.google.privacy.dlp.v2beta1.TableLocation getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.TableLocation.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.TableLocation build() { - com.google.privacy.dlp.v2beta1.TableLocation result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.TableLocation buildPartial() { - com.google.privacy.dlp.v2beta1.TableLocation result = new com.google.privacy.dlp.v2beta1.TableLocation(this); - result.rowIndex_ = rowIndex_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.TableLocation) { - return mergeFrom((com.google.privacy.dlp.v2beta1.TableLocation)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.TableLocation other) { - if (other == com.google.privacy.dlp.v2beta1.TableLocation.getDefaultInstance()) return this; - if (other.getRowIndex() != 0L) { - setRowIndex(other.getRowIndex()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.TableLocation parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.TableLocation) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private long rowIndex_ ; - /** - *
-     * The zero-based index of the row where the finding is located.
-     * 
- * - * int64 row_index = 1; - */ - public long getRowIndex() { - return rowIndex_; - } - /** - *
-     * The zero-based index of the row where the finding is located.
-     * 
- * - * int64 row_index = 1; - */ - public Builder setRowIndex(long value) { - - rowIndex_ = value; - onChanged(); - return this; - } - /** - *
-     * The zero-based index of the row where the finding is located.
-     * 
- * - * int64 row_index = 1; - */ - public Builder clearRowIndex() { - - rowIndex_ = 0L; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.TableLocation) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.TableLocation) - private static final com.google.privacy.dlp.v2beta1.TableLocation DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.TableLocation(); - } - - public static com.google.privacy.dlp.v2beta1.TableLocation getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public TableLocation parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TableLocation(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.TableLocation getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TableLocationOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TableLocationOrBuilder.java deleted file mode 100644 index bf595a42da1a..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TableLocationOrBuilder.java +++ /dev/null @@ -1,18 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface TableLocationOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.TableLocation) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The zero-based index of the row where the finding is located.
-   * 
- * - * int64 row_index = 1; - */ - long getRowIndex(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TableOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TableOrBuilder.java deleted file mode 100644 index 8e376727779e..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TableOrBuilder.java +++ /dev/null @@ -1,57 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface TableOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.Table) - com.google.protobuf.MessageOrBuilder { - - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - java.util.List - getHeadersList(); - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - com.google.privacy.dlp.v2beta1.FieldId getHeaders(int index); - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - int getHeadersCount(); - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - java.util.List - getHeadersOrBuilderList(); - /** - * repeated .google.privacy.dlp.v2beta1.FieldId headers = 1; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getHeadersOrBuilder( - int index); - - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - java.util.List - getRowsList(); - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - com.google.privacy.dlp.v2beta1.Table.Row getRows(int index); - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - int getRowsCount(); - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - java.util.List - getRowsOrBuilderList(); - /** - * repeated .google.privacy.dlp.v2beta1.Table.Row rows = 2; - */ - com.google.privacy.dlp.v2beta1.Table.RowOrBuilder getRowsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TimePartConfig.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TimePartConfig.java deleted file mode 100644 index 4e7934f44e54..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TimePartConfig.java +++ /dev/null @@ -1,673 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * For use with `Date`, `Timestamp`, and `TimeOfDay`, extract or preserve a
- * portion of the value.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.TimePartConfig} - */ -public final class TimePartConfig extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.TimePartConfig) - TimePartConfigOrBuilder { -private static final long serialVersionUID = 0L; - // Use TimePartConfig.newBuilder() to construct. - private TimePartConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private TimePartConfig() { - partToExtract_ = 0; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private TimePartConfig( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - int rawValue = input.readEnum(); - - partToExtract_ = rawValue; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TimePartConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TimePartConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.TimePartConfig.class, com.google.privacy.dlp.v2beta1.TimePartConfig.Builder.class); - } - - /** - * Protobuf enum {@code google.privacy.dlp.v2beta1.TimePartConfig.TimePart} - */ - public enum TimePart - implements com.google.protobuf.ProtocolMessageEnum { - /** - * TIME_PART_UNSPECIFIED = 0; - */ - TIME_PART_UNSPECIFIED(0), - /** - *
-     * [000-9999]
-     * 
- * - * YEAR = 1; - */ - YEAR(1), - /** - *
-     * [1-12]
-     * 
- * - * MONTH = 2; - */ - MONTH(2), - /** - *
-     * [1-31]
-     * 
- * - * DAY_OF_MONTH = 3; - */ - DAY_OF_MONTH(3), - /** - *
-     * [1-7]
-     * 
- * - * DAY_OF_WEEK = 4; - */ - DAY_OF_WEEK(4), - /** - *
-     * [1-52]
-     * 
- * - * WEEK_OF_YEAR = 5; - */ - WEEK_OF_YEAR(5), - /** - *
-     * [0-24]
-     * 
- * - * HOUR_OF_DAY = 6; - */ - HOUR_OF_DAY(6), - UNRECOGNIZED(-1), - ; - - /** - * TIME_PART_UNSPECIFIED = 0; - */ - public static final int TIME_PART_UNSPECIFIED_VALUE = 0; - /** - *
-     * [000-9999]
-     * 
- * - * YEAR = 1; - */ - public static final int YEAR_VALUE = 1; - /** - *
-     * [1-12]
-     * 
- * - * MONTH = 2; - */ - public static final int MONTH_VALUE = 2; - /** - *
-     * [1-31]
-     * 
- * - * DAY_OF_MONTH = 3; - */ - public static final int DAY_OF_MONTH_VALUE = 3; - /** - *
-     * [1-7]
-     * 
- * - * DAY_OF_WEEK = 4; - */ - public static final int DAY_OF_WEEK_VALUE = 4; - /** - *
-     * [1-52]
-     * 
- * - * WEEK_OF_YEAR = 5; - */ - public static final int WEEK_OF_YEAR_VALUE = 5; - /** - *
-     * [0-24]
-     * 
- * - * HOUR_OF_DAY = 6; - */ - public static final int HOUR_OF_DAY_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; - } - - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TimePart valueOf(int value) { - return forNumber(value); - } - - public static TimePart forNumber(int value) { - switch (value) { - case 0: return TIME_PART_UNSPECIFIED; - case 1: return YEAR; - case 2: return MONTH; - case 3: return DAY_OF_MONTH; - case 4: return DAY_OF_WEEK; - case 5: return WEEK_OF_YEAR; - case 6: return HOUR_OF_DAY; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - private static final com.google.protobuf.Internal.EnumLiteMap< - TimePart> internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public TimePart findValueByNumber(int number) { - return TimePart.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - 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.privacy.dlp.v2beta1.TimePartConfig.getDescriptor().getEnumTypes().get(0); - } - - private static final TimePart[] VALUES = values(); - - public static TimePart 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 TimePart(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.privacy.dlp.v2beta1.TimePartConfig.TimePart) - } - - public static final int PART_TO_EXTRACT_FIELD_NUMBER = 1; - private int partToExtract_; - /** - * .google.privacy.dlp.v2beta1.TimePartConfig.TimePart part_to_extract = 1; - */ - public int getPartToExtractValue() { - return partToExtract_; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig.TimePart part_to_extract = 1; - */ - public com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart getPartToExtract() { - com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart result = com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart.valueOf(partToExtract_); - return result == null ? com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart.UNRECOGNIZED : result; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (partToExtract_ != com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart.TIME_PART_UNSPECIFIED.getNumber()) { - output.writeEnum(1, partToExtract_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (partToExtract_ != com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart.TIME_PART_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(1, partToExtract_); - } - 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.privacy.dlp.v2beta1.TimePartConfig)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.TimePartConfig other = (com.google.privacy.dlp.v2beta1.TimePartConfig) obj; - - boolean result = true; - result = result && partToExtract_ == other.partToExtract_; - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PART_TO_EXTRACT_FIELD_NUMBER; - hash = (53 * hash) + partToExtract_; - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.TimePartConfig parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TimePartConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.TimePartConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TimePartConfig 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.privacy.dlp.v2beta1.TimePartConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TimePartConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.TimePartConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TimePartConfig 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.privacy.dlp.v2beta1.TimePartConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TimePartConfig 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.privacy.dlp.v2beta1.TimePartConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TimePartConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.TimePartConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * For use with `Date`, `Timestamp`, and `TimeOfDay`, extract or preserve a
-   * portion of the value.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.TimePartConfig} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.TimePartConfig) - com.google.privacy.dlp.v2beta1.TimePartConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TimePartConfig_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TimePartConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.TimePartConfig.class, com.google.privacy.dlp.v2beta1.TimePartConfig.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.TimePartConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - partToExtract_ = 0; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TimePartConfig_descriptor; - } - - public com.google.privacy.dlp.v2beta1.TimePartConfig getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.TimePartConfig.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.TimePartConfig build() { - com.google.privacy.dlp.v2beta1.TimePartConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.TimePartConfig buildPartial() { - com.google.privacy.dlp.v2beta1.TimePartConfig result = new com.google.privacy.dlp.v2beta1.TimePartConfig(this); - result.partToExtract_ = partToExtract_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.TimePartConfig) { - return mergeFrom((com.google.privacy.dlp.v2beta1.TimePartConfig)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.TimePartConfig other) { - if (other == com.google.privacy.dlp.v2beta1.TimePartConfig.getDefaultInstance()) return this; - if (other.partToExtract_ != 0) { - setPartToExtractValue(other.getPartToExtractValue()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.TimePartConfig parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.TimePartConfig) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int partToExtract_ = 0; - /** - * .google.privacy.dlp.v2beta1.TimePartConfig.TimePart part_to_extract = 1; - */ - public int getPartToExtractValue() { - return partToExtract_; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig.TimePart part_to_extract = 1; - */ - public Builder setPartToExtractValue(int value) { - partToExtract_ = value; - onChanged(); - return this; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig.TimePart part_to_extract = 1; - */ - public com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart getPartToExtract() { - com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart result = com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart.valueOf(partToExtract_); - return result == null ? com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart.UNRECOGNIZED : result; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig.TimePart part_to_extract = 1; - */ - public Builder setPartToExtract(com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart value) { - if (value == null) { - throw new NullPointerException(); - } - - partToExtract_ = value.getNumber(); - onChanged(); - return this; - } - /** - * .google.privacy.dlp.v2beta1.TimePartConfig.TimePart part_to_extract = 1; - */ - public Builder clearPartToExtract() { - - partToExtract_ = 0; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.TimePartConfig) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.TimePartConfig) - private static final com.google.privacy.dlp.v2beta1.TimePartConfig DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.TimePartConfig(); - } - - public static com.google.privacy.dlp.v2beta1.TimePartConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public TimePartConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TimePartConfig(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.TimePartConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TimePartConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TimePartConfigOrBuilder.java deleted file mode 100644 index 2195c30a96c5..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TimePartConfigOrBuilder.java +++ /dev/null @@ -1,18 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface TimePartConfigOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.TimePartConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * .google.privacy.dlp.v2beta1.TimePartConfig.TimePart part_to_extract = 1; - */ - int getPartToExtractValue(); - /** - * .google.privacy.dlp.v2beta1.TimePartConfig.TimePart part_to_extract = 1; - */ - com.google.privacy.dlp.v2beta1.TimePartConfig.TimePart getPartToExtract(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransformationSummary.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransformationSummary.java deleted file mode 100644 index 4f263250a028..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransformationSummary.java +++ /dev/null @@ -1,2966 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Summary of a single tranformation.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.TransformationSummary} - */ -public final class TransformationSummary extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.TransformationSummary) - TransformationSummaryOrBuilder { -private static final long serialVersionUID = 0L; - // Use TransformationSummary.newBuilder() to construct. - private TransformationSummary(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private TransformationSummary() { - fieldTransformations_ = java.util.Collections.emptyList(); - results_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private TransformationSummary( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.InfoType.Builder subBuilder = null; - if (infoType_ != null) { - subBuilder = infoType_.toBuilder(); - } - infoType_ = input.readMessage(com.google.privacy.dlp.v2beta1.InfoType.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(infoType_); - infoType_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null; - if (field_ != null) { - subBuilder = field_.toBuilder(); - } - field_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(field_); - field_ = subBuilder.buildPartial(); - } - - break; - } - case 26: { - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder subBuilder = null; - if (transformation_ != null) { - subBuilder = transformation_.toBuilder(); - } - transformation_ = input.readMessage(com.google.privacy.dlp.v2beta1.PrimitiveTransformation.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(transformation_); - transformation_ = subBuilder.buildPartial(); - } - - break; - } - case 34: { - if (!((mutable_bitField0_ & 0x00000020) == 0x00000020)) { - results_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000020; - } - results_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.parser(), extensionRegistry)); - break; - } - case 42: { - if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - fieldTransformations_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - fieldTransformations_.add( - input.readMessage(com.google.privacy.dlp.v2beta1.FieldTransformation.parser(), extensionRegistry)); - break; - } - case 50: { - com.google.privacy.dlp.v2beta1.RecordSuppression.Builder subBuilder = null; - if (recordSuppress_ != null) { - subBuilder = recordSuppress_.toBuilder(); - } - recordSuppress_ = input.readMessage(com.google.privacy.dlp.v2beta1.RecordSuppression.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(recordSuppress_); - recordSuppress_ = subBuilder.buildPartial(); - } - - 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_ & 0x00000020) == 0x00000020)) { - results_ = java.util.Collections.unmodifiableList(results_); - } - if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) { - fieldTransformations_ = java.util.Collections.unmodifiableList(fieldTransformations_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransformationSummary_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransformationSummary_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.TransformationSummary.class, com.google.privacy.dlp.v2beta1.TransformationSummary.Builder.class); - } - - /** - *
-   * Possible outcomes of transformations.
-   * 
- * - * Protobuf enum {@code google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode} - */ - public enum TransformationResultCode - implements com.google.protobuf.ProtocolMessageEnum { - /** - * TRANSFORMATION_RESULT_CODE_UNSPECIFIED = 0; - */ - TRANSFORMATION_RESULT_CODE_UNSPECIFIED(0), - /** - * SUCCESS = 1; - */ - SUCCESS(1), - /** - * ERROR = 2; - */ - ERROR(2), - UNRECOGNIZED(-1), - ; - - /** - * TRANSFORMATION_RESULT_CODE_UNSPECIFIED = 0; - */ - public static final int TRANSFORMATION_RESULT_CODE_UNSPECIFIED_VALUE = 0; - /** - * SUCCESS = 1; - */ - public static final int SUCCESS_VALUE = 1; - /** - * ERROR = 2; - */ - public static final int ERROR_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; - } - - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TransformationResultCode valueOf(int value) { - return forNumber(value); - } - - public static TransformationResultCode forNumber(int value) { - switch (value) { - case 0: return TRANSFORMATION_RESULT_CODE_UNSPECIFIED; - case 1: return SUCCESS; - case 2: return ERROR; - default: return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - private static final com.google.protobuf.Internal.EnumLiteMap< - TransformationResultCode> internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public TransformationResultCode findValueByNumber(int number) { - return TransformationResultCode.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { - 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.privacy.dlp.v2beta1.TransformationSummary.getDescriptor().getEnumTypes().get(0); - } - - private static final TransformationResultCode[] VALUES = values(); - - public static TransformationResultCode 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 TransformationResultCode(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode) - } - - public interface SummaryResultOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult) - com.google.protobuf.MessageOrBuilder { - - /** - * int64 count = 1; - */ - long getCount(); - - /** - * .google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode code = 2; - */ - int getCodeValue(); - /** - * .google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode code = 2; - */ - com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode getCode(); - - /** - *
-     * A place for warnings or errors to show up if a transformation didn't
-     * work as expected.
-     * 
- * - * string details = 3; - */ - java.lang.String getDetails(); - /** - *
-     * A place for warnings or errors to show up if a transformation didn't
-     * work as expected.
-     * 
- * - * string details = 3; - */ - com.google.protobuf.ByteString - getDetailsBytes(); - } - /** - *
-   * A collection that informs the user the number of times a particular
-   * `TransformationResultCode` and error details occurred.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult} - */ - public static final class SummaryResult extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult) - SummaryResultOrBuilder { - private static final long serialVersionUID = 0L; - // Use SummaryResult.newBuilder() to construct. - private SummaryResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private SummaryResult() { - count_ = 0L; - code_ = 0; - details_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private SummaryResult( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - - count_ = input.readInt64(); - break; - } - case 16: { - int rawValue = input.readEnum(); - - code_ = rawValue; - break; - } - case 26: { - java.lang.String s = input.readStringRequireUtf8(); - - details_ = s; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransformationSummary_SummaryResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransformationSummary_SummaryResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.class, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder.class); - } - - public static final int COUNT_FIELD_NUMBER = 1; - private long count_; - /** - * int64 count = 1; - */ - public long getCount() { - return count_; - } - - public static final int CODE_FIELD_NUMBER = 2; - private int code_; - /** - * .google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode code = 2; - */ - public int getCodeValue() { - return code_; - } - /** - * .google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode code = 2; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode getCode() { - com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode result = com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode.valueOf(code_); - return result == null ? com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode.UNRECOGNIZED : result; - } - - public static final int DETAILS_FIELD_NUMBER = 3; - private volatile java.lang.Object details_; - /** - *
-     * A place for warnings or errors to show up if a transformation didn't
-     * work as expected.
-     * 
- * - * string details = 3; - */ - public java.lang.String getDetails() { - java.lang.Object ref = details_; - 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(); - details_ = s; - return s; - } - } - /** - *
-     * A place for warnings or errors to show up if a transformation didn't
-     * work as expected.
-     * 
- * - * string details = 3; - */ - public com.google.protobuf.ByteString - getDetailsBytes() { - java.lang.Object ref = details_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - details_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (count_ != 0L) { - output.writeInt64(1, count_); - } - if (code_ != com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode.TRANSFORMATION_RESULT_CODE_UNSPECIFIED.getNumber()) { - output.writeEnum(2, code_); - } - if (!getDetailsBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, details_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (count_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(1, count_); - } - if (code_ != com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode.TRANSFORMATION_RESULT_CODE_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(2, code_); - } - if (!getDetailsBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, details_); - } - 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.privacy.dlp.v2beta1.TransformationSummary.SummaryResult)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult other = (com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult) obj; - - boolean result = true; - result = result && (getCount() - == other.getCount()); - result = result && code_ == other.code_; - result = result && getDetails() - .equals(other.getDetails()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + COUNT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getCount()); - hash = (37 * hash) + CODE_FIELD_NUMBER; - hash = (53 * hash) + code_; - hash = (37 * hash) + DETAILS_FIELD_NUMBER; - hash = (53 * hash) + getDetails().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult 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.privacy.dlp.v2beta1.TransformationSummary.SummaryResult parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult 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.privacy.dlp.v2beta1.TransformationSummary.SummaryResult parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult 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.privacy.dlp.v2beta1.TransformationSummary.SummaryResult parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-     * A collection that informs the user the number of times a particular
-     * `TransformationResultCode` and error details occurred.
-     * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult) - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResultOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransformationSummary_SummaryResult_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransformationSummary_SummaryResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.class, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - count_ = 0L; - - code_ = 0; - - details_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransformationSummary_SummaryResult_descriptor; - } - - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult build() { - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult buildPartial() { - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult result = new com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult(this); - result.count_ = count_; - result.code_ = code_; - result.details_ = details_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult) { - return mergeFrom((com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult other) { - if (other == com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.getDefaultInstance()) return this; - if (other.getCount() != 0L) { - setCount(other.getCount()); - } - if (other.code_ != 0) { - setCodeValue(other.getCodeValue()); - } - if (!other.getDetails().isEmpty()) { - details_ = other.details_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private long count_ ; - /** - * int64 count = 1; - */ - public long getCount() { - return count_; - } - /** - * int64 count = 1; - */ - public Builder setCount(long value) { - - count_ = value; - onChanged(); - return this; - } - /** - * int64 count = 1; - */ - public Builder clearCount() { - - count_ = 0L; - onChanged(); - return this; - } - - private int code_ = 0; - /** - * .google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode code = 2; - */ - public int getCodeValue() { - return code_; - } - /** - * .google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode code = 2; - */ - public Builder setCodeValue(int value) { - code_ = value; - onChanged(); - return this; - } - /** - * .google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode code = 2; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode getCode() { - com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode result = com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode.valueOf(code_); - return result == null ? com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode.UNRECOGNIZED : result; - } - /** - * .google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode code = 2; - */ - public Builder setCode(com.google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode value) { - if (value == null) { - throw new NullPointerException(); - } - - code_ = value.getNumber(); - onChanged(); - return this; - } - /** - * .google.privacy.dlp.v2beta1.TransformationSummary.TransformationResultCode code = 2; - */ - public Builder clearCode() { - - code_ = 0; - onChanged(); - return this; - } - - private java.lang.Object details_ = ""; - /** - *
-       * A place for warnings or errors to show up if a transformation didn't
-       * work as expected.
-       * 
- * - * string details = 3; - */ - public java.lang.String getDetails() { - java.lang.Object ref = details_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - details_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - *
-       * A place for warnings or errors to show up if a transformation didn't
-       * work as expected.
-       * 
- * - * string details = 3; - */ - public com.google.protobuf.ByteString - getDetailsBytes() { - java.lang.Object ref = details_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - details_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - *
-       * A place for warnings or errors to show up if a transformation didn't
-       * work as expected.
-       * 
- * - * string details = 3; - */ - public Builder setDetails( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - details_ = value; - onChanged(); - return this; - } - /** - *
-       * A place for warnings or errors to show up if a transformation didn't
-       * work as expected.
-       * 
- * - * string details = 3; - */ - public Builder clearDetails() { - - details_ = getDefaultInstance().getDetails(); - onChanged(); - return this; - } - /** - *
-       * A place for warnings or errors to show up if a transformation didn't
-       * work as expected.
-       * 
- * - * string details = 3; - */ - public Builder setDetailsBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - details_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult) - private static final com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult(); - } - - public static com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public SummaryResult parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new SummaryResult(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private int bitField0_; - public static final int INFO_TYPE_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.InfoType infoType_; - /** - *
-   * Set if the transformation was limited to a specific info_type.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return infoType_ != null; - } - /** - *
-   * Set if the transformation was limited to a specific info_type.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - /** - *
-   * Set if the transformation was limited to a specific info_type.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - return getInfoType(); - } - - public static final int FIELD_FIELD_NUMBER = 2; - private com.google.privacy.dlp.v2beta1.FieldId field_; - /** - *
-   * Set if the transformation was limited to a specific FieldId.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public boolean hasField() { - return field_ != null; - } - /** - *
-   * Set if the transformation was limited to a specific FieldId.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId getField() { - return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } - /** - *
-   * Set if the transformation was limited to a specific FieldId.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() { - return getField(); - } - - public static final int TRANSFORMATION_FIELD_NUMBER = 3; - private com.google.privacy.dlp.v2beta1.PrimitiveTransformation transformation_; - /** - *
-   * The specific transformation these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public boolean hasTransformation() { - return transformation_ != null; - } - /** - *
-   * The specific transformation these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation getTransformation() { - return transformation_ == null ? com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance() : transformation_; - } - /** - *
-   * The specific transformation these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder getTransformationOrBuilder() { - return getTransformation(); - } - - public static final int FIELD_TRANSFORMATIONS_FIELD_NUMBER = 5; - private java.util.List fieldTransformations_; - /** - *
-   * The field transformation that was applied. This list will contain
-   * multiple only in the case of errors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public java.util.List getFieldTransformationsList() { - return fieldTransformations_; - } - /** - *
-   * The field transformation that was applied. This list will contain
-   * multiple only in the case of errors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public java.util.List - getFieldTransformationsOrBuilderList() { - return fieldTransformations_; - } - /** - *
-   * The field transformation that was applied. This list will contain
-   * multiple only in the case of errors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public int getFieldTransformationsCount() { - return fieldTransformations_.size(); - } - /** - *
-   * The field transformation that was applied. This list will contain
-   * multiple only in the case of errors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformation getFieldTransformations(int index) { - return fieldTransformations_.get(index); - } - /** - *
-   * The field transformation that was applied. This list will contain
-   * multiple only in the case of errors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder getFieldTransformationsOrBuilder( - int index) { - return fieldTransformations_.get(index); - } - - public static final int RECORD_SUPPRESS_FIELD_NUMBER = 6; - private com.google.privacy.dlp.v2beta1.RecordSuppression recordSuppress_; - /** - *
-   * The specific suppression option these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public boolean hasRecordSuppress() { - return recordSuppress_ != null; - } - /** - *
-   * The specific suppression option these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppression getRecordSuppress() { - return recordSuppress_ == null ? com.google.privacy.dlp.v2beta1.RecordSuppression.getDefaultInstance() : recordSuppress_; - } - /** - *
-   * The specific suppression option these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder getRecordSuppressOrBuilder() { - return getRecordSuppress(); - } - - public static final int RESULTS_FIELD_NUMBER = 4; - private java.util.List results_; - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public java.util.List getResultsList() { - return results_; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public java.util.List - getResultsOrBuilderList() { - return results_; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public int getResultsCount() { - return results_.size(); - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult getResults(int index) { - return results_.get(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResultOrBuilder getResultsOrBuilder( - int index) { - return results_.get(index); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (infoType_ != null) { - output.writeMessage(1, getInfoType()); - } - if (field_ != null) { - output.writeMessage(2, getField()); - } - if (transformation_ != null) { - output.writeMessage(3, getTransformation()); - } - for (int i = 0; i < results_.size(); i++) { - output.writeMessage(4, results_.get(i)); - } - for (int i = 0; i < fieldTransformations_.size(); i++) { - output.writeMessage(5, fieldTransformations_.get(i)); - } - if (recordSuppress_ != null) { - output.writeMessage(6, getRecordSuppress()); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (infoType_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getInfoType()); - } - if (field_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getField()); - } - if (transformation_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, getTransformation()); - } - for (int i = 0; i < results_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, results_.get(i)); - } - for (int i = 0; i < fieldTransformations_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, fieldTransformations_.get(i)); - } - if (recordSuppress_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, getRecordSuppress()); - } - 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.privacy.dlp.v2beta1.TransformationSummary)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.TransformationSummary other = (com.google.privacy.dlp.v2beta1.TransformationSummary) obj; - - boolean result = true; - result = result && (hasInfoType() == other.hasInfoType()); - if (hasInfoType()) { - result = result && getInfoType() - .equals(other.getInfoType()); - } - result = result && (hasField() == other.hasField()); - if (hasField()) { - result = result && getField() - .equals(other.getField()); - } - result = result && (hasTransformation() == other.hasTransformation()); - if (hasTransformation()) { - result = result && getTransformation() - .equals(other.getTransformation()); - } - result = result && getFieldTransformationsList() - .equals(other.getFieldTransformationsList()); - result = result && (hasRecordSuppress() == other.hasRecordSuppress()); - if (hasRecordSuppress()) { - result = result && getRecordSuppress() - .equals(other.getRecordSuppress()); - } - result = result && getResultsList() - .equals(other.getResultsList()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasInfoType()) { - hash = (37 * hash) + INFO_TYPE_FIELD_NUMBER; - hash = (53 * hash) + getInfoType().hashCode(); - } - if (hasField()) { - hash = (37 * hash) + FIELD_FIELD_NUMBER; - hash = (53 * hash) + getField().hashCode(); - } - if (hasTransformation()) { - hash = (37 * hash) + TRANSFORMATION_FIELD_NUMBER; - hash = (53 * hash) + getTransformation().hashCode(); - } - if (getFieldTransformationsCount() > 0) { - hash = (37 * hash) + FIELD_TRANSFORMATIONS_FIELD_NUMBER; - hash = (53 * hash) + getFieldTransformationsList().hashCode(); - } - if (hasRecordSuppress()) { - hash = (37 * hash) + RECORD_SUPPRESS_FIELD_NUMBER; - hash = (53 * hash) + getRecordSuppress().hashCode(); - } - if (getResultsCount() > 0) { - hash = (37 * hash) + RESULTS_FIELD_NUMBER; - hash = (53 * hash) + getResultsList().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.TransformationSummary parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary 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.privacy.dlp.v2beta1.TransformationSummary parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary 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.privacy.dlp.v2beta1.TransformationSummary parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary 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.privacy.dlp.v2beta1.TransformationSummary parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TransformationSummary parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.TransformationSummary prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Summary of a single tranformation.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.TransformationSummary} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.TransformationSummary) - com.google.privacy.dlp.v2beta1.TransformationSummaryOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransformationSummary_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransformationSummary_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.TransformationSummary.class, com.google.privacy.dlp.v2beta1.TransformationSummary.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.TransformationSummary.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - getFieldTransformationsFieldBuilder(); - getResultsFieldBuilder(); - } - } - public Builder clear() { - super.clear(); - if (infoTypeBuilder_ == null) { - infoType_ = null; - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - if (fieldBuilder_ == null) { - field_ = null; - } else { - field_ = null; - fieldBuilder_ = null; - } - if (transformationBuilder_ == null) { - transformation_ = null; - } else { - transformation_ = null; - transformationBuilder_ = null; - } - if (fieldTransformationsBuilder_ == null) { - fieldTransformations_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - } else { - fieldTransformationsBuilder_.clear(); - } - if (recordSuppressBuilder_ == null) { - recordSuppress_ = null; - } else { - recordSuppress_ = null; - recordSuppressBuilder_ = null; - } - if (resultsBuilder_ == null) { - results_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000020); - } else { - resultsBuilder_.clear(); - } - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransformationSummary_descriptor; - } - - public com.google.privacy.dlp.v2beta1.TransformationSummary getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.TransformationSummary.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.TransformationSummary build() { - com.google.privacy.dlp.v2beta1.TransformationSummary result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.TransformationSummary buildPartial() { - com.google.privacy.dlp.v2beta1.TransformationSummary result = new com.google.privacy.dlp.v2beta1.TransformationSummary(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (infoTypeBuilder_ == null) { - result.infoType_ = infoType_; - } else { - result.infoType_ = infoTypeBuilder_.build(); - } - if (fieldBuilder_ == null) { - result.field_ = field_; - } else { - result.field_ = fieldBuilder_.build(); - } - if (transformationBuilder_ == null) { - result.transformation_ = transformation_; - } else { - result.transformation_ = transformationBuilder_.build(); - } - if (fieldTransformationsBuilder_ == null) { - if (((bitField0_ & 0x00000008) == 0x00000008)) { - fieldTransformations_ = java.util.Collections.unmodifiableList(fieldTransformations_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.fieldTransformations_ = fieldTransformations_; - } else { - result.fieldTransformations_ = fieldTransformationsBuilder_.build(); - } - if (recordSuppressBuilder_ == null) { - result.recordSuppress_ = recordSuppress_; - } else { - result.recordSuppress_ = recordSuppressBuilder_.build(); - } - if (resultsBuilder_ == null) { - if (((bitField0_ & 0x00000020) == 0x00000020)) { - results_ = java.util.Collections.unmodifiableList(results_); - bitField0_ = (bitField0_ & ~0x00000020); - } - result.results_ = results_; - } else { - result.results_ = resultsBuilder_.build(); - } - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.TransformationSummary) { - return mergeFrom((com.google.privacy.dlp.v2beta1.TransformationSummary)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.TransformationSummary other) { - if (other == com.google.privacy.dlp.v2beta1.TransformationSummary.getDefaultInstance()) return this; - if (other.hasInfoType()) { - mergeInfoType(other.getInfoType()); - } - if (other.hasField()) { - mergeField(other.getField()); - } - if (other.hasTransformation()) { - mergeTransformation(other.getTransformation()); - } - if (fieldTransformationsBuilder_ == null) { - if (!other.fieldTransformations_.isEmpty()) { - if (fieldTransformations_.isEmpty()) { - fieldTransformations_ = other.fieldTransformations_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureFieldTransformationsIsMutable(); - fieldTransformations_.addAll(other.fieldTransformations_); - } - onChanged(); - } - } else { - if (!other.fieldTransformations_.isEmpty()) { - if (fieldTransformationsBuilder_.isEmpty()) { - fieldTransformationsBuilder_.dispose(); - fieldTransformationsBuilder_ = null; - fieldTransformations_ = other.fieldTransformations_; - bitField0_ = (bitField0_ & ~0x00000008); - fieldTransformationsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getFieldTransformationsFieldBuilder() : null; - } else { - fieldTransformationsBuilder_.addAllMessages(other.fieldTransformations_); - } - } - } - if (other.hasRecordSuppress()) { - mergeRecordSuppress(other.getRecordSuppress()); - } - if (resultsBuilder_ == null) { - if (!other.results_.isEmpty()) { - if (results_.isEmpty()) { - results_ = other.results_; - bitField0_ = (bitField0_ & ~0x00000020); - } else { - ensureResultsIsMutable(); - results_.addAll(other.results_); - } - onChanged(); - } - } else { - if (!other.results_.isEmpty()) { - if (resultsBuilder_.isEmpty()) { - resultsBuilder_.dispose(); - resultsBuilder_ = null; - results_ = other.results_; - bitField0_ = (bitField0_ & ~0x00000020); - resultsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getResultsFieldBuilder() : null; - } else { - resultsBuilder_.addAllMessages(other.results_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.TransformationSummary parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.TransformationSummary) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private com.google.privacy.dlp.v2beta1.InfoType infoType_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> infoTypeBuilder_; - /** - *
-     * Set if the transformation was limited to a specific info_type.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public boolean hasInfoType() { - return infoTypeBuilder_ != null || infoType_ != null; - } - /** - *
-     * Set if the transformation was limited to a specific info_type.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType getInfoType() { - if (infoTypeBuilder_ == null) { - return infoType_ == null ? com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } else { - return infoTypeBuilder_.getMessage(); - } - } - /** - *
-     * Set if the transformation was limited to a specific info_type.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - infoType_ = value; - onChanged(); - } else { - infoTypeBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Set if the transformation was limited to a specific info_type.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder setInfoType( - com.google.privacy.dlp.v2beta1.InfoType.Builder builderForValue) { - if (infoTypeBuilder_ == null) { - infoType_ = builderForValue.build(); - onChanged(); - } else { - infoTypeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Set if the transformation was limited to a specific info_type.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder mergeInfoType(com.google.privacy.dlp.v2beta1.InfoType value) { - if (infoTypeBuilder_ == null) { - if (infoType_ != null) { - infoType_ = - com.google.privacy.dlp.v2beta1.InfoType.newBuilder(infoType_).mergeFrom(value).buildPartial(); - } else { - infoType_ = value; - } - onChanged(); - } else { - infoTypeBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Set if the transformation was limited to a specific info_type.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public Builder clearInfoType() { - if (infoTypeBuilder_ == null) { - infoType_ = null; - onChanged(); - } else { - infoType_ = null; - infoTypeBuilder_ = null; - } - - return this; - } - /** - *
-     * Set if the transformation was limited to a specific info_type.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoType.Builder getInfoTypeBuilder() { - - onChanged(); - return getInfoTypeFieldBuilder().getBuilder(); - } - /** - *
-     * Set if the transformation was limited to a specific info_type.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - public com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder() { - if (infoTypeBuilder_ != null) { - return infoTypeBuilder_.getMessageOrBuilder(); - } else { - return infoType_ == null ? - com.google.privacy.dlp.v2beta1.InfoType.getDefaultInstance() : infoType_; - } - } - /** - *
-     * Set if the transformation was limited to a specific info_type.
-     * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder> - getInfoTypeFieldBuilder() { - if (infoTypeBuilder_ == null) { - infoTypeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.InfoType, com.google.privacy.dlp.v2beta1.InfoType.Builder, com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder>( - getInfoType(), - getParentForChildren(), - isClean()); - infoType_ = null; - } - return infoTypeBuilder_; - } - - private com.google.privacy.dlp.v2beta1.FieldId field_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> fieldBuilder_; - /** - *
-     * Set if the transformation was limited to a specific FieldId.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public boolean hasField() { - return fieldBuilder_ != null || field_ != null; - } - /** - *
-     * Set if the transformation was limited to a specific FieldId.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId getField() { - if (fieldBuilder_ == null) { - return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } else { - return fieldBuilder_.getMessage(); - } - } - /** - *
-     * Set if the transformation was limited to a specific FieldId.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public Builder setField(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - field_ = value; - onChanged(); - } else { - fieldBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * Set if the transformation was limited to a specific FieldId.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public Builder setField( - com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) { - if (fieldBuilder_ == null) { - field_ = builderForValue.build(); - onChanged(); - } else { - fieldBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * Set if the transformation was limited to a specific FieldId.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public Builder mergeField(com.google.privacy.dlp.v2beta1.FieldId value) { - if (fieldBuilder_ == null) { - if (field_ != null) { - field_ = - com.google.privacy.dlp.v2beta1.FieldId.newBuilder(field_).mergeFrom(value).buildPartial(); - } else { - field_ = value; - } - onChanged(); - } else { - fieldBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * Set if the transformation was limited to a specific FieldId.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public Builder clearField() { - if (fieldBuilder_ == null) { - field_ = null; - onChanged(); - } else { - field_ = null; - fieldBuilder_ = null; - } - - return this; - } - /** - *
-     * Set if the transformation was limited to a specific FieldId.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldId.Builder getFieldBuilder() { - - onChanged(); - return getFieldFieldBuilder().getBuilder(); - } - /** - *
-     * Set if the transformation was limited to a specific FieldId.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() { - if (fieldBuilder_ != null) { - return fieldBuilder_.getMessageOrBuilder(); - } else { - return field_ == null ? - com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_; - } - } - /** - *
-     * Set if the transformation was limited to a specific FieldId.
-     * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> - getFieldFieldBuilder() { - if (fieldBuilder_ == null) { - fieldBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>( - getField(), - getParentForChildren(), - isClean()); - field_ = null; - } - return fieldBuilder_; - } - - private com.google.privacy.dlp.v2beta1.PrimitiveTransformation transformation_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrimitiveTransformation, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder, com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder> transformationBuilder_; - /** - *
-     * The specific transformation these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public boolean hasTransformation() { - return transformationBuilder_ != null || transformation_ != null; - } - /** - *
-     * The specific transformation these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation getTransformation() { - if (transformationBuilder_ == null) { - return transformation_ == null ? com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance() : transformation_; - } else { - return transformationBuilder_.getMessage(); - } - } - /** - *
-     * The specific transformation these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public Builder setTransformation(com.google.privacy.dlp.v2beta1.PrimitiveTransformation value) { - if (transformationBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - transformation_ = value; - onChanged(); - } else { - transformationBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The specific transformation these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public Builder setTransformation( - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder builderForValue) { - if (transformationBuilder_ == null) { - transformation_ = builderForValue.build(); - onChanged(); - } else { - transformationBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The specific transformation these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public Builder mergeTransformation(com.google.privacy.dlp.v2beta1.PrimitiveTransformation value) { - if (transformationBuilder_ == null) { - if (transformation_ != null) { - transformation_ = - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.newBuilder(transformation_).mergeFrom(value).buildPartial(); - } else { - transformation_ = value; - } - onChanged(); - } else { - transformationBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The specific transformation these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public Builder clearTransformation() { - if (transformationBuilder_ == null) { - transformation_ = null; - onChanged(); - } else { - transformation_ = null; - transformationBuilder_ = null; - } - - return this; - } - /** - *
-     * The specific transformation these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder getTransformationBuilder() { - - onChanged(); - return getTransformationFieldBuilder().getBuilder(); - } - /** - *
-     * The specific transformation these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - public com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder getTransformationOrBuilder() { - if (transformationBuilder_ != null) { - return transformationBuilder_.getMessageOrBuilder(); - } else { - return transformation_ == null ? - com.google.privacy.dlp.v2beta1.PrimitiveTransformation.getDefaultInstance() : transformation_; - } - } - /** - *
-     * The specific transformation these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrimitiveTransformation, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder, com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder> - getTransformationFieldBuilder() { - if (transformationBuilder_ == null) { - transformationBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.PrimitiveTransformation, com.google.privacy.dlp.v2beta1.PrimitiveTransformation.Builder, com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder>( - getTransformation(), - getParentForChildren(), - isClean()); - transformation_ = null; - } - return transformationBuilder_; - } - - private java.util.List fieldTransformations_ = - java.util.Collections.emptyList(); - private void ensureFieldTransformationsIsMutable() { - if (!((bitField0_ & 0x00000008) == 0x00000008)) { - fieldTransformations_ = new java.util.ArrayList(fieldTransformations_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldTransformation, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder, com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder> fieldTransformationsBuilder_; - - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public java.util.List getFieldTransformationsList() { - if (fieldTransformationsBuilder_ == null) { - return java.util.Collections.unmodifiableList(fieldTransformations_); - } else { - return fieldTransformationsBuilder_.getMessageList(); - } - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public int getFieldTransformationsCount() { - if (fieldTransformationsBuilder_ == null) { - return fieldTransformations_.size(); - } else { - return fieldTransformationsBuilder_.getCount(); - } - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformation getFieldTransformations(int index) { - if (fieldTransformationsBuilder_ == null) { - return fieldTransformations_.get(index); - } else { - return fieldTransformationsBuilder_.getMessage(index); - } - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public Builder setFieldTransformations( - int index, com.google.privacy.dlp.v2beta1.FieldTransformation value) { - if (fieldTransformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldTransformationsIsMutable(); - fieldTransformations_.set(index, value); - onChanged(); - } else { - fieldTransformationsBuilder_.setMessage(index, value); - } - return this; - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public Builder setFieldTransformations( - int index, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder builderForValue) { - if (fieldTransformationsBuilder_ == null) { - ensureFieldTransformationsIsMutable(); - fieldTransformations_.set(index, builderForValue.build()); - onChanged(); - } else { - fieldTransformationsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public Builder addFieldTransformations(com.google.privacy.dlp.v2beta1.FieldTransformation value) { - if (fieldTransformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldTransformationsIsMutable(); - fieldTransformations_.add(value); - onChanged(); - } else { - fieldTransformationsBuilder_.addMessage(value); - } - return this; - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public Builder addFieldTransformations( - int index, com.google.privacy.dlp.v2beta1.FieldTransformation value) { - if (fieldTransformationsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFieldTransformationsIsMutable(); - fieldTransformations_.add(index, value); - onChanged(); - } else { - fieldTransformationsBuilder_.addMessage(index, value); - } - return this; - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public Builder addFieldTransformations( - com.google.privacy.dlp.v2beta1.FieldTransformation.Builder builderForValue) { - if (fieldTransformationsBuilder_ == null) { - ensureFieldTransformationsIsMutable(); - fieldTransformations_.add(builderForValue.build()); - onChanged(); - } else { - fieldTransformationsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public Builder addFieldTransformations( - int index, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder builderForValue) { - if (fieldTransformationsBuilder_ == null) { - ensureFieldTransformationsIsMutable(); - fieldTransformations_.add(index, builderForValue.build()); - onChanged(); - } else { - fieldTransformationsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public Builder addAllFieldTransformations( - java.lang.Iterable values) { - if (fieldTransformationsBuilder_ == null) { - ensureFieldTransformationsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, fieldTransformations_); - onChanged(); - } else { - fieldTransformationsBuilder_.addAllMessages(values); - } - return this; - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public Builder clearFieldTransformations() { - if (fieldTransformationsBuilder_ == null) { - fieldTransformations_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - fieldTransformationsBuilder_.clear(); - } - return this; - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public Builder removeFieldTransformations(int index) { - if (fieldTransformationsBuilder_ == null) { - ensureFieldTransformationsIsMutable(); - fieldTransformations_.remove(index); - onChanged(); - } else { - fieldTransformationsBuilder_.remove(index); - } - return this; - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformation.Builder getFieldTransformationsBuilder( - int index) { - return getFieldTransformationsFieldBuilder().getBuilder(index); - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder getFieldTransformationsOrBuilder( - int index) { - if (fieldTransformationsBuilder_ == null) { - return fieldTransformations_.get(index); } else { - return fieldTransformationsBuilder_.getMessageOrBuilder(index); - } - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public java.util.List - getFieldTransformationsOrBuilderList() { - if (fieldTransformationsBuilder_ != null) { - return fieldTransformationsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(fieldTransformations_); - } - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformation.Builder addFieldTransformationsBuilder() { - return getFieldTransformationsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.FieldTransformation.getDefaultInstance()); - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public com.google.privacy.dlp.v2beta1.FieldTransformation.Builder addFieldTransformationsBuilder( - int index) { - return getFieldTransformationsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.FieldTransformation.getDefaultInstance()); - } - /** - *
-     * The field transformation that was applied. This list will contain
-     * multiple only in the case of errors.
-     * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - public java.util.List - getFieldTransformationsBuilderList() { - return getFieldTransformationsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldTransformation, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder, com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder> - getFieldTransformationsFieldBuilder() { - if (fieldTransformationsBuilder_ == null) { - fieldTransformationsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.FieldTransformation, com.google.privacy.dlp.v2beta1.FieldTransformation.Builder, com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder>( - fieldTransformations_, - ((bitField0_ & 0x00000008) == 0x00000008), - getParentForChildren(), - isClean()); - fieldTransformations_ = null; - } - return fieldTransformationsBuilder_; - } - - private com.google.privacy.dlp.v2beta1.RecordSuppression recordSuppress_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordSuppression, com.google.privacy.dlp.v2beta1.RecordSuppression.Builder, com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder> recordSuppressBuilder_; - /** - *
-     * The specific suppression option these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public boolean hasRecordSuppress() { - return recordSuppressBuilder_ != null || recordSuppress_ != null; - } - /** - *
-     * The specific suppression option these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppression getRecordSuppress() { - if (recordSuppressBuilder_ == null) { - return recordSuppress_ == null ? com.google.privacy.dlp.v2beta1.RecordSuppression.getDefaultInstance() : recordSuppress_; - } else { - return recordSuppressBuilder_.getMessage(); - } - } - /** - *
-     * The specific suppression option these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public Builder setRecordSuppress(com.google.privacy.dlp.v2beta1.RecordSuppression value) { - if (recordSuppressBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - recordSuppress_ = value; - onChanged(); - } else { - recordSuppressBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * The specific suppression option these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public Builder setRecordSuppress( - com.google.privacy.dlp.v2beta1.RecordSuppression.Builder builderForValue) { - if (recordSuppressBuilder_ == null) { - recordSuppress_ = builderForValue.build(); - onChanged(); - } else { - recordSuppressBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * The specific suppression option these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public Builder mergeRecordSuppress(com.google.privacy.dlp.v2beta1.RecordSuppression value) { - if (recordSuppressBuilder_ == null) { - if (recordSuppress_ != null) { - recordSuppress_ = - com.google.privacy.dlp.v2beta1.RecordSuppression.newBuilder(recordSuppress_).mergeFrom(value).buildPartial(); - } else { - recordSuppress_ = value; - } - onChanged(); - } else { - recordSuppressBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * The specific suppression option these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public Builder clearRecordSuppress() { - if (recordSuppressBuilder_ == null) { - recordSuppress_ = null; - onChanged(); - } else { - recordSuppress_ = null; - recordSuppressBuilder_ = null; - } - - return this; - } - /** - *
-     * The specific suppression option these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppression.Builder getRecordSuppressBuilder() { - - onChanged(); - return getRecordSuppressFieldBuilder().getBuilder(); - } - /** - *
-     * The specific suppression option these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - public com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder getRecordSuppressOrBuilder() { - if (recordSuppressBuilder_ != null) { - return recordSuppressBuilder_.getMessageOrBuilder(); - } else { - return recordSuppress_ == null ? - com.google.privacy.dlp.v2beta1.RecordSuppression.getDefaultInstance() : recordSuppress_; - } - } - /** - *
-     * The specific suppression option these stats apply to.
-     * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordSuppression, com.google.privacy.dlp.v2beta1.RecordSuppression.Builder, com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder> - getRecordSuppressFieldBuilder() { - if (recordSuppressBuilder_ == null) { - recordSuppressBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.RecordSuppression, com.google.privacy.dlp.v2beta1.RecordSuppression.Builder, com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder>( - getRecordSuppress(), - getParentForChildren(), - isClean()); - recordSuppress_ = null; - } - return recordSuppressBuilder_; - } - - private java.util.List results_ = - java.util.Collections.emptyList(); - private void ensureResultsIsMutable() { - if (!((bitField0_ & 0x00000020) == 0x00000020)) { - results_ = new java.util.ArrayList(results_); - bitField0_ |= 0x00000020; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResultOrBuilder> resultsBuilder_; - - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public java.util.List getResultsList() { - if (resultsBuilder_ == null) { - return java.util.Collections.unmodifiableList(results_); - } else { - return resultsBuilder_.getMessageList(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public int getResultsCount() { - if (resultsBuilder_ == null) { - return results_.size(); - } else { - return resultsBuilder_.getCount(); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult getResults(int index) { - if (resultsBuilder_ == null) { - return results_.get(index); - } else { - return resultsBuilder_.getMessage(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public Builder setResults( - int index, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult value) { - if (resultsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureResultsIsMutable(); - results_.set(index, value); - onChanged(); - } else { - resultsBuilder_.setMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public Builder setResults( - int index, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder builderForValue) { - if (resultsBuilder_ == null) { - ensureResultsIsMutable(); - results_.set(index, builderForValue.build()); - onChanged(); - } else { - resultsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public Builder addResults(com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult value) { - if (resultsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureResultsIsMutable(); - results_.add(value); - onChanged(); - } else { - resultsBuilder_.addMessage(value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public Builder addResults( - int index, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult value) { - if (resultsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureResultsIsMutable(); - results_.add(index, value); - onChanged(); - } else { - resultsBuilder_.addMessage(index, value); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public Builder addResults( - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder builderForValue) { - if (resultsBuilder_ == null) { - ensureResultsIsMutable(); - results_.add(builderForValue.build()); - onChanged(); - } else { - resultsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public Builder addResults( - int index, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder builderForValue) { - if (resultsBuilder_ == null) { - ensureResultsIsMutable(); - results_.add(index, builderForValue.build()); - onChanged(); - } else { - resultsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public Builder addAllResults( - java.lang.Iterable values) { - if (resultsBuilder_ == null) { - ensureResultsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, results_); - onChanged(); - } else { - resultsBuilder_.addAllMessages(values); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public Builder clearResults() { - if (resultsBuilder_ == null) { - results_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000020); - onChanged(); - } else { - resultsBuilder_.clear(); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public Builder removeResults(int index) { - if (resultsBuilder_ == null) { - ensureResultsIsMutable(); - results_.remove(index); - onChanged(); - } else { - resultsBuilder_.remove(index); - } - return this; - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder getResultsBuilder( - int index) { - return getResultsFieldBuilder().getBuilder(index); - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResultOrBuilder getResultsOrBuilder( - int index) { - if (resultsBuilder_ == null) { - return results_.get(index); } else { - return resultsBuilder_.getMessageOrBuilder(index); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public java.util.List - getResultsOrBuilderList() { - if (resultsBuilder_ != null) { - return resultsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(results_); - } - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder addResultsBuilder() { - return getResultsFieldBuilder().addBuilder( - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder addResultsBuilder( - int index) { - return getResultsFieldBuilder().addBuilder( - index, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.getDefaultInstance()); - } - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - public java.util.List - getResultsBuilderList() { - return getResultsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResultOrBuilder> - getResultsFieldBuilder() { - if (resultsBuilder_ == null) { - resultsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult.Builder, com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResultOrBuilder>( - results_, - ((bitField0_ & 0x00000020) == 0x00000020), - getParentForChildren(), - isClean()); - results_ = null; - } - return resultsBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.TransformationSummary) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.TransformationSummary) - private static final com.google.privacy.dlp.v2beta1.TransformationSummary DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.TransformationSummary(); - } - - public static com.google.privacy.dlp.v2beta1.TransformationSummary getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public TransformationSummary parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TransformationSummary(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.TransformationSummary getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransformationSummaryOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransformationSummaryOrBuilder.java deleted file mode 100644 index 031b4e940083..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransformationSummaryOrBuilder.java +++ /dev/null @@ -1,182 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface TransformationSummaryOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.TransformationSummary) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Set if the transformation was limited to a specific info_type.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - boolean hasInfoType(); - /** - *
-   * Set if the transformation was limited to a specific info_type.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoType getInfoType(); - /** - *
-   * Set if the transformation was limited to a specific info_type.
-   * 
- * - * .google.privacy.dlp.v2beta1.InfoType info_type = 1; - */ - com.google.privacy.dlp.v2beta1.InfoTypeOrBuilder getInfoTypeOrBuilder(); - - /** - *
-   * Set if the transformation was limited to a specific FieldId.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - boolean hasField(); - /** - *
-   * Set if the transformation was limited to a specific FieldId.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - com.google.privacy.dlp.v2beta1.FieldId getField(); - /** - *
-   * Set if the transformation was limited to a specific FieldId.
-   * 
- * - * .google.privacy.dlp.v2beta1.FieldId field = 2; - */ - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder(); - - /** - *
-   * The specific transformation these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - boolean hasTransformation(); - /** - *
-   * The specific transformation these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - com.google.privacy.dlp.v2beta1.PrimitiveTransformation getTransformation(); - /** - *
-   * The specific transformation these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.PrimitiveTransformation transformation = 3; - */ - com.google.privacy.dlp.v2beta1.PrimitiveTransformationOrBuilder getTransformationOrBuilder(); - - /** - *
-   * The field transformation that was applied. This list will contain
-   * multiple only in the case of errors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - java.util.List - getFieldTransformationsList(); - /** - *
-   * The field transformation that was applied. This list will contain
-   * multiple only in the case of errors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - com.google.privacy.dlp.v2beta1.FieldTransformation getFieldTransformations(int index); - /** - *
-   * The field transformation that was applied. This list will contain
-   * multiple only in the case of errors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - int getFieldTransformationsCount(); - /** - *
-   * The field transformation that was applied. This list will contain
-   * multiple only in the case of errors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - java.util.List - getFieldTransformationsOrBuilderList(); - /** - *
-   * The field transformation that was applied. This list will contain
-   * multiple only in the case of errors.
-   * 
- * - * repeated .google.privacy.dlp.v2beta1.FieldTransformation field_transformations = 5; - */ - com.google.privacy.dlp.v2beta1.FieldTransformationOrBuilder getFieldTransformationsOrBuilder( - int index); - - /** - *
-   * The specific suppression option these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - boolean hasRecordSuppress(); - /** - *
-   * The specific suppression option these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - com.google.privacy.dlp.v2beta1.RecordSuppression getRecordSuppress(); - /** - *
-   * The specific suppression option these stats apply to.
-   * 
- * - * .google.privacy.dlp.v2beta1.RecordSuppression record_suppress = 6; - */ - com.google.privacy.dlp.v2beta1.RecordSuppressionOrBuilder getRecordSuppressOrBuilder(); - - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - java.util.List - getResultsList(); - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult getResults(int index); - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - int getResultsCount(); - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - java.util.List - getResultsOrBuilderList(); - /** - * repeated .google.privacy.dlp.v2beta1.TransformationSummary.SummaryResult results = 4; - */ - com.google.privacy.dlp.v2beta1.TransformationSummary.SummaryResultOrBuilder getResultsOrBuilder( - int index); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransientCryptoKey.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransientCryptoKey.java deleted file mode 100644 index b4a22c63c72f..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransientCryptoKey.java +++ /dev/null @@ -1,589 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Use this to have a random data crypto key generated.
- * It will be discarded after the operation/request finishes.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.TransientCryptoKey} - */ -public final class TransientCryptoKey extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.TransientCryptoKey) - TransientCryptoKeyOrBuilder { -private static final long serialVersionUID = 0L; - // Use TransientCryptoKey.newBuilder() to construct. - private TransientCryptoKey(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private TransientCryptoKey() { - name_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private TransientCryptoKey( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransientCryptoKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransientCryptoKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.TransientCryptoKey.class, com.google.privacy.dlp.v2beta1.TransientCryptoKey.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - *
-   * Name of the key. [required]
-   * This is an arbitrary string used to differentiate different keys.
-   * A unique key is generated per name: two separate `TransientCryptoKey`
-   * protos share the same generated key if their names are the same.
-   * When the data crypto key is generated, this name is not used in any way
-   * (repeating the api call will result in a different key being generated).
-   * 
- * - * string name = 1; - */ - 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 key. [required]
-   * This is an arbitrary string used to differentiate different keys.
-   * A unique key is generated per name: two separate `TransientCryptoKey`
-   * protos share the same generated key if their names are the same.
-   * When the data crypto key is generated, this name is not used in any way
-   * (repeating the api call will result in a different key being generated).
-   * 
- * - * string name = 1; - */ - public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - 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.privacy.dlp.v2beta1.TransientCryptoKey)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.TransientCryptoKey other = (com.google.privacy.dlp.v2beta1.TransientCryptoKey) obj; - - boolean result = true; - result = result && getName() - .equals(other.getName()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.TransientCryptoKey parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TransientCryptoKey parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.TransientCryptoKey parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TransientCryptoKey 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.privacy.dlp.v2beta1.TransientCryptoKey parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.TransientCryptoKey parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.TransientCryptoKey parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TransientCryptoKey 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.privacy.dlp.v2beta1.TransientCryptoKey parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TransientCryptoKey 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.privacy.dlp.v2beta1.TransientCryptoKey parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.TransientCryptoKey parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.TransientCryptoKey prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Use this to have a random data crypto key generated.
-   * It will be discarded after the operation/request finishes.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.TransientCryptoKey} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.TransientCryptoKey) - com.google.privacy.dlp.v2beta1.TransientCryptoKeyOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransientCryptoKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransientCryptoKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.TransientCryptoKey.class, com.google.privacy.dlp.v2beta1.TransientCryptoKey.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.TransientCryptoKey.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_TransientCryptoKey_descriptor; - } - - public com.google.privacy.dlp.v2beta1.TransientCryptoKey getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.TransientCryptoKey.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.TransientCryptoKey build() { - com.google.privacy.dlp.v2beta1.TransientCryptoKey result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.TransientCryptoKey buildPartial() { - com.google.privacy.dlp.v2beta1.TransientCryptoKey result = new com.google.privacy.dlp.v2beta1.TransientCryptoKey(this); - result.name_ = name_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.TransientCryptoKey) { - return mergeFrom((com.google.privacy.dlp.v2beta1.TransientCryptoKey)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.TransientCryptoKey other) { - if (other == com.google.privacy.dlp.v2beta1.TransientCryptoKey.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.TransientCryptoKey parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.TransientCryptoKey) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private java.lang.Object name_ = ""; - /** - *
-     * Name of the key. [required]
-     * This is an arbitrary string used to differentiate different keys.
-     * A unique key is generated per name: two separate `TransientCryptoKey`
-     * protos share the same generated key if their names are the same.
-     * When the data crypto key is generated, this name is not used in any way
-     * (repeating the api call will result in a different key being generated).
-     * 
- * - * string name = 1; - */ - 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 key. [required]
-     * This is an arbitrary string used to differentiate different keys.
-     * A unique key is generated per name: two separate `TransientCryptoKey`
-     * protos share the same generated key if their names are the same.
-     * When the data crypto key is generated, this name is not used in any way
-     * (repeating the api call will result in a different key being generated).
-     * 
- * - * string name = 1; - */ - 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 key. [required]
-     * This is an arbitrary string used to differentiate different keys.
-     * A unique key is generated per name: two separate `TransientCryptoKey`
-     * protos share the same generated key if their names are the same.
-     * When the data crypto key is generated, this name is not used in any way
-     * (repeating the api call will result in a different key being generated).
-     * 
- * - * string name = 1; - */ - public Builder setName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - *
-     * Name of the key. [required]
-     * This is an arbitrary string used to differentiate different keys.
-     * A unique key is generated per name: two separate `TransientCryptoKey`
-     * protos share the same generated key if their names are the same.
-     * When the data crypto key is generated, this name is not used in any way
-     * (repeating the api call will result in a different key being generated).
-     * 
- * - * string name = 1; - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - *
-     * Name of the key. [required]
-     * This is an arbitrary string used to differentiate different keys.
-     * A unique key is generated per name: two separate `TransientCryptoKey`
-     * protos share the same generated key if their names are the same.
-     * When the data crypto key is generated, this name is not used in any way
-     * (repeating the api call will result in a different key being generated).
-     * 
- * - * string name = 1; - */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.TransientCryptoKey) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.TransientCryptoKey) - private static final com.google.privacy.dlp.v2beta1.TransientCryptoKey DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.TransientCryptoKey(); - } - - public static com.google.privacy.dlp.v2beta1.TransientCryptoKey getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public TransientCryptoKey parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TransientCryptoKey(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.TransientCryptoKey getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransientCryptoKeyOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransientCryptoKeyOrBuilder.java deleted file mode 100644 index 4b01fba94dd1..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/TransientCryptoKeyOrBuilder.java +++ /dev/null @@ -1,37 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface TransientCryptoKeyOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.TransientCryptoKey) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * Name of the key. [required]
-   * This is an arbitrary string used to differentiate different keys.
-   * A unique key is generated per name: two separate `TransientCryptoKey`
-   * protos share the same generated key if their names are the same.
-   * When the data crypto key is generated, this name is not used in any way
-   * (repeating the api call will result in a different key being generated).
-   * 
- * - * string name = 1; - */ - java.lang.String getName(); - /** - *
-   * Name of the key. [required]
-   * This is an arbitrary string used to differentiate different keys.
-   * A unique key is generated per name: two separate `TransientCryptoKey`
-   * protos share the same generated key if their names are the same.
-   * When the data crypto key is generated, this name is not used in any way
-   * (repeating the api call will result in a different key being generated).
-   * 
- * - * string name = 1; - */ - com.google.protobuf.ByteString - getNameBytes(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/UnwrappedCryptoKey.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/UnwrappedCryptoKey.java deleted file mode 100644 index 946cf5a6caf1..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/UnwrappedCryptoKey.java +++ /dev/null @@ -1,476 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Using raw keys is prone to security risks due to accidentally
- * leaking the key. Choose another type of key if possible.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.UnwrappedCryptoKey} - */ -public final class UnwrappedCryptoKey extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.UnwrappedCryptoKey) - UnwrappedCryptoKeyOrBuilder { -private static final long serialVersionUID = 0L; - // Use UnwrappedCryptoKey.newBuilder() to construct. - private UnwrappedCryptoKey(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private UnwrappedCryptoKey() { - key_ = com.google.protobuf.ByteString.EMPTY; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private UnwrappedCryptoKey( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - - key_ = input.readBytes(); - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_UnwrappedCryptoKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_UnwrappedCryptoKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.class, com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.Builder.class); - } - - public static final int KEY_FIELD_NUMBER = 1; - private com.google.protobuf.ByteString key_; - /** - *
-   * The AES 128/192/256 bit key. [required]
-   * 
- * - * bytes key = 1; - */ - public com.google.protobuf.ByteString getKey() { - return key_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (!key_.isEmpty()) { - output.writeBytes(1, key_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!key_.isEmpty()) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, key_); - } - 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.privacy.dlp.v2beta1.UnwrappedCryptoKey)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey other = (com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) obj; - - boolean result = true; - result = result && getKey() - .equals(other.getKey()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + KEY_FIELD_NUMBER; - hash = (53 * hash) + getKey().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey 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.privacy.dlp.v2beta1.UnwrappedCryptoKey parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey 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.privacy.dlp.v2beta1.UnwrappedCryptoKey parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey 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.privacy.dlp.v2beta1.UnwrappedCryptoKey parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Using raw keys is prone to security risks due to accidentally
-   * leaking the key. Choose another type of key if possible.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.UnwrappedCryptoKey} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.UnwrappedCryptoKey) - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKeyOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_UnwrappedCryptoKey_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_UnwrappedCryptoKey_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.class, com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - key_ = com.google.protobuf.ByteString.EMPTY; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_UnwrappedCryptoKey_descriptor; - } - - public com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey build() { - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey buildPartial() { - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey result = new com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey(this); - result.key_ = key_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) { - return mergeFrom((com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey other) { - if (other == com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey.getDefaultInstance()) return this; - if (other.getKey() != com.google.protobuf.ByteString.EMPTY) { - setKey(other.getKey()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.protobuf.ByteString key_ = com.google.protobuf.ByteString.EMPTY; - /** - *
-     * The AES 128/192/256 bit key. [required]
-     * 
- * - * bytes key = 1; - */ - public com.google.protobuf.ByteString getKey() { - return key_; - } - /** - *
-     * The AES 128/192/256 bit key. [required]
-     * 
- * - * bytes key = 1; - */ - public Builder setKey(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - - key_ = value; - onChanged(); - return this; - } - /** - *
-     * The AES 128/192/256 bit key. [required]
-     * 
- * - * bytes key = 1; - */ - public Builder clearKey() { - - key_ = getDefaultInstance().getKey(); - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.UnwrappedCryptoKey) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.UnwrappedCryptoKey) - private static final com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey(); - } - - public static com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public UnwrappedCryptoKey parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new UnwrappedCryptoKey(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.UnwrappedCryptoKey getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/UnwrappedCryptoKeyOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/UnwrappedCryptoKeyOrBuilder.java deleted file mode 100644 index ca177eb60e10..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/UnwrappedCryptoKeyOrBuilder.java +++ /dev/null @@ -1,18 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface UnwrappedCryptoKeyOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.UnwrappedCryptoKey) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * The AES 128/192/256 bit key. [required]
-   * 
- * - * bytes key = 1; - */ - com.google.protobuf.ByteString getKey(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Value.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Value.java deleted file mode 100644 index 2034d4155654..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Value.java +++ /dev/null @@ -1,1452 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * Set of primitive values supported by the system.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Value} - */ -public final class Value extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.Value) - ValueOrBuilder { -private static final long serialVersionUID = 0L; - // Use Value.newBuilder() to construct. - private Value(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private Value() { - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private Value( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 8: { - typeCase_ = 1; - type_ = input.readInt64(); - break; - } - case 17: { - typeCase_ = 2; - type_ = input.readDouble(); - break; - } - case 26: { - java.lang.String s = input.readStringRequireUtf8(); - typeCase_ = 3; - type_ = s; - break; - } - case 32: { - typeCase_ = 4; - type_ = input.readBool(); - break; - } - case 42: { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (typeCase_ == 5) { - subBuilder = ((com.google.protobuf.Timestamp) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.protobuf.Timestamp) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 5; - break; - } - case 50: { - com.google.type.TimeOfDay.Builder subBuilder = null; - if (typeCase_ == 6) { - subBuilder = ((com.google.type.TimeOfDay) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.type.TimeOfDay.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.type.TimeOfDay) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 6; - break; - } - case 58: { - com.google.type.Date.Builder subBuilder = null; - if (typeCase_ == 7) { - subBuilder = ((com.google.type.Date) type_).toBuilder(); - } - type_ = - input.readMessage(com.google.type.Date.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.type.Date) type_); - type_ = subBuilder.buildPartial(); - } - typeCase_ = 7; - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Value_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Value_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Value.class, com.google.privacy.dlp.v2beta1.Value.Builder.class); - } - - private int typeCase_ = 0; - private java.lang.Object type_; - public enum TypeCase - implements com.google.protobuf.Internal.EnumLite { - INTEGER_VALUE(1), - FLOAT_VALUE(2), - STRING_VALUE(3), - BOOLEAN_VALUE(4), - TIMESTAMP_VALUE(5), - TIME_VALUE(6), - DATE_VALUE(7), - TYPE_NOT_SET(0); - private final int value; - private TypeCase(int value) { - this.value = value; - } - /** - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static TypeCase valueOf(int value) { - return forNumber(value); - } - - public static TypeCase forNumber(int value) { - switch (value) { - case 1: return INTEGER_VALUE; - case 2: return FLOAT_VALUE; - case 3: return STRING_VALUE; - case 4: return BOOLEAN_VALUE; - case 5: return TIMESTAMP_VALUE; - case 6: return TIME_VALUE; - case 7: return DATE_VALUE; - case 0: return TYPE_NOT_SET; - default: return null; - } - } - public int getNumber() { - return this.value; - } - }; - - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public static final int INTEGER_VALUE_FIELD_NUMBER = 1; - /** - * int64 integer_value = 1; - */ - public long getIntegerValue() { - if (typeCase_ == 1) { - return (java.lang.Long) type_; - } - return 0L; - } - - public static final int FLOAT_VALUE_FIELD_NUMBER = 2; - /** - * double float_value = 2; - */ - public double getFloatValue() { - if (typeCase_ == 2) { - return (java.lang.Double) type_; - } - return 0D; - } - - public static final int STRING_VALUE_FIELD_NUMBER = 3; - /** - * string string_value = 3; - */ - public java.lang.String getStringValue() { - java.lang.Object ref = ""; - if (typeCase_ == 3) { - ref = type_; - } - 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 (typeCase_ == 3) { - type_ = s; - } - return s; - } - } - /** - * string string_value = 3; - */ - public com.google.protobuf.ByteString - getStringValueBytes() { - java.lang.Object ref = ""; - if (typeCase_ == 3) { - ref = type_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - if (typeCase_ == 3) { - type_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int BOOLEAN_VALUE_FIELD_NUMBER = 4; - /** - * bool boolean_value = 4; - */ - public boolean getBooleanValue() { - if (typeCase_ == 4) { - return (java.lang.Boolean) type_; - } - return false; - } - - public static final int TIMESTAMP_VALUE_FIELD_NUMBER = 5; - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public boolean hasTimestampValue() { - return typeCase_ == 5; - } - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public com.google.protobuf.Timestamp getTimestampValue() { - if (typeCase_ == 5) { - return (com.google.protobuf.Timestamp) type_; - } - return com.google.protobuf.Timestamp.getDefaultInstance(); - } - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public com.google.protobuf.TimestampOrBuilder getTimestampValueOrBuilder() { - if (typeCase_ == 5) { - return (com.google.protobuf.Timestamp) type_; - } - return com.google.protobuf.Timestamp.getDefaultInstance(); - } - - public static final int TIME_VALUE_FIELD_NUMBER = 6; - /** - * .google.type.TimeOfDay time_value = 6; - */ - public boolean hasTimeValue() { - return typeCase_ == 6; - } - /** - * .google.type.TimeOfDay time_value = 6; - */ - public com.google.type.TimeOfDay getTimeValue() { - if (typeCase_ == 6) { - return (com.google.type.TimeOfDay) type_; - } - return com.google.type.TimeOfDay.getDefaultInstance(); - } - /** - * .google.type.TimeOfDay time_value = 6; - */ - public com.google.type.TimeOfDayOrBuilder getTimeValueOrBuilder() { - if (typeCase_ == 6) { - return (com.google.type.TimeOfDay) type_; - } - return com.google.type.TimeOfDay.getDefaultInstance(); - } - - public static final int DATE_VALUE_FIELD_NUMBER = 7; - /** - * .google.type.Date date_value = 7; - */ - public boolean hasDateValue() { - return typeCase_ == 7; - } - /** - * .google.type.Date date_value = 7; - */ - public com.google.type.Date getDateValue() { - if (typeCase_ == 7) { - return (com.google.type.Date) type_; - } - return com.google.type.Date.getDefaultInstance(); - } - /** - * .google.type.Date date_value = 7; - */ - public com.google.type.DateOrBuilder getDateValueOrBuilder() { - if (typeCase_ == 7) { - return (com.google.type.Date) type_; - } - return com.google.type.Date.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (typeCase_ == 1) { - output.writeInt64( - 1, (long)((java.lang.Long) type_)); - } - if (typeCase_ == 2) { - output.writeDouble( - 2, (double)((java.lang.Double) type_)); - } - if (typeCase_ == 3) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, type_); - } - if (typeCase_ == 4) { - output.writeBool( - 4, (boolean)((java.lang.Boolean) type_)); - } - if (typeCase_ == 5) { - output.writeMessage(5, (com.google.protobuf.Timestamp) type_); - } - if (typeCase_ == 6) { - output.writeMessage(6, (com.google.type.TimeOfDay) type_); - } - if (typeCase_ == 7) { - output.writeMessage(7, (com.google.type.Date) type_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (typeCase_ == 1) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size( - 1, (long)((java.lang.Long) type_)); - } - if (typeCase_ == 2) { - size += com.google.protobuf.CodedOutputStream - .computeDoubleSize( - 2, (double)((java.lang.Double) type_)); - } - if (typeCase_ == 3) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, type_); - } - if (typeCase_ == 4) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize( - 4, (boolean)((java.lang.Boolean) type_)); - } - if (typeCase_ == 5) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, (com.google.protobuf.Timestamp) type_); - } - if (typeCase_ == 6) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, (com.google.type.TimeOfDay) type_); - } - if (typeCase_ == 7) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(7, (com.google.type.Date) type_); - } - 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.privacy.dlp.v2beta1.Value)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.Value other = (com.google.privacy.dlp.v2beta1.Value) obj; - - boolean result = true; - result = result && getTypeCase().equals( - other.getTypeCase()); - if (!result) return false; - switch (typeCase_) { - case 1: - result = result && (getIntegerValue() - == other.getIntegerValue()); - break; - case 2: - result = result && ( - java.lang.Double.doubleToLongBits(getFloatValue()) - == java.lang.Double.doubleToLongBits( - other.getFloatValue())); - break; - case 3: - result = result && getStringValue() - .equals(other.getStringValue()); - break; - case 4: - result = result && (getBooleanValue() - == other.getBooleanValue()); - break; - case 5: - result = result && getTimestampValue() - .equals(other.getTimestampValue()); - break; - case 6: - result = result && getTimeValue() - .equals(other.getTimeValue()); - break; - case 7: - result = result && getDateValue() - .equals(other.getDateValue()); - break; - case 0: - default: - } - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (typeCase_) { - case 1: - hash = (37 * hash) + INTEGER_VALUE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getIntegerValue()); - break; - case 2: - hash = (37 * hash) + FLOAT_VALUE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - java.lang.Double.doubleToLongBits(getFloatValue())); - break; - case 3: - hash = (37 * hash) + STRING_VALUE_FIELD_NUMBER; - hash = (53 * hash) + getStringValue().hashCode(); - break; - case 4: - hash = (37 * hash) + BOOLEAN_VALUE_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getBooleanValue()); - break; - case 5: - hash = (37 * hash) + TIMESTAMP_VALUE_FIELD_NUMBER; - hash = (53 * hash) + getTimestampValue().hashCode(); - break; - case 6: - hash = (37 * hash) + TIME_VALUE_FIELD_NUMBER; - hash = (53 * hash) + getTimeValue().hashCode(); - break; - case 7: - hash = (37 * hash) + DATE_VALUE_FIELD_NUMBER; - hash = (53 * hash) + getDateValue().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.Value parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Value parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Value parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Value 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.privacy.dlp.v2beta1.Value parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.Value parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.Value parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Value 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.privacy.dlp.v2beta1.Value parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Value 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.privacy.dlp.v2beta1.Value parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.Value parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.Value prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - 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; - } - /** - *
-   * Set of primitive values supported by the system.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.Value} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.Value) - com.google.privacy.dlp.v2beta1.ValueOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Value_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Value_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Value.class, com.google.privacy.dlp.v2beta1.Value.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.Value.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - typeCase_ = 0; - type_ = null; - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Value_descriptor; - } - - public com.google.privacy.dlp.v2beta1.Value getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.Value.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.Value build() { - com.google.privacy.dlp.v2beta1.Value result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.Value buildPartial() { - com.google.privacy.dlp.v2beta1.Value result = new com.google.privacy.dlp.v2beta1.Value(this); - if (typeCase_ == 1) { - result.type_ = type_; - } - if (typeCase_ == 2) { - result.type_ = type_; - } - if (typeCase_ == 3) { - result.type_ = type_; - } - if (typeCase_ == 4) { - result.type_ = type_; - } - if (typeCase_ == 5) { - if (timestampValueBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = timestampValueBuilder_.build(); - } - } - if (typeCase_ == 6) { - if (timeValueBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = timeValueBuilder_.build(); - } - } - if (typeCase_ == 7) { - if (dateValueBuilder_ == null) { - result.type_ = type_; - } else { - result.type_ = dateValueBuilder_.build(); - } - } - result.typeCase_ = typeCase_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.Value) { - return mergeFrom((com.google.privacy.dlp.v2beta1.Value)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.Value other) { - if (other == com.google.privacy.dlp.v2beta1.Value.getDefaultInstance()) return this; - switch (other.getTypeCase()) { - case INTEGER_VALUE: { - setIntegerValue(other.getIntegerValue()); - break; - } - case FLOAT_VALUE: { - setFloatValue(other.getFloatValue()); - break; - } - case STRING_VALUE: { - typeCase_ = 3; - type_ = other.type_; - onChanged(); - break; - } - case BOOLEAN_VALUE: { - setBooleanValue(other.getBooleanValue()); - break; - } - case TIMESTAMP_VALUE: { - mergeTimestampValue(other.getTimestampValue()); - break; - } - case TIME_VALUE: { - mergeTimeValue(other.getTimeValue()); - break; - } - case DATE_VALUE: { - mergeDateValue(other.getDateValue()); - break; - } - case TYPE_NOT_SET: { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.Value parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.Value) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int typeCase_ = 0; - private java.lang.Object type_; - public TypeCase - getTypeCase() { - return TypeCase.forNumber( - typeCase_); - } - - public Builder clearType() { - typeCase_ = 0; - type_ = null; - onChanged(); - return this; - } - - - /** - * int64 integer_value = 1; - */ - public long getIntegerValue() { - if (typeCase_ == 1) { - return (java.lang.Long) type_; - } - return 0L; - } - /** - * int64 integer_value = 1; - */ - public Builder setIntegerValue(long value) { - typeCase_ = 1; - type_ = value; - onChanged(); - return this; - } - /** - * int64 integer_value = 1; - */ - public Builder clearIntegerValue() { - if (typeCase_ == 1) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - return this; - } - - /** - * double float_value = 2; - */ - public double getFloatValue() { - if (typeCase_ == 2) { - return (java.lang.Double) type_; - } - return 0D; - } - /** - * double float_value = 2; - */ - public Builder setFloatValue(double value) { - typeCase_ = 2; - type_ = value; - onChanged(); - return this; - } - /** - * double float_value = 2; - */ - public Builder clearFloatValue() { - if (typeCase_ == 2) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - return this; - } - - /** - * string string_value = 3; - */ - public java.lang.String getStringValue() { - java.lang.Object ref = ""; - if (typeCase_ == 3) { - ref = type_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (typeCase_ == 3) { - type_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * string string_value = 3; - */ - public com.google.protobuf.ByteString - getStringValueBytes() { - java.lang.Object ref = ""; - if (typeCase_ == 3) { - ref = type_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - if (typeCase_ == 3) { - type_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * string string_value = 3; - */ - public Builder setStringValue( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - typeCase_ = 3; - type_ = value; - onChanged(); - return this; - } - /** - * string string_value = 3; - */ - public Builder clearStringValue() { - if (typeCase_ == 3) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - return this; - } - /** - * string string_value = 3; - */ - public Builder setStringValueBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - typeCase_ = 3; - type_ = value; - onChanged(); - return this; - } - - /** - * bool boolean_value = 4; - */ - public boolean getBooleanValue() { - if (typeCase_ == 4) { - return (java.lang.Boolean) type_; - } - return false; - } - /** - * bool boolean_value = 4; - */ - public Builder setBooleanValue(boolean value) { - typeCase_ = 4; - type_ = value; - onChanged(); - return this; - } - /** - * bool boolean_value = 4; - */ - public Builder clearBooleanValue() { - if (typeCase_ == 4) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> timestampValueBuilder_; - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public boolean hasTimestampValue() { - return typeCase_ == 5; - } - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public com.google.protobuf.Timestamp getTimestampValue() { - if (timestampValueBuilder_ == null) { - if (typeCase_ == 5) { - return (com.google.protobuf.Timestamp) type_; - } - return com.google.protobuf.Timestamp.getDefaultInstance(); - } else { - if (typeCase_ == 5) { - return timestampValueBuilder_.getMessage(); - } - return com.google.protobuf.Timestamp.getDefaultInstance(); - } - } - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public Builder setTimestampValue(com.google.protobuf.Timestamp value) { - if (timestampValueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - timestampValueBuilder_.setMessage(value); - } - typeCase_ = 5; - return this; - } - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public Builder setTimestampValue( - com.google.protobuf.Timestamp.Builder builderForValue) { - if (timestampValueBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - timestampValueBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 5; - return this; - } - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public Builder mergeTimestampValue(com.google.protobuf.Timestamp value) { - if (timestampValueBuilder_ == null) { - if (typeCase_ == 5 && - type_ != com.google.protobuf.Timestamp.getDefaultInstance()) { - type_ = com.google.protobuf.Timestamp.newBuilder((com.google.protobuf.Timestamp) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 5) { - timestampValueBuilder_.mergeFrom(value); - } - timestampValueBuilder_.setMessage(value); - } - typeCase_ = 5; - return this; - } - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public Builder clearTimestampValue() { - if (timestampValueBuilder_ == null) { - if (typeCase_ == 5) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 5) { - typeCase_ = 0; - type_ = null; - } - timestampValueBuilder_.clear(); - } - return this; - } - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public com.google.protobuf.Timestamp.Builder getTimestampValueBuilder() { - return getTimestampValueFieldBuilder().getBuilder(); - } - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - public com.google.protobuf.TimestampOrBuilder getTimestampValueOrBuilder() { - if ((typeCase_ == 5) && (timestampValueBuilder_ != null)) { - return timestampValueBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 5) { - return (com.google.protobuf.Timestamp) type_; - } - return com.google.protobuf.Timestamp.getDefaultInstance(); - } - } - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> - getTimestampValueFieldBuilder() { - if (timestampValueBuilder_ == null) { - if (!(typeCase_ == 5)) { - type_ = com.google.protobuf.Timestamp.getDefaultInstance(); - } - timestampValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( - (com.google.protobuf.Timestamp) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 5; - onChanged();; - return timestampValueBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.type.TimeOfDay, com.google.type.TimeOfDay.Builder, com.google.type.TimeOfDayOrBuilder> timeValueBuilder_; - /** - * .google.type.TimeOfDay time_value = 6; - */ - public boolean hasTimeValue() { - return typeCase_ == 6; - } - /** - * .google.type.TimeOfDay time_value = 6; - */ - public com.google.type.TimeOfDay getTimeValue() { - if (timeValueBuilder_ == null) { - if (typeCase_ == 6) { - return (com.google.type.TimeOfDay) type_; - } - return com.google.type.TimeOfDay.getDefaultInstance(); - } else { - if (typeCase_ == 6) { - return timeValueBuilder_.getMessage(); - } - return com.google.type.TimeOfDay.getDefaultInstance(); - } - } - /** - * .google.type.TimeOfDay time_value = 6; - */ - public Builder setTimeValue(com.google.type.TimeOfDay value) { - if (timeValueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - timeValueBuilder_.setMessage(value); - } - typeCase_ = 6; - return this; - } - /** - * .google.type.TimeOfDay time_value = 6; - */ - public Builder setTimeValue( - com.google.type.TimeOfDay.Builder builderForValue) { - if (timeValueBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - timeValueBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 6; - return this; - } - /** - * .google.type.TimeOfDay time_value = 6; - */ - public Builder mergeTimeValue(com.google.type.TimeOfDay value) { - if (timeValueBuilder_ == null) { - if (typeCase_ == 6 && - type_ != com.google.type.TimeOfDay.getDefaultInstance()) { - type_ = com.google.type.TimeOfDay.newBuilder((com.google.type.TimeOfDay) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 6) { - timeValueBuilder_.mergeFrom(value); - } - timeValueBuilder_.setMessage(value); - } - typeCase_ = 6; - return this; - } - /** - * .google.type.TimeOfDay time_value = 6; - */ - public Builder clearTimeValue() { - if (timeValueBuilder_ == null) { - if (typeCase_ == 6) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 6) { - typeCase_ = 0; - type_ = null; - } - timeValueBuilder_.clear(); - } - return this; - } - /** - * .google.type.TimeOfDay time_value = 6; - */ - public com.google.type.TimeOfDay.Builder getTimeValueBuilder() { - return getTimeValueFieldBuilder().getBuilder(); - } - /** - * .google.type.TimeOfDay time_value = 6; - */ - public com.google.type.TimeOfDayOrBuilder getTimeValueOrBuilder() { - if ((typeCase_ == 6) && (timeValueBuilder_ != null)) { - return timeValueBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 6) { - return (com.google.type.TimeOfDay) type_; - } - return com.google.type.TimeOfDay.getDefaultInstance(); - } - } - /** - * .google.type.TimeOfDay time_value = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.type.TimeOfDay, com.google.type.TimeOfDay.Builder, com.google.type.TimeOfDayOrBuilder> - getTimeValueFieldBuilder() { - if (timeValueBuilder_ == null) { - if (!(typeCase_ == 6)) { - type_ = com.google.type.TimeOfDay.getDefaultInstance(); - } - timeValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.type.TimeOfDay, com.google.type.TimeOfDay.Builder, com.google.type.TimeOfDayOrBuilder>( - (com.google.type.TimeOfDay) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 6; - onChanged();; - return timeValueBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.type.Date, com.google.type.Date.Builder, com.google.type.DateOrBuilder> dateValueBuilder_; - /** - * .google.type.Date date_value = 7; - */ - public boolean hasDateValue() { - return typeCase_ == 7; - } - /** - * .google.type.Date date_value = 7; - */ - public com.google.type.Date getDateValue() { - if (dateValueBuilder_ == null) { - if (typeCase_ == 7) { - return (com.google.type.Date) type_; - } - return com.google.type.Date.getDefaultInstance(); - } else { - if (typeCase_ == 7) { - return dateValueBuilder_.getMessage(); - } - return com.google.type.Date.getDefaultInstance(); - } - } - /** - * .google.type.Date date_value = 7; - */ - public Builder setDateValue(com.google.type.Date value) { - if (dateValueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - type_ = value; - onChanged(); - } else { - dateValueBuilder_.setMessage(value); - } - typeCase_ = 7; - return this; - } - /** - * .google.type.Date date_value = 7; - */ - public Builder setDateValue( - com.google.type.Date.Builder builderForValue) { - if (dateValueBuilder_ == null) { - type_ = builderForValue.build(); - onChanged(); - } else { - dateValueBuilder_.setMessage(builderForValue.build()); - } - typeCase_ = 7; - return this; - } - /** - * .google.type.Date date_value = 7; - */ - public Builder mergeDateValue(com.google.type.Date value) { - if (dateValueBuilder_ == null) { - if (typeCase_ == 7 && - type_ != com.google.type.Date.getDefaultInstance()) { - type_ = com.google.type.Date.newBuilder((com.google.type.Date) type_) - .mergeFrom(value).buildPartial(); - } else { - type_ = value; - } - onChanged(); - } else { - if (typeCase_ == 7) { - dateValueBuilder_.mergeFrom(value); - } - dateValueBuilder_.setMessage(value); - } - typeCase_ = 7; - return this; - } - /** - * .google.type.Date date_value = 7; - */ - public Builder clearDateValue() { - if (dateValueBuilder_ == null) { - if (typeCase_ == 7) { - typeCase_ = 0; - type_ = null; - onChanged(); - } - } else { - if (typeCase_ == 7) { - typeCase_ = 0; - type_ = null; - } - dateValueBuilder_.clear(); - } - return this; - } - /** - * .google.type.Date date_value = 7; - */ - public com.google.type.Date.Builder getDateValueBuilder() { - return getDateValueFieldBuilder().getBuilder(); - } - /** - * .google.type.Date date_value = 7; - */ - public com.google.type.DateOrBuilder getDateValueOrBuilder() { - if ((typeCase_ == 7) && (dateValueBuilder_ != null)) { - return dateValueBuilder_.getMessageOrBuilder(); - } else { - if (typeCase_ == 7) { - return (com.google.type.Date) type_; - } - return com.google.type.Date.getDefaultInstance(); - } - } - /** - * .google.type.Date date_value = 7; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.type.Date, com.google.type.Date.Builder, com.google.type.DateOrBuilder> - getDateValueFieldBuilder() { - if (dateValueBuilder_ == null) { - if (!(typeCase_ == 7)) { - type_ = com.google.type.Date.getDefaultInstance(); - } - dateValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.type.Date, com.google.type.Date.Builder, com.google.type.DateOrBuilder>( - (com.google.type.Date) type_, - getParentForChildren(), - isClean()); - type_ = null; - } - typeCase_ = 7; - onChanged();; - return dateValueBuilder_; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.Value) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.Value) - private static final com.google.privacy.dlp.v2beta1.Value DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.Value(); - } - - public static com.google.privacy.dlp.v2beta1.Value getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Value parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Value(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.Value getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ValueFrequency.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ValueFrequency.java deleted file mode 100644 index 94d3f09e3f97..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ValueFrequency.java +++ /dev/null @@ -1,701 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -/** - *
- * A value of a field, including its frequency.
- * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ValueFrequency} - */ -public final class ValueFrequency extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.ValueFrequency) - ValueFrequencyOrBuilder { -private static final long serialVersionUID = 0L; - // Use ValueFrequency.newBuilder() to construct. - private ValueFrequency(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private ValueFrequency() { - count_ = 0L; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private ValueFrequency( - 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; - default: { - if (!parseUnknownFieldProto3( - input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - com.google.privacy.dlp.v2beta1.Value.Builder subBuilder = null; - if (value_ != null) { - subBuilder = value_.toBuilder(); - } - value_ = input.readMessage(com.google.privacy.dlp.v2beta1.Value.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(value_); - value_ = subBuilder.buildPartial(); - } - - break; - } - case 16: { - - count_ = input.readInt64(); - 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.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ValueFrequency_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ValueFrequency_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ValueFrequency.class, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder.class); - } - - public static final int VALUE_FIELD_NUMBER = 1; - private com.google.privacy.dlp.v2beta1.Value value_; - /** - *
-   * A value contained in the field in question.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public boolean hasValue() { - return value_ != null; - } - /** - *
-   * A value contained in the field in question.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getValue() { - return value_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : value_; - } - /** - *
-   * A value contained in the field in question.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getValueOrBuilder() { - return getValue(); - } - - public static final int COUNT_FIELD_NUMBER = 2; - private long count_; - /** - *
-   * How many times the value is contained in the field.
-   * 
- * - * int64 count = 2; - */ - public long getCount() { - return count_; - } - - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (value_ != null) { - output.writeMessage(1, getValue()); - } - if (count_ != 0L) { - output.writeInt64(2, count_); - } - unknownFields.writeTo(output); - } - - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (value_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getValue()); - } - if (count_ != 0L) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(2, count_); - } - 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.privacy.dlp.v2beta1.ValueFrequency)) { - return super.equals(obj); - } - com.google.privacy.dlp.v2beta1.ValueFrequency other = (com.google.privacy.dlp.v2beta1.ValueFrequency) obj; - - boolean result = true; - result = result && (hasValue() == other.hasValue()); - if (hasValue()) { - result = result && getValue() - .equals(other.getValue()); - } - result = result && (getCount() - == other.getCount()); - result = result && unknownFields.equals(other.unknownFields); - return result; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasValue()) { - hash = (37 * hash) + VALUE_FIELD_NUMBER; - hash = (53 * hash) + getValue().hashCode(); - } - hash = (37 * hash) + COUNT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getCount()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.privacy.dlp.v2beta1.ValueFrequency parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ValueFrequency parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ValueFrequency parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ValueFrequency 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.privacy.dlp.v2beta1.ValueFrequency parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static com.google.privacy.dlp.v2beta1.ValueFrequency parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static com.google.privacy.dlp.v2beta1.ValueFrequency parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ValueFrequency 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.privacy.dlp.v2beta1.ValueFrequency parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ValueFrequency 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.privacy.dlp.v2beta1.ValueFrequency parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static com.google.privacy.dlp.v2beta1.ValueFrequency parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); - } - - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.ValueFrequency prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - *
-   * A value of a field, including its frequency.
-   * 
- * - * Protobuf type {@code google.privacy.dlp.v2beta1.ValueFrequency} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.ValueFrequency) - com.google.privacy.dlp.v2beta1.ValueFrequencyOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ValueFrequency_descriptor; - } - - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ValueFrequency_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.ValueFrequency.class, com.google.privacy.dlp.v2beta1.ValueFrequency.Builder.class); - } - - // Construct using com.google.privacy.dlp.v2beta1.ValueFrequency.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } - } - public Builder clear() { - super.clear(); - if (valueBuilder_ == null) { - value_ = null; - } else { - value_ = null; - valueBuilder_ = null; - } - count_ = 0L; - - return this; - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_ValueFrequency_descriptor; - } - - public com.google.privacy.dlp.v2beta1.ValueFrequency getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.ValueFrequency.getDefaultInstance(); - } - - public com.google.privacy.dlp.v2beta1.ValueFrequency build() { - com.google.privacy.dlp.v2beta1.ValueFrequency result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public com.google.privacy.dlp.v2beta1.ValueFrequency buildPartial() { - com.google.privacy.dlp.v2beta1.ValueFrequency result = new com.google.privacy.dlp.v2beta1.ValueFrequency(this); - if (valueBuilder_ == null) { - result.value_ = value_; - } else { - result.value_ = valueBuilder_.build(); - } - result.count_ = count_; - onBuilt(); - return result; - } - - public Builder clone() { - return (Builder) super.clone(); - } - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.setField(field, value); - } - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { - return (Builder) super.clearField(field); - } - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return (Builder) super.clearOneof(oneof); - } - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { - return (Builder) super.setRepeatedField(field, index, value); - } - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { - return (Builder) super.addRepeatedField(field, value); - } - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.ValueFrequency) { - return mergeFrom((com.google.privacy.dlp.v2beta1.ValueFrequency)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.ValueFrequency other) { - if (other == com.google.privacy.dlp.v2beta1.ValueFrequency.getDefaultInstance()) return this; - if (other.hasValue()) { - mergeValue(other.getValue()); - } - if (other.getCount() != 0L) { - setCount(other.getCount()); - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } - - public final boolean isInitialized() { - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.privacy.dlp.v2beta1.ValueFrequency parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.ValueFrequency) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private com.google.privacy.dlp.v2beta1.Value value_ = null; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> valueBuilder_; - /** - *
-     * A value contained in the field in question.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public boolean hasValue() { - return valueBuilder_ != null || value_ != null; - } - /** - *
-     * A value contained in the field in question.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public com.google.privacy.dlp.v2beta1.Value getValue() { - if (valueBuilder_ == null) { - return value_ == null ? com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : value_; - } else { - return valueBuilder_.getMessage(); - } - } - /** - *
-     * A value contained in the field in question.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public Builder setValue(com.google.privacy.dlp.v2beta1.Value value) { - if (valueBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - value_ = value; - onChanged(); - } else { - valueBuilder_.setMessage(value); - } - - return this; - } - /** - *
-     * A value contained in the field in question.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public Builder setValue( - com.google.privacy.dlp.v2beta1.Value.Builder builderForValue) { - if (valueBuilder_ == null) { - value_ = builderForValue.build(); - onChanged(); - } else { - valueBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - *
-     * A value contained in the field in question.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public Builder mergeValue(com.google.privacy.dlp.v2beta1.Value value) { - if (valueBuilder_ == null) { - if (value_ != null) { - value_ = - com.google.privacy.dlp.v2beta1.Value.newBuilder(value_).mergeFrom(value).buildPartial(); - } else { - value_ = value; - } - onChanged(); - } else { - valueBuilder_.mergeFrom(value); - } - - return this; - } - /** - *
-     * A value contained in the field in question.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public Builder clearValue() { - if (valueBuilder_ == null) { - value_ = null; - onChanged(); - } else { - value_ = null; - valueBuilder_ = null; - } - - return this; - } - /** - *
-     * A value contained in the field in question.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public com.google.privacy.dlp.v2beta1.Value.Builder getValueBuilder() { - - onChanged(); - return getValueFieldBuilder().getBuilder(); - } - /** - *
-     * A value contained in the field in question.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - public com.google.privacy.dlp.v2beta1.ValueOrBuilder getValueOrBuilder() { - if (valueBuilder_ != null) { - return valueBuilder_.getMessageOrBuilder(); - } else { - return value_ == null ? - com.google.privacy.dlp.v2beta1.Value.getDefaultInstance() : value_; - } - } - /** - *
-     * A value contained in the field in question.
-     * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder> - getValueFieldBuilder() { - if (valueBuilder_ == null) { - valueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.privacy.dlp.v2beta1.Value, com.google.privacy.dlp.v2beta1.Value.Builder, com.google.privacy.dlp.v2beta1.ValueOrBuilder>( - getValue(), - getParentForChildren(), - isClean()); - value_ = null; - } - return valueBuilder_; - } - - private long count_ ; - /** - *
-     * How many times the value is contained in the field.
-     * 
- * - * int64 count = 2; - */ - public long getCount() { - return count_; - } - /** - *
-     * How many times the value is contained in the field.
-     * 
- * - * int64 count = 2; - */ - public Builder setCount(long value) { - - count_ = value; - onChanged(); - return this; - } - /** - *
-     * How many times the value is contained in the field.
-     * 
- * - * int64 count = 2; - */ - public Builder clearCount() { - - count_ = 0L; - onChanged(); - return this; - } - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFieldsProto3(unknownFields); - } - - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.ValueFrequency) - } - - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.ValueFrequency) - private static final com.google.privacy.dlp.v2beta1.ValueFrequency DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.ValueFrequency(); - } - - public static com.google.privacy.dlp.v2beta1.ValueFrequency getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public ValueFrequency parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new ValueFrequency(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - public com.google.privacy.dlp.v2beta1.ValueFrequency getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - -} - diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ValueFrequencyOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ValueFrequencyOrBuilder.java deleted file mode 100644 index b53b8646e948..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ValueFrequencyOrBuilder.java +++ /dev/null @@ -1,43 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ValueFrequencyOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.ValueFrequency) - com.google.protobuf.MessageOrBuilder { - - /** - *
-   * A value contained in the field in question.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - boolean hasValue(); - /** - *
-   * A value contained in the field in question.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - com.google.privacy.dlp.v2beta1.Value getValue(); - /** - *
-   * A value contained in the field in question.
-   * 
- * - * .google.privacy.dlp.v2beta1.Value value = 1; - */ - com.google.privacy.dlp.v2beta1.ValueOrBuilder getValueOrBuilder(); - - /** - *
-   * How many times the value is contained in the field.
-   * 
- * - * int64 count = 2; - */ - long getCount(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ValueOrBuilder.java b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ValueOrBuilder.java deleted file mode 100644 index 7b9618601f4b..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/ValueOrBuilder.java +++ /dev/null @@ -1,75 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto - -package com.google.privacy.dlp.v2beta1; - -public interface ValueOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.Value) - com.google.protobuf.MessageOrBuilder { - - /** - * int64 integer_value = 1; - */ - long getIntegerValue(); - - /** - * double float_value = 2; - */ - double getFloatValue(); - - /** - * string string_value = 3; - */ - java.lang.String getStringValue(); - /** - * string string_value = 3; - */ - com.google.protobuf.ByteString - getStringValueBytes(); - - /** - * bool boolean_value = 4; - */ - boolean getBooleanValue(); - - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - boolean hasTimestampValue(); - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - com.google.protobuf.Timestamp getTimestampValue(); - /** - * .google.protobuf.Timestamp timestamp_value = 5; - */ - com.google.protobuf.TimestampOrBuilder getTimestampValueOrBuilder(); - - /** - * .google.type.TimeOfDay time_value = 6; - */ - boolean hasTimeValue(); - /** - * .google.type.TimeOfDay time_value = 6; - */ - com.google.type.TimeOfDay getTimeValue(); - /** - * .google.type.TimeOfDay time_value = 6; - */ - com.google.type.TimeOfDayOrBuilder getTimeValueOrBuilder(); - - /** - * .google.type.Date date_value = 7; - */ - boolean hasDateValue(); - /** - * .google.type.Date date_value = 7; - */ - com.google.type.Date getDateValue(); - /** - * .google.type.Date date_value = 7; - */ - com.google.type.DateOrBuilder getDateValueOrBuilder(); - - public com.google.privacy.dlp.v2beta1.Value.TypeCase getTypeCase(); -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/proto/google/privacy/dlp/v2beta1/dlp.proto b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/proto/google/privacy/dlp/v2beta1/dlp.proto deleted file mode 100644 index 1b978eb6c035..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/proto/google/privacy/dlp/v2beta1/dlp.proto +++ /dev/null @@ -1,1329 +0,0 @@ -// Copyright 2017 Google Inc. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -syntax = "proto3"; - -package google.privacy.dlp.v2beta1; - -import "google/api/annotations.proto"; -import "google/longrunning/operations.proto"; -import "google/privacy/dlp/v2beta1/storage.proto"; -import "google/protobuf/empty.proto"; -import "google/protobuf/timestamp.proto"; -import "google/type/date.proto"; -import "google/type/timeofday.proto"; - -option csharp_namespace = "Google.Cloud.Dlp.V2Beta1"; -option go_package = "google.golang.org/genproto/googleapis/privacy/dlp/v2beta1;dlp"; -option java_multiple_files = true; -option java_outer_classname = "DlpProto"; -option java_package = "com.google.privacy.dlp.v2beta1"; -option php_namespace = "Google\\Cloud\\Dlp\\V2beta1"; - - -// The DLP API is a service that allows clients -// to detect the presence of Personally Identifiable Information (PII) and other -// privacy-sensitive data in user-supplied, unstructured data streams, like text -// blocks or images. -// The service also includes methods for sensitive data redaction and -// scheduling of data scans on Google Cloud Platform based data sets. -service DlpService { - // Finds potentially sensitive info in a list of strings. - // This method has limits on input size, processing time, and output size. - rpc InspectContent(InspectContentRequest) returns (InspectContentResponse) { - option (google.api.http) = { post: "/v2beta1/content:inspect" body: "*" }; - } - - // Redacts potentially sensitive info from a list of strings. - // This method has limits on input size, processing time, and output size. - rpc RedactContent(RedactContentRequest) returns (RedactContentResponse) { - option (google.api.http) = { post: "/v2beta1/content:redact" body: "*" }; - } - - // De-identifies potentially sensitive info from a list of strings. - // This method has limits on input size and output size. - rpc DeidentifyContent(DeidentifyContentRequest) returns (DeidentifyContentResponse) { - option (google.api.http) = { post: "/v2beta1/content:deidentify" body: "*" }; - } - - // Schedules a job scanning content in a Google Cloud Platform data - // repository. - rpc CreateInspectOperation(CreateInspectOperationRequest) returns (google.longrunning.Operation) { - option (google.api.http) = { post: "/v2beta1/inspect/operations" body: "*" }; - } - - // Schedules a job to compute risk analysis metrics over content in a Google - // Cloud Platform repository. - rpc AnalyzeDataSourceRisk(AnalyzeDataSourceRiskRequest) returns (google.longrunning.Operation) { - option (google.api.http) = { post: "/v2beta1/dataSource:analyze" body: "*" }; - } - - // Returns list of results for given inspect operation result set id. - rpc ListInspectFindings(ListInspectFindingsRequest) returns (ListInspectFindingsResponse) { - option (google.api.http) = { get: "/v2beta1/{name=inspect/results/*}/findings" }; - } - - // Returns sensitive information types for given category. - rpc ListInfoTypes(ListInfoTypesRequest) returns (ListInfoTypesResponse) { - option (google.api.http) = { get: "/v2beta1/rootCategories/{category=*}/infoTypes" }; - } - - // Returns the list of root categories of sensitive information. - rpc ListRootCategories(ListRootCategoriesRequest) returns (ListRootCategoriesResponse) { - option (google.api.http) = { get: "/v2beta1/rootCategories" }; - } -} - -// Configuration description of the scanning process. -// When used with redactContent only info_types and min_likelihood are currently -// used. -message InspectConfig { - // Max findings configuration per info type, per content item or long running - // operation. - message InfoTypeLimit { - // Type of information the findings limit applies to. Only one limit per - // info_type should be provided. If InfoTypeLimit does not have an - // info_type, the DLP API applies the limit against all info_types that are - // found but not specified in another InfoTypeLimit. - InfoType info_type = 1; - - // Max findings limit for the given infoType. - int32 max_findings = 2; - } - - // Restricts what info_types to look for. The values must correspond to - // InfoType values returned by ListInfoTypes or found in documentation. - // Empty info_types runs all enabled detectors. - repeated InfoType info_types = 1; - - // Only returns findings equal or above this threshold. - Likelihood min_likelihood = 2; - - // Limits the number of findings per content item or long running operation. - int32 max_findings = 3; - - // When true, a contextual quote from the data that triggered a finding is - // included in the response; see Finding.quote. - bool include_quote = 4; - - // When true, excludes type information of the findings. - bool exclude_types = 6; - - // Configuration of findings limit given for specified info types. - repeated InfoTypeLimit info_type_limits = 7; - - // Custom info types provided by the user. - repeated CustomInfoType custom_info_types = 8; -} - -// Additional configuration for inspect long running operations. -message OperationConfig { - // Max number of findings per file, Datastore entity, or database row. - int64 max_item_findings = 1; -} - -// Container structure for the content to inspect. -message ContentItem { - // Type of the content, as defined in Content-Type HTTP header. - // Supported types are: all "text" types, octet streams, PNG images, - // JPEG images. - string type = 1; - - // Data of the item either in the byte array or UTF-8 string form. - oneof data_item { - // Content data to inspect or redact. - bytes data = 2; - - // String data to inspect or redact. - string value = 3; - - // Structured content for inspection. - Table table = 4; - } -} - -// Structured content to inspect. Up to 50,000 `Value`s per request allowed. -message Table { - message Row { - repeated Value values = 1; - } - - repeated FieldId headers = 1; - - repeated Row rows = 2; -} - -// All the findings for a single scanned item. -message InspectResult { - // List of findings for an item. - repeated Finding findings = 1; - - // If true, then this item might have more findings than were returned, - // and the findings returned are an arbitrary subset of all findings. - // The findings list might be truncated because the input items were too - // large, or because the server reached the maximum amount of resources - // allowed for a single API call. For best results, divide the input into - // smaller batches. - bool findings_truncated = 2; -} - -// Container structure describing a single finding within a string or image. -message Finding { - // The specific string that may be potentially sensitive info. - string quote = 1; - - // The specific type of info the string might be. - InfoType info_type = 2; - - // Estimate of how likely it is that the info_type is correct. - Likelihood likelihood = 3; - - // Location of the info found. - Location location = 4; - - // Timestamp when finding was detected. - google.protobuf.Timestamp create_time = 6; -} - -// Specifies the location of a finding within its source item. -message Location { - // Zero-based byte offsets within a content item. - Range byte_range = 1; - - // Character offsets within a content item, included when content type - // is a text. Default charset assumed to be UTF-8. - Range codepoint_range = 2; - - // Location within an image's pixels. - repeated ImageLocation image_boxes = 3; - - // Key of the finding. - RecordKey record_key = 4; - - // Field id of the field containing the finding. - FieldId field_id = 5; - - // Location within a `ContentItem.Table`. - TableLocation table_location = 6; -} - -// Location of a finding within a `ContentItem.Table`. -message TableLocation { - // The zero-based index of the row where the finding is located. - int64 row_index = 1; -} - -// Generic half-open interval [start, end) -message Range { - // Index of the first character of the range (inclusive). - int64 start = 1; - - // Index of the last character of the range (exclusive). - int64 end = 2; -} - -// Bounding box encompassing detected text within an image. -message ImageLocation { - // Top coordinate of the bounding box. (0,0) is upper left. - int32 top = 1; - - // Left coordinate of the bounding box. (0,0) is upper left. - int32 left = 2; - - // Width of the bounding box in pixels. - int32 width = 3; - - // Height of the bounding box in pixels. - int32 height = 4; -} - -// Request to search for potentially sensitive info in a list of items -// and replace it with a default or provided content. -message RedactContentRequest { - message ReplaceConfig { - // Type of information to replace. Only one ReplaceConfig per info_type - // should be provided. If ReplaceConfig does not have an info_type, the DLP - // API matches it against all info_types that are found but not specified in - // another ReplaceConfig. - InfoType info_type = 1; - - // Content replacing sensitive information of given type. Max 256 chars. - string replace_with = 2; - } - - // Configuration for determining how redaction of images should occur. - message ImageRedactionConfig { - // Type of information to redact from images. - oneof target { - // Only one per info_type should be provided per request. If not - // specified, and redact_all_text is false, the DLP API will redact all - // text that it matches against all info_types that are found, but not - // specified in another ImageRedactionConfig. - InfoType info_type = 1; - - // If true, all text found in the image, regardless whether it matches an - // info_type, is redacted. - bool redact_all_text = 2; - } - - // The color to use when redacting content from an image. If not specified, - // the default is black. - Color redaction_color = 3; - } - - // Configuration for the inspector. - InspectConfig inspect_config = 1; - - // The list of items to inspect. Up to 100 are allowed per request. - repeated ContentItem items = 2; - - // The strings to replace findings text findings with. Must specify at least - // one of these or one ImageRedactionConfig if redacting images. - repeated ReplaceConfig replace_configs = 3; - - // The configuration for specifying what content to redact from images. - repeated ImageRedactionConfig image_redaction_configs = 4; -} - -// Represents a color in the RGB color space. -message Color { - // The amount of red in the color as a value in the interval [0, 1]. - float red = 1; - - // The amount of green in the color as a value in the interval [0, 1]. - float green = 2; - - // The amount of blue in the color as a value in the interval [0, 1]. - float blue = 3; -} - -// Results of redacting a list of items. -message RedactContentResponse { - // The redacted content. - repeated ContentItem items = 1; -} - -// Request to de-identify a list of items. -message DeidentifyContentRequest { - // Configuration for the de-identification of the list of content items. - DeidentifyConfig deidentify_config = 1; - - // Configuration for the inspector. - InspectConfig inspect_config = 2; - - // The list of items to inspect. Up to 100 are allowed per request. - // All items will be treated as text/*. - repeated ContentItem items = 3; -} - -// Results of de-identifying a list of items. -message DeidentifyContentResponse { - repeated ContentItem items = 1; - - // A review of the transformations that took place for each item. - repeated DeidentificationSummary summaries = 2; -} - -// Request to search for potentially sensitive info in a list of items. -message InspectContentRequest { - // Configuration for the inspector. - InspectConfig inspect_config = 1; - - // The list of items to inspect. Items in a single request are - // considered "related" unless inspect_config.independent_inputs is true. - // Up to 100 are allowed per request. - repeated ContentItem items = 2; -} - -// Results of inspecting a list of items. -message InspectContentResponse { - // Each content_item from the request has a result in this list, in the - // same order as the request. - repeated InspectResult results = 1; -} - -// Request for scheduling a scan of a data subset from a Google Platform data -// repository. -message CreateInspectOperationRequest { - // Configuration for the inspector. - InspectConfig inspect_config = 1; - - // Specification of the data set to process. - StorageConfig storage_config = 2; - - // Optional location to store findings. - OutputStorageConfig output_config = 3; - - // Additional configuration settings for long running operations. - OperationConfig operation_config = 5; -} - -// Cloud repository for storing output. -message OutputStorageConfig { - oneof type { - // Store findings in a new table in the dataset. - BigQueryTable table = 1; - - // The path to a Google Cloud Storage location to store output. - // The bucket must already exist and - // the Google APIs service account for DLP must have write permission to - // write to the given bucket. - // Results are split over multiple csv files with each file name matching - // the pattern "[operation_id]_[count].csv", for example - // `3094877188788974909_1.csv`. The `operation_id` matches the - // identifier for the Operation, and the `count` is a counter used for - // tracking the number of files written. - // - // The CSV file(s) contain the following columns regardless of storage type - // scanned: - // - id - // - info_type - // - likelihood - // - byte size of finding - // - quote - // - timestamp - // - // For Cloud Storage the next columns are: - // - // - file_path - // - start_offset - // - // For Cloud Datastore the next columns are: - // - // - project_id - // - namespace_id - // - path - // - column_name - // - offset - // - // For BigQuery the next columns are: - // - // - row_number - // - project_id - // - dataset_id - // - table_id - CloudStoragePath storage_path = 2; - } -} - -// Statistics regarding a specific InfoType. -message InfoTypeStatistics { - // The type of finding this stat is for. - InfoType info_type = 1; - - // Number of findings for this info type. - int64 count = 2; -} - -// Metadata returned within GetOperation for an inspect request. -message InspectOperationMetadata { - // Total size in bytes that were processed. - int64 processed_bytes = 1; - - // Estimate of the number of bytes to process. - int64 total_estimated_bytes = 4; - - repeated InfoTypeStatistics info_type_stats = 2; - - // The time which this request was started. - google.protobuf.Timestamp create_time = 3; - - // The inspect config used to create the Operation. - InspectConfig request_inspect_config = 5; - - // The storage config used to create the Operation. - StorageConfig request_storage_config = 6; - - // Optional location to store findings. - OutputStorageConfig request_output_config = 7; -} - -// The operational data. -message InspectOperationResult { - // The server-assigned name, which is only unique within the same service that - // originally returns it. If you use the default HTTP mapping, the - // `name` should have the format of `inspect/results/{id}`. - string name = 1; -} - -// Request for the list of results in a given inspect operation. -message ListInspectFindingsRequest { - // Identifier of the results set returned as metadata of - // the longrunning operation created by a call to InspectDataSource. - // Should be in the format of `inspect/results/{id}`. - string name = 1; - - // Maximum number of results to return. - // If 0, the implementation selects a reasonable value. - int32 page_size = 2; - - // The value returned by the last `ListInspectFindingsResponse`; indicates - // that this is a continuation of a prior `ListInspectFindings` call, and that - // the system should return the next page of data. - string page_token = 3; - - // Restricts findings to items that match. Supports info_type and likelihood. - // - // Examples: - // - // - info_type=EMAIL_ADDRESS - // - info_type=PHONE_NUMBER,EMAIL_ADDRESS - // - likelihood=VERY_LIKELY - // - likelihood=VERY_LIKELY,LIKELY - // - info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY - string filter = 4; -} - -// Response to the ListInspectFindings request. -message ListInspectFindingsResponse { - // The results. - InspectResult result = 1; - - // If not empty, indicates that there may be more results that match the - // request; this value should be passed in a new `ListInspectFindingsRequest`. - string next_page_token = 2; -} - -// Description of the information type (infoType). -message InfoTypeDescription { - // Internal name of the infoType. - string name = 1; - - // Human readable form of the infoType name. - string display_name = 2; - - // List of categories this infoType belongs to. - repeated CategoryDescription categories = 3; -} - -// Request for the list of info types belonging to a given category, -// or all supported info types if no category is specified. -message ListInfoTypesRequest { - // Category name as returned by ListRootCategories. - string category = 1; - - // Optional BCP-47 language code for localized info type friendly - // names. If omitted, or if localized strings are not available, - // en-US strings will be returned. - string language_code = 2; -} - -// Response to the ListInfoTypes request. -message ListInfoTypesResponse { - // Set of sensitive info types belonging to a category. - repeated InfoTypeDescription info_types = 1; -} - -// Info Type Category description. -message CategoryDescription { - // Internal name of the category. - string name = 1; - - // Human readable form of the category name. - string display_name = 2; -} - -// Request for root categories of Info Types supported by the API. -// Example values might include "FINANCE", "HEALTH", "FAST", "DEFAULT". -message ListRootCategoriesRequest { - // Optional language code for localized friendly category names. - // If omitted or if localized strings are not available, - // en-US strings will be returned. - string language_code = 1; -} - -// Response for ListRootCategories request. -message ListRootCategoriesResponse { - // List of all into type categories supported by the API. - repeated CategoryDescription categories = 1; -} - -// Request for creating a risk analysis operation. -message AnalyzeDataSourceRiskRequest { - // Privacy metric to compute. - PrivacyMetric privacy_metric = 1; - - // Input dataset to compute metrics over. - BigQueryTable source_table = 3; -} - -// Privacy metric to compute for reidentification risk analysis. -message PrivacyMetric { - // Compute numerical stats over an individual column, including - // min, max, and quantiles. - message NumericalStatsConfig { - // Field to compute numerical stats on. Supported types are - // integer, float, date, datetime, timestamp, time. - FieldId field = 1; - } - - // Compute numerical stats over an individual column, including - // number of distinct values and value count distribution. - message CategoricalStatsConfig { - // Field to compute categorical stats on. All column types are - // supported except for arrays and structs. However, it may be more - // informative to use NumericalStats when the field type is supported, - // depending on the data. - FieldId field = 1; - } - - // k-anonymity metric, used for analysis of reidentification risk. - message KAnonymityConfig { - // Set of fields to compute k-anonymity over. When multiple fields are - // specified, they are considered a single composite key. Structs and - // repeated data types are not supported; however, nested fields are - // supported so long as they are not structs themselves or nested within - // a repeated field. - repeated FieldId quasi_ids = 1; - - // Optional message indicating that each distinct `EntityId` should not - // contribute to the k-anonymity count more than once per equivalence class. - EntityId entity_id = 2; - } - - // l-diversity metric, used for analysis of reidentification risk. - message LDiversityConfig { - // Set of quasi-identifiers indicating how equivalence classes are - // defined for the l-diversity computation. When multiple fields are - // specified, they are considered a single composite key. - repeated FieldId quasi_ids = 1; - - // Sensitive field for computing the l-value. - FieldId sensitive_attribute = 2; - } - - oneof type { - NumericalStatsConfig numerical_stats_config = 1; - - CategoricalStatsConfig categorical_stats_config = 2; - - KAnonymityConfig k_anonymity_config = 3; - - LDiversityConfig l_diversity_config = 4; - } -} - -// Metadata returned within the -// [`riskAnalysis.operations.get`](/dlp/docs/reference/rest/v2beta1/riskAnalysis.operations/get) -// for risk analysis. -message RiskAnalysisOperationMetadata { - // The time which this request was started. - google.protobuf.Timestamp create_time = 1; - - // Privacy metric to compute. - PrivacyMetric requested_privacy_metric = 2; - - // Input dataset to compute metrics over. - BigQueryTable requested_source_table = 3; -} - -// Result of a risk analysis -// [`Operation`](/dlp/docs/reference/rest/v2beta1/inspect.operations) -// request. -message RiskAnalysisOperationResult { - // Result of the numerical stats computation. - message NumericalStatsResult { - // Minimum value appearing in the column. - Value min_value = 1; - - // Maximum value appearing in the column. - Value max_value = 2; - - // List of 99 values that partition the set of field values into 100 equal - // sized buckets. - repeated Value quantile_values = 4; - } - - // Result of the categorical stats computation. - message CategoricalStatsResult { - // Histogram bucket of value frequencies in the column. - message CategoricalStatsHistogramBucket { - // Lower bound on the value frequency of the values in this bucket. - int64 value_frequency_lower_bound = 1; - - // Upper bound on the value frequency of the values in this bucket. - int64 value_frequency_upper_bound = 2; - - // Total number of records in this bucket. - int64 bucket_size = 3; - - // Sample of value frequencies in this bucket. The total number of - // values returned per bucket is capped at 20. - repeated ValueFrequency bucket_values = 4; - } - - // Histogram of value frequencies in the column. - repeated CategoricalStatsHistogramBucket value_frequency_histogram_buckets = 5; - } - - // Result of the k-anonymity computation. - message KAnonymityResult { - // The set of columns' values that share the same k-anonymity value. - message KAnonymityEquivalenceClass { - // Set of values defining the equivalence class. One value per - // quasi-identifier column in the original KAnonymity metric message. - // The order is always the same as the original request. - repeated Value quasi_ids_values = 1; - - // Size of the equivalence class, for example number of rows with the - // above set of values. - int64 equivalence_class_size = 2; - } - - // Histogram bucket of equivalence class sizes in the table. - message KAnonymityHistogramBucket { - // Lower bound on the size of the equivalence classes in this bucket. - int64 equivalence_class_size_lower_bound = 1; - - // Upper bound on the size of the equivalence classes in this bucket. - int64 equivalence_class_size_upper_bound = 2; - - // Total number of records in this bucket. - int64 bucket_size = 3; - - // Sample of equivalence classes in this bucket. The total number of - // classes returned per bucket is capped at 20. - repeated KAnonymityEquivalenceClass bucket_values = 4; - } - - // Histogram of k-anonymity equivalence classes. - repeated KAnonymityHistogramBucket equivalence_class_histogram_buckets = 5; - } - - // Result of the l-diversity computation. - message LDiversityResult { - // The set of columns' values that share the same l-diversity value. - message LDiversityEquivalenceClass { - // Quasi-identifier values defining the k-anonymity equivalence - // class. The order is always the same as the original request. - repeated Value quasi_ids_values = 1; - - // Size of the k-anonymity equivalence class. - int64 equivalence_class_size = 2; - - // Number of distinct sensitive values in this equivalence class. - int64 num_distinct_sensitive_values = 3; - - // Estimated frequencies of top sensitive values. - repeated ValueFrequency top_sensitive_values = 4; - } - - // Histogram bucket of sensitive value frequencies in the table. - message LDiversityHistogramBucket { - // Lower bound on the sensitive value frequencies of the equivalence - // classes in this bucket. - int64 sensitive_value_frequency_lower_bound = 1; - - // Upper bound on the sensitive value frequencies of the equivalence - // classes in this bucket. - int64 sensitive_value_frequency_upper_bound = 2; - - // Total number of records in this bucket. - int64 bucket_size = 3; - - // Sample of equivalence classes in this bucket. The total number of - // classes returned per bucket is capped at 20. - repeated LDiversityEquivalenceClass bucket_values = 4; - } - - // Histogram of l-diversity equivalence class sensitive value frequencies. - repeated LDiversityHistogramBucket sensitive_value_frequency_histogram_buckets = 5; - } - - // Values associated with this metric. - oneof result { - NumericalStatsResult numerical_stats_result = 3; - - CategoricalStatsResult categorical_stats_result = 4; - - KAnonymityResult k_anonymity_result = 5; - - LDiversityResult l_diversity_result = 6; - } -} - -// A value of a field, including its frequency. -message ValueFrequency { - // A value contained in the field in question. - Value value = 1; - - // How many times the value is contained in the field. - int64 count = 2; -} - -// Set of primitive values supported by the system. -message Value { - oneof type { - int64 integer_value = 1; - - double float_value = 2; - - string string_value = 3; - - bool boolean_value = 4; - - google.protobuf.Timestamp timestamp_value = 5; - - google.type.TimeOfDay time_value = 6; - - google.type.Date date_value = 7; - } -} - -// The configuration that controls how the data will change. -message DeidentifyConfig { - oneof transformation { - // Treat the dataset as free-form text and apply the same free text - // transformation everywhere. - InfoTypeTransformations info_type_transformations = 1; - - // Treat the dataset as structured. Transformations can be applied to - // specific locations within structured datasets, such as transforming - // a column within a table. - RecordTransformations record_transformations = 2; - } -} - -// A rule for transforming a value. -message PrimitiveTransformation { - oneof transformation { - ReplaceValueConfig replace_config = 1; - - RedactConfig redact_config = 2; - - CharacterMaskConfig character_mask_config = 3; - - CryptoReplaceFfxFpeConfig crypto_replace_ffx_fpe_config = 4; - - FixedSizeBucketingConfig fixed_size_bucketing_config = 5; - - BucketingConfig bucketing_config = 6; - - ReplaceWithInfoTypeConfig replace_with_info_type_config = 7; - - TimePartConfig time_part_config = 8; - - CryptoHashConfig crypto_hash_config = 9; - } -} - -// For use with `Date`, `Timestamp`, and `TimeOfDay`, extract or preserve a -// portion of the value. -message TimePartConfig { - enum TimePart { - TIME_PART_UNSPECIFIED = 0; - - // [000-9999] - YEAR = 1; - - // [1-12] - MONTH = 2; - - // [1-31] - DAY_OF_MONTH = 3; - - // [1-7] - DAY_OF_WEEK = 4; - - // [1-52] - WEEK_OF_YEAR = 5; - - // [0-24] - HOUR_OF_DAY = 6; - } - - TimePart part_to_extract = 1; -} - -// Pseudonymization method that generates surrogates via cryptographic hashing. -// Uses SHA-256. -// Outputs a 32 byte digest as an uppercase hex string -// (for example, 41D1567F7F99F1DC2A5FAB886DEE5BEE). -// Currently, only string and integer values can be hashed. -message CryptoHashConfig { - // The key used by the hash function. - CryptoKey crypto_key = 1; -} - -// Replace each input value with a given `Value`. -message ReplaceValueConfig { - // Value to replace it with. - Value new_value = 1; -} - -// Replace each matching finding with the name of the info_type. -message ReplaceWithInfoTypeConfig { - -} - -// Redact a given value. For example, if used with an `InfoTypeTransformation` -// transforming PHONE_NUMBER, and input 'My phone number is 206-555-0123', the -// output would be 'My phone number is '. -message RedactConfig { - -} - -// Characters to skip when doing deidentification of a value. These will be left -// alone and skipped. -message CharsToIgnore { - enum CharacterGroup { - CHARACTER_GROUP_UNSPECIFIED = 0; - - // 0-9 - NUMERIC = 1; - - // A-Z - ALPHA_UPPER_CASE = 2; - - // a-z - ALPHA_LOWER_CASE = 3; - - // US Punctuation, one of !"#$%&'()*+,-./:;<=>?@[\]^_`{|}~ - PUNCTUATION = 4; - - // Whitespace character, one of [ \t\n\x0B\f\r] - WHITESPACE = 5; - } - - oneof characters { - string characters_to_skip = 1; - - CharacterGroup common_characters_to_ignore = 2; - } -} - -// Partially mask a string by replacing a given number of characters with a -// fixed character. Masking can start from the beginning or end of the string. -// This can be used on data of any type (numbers, longs, and so on) and when -// de-identifying structured data we'll attempt to preserve the original data's -// type. (This allows you to take a long like 123 and modify it to a string like -// **3. -message CharacterMaskConfig { - // Character to mask the sensitive values—for example, "*" for an - // alphabetic string such as name, or "0" for a numeric string such as ZIP - // code or credit card number. String must have length 1. If not supplied, we - // will default to "*" for strings, 0 for digits. - string masking_character = 1; - - // Number of characters to mask. If not set, all matching chars will be - // masked. Skipped characters do not count towards this tally. - int32 number_to_mask = 2; - - // Mask characters in reverse order. For example, if `masking_character` is - // '0', number_to_mask is 14, and `reverse_order` is false, then - // 1234-5678-9012-3456 -> 00000000000000-3456 - // If `masking_character` is '*', `number_to_mask` is 3, and `reverse_order` - // is true, then 12345 -> 12*** - bool reverse_order = 3; - - // When masking a string, items in this list will be skipped when replacing. - // For example, if your string is 555-555-5555 and you ask us to skip `-` and - // mask 5 chars with * we would produce ***-*55-5555. - repeated CharsToIgnore characters_to_ignore = 4; -} - -// Buckets values based on fixed size ranges. The -// Bucketing transformation can provide all of this functionality, -// but requires more configuration. This message is provided as a convenience to -// the user for simple bucketing strategies. -// The resulting value will be a hyphenated string of -// lower_bound-upper_bound. -// This can be used on data of type: double, long. -// If the bound Value type differs from the type of data -// being transformed, we will first attempt converting the type of the data to -// be transformed to match the type of the bound before comparing. -message FixedSizeBucketingConfig { - // Lower bound value of buckets. All values less than `lower_bound` are - // grouped together into a single bucket; for example if `lower_bound` = 10, - // then all values less than 10 are replaced with the value “-10”. [Required]. - Value lower_bound = 1; - - // Upper bound value of buckets. All values greater than upper_bound are - // grouped together into a single bucket; for example if `upper_bound` = 89, - // then all values greater than 89 are replaced with the value “89+”. - // [Required]. - Value upper_bound = 2; - - // Size of each bucket (except for minimum and maximum buckets). So if - // `lower_bound` = 10, `upper_bound` = 89, and `bucket_size` = 10, then the - // following buckets would be used: -10, 10-20, 20-30, 30-40, 40-50, 50-60, - // 60-70, 70-80, 80-89, 89+. Precision up to 2 decimals works. [Required]. - double bucket_size = 3; -} - -// Generalization function that buckets values based on ranges. The ranges and -// replacement values are dynamically provided by the user for custom behavior, -// such as 1-30 -> LOW 31-65 -> MEDIUM 66-100 -> HIGH -// This can be used on -// data of type: number, long, string, timestamp. -// If the bound `Value` type differs from the type of data being transformed, we -// will first attempt converting the type of the data to be transformed to match -// the type of the bound before comparing. -message BucketingConfig { - // Buckets represented as ranges, along with replacement values. Ranges must - // be non-overlapping. - message Bucket { - // Lower bound of the range, inclusive. Type should be the same as max if - // used. - Value min = 1; - - // Upper bound of the range, exclusive; type must match min. - Value max = 2; - - // Replacement value for this bucket. If not provided - // the default behavior will be to hyphenate the min-max range. - Value replacement_value = 3; - } - - repeated Bucket buckets = 1; -} - -// Replaces an identifier with a surrogate using FPE with the FFX -// mode of operation. -// The identifier must be representable by the US-ASCII character set. -// For a given crypto key and context, the same identifier will be -// replaced with the same surrogate. -// Identifiers must be at least two characters long. -// In the case that the identifier is the empty string, it will be skipped. -message CryptoReplaceFfxFpeConfig { - // These are commonly used subsets of the alphabet that the FFX mode - // natively supports. In the algorithm, the alphabet is selected using - // the "radix". Therefore each corresponds to particular radix. - enum FfxCommonNativeAlphabet { - FFX_COMMON_NATIVE_ALPHABET_UNSPECIFIED = 0; - - // [0-9] (radix of 10) - NUMERIC = 1; - - // [0-9A-F] (radix of 16) - HEXADECIMAL = 2; - - // [0-9A-Z] (radix of 36) - UPPER_CASE_ALPHA_NUMERIC = 3; - - // [0-9A-Za-z] (radix of 62) - ALPHA_NUMERIC = 4; - } - - // The key used by the encryption algorithm. [required] - CryptoKey crypto_key = 1; - - // A context may be used for higher security since the same - // identifier in two different contexts likely will be given a distinct - // surrogate. The principle is that the likeliness is inversely related - // to the ratio of the number of distinct identifiers per context over the - // number of possible surrogates: As long as this ratio is small, the - // likehood is large. - // - // If the context is not set, a default tweak will be used. - // If the context is set but: - // - // 1. there is no record present when transforming a given value or - // 1. the field is not present when transforming a given value, - // - // a default tweak will be used. - // - // Note that case (1) is expected when an `InfoTypeTransformation` is - // applied to both structured and non-structured `ContentItem`s. - // Currently, the referenced field may be of value type integer or string. - // - // The tweak is constructed as a sequence of bytes in big endian byte order - // such that: - // - // - a 64 bit integer is encoded followed by a single byte of value 1 - // - a string is encoded in UTF-8 format followed by a single byte of value 2 - // - // This is also known as the 'tweak', as in tweakable encryption. - FieldId context = 2; - - oneof alphabet { - FfxCommonNativeAlphabet common_alphabet = 4; - - // This is supported by mapping these to the alphanumeric characters - // that the FFX mode natively supports. This happens before/after - // encryption/decryption. - // Each character listed must appear only once. - // Number of characters must be in the range [2, 62]. - // This must be encoded as ASCII. - // The order of characters does not matter. - string custom_alphabet = 5; - - // The native way to select the alphabet. Must be in the range [2, 62]. - int32 radix = 6; - } -} - -// This is a data encryption key (DEK) (as opposed to -// a key encryption key (KEK) stored by KMS). -// When using KMS to wrap/unwrap DEKs, be sure to set an appropriate -// IAM policy on the KMS CryptoKey (KEK) to ensure an attacker cannot -// unwrap the data crypto key. -message CryptoKey { - oneof source { - TransientCryptoKey transient = 1; - - UnwrappedCryptoKey unwrapped = 2; - - KmsWrappedCryptoKey kms_wrapped = 3; - } -} - -// Use this to have a random data crypto key generated. -// It will be discarded after the operation/request finishes. -message TransientCryptoKey { - // Name of the key. [required] - // This is an arbitrary string used to differentiate different keys. - // A unique key is generated per name: two separate `TransientCryptoKey` - // protos share the same generated key if their names are the same. - // When the data crypto key is generated, this name is not used in any way - // (repeating the api call will result in a different key being generated). - string name = 1; -} - -// Using raw keys is prone to security risks due to accidentally -// leaking the key. Choose another type of key if possible. -message UnwrappedCryptoKey { - // The AES 128/192/256 bit key. [required] - bytes key = 1; -} - -// Include to use an existing data crypto key wrapped by KMS. -// Authorization requires the following IAM permissions when sending a request -// to perform a crypto transformation using a kms-wrapped crypto key: -// dlp.kms.encrypt -message KmsWrappedCryptoKey { - // The wrapped data crypto key. [required] - bytes wrapped_key = 1; - - // The resource name of the KMS CryptoKey to use for unwrapping. [required] - string crypto_key_name = 2; -} - -// A type of transformation that will scan unstructured text and -// apply various `PrimitiveTransformation`s to each finding, where the -// transformation is applied to only values that were identified as a specific -// info_type. -message InfoTypeTransformations { - // A transformation to apply to text that is identified as a specific - // info_type. - message InfoTypeTransformation { - // Info types to apply the transformation to. Empty list will match all - // available info types for this transformation. - repeated InfoType info_types = 1; - - // Primitive transformation to apply to the info type. [required] - PrimitiveTransformation primitive_transformation = 2; - } - - // Transformation for each info type. Cannot specify more than one - // for a given info type. [required] - repeated InfoTypeTransformation transformations = 1; -} - -// The transformation to apply to the field. -message FieldTransformation { - // Input field(s) to apply the transformation to. [required] - repeated FieldId fields = 1; - - // Only apply the transformation if the condition evaluates to true for the - // given `RecordCondition`. The conditions are allowed to reference fields - // that are not used in the actual transformation. [optional] - // - // Example Use Cases: - // - // - Apply a different bucket transformation to an age column if the zip code - // column for the same record is within a specific range. - // - Redact a field if the date of birth field is greater than 85. - RecordCondition condition = 3; - - // Transformation to apply. [required] - oneof transformation { - // Apply the transformation to the entire field. - PrimitiveTransformation primitive_transformation = 4; - - // Treat the contents of the field as free text, and selectively - // transform content that matches an `InfoType`. - InfoTypeTransformations info_type_transformations = 5; - } -} - -// A type of transformation that is applied over structured data such as a -// table. -message RecordTransformations { - // Transform the record by applying various field transformations. - repeated FieldTransformation field_transformations = 1; - - // Configuration defining which records get suppressed entirely. Records that - // match any suppression rule are omitted from the output [optional]. - repeated RecordSuppression record_suppressions = 2; -} - -// Configuration to suppress records whose suppression conditions evaluate to -// true. -message RecordSuppression { - RecordCondition condition = 1; -} - -// A condition for determining whether a transformation should be applied to -// a field. -message RecordCondition { - // The field type of `value` and `field` do not need to match to be - // considered equal, but not all comparisons are possible. - // - // A `value` of type: - // - // - `string` can be compared against all other types - // - `boolean` can only be compared against other booleans - // - `integer` can be compared against doubles or a string if the string value - // can be parsed as an integer. - // - `double` can be compared against integers or a string if the string can - // be parsed as a double. - // - `Timestamp` can be compared against strings in RFC 3339 date string - // format. - // - `TimeOfDay` can be compared against timestamps and strings in the format - // of 'HH:mm:ss'. - // - // If we fail to compare do to type mismatch, a warning will be given and - // the condition will evaluate to false. - message Condition { - // Field within the record this condition is evaluated against. [required] - FieldId field = 1; - - // Operator used to compare the field or info type to the value. [required] - RelationalOperator operator = 3; - - // Value to compare against. [Required, except for `EXISTS` tests.] - Value value = 4; - } - - message Conditions { - repeated Condition conditions = 1; - } - - // A collection of expressions - message Expressions { - enum LogicalOperator { - LOGICAL_OPERATOR_UNSPECIFIED = 0; - - AND = 1; - } - - // The operator to apply to the result of conditions. Default and currently - // only supported value is `AND`. - LogicalOperator logical_operator = 1; - - oneof type { - Conditions conditions = 3; - } - } - - Expressions expressions = 3; -} - -// High level summary of deidentification. -message DeidentificationSummary { - // Total size in bytes that were transformed in some way. - int64 transformed_bytes = 2; - - // Transformations applied to the dataset. - repeated TransformationSummary transformation_summaries = 3; -} - -// Summary of a single tranformation. -message TransformationSummary { - // A collection that informs the user the number of times a particular - // `TransformationResultCode` and error details occurred. - message SummaryResult { - int64 count = 1; - - TransformationResultCode code = 2; - - // A place for warnings or errors to show up if a transformation didn't - // work as expected. - string details = 3; - } - - // Possible outcomes of transformations. - enum TransformationResultCode { - TRANSFORMATION_RESULT_CODE_UNSPECIFIED = 0; - - SUCCESS = 1; - - ERROR = 2; - } - - // Set if the transformation was limited to a specific info_type. - InfoType info_type = 1; - - // Set if the transformation was limited to a specific FieldId. - FieldId field = 2; - - // The specific transformation these stats apply to. - PrimitiveTransformation transformation = 3; - - // The field transformation that was applied. This list will contain - // multiple only in the case of errors. - repeated FieldTransformation field_transformations = 5; - - // The specific suppression option these stats apply to. - RecordSuppression record_suppress = 6; - - repeated SummaryResult results = 4; -} - -// Categorization of results based on how likely they are to represent a match, -// based on the number of elements they contain which imply a match. -enum Likelihood { - // Default value; information with all likelihoods is included. - LIKELIHOOD_UNSPECIFIED = 0; - - // Few matching elements. - VERY_UNLIKELY = 1; - - UNLIKELY = 2; - - // Some matching elements. - POSSIBLE = 3; - - LIKELY = 4; - - // Many matching elements. - VERY_LIKELY = 5; -} - -// Operators available for comparing the value of fields. -enum RelationalOperator { - RELATIONAL_OPERATOR_UNSPECIFIED = 0; - - // Equal. - EQUAL_TO = 1; - - // Not equal to. - NOT_EQUAL_TO = 2; - - // Greater than. - GREATER_THAN = 3; - - // Less than. - LESS_THAN = 4; - - // Greater than or equals. - GREATER_THAN_OR_EQUALS = 5; - - // Less than or equals. - LESS_THAN_OR_EQUALS = 6; - - // Exists - EXISTS = 7; -} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/proto/google/privacy/dlp/v2beta1/storage.proto b/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/proto/google/privacy/dlp/v2beta1/storage.proto deleted file mode 100644 index d44724c47c03..000000000000 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/proto/google/privacy/dlp/v2beta1/storage.proto +++ /dev/null @@ -1,276 +0,0 @@ -// Copyright 2017 Google Inc. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -syntax = "proto3"; - -package google.privacy.dlp.v2beta1; - -import "google/api/annotations.proto"; -import "google/protobuf/timestamp.proto"; - -option csharp_namespace = "Google.Cloud.Dlp.V2Beta1"; -option go_package = "google.golang.org/genproto/googleapis/privacy/dlp/v2beta1;dlp"; -option java_multiple_files = true; -option java_outer_classname = "DlpStorage"; -option java_package = "com.google.privacy.dlp.v2beta1"; -option php_namespace = "Google\\Cloud\\Dlp\\V2beta1"; - - -// Type of information detected by the API. -message InfoType { - // Name of the information type. - string name = 1; -} - -// Custom information type provided by the user. Used to find domain-specific -// sensitive information configurable to the data in question. -message CustomInfoType { - // Custom information type based on a dictionary of words or phrases. This can - // be used to match sensitive information specific to the data, such as a list - // of employee IDs or job titles. - // - // Dictionary words are case-insensitive and all characters other than letters - // and digits in the unicode [Basic Multilingual - // Plane](https://en.wikipedia.org/wiki/Plane_%28Unicode%29#Basic_Multilingual_Plane) - // will be replaced with whitespace when scanning for matches, so the - // dictionary phrase "Sam Johnson" will match all three phrases "sam johnson", - // "Sam, Johnson", and "Sam (Johnson)". Additionally, the characters - // surrounding any match must be of a different type than the adjacent - // characters within the word, so letters must be next to non-letters and - // digits next to non-digits. For example, the dictionary word "jen" will - // match the first three letters of the text "jen123" but will return no - // matches for "jennifer". - // - // Dictionary words containing a large number of characters that are not - // letters or digits may result in unexpected findings because such characters - // are treated as whitespace. - message Dictionary { - // Message defining a list of words or phrases to search for in the data. - message WordList { - // Words or phrases defining the dictionary. The dictionary must contain - // at least one phrase and every phrase must contain at least 2 characters - // that are letters or digits. [required] - repeated string words = 1; - } - - oneof source { - // List of words or phrases to search for. - WordList word_list = 1; - } - } - - // Info type configuration. All custom info types must have configurations - // that do not conflict with built-in info types or other custom info types. - InfoType info_type = 1; - - oneof type { - // Dictionary-based custom info type. - Dictionary dictionary = 2; - } -} - -// General identifier of a data field in a storage service. -message FieldId { - // Name describing the field. - string column_name = 1; -} - -// Datastore partition ID. -// A partition ID identifies a grouping of entities. The grouping is always -// by project and namespace, however the namespace ID may be empty. -// -// A partition ID contains several dimensions: -// project ID and namespace ID. -message PartitionId { - // The ID of the project to which the entities belong. - string project_id = 2; - - // If not empty, the ID of the namespace to which the entities belong. - string namespace_id = 4; -} - -// A representation of a Datastore kind. -message KindExpression { - // The name of the kind. - string name = 1; -} - -// A reference to a property relative to the Datastore kind expressions. -message PropertyReference { - // The name of the property. - // If name includes "."s, it may be interpreted as a property name path. - string name = 2; -} - -// A representation of a Datastore property in a projection. -message Projection { - // The property to project. - PropertyReference property = 1; -} - -// Options defining a data set within Google Cloud Datastore. -message DatastoreOptions { - // A partition ID identifies a grouping of entities. The grouping is always - // by project and namespace, however the namespace ID may be empty. - PartitionId partition_id = 1; - - // The kind to process. - KindExpression kind = 2; - - // Properties to scan. If none are specified, all properties will be scanned - // by default. - repeated Projection projection = 3; -} - -// Options defining a file or a set of files (path ending with *) within -// a Google Cloud Storage bucket. -message CloudStorageOptions { - // Set of files to scan. - message FileSet { - // The url, in the format `gs:///`. Trailing wildcard in the - // path is allowed. - string url = 1; - } - - FileSet file_set = 1; -} - -// A location in Cloud Storage. -message CloudStoragePath { - // The url, in the format of `gs://bucket/`. - string path = 1; -} - -// Options defining BigQuery table and row identifiers. -message BigQueryOptions { - // Complete BigQuery table reference. - BigQueryTable table_reference = 1; - - // References to fields uniquely identifying rows within the table. - // Nested fields in the format, like `person.birthdate.year`, are allowed. - repeated FieldId identifying_fields = 2; -} - -// Shared message indicating Cloud storage type. -message StorageConfig { - oneof type { - // Google Cloud Datastore options specification. - DatastoreOptions datastore_options = 2; - - // Google Cloud Storage options specification. - CloudStorageOptions cloud_storage_options = 3; - - // BigQuery options specification. - BigQueryOptions big_query_options = 4; - } -} - -// Record key for a finding in a Cloud Storage file. -message CloudStorageKey { - // Path to the file. - string file_path = 1; - - // Byte offset of the referenced data in the file. - int64 start_offset = 2; -} - -// Record key for a finding in Cloud Datastore. -message DatastoreKey { - // Datastore entity key. - Key entity_key = 1; -} - -// A unique identifier for a Datastore entity. -// If a key's partition ID or any of its path kinds or names are -// reserved/read-only, the key is reserved/read-only. -// A reserved/read-only key is forbidden in certain documented contexts. -message Key { - // A (kind, ID/name) pair used to construct a key path. - // - // If either name or ID is set, the element is complete. - // If neither is set, the element is incomplete. - message PathElement { - // The kind of the entity. - // A kind matching regex `__.*__` is reserved/read-only. - // A kind must not contain more than 1500 bytes when UTF-8 encoded. - // Cannot be `""`. - string kind = 1; - - // The type of ID. - oneof id_type { - // The auto-allocated ID of the entity. - // Never equal to zero. Values less than zero are discouraged and may not - // be supported in the future. - int64 id = 2; - - // The name of the entity. - // A name matching regex `__.*__` is reserved/read-only. - // A name must not be more than 1500 bytes when UTF-8 encoded. - // Cannot be `""`. - string name = 3; - } - } - - // Entities are partitioned into subsets, currently identified by a project - // ID and namespace ID. - // Queries are scoped to a single partition. - PartitionId partition_id = 1; - - // The entity path. - // An entity path consists of one or more elements composed of a kind and a - // string or numerical identifier, which identify entities. The first - // element identifies a _root entity_, the second element identifies - // a _child_ of the root entity, the third element identifies a child of the - // second entity, and so forth. The entities identified by all prefixes of - // the path are called the element's _ancestors_. - // - // A path can never be empty, and a path can have at most 100 elements. - repeated PathElement path = 2; -} - -// Message for a unique key indicating a record that contains a finding. -message RecordKey { - oneof type { - CloudStorageKey cloud_storage_key = 1; - - DatastoreKey datastore_key = 2; - } -} - -// Message defining the location of a BigQuery table. A table is uniquely -// identified by its project_id, dataset_id, and table_name. Within a query -// a table is often referenced with a string in the format of: -// `:.` or -// `..`. -message BigQueryTable { - // The Google Cloud Platform project ID of the project containing the table. - // If omitted, project ID is inferred from the API call. - string project_id = 1; - - // Dataset ID of the table. - string dataset_id = 2; - - // Name of the table. - string table_id = 3; -} - -// An entity in a dataset is a field or set of fields that correspond to a -// single person. For example, in medical records the `EntityId` might be -// a patient identifier, or for financial records it might be an account -// identifier. This message is used when generalizations or analysis must be -// consistent across multiple rows pertaining to the same entity. -message EntityId { - // Composite key indicating which field contains the entity identifier. - FieldId field = 1; -} diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/pom.xml b/google-api-grpc/proto-google-cloud-iot-v1/pom.xml similarity index 84% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/pom.xml rename to google-api-grpc/proto-google-cloud-iot-v1/pom.xml index 719aa6215677..aeafe2c2d214 100644 --- a/google-api-grpc/proto-google-cloud-cloudiot-v1/pom.xml +++ b/google-api-grpc/proto-google-cloud-iot-v1/pom.xml @@ -2,10 +2,10 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 - proto-google-cloud-cloudiot-v1 - 0.12.1-SNAPSHOT - proto-google-cloud-cloudiot-v1 - PROTO library for proto-google-cloud-cloudiot-v1 + proto-google-cloud-iot-v1 + 0.12.1-SNAPSHOT + proto-google-cloud-iot-v1 + PROTO library for proto-google-cloud-iot-v1 com.google.api.grpc google-api-grpc diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRegistryRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRegistryRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRegistryRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRegistryRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRegistryRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRegistryRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRegistryRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRegistryRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/CreateDeviceRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRegistryRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRegistryRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRegistryRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRegistryRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRegistryRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRegistryRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRegistryRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRegistryRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeleteDeviceRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/Device.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/Device.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/Device.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/Device.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceConfig.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceConfig.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceConfig.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceConfig.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceConfigOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceConfigOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceConfigOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceCredential.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceCredential.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceCredential.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceCredential.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceCredentialOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceCredentialOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceCredentialOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceCredentialOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceManagerProto.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceManagerProto.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceManagerProto.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceManagerProto.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceName.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceName.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceName.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceName.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceRegistry.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceRegistry.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceRegistry.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceRegistry.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceRegistryOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceRegistryOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceRegistryOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceRegistryOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceState.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceState.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceState.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceState.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceStateOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceStateOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/DeviceStateOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/DeviceStateOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/EventNotificationConfig.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/EventNotificationConfig.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/EventNotificationConfig.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/EventNotificationConfig.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/EventNotificationConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/EventNotificationConfigOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/EventNotificationConfigOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/EventNotificationConfigOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRegistryRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRegistryRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRegistryRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRegistryRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRegistryRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRegistryRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRegistryRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRegistryRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/GetDeviceRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/HttpConfig.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/HttpConfig.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/HttpConfig.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/HttpConfig.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/HttpConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/HttpConfigOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/HttpConfigOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/HttpConfigOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/HttpState.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/HttpState.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/HttpState.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/HttpState.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsResponse.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsResponse.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsResponse.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsResponse.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsResponseOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsResponseOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceConfigVersionsResponseOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesResponse.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesResponse.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesResponse.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesResponse.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesResponseOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesResponseOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceRegistriesResponseOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesResponse.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesResponse.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesResponse.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesResponse.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesResponseOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesResponseOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDeviceStatesResponseOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesResponse.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesResponse.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesResponse.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesResponse.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesResponseOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesResponseOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ListDevicesResponseOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/LocationName.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/LocationName.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/LocationName.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/LocationName.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ModifyCloudToDeviceConfigRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ModifyCloudToDeviceConfigRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ModifyCloudToDeviceConfigRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ModifyCloudToDeviceConfigRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ModifyCloudToDeviceConfigRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ModifyCloudToDeviceConfigRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ModifyCloudToDeviceConfigRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ModifyCloudToDeviceConfigRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/MqttConfig.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/MqttConfig.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/MqttConfig.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/MqttConfig.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/MqttConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/MqttConfigOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/MqttConfigOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/MqttConfigOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/MqttState.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/MqttState.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/MqttState.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/MqttState.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificate.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificate.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificate.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificate.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificateFormat.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificateFormat.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificateFormat.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificateFormat.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificateOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificateOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificateOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCertificateOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCredential.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCredential.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCredential.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCredential.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCredentialOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCredentialOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCredentialOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyCredentialOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyFormat.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyFormat.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyFormat.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/PublicKeyFormat.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/RegistryCredential.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/RegistryCredential.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/RegistryCredential.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/RegistryCredential.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/RegistryCredentialOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/RegistryCredentialOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/RegistryCredentialOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/RegistryCredentialOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/RegistryName.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/RegistryName.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/RegistryName.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/RegistryName.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ResourcesProto.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ResourcesProto.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/ResourcesProto.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/ResourcesProto.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/StateNotificationConfig.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/StateNotificationConfig.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/StateNotificationConfig.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/StateNotificationConfig.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/StateNotificationConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/StateNotificationConfigOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/StateNotificationConfigOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/StateNotificationConfigOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRegistryRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRegistryRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRegistryRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRegistryRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRegistryRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRegistryRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRegistryRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRegistryRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRequest.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRequest.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRequest.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRequest.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRequestOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRequestOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/UpdateDeviceRequestOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/X509CertificateDetails.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/X509CertificateDetails.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/X509CertificateDetails.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/X509CertificateDetails.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/X509CertificateDetailsOrBuilder.java b/google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/X509CertificateDetailsOrBuilder.java similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/java/com/google/cloud/iot/v1/X509CertificateDetailsOrBuilder.java rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/java/com/google/cloud/iot/v1/X509CertificateDetailsOrBuilder.java diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/proto/google/cloud/iot/v1/device_manager.proto b/google-api-grpc/proto-google-cloud-iot-v1/src/main/proto/google/cloud/iot/v1/device_manager.proto similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/proto/google/cloud/iot/v1/device_manager.proto rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/proto/google/cloud/iot/v1/device_manager.proto diff --git a/google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/proto/google/cloud/iot/v1/resources.proto b/google-api-grpc/proto-google-cloud-iot-v1/src/main/proto/google/cloud/iot/v1/resources.proto similarity index 100% rename from google-api-grpc/proto-google-cloud-cloudiot-v1/src/main/proto/google/cloud/iot/v1/resources.proto rename to google-api-grpc/proto-google-cloud-iot-v1/src/main/proto/google/cloud/iot/v1/resources.proto diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateFileResponse.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateFileResponse.java new file mode 100644 index 000000000000..2ac0c3be8fee --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateFileResponse.java @@ -0,0 +1,1068 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +/** + *
+ * Response to a single file annotation request. A file may contain one or more
+ * images, which individually have their own responses.
+ * 
+ * + * Protobuf type {@code google.cloud.vision.v1.AnnotateFileResponse} + */ +public final class AnnotateFileResponse extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.AnnotateFileResponse) + AnnotateFileResponseOrBuilder { +private static final long serialVersionUID = 0L; + // Use AnnotateFileResponse.newBuilder() to construct. + private AnnotateFileResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private AnnotateFileResponse() { + responses_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private AnnotateFileResponse( + 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; + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + case 10: { + com.google.cloud.vision.v1.InputConfig.Builder subBuilder = null; + if (inputConfig_ != null) { + subBuilder = inputConfig_.toBuilder(); + } + inputConfig_ = input.readMessage(com.google.cloud.vision.v1.InputConfig.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(inputConfig_); + inputConfig_ = subBuilder.buildPartial(); + } + + break; + } + case 18: { + if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + responses_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000002; + } + responses_.add( + input.readMessage(com.google.cloud.vision.v1.AnnotateImageResponse.parser(), extensionRegistry)); + 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_ & 0x00000002) == 0x00000002)) { + responses_ = java.util.Collections.unmodifiableList(responses_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AnnotateFileResponse_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AnnotateFileResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.AnnotateFileResponse.class, com.google.cloud.vision.v1.AnnotateFileResponse.Builder.class); + } + + private int bitField0_; + public static final int INPUT_CONFIG_FIELD_NUMBER = 1; + private com.google.cloud.vision.v1.InputConfig inputConfig_; + /** + *
+   * Information about the file for which this response is generated.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public boolean hasInputConfig() { + return inputConfig_ != null; + } + /** + *
+   * Information about the file for which this response is generated.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public com.google.cloud.vision.v1.InputConfig getInputConfig() { + return inputConfig_ == null ? com.google.cloud.vision.v1.InputConfig.getDefaultInstance() : inputConfig_; + } + /** + *
+   * Information about the file for which this response is generated.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public com.google.cloud.vision.v1.InputConfigOrBuilder getInputConfigOrBuilder() { + return getInputConfig(); + } + + public static final int RESPONSES_FIELD_NUMBER = 2; + private java.util.List responses_; + /** + *
+   * Individual responses to images found within the file.
+   * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public java.util.List getResponsesList() { + return responses_; + } + /** + *
+   * Individual responses to images found within the file.
+   * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public java.util.List + getResponsesOrBuilderList() { + return responses_; + } + /** + *
+   * Individual responses to images found within the file.
+   * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public int getResponsesCount() { + return responses_.size(); + } + /** + *
+   * Individual responses to images found within the file.
+   * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public com.google.cloud.vision.v1.AnnotateImageResponse getResponses(int index) { + return responses_.get(index); + } + /** + *
+   * Individual responses to images found within the file.
+   * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public com.google.cloud.vision.v1.AnnotateImageResponseOrBuilder getResponsesOrBuilder( + int index) { + return responses_.get(index); + } + + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + if (inputConfig_ != null) { + output.writeMessage(1, getInputConfig()); + } + for (int i = 0; i < responses_.size(); i++) { + output.writeMessage(2, responses_.get(i)); + } + unknownFields.writeTo(output); + } + + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (inputConfig_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, getInputConfig()); + } + for (int i = 0; i < responses_.size(); i++) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(2, responses_.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.vision.v1.AnnotateFileResponse)) { + return super.equals(obj); + } + com.google.cloud.vision.v1.AnnotateFileResponse other = (com.google.cloud.vision.v1.AnnotateFileResponse) obj; + + boolean result = true; + result = result && (hasInputConfig() == other.hasInputConfig()); + if (hasInputConfig()) { + result = result && getInputConfig() + .equals(other.getInputConfig()); + } + result = result && getResponsesList() + .equals(other.getResponsesList()); + result = result && unknownFields.equals(other.unknownFields); + return result; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasInputConfig()) { + hash = (37 * hash) + INPUT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getInputConfig().hashCode(); + } + if (getResponsesCount() > 0) { + hash = (37 * hash) + RESPONSES_FIELD_NUMBER; + hash = (53 * hash) + getResponsesList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.vision.v1.AnnotateFileResponse parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AnnotateFileResponse 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.vision.v1.AnnotateFileResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AnnotateFileResponse 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.vision.v1.AnnotateFileResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AnnotateFileResponse parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.google.cloud.vision.v1.AnnotateFileResponse parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AnnotateFileResponse 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.vision.v1.AnnotateFileResponse parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AnnotateFileResponse 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.vision.v1.AnnotateFileResponse parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AnnotateFileResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(com.google.cloud.vision.v1.AnnotateFileResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + public Builder toBuilder() { + return this == DEFAULT_INSTANCE + ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + *
+   * Response to a single file annotation request. A file may contain one or more
+   * images, which individually have their own responses.
+   * 
+ * + * Protobuf type {@code google.cloud.vision.v1.AnnotateFileResponse} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.AnnotateFileResponse) + com.google.cloud.vision.v1.AnnotateFileResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AnnotateFileResponse_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AnnotateFileResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.AnnotateFileResponse.class, com.google.cloud.vision.v1.AnnotateFileResponse.Builder.class); + } + + // Construct using com.google.cloud.vision.v1.AnnotateFileResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + getResponsesFieldBuilder(); + } + } + public Builder clear() { + super.clear(); + if (inputConfigBuilder_ == null) { + inputConfig_ = null; + } else { + inputConfig_ = null; + inputConfigBuilder_ = null; + } + if (responsesBuilder_ == null) { + responses_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + } else { + responsesBuilder_.clear(); + } + return this; + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AnnotateFileResponse_descriptor; + } + + public com.google.cloud.vision.v1.AnnotateFileResponse getDefaultInstanceForType() { + return com.google.cloud.vision.v1.AnnotateFileResponse.getDefaultInstance(); + } + + public com.google.cloud.vision.v1.AnnotateFileResponse build() { + com.google.cloud.vision.v1.AnnotateFileResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public com.google.cloud.vision.v1.AnnotateFileResponse buildPartial() { + com.google.cloud.vision.v1.AnnotateFileResponse result = new com.google.cloud.vision.v1.AnnotateFileResponse(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (inputConfigBuilder_ == null) { + result.inputConfig_ = inputConfig_; + } else { + result.inputConfig_ = inputConfigBuilder_.build(); + } + if (responsesBuilder_ == null) { + if (((bitField0_ & 0x00000002) == 0x00000002)) { + responses_ = java.util.Collections.unmodifiableList(responses_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.responses_ = responses_; + } else { + result.responses_ = responsesBuilder_.build(); + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + public Builder clone() { + return (Builder) super.clone(); + } + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.setField(field, value); + } + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return (Builder) super.clearField(field); + } + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return (Builder) super.clearOneof(oneof); + } + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, java.lang.Object value) { + return (Builder) super.setRepeatedField(field, index, value); + } + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.addRepeatedField(field, value); + } + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.vision.v1.AnnotateFileResponse) { + return mergeFrom((com.google.cloud.vision.v1.AnnotateFileResponse)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.vision.v1.AnnotateFileResponse other) { + if (other == com.google.cloud.vision.v1.AnnotateFileResponse.getDefaultInstance()) return this; + if (other.hasInputConfig()) { + mergeInputConfig(other.getInputConfig()); + } + if (responsesBuilder_ == null) { + if (!other.responses_.isEmpty()) { + if (responses_.isEmpty()) { + responses_ = other.responses_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureResponsesIsMutable(); + responses_.addAll(other.responses_); + } + onChanged(); + } + } else { + if (!other.responses_.isEmpty()) { + if (responsesBuilder_.isEmpty()) { + responsesBuilder_.dispose(); + responsesBuilder_ = null; + responses_ = other.responses_; + bitField0_ = (bitField0_ & ~0x00000002); + responsesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? + getResponsesFieldBuilder() : null; + } else { + responsesBuilder_.addAllMessages(other.responses_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + public final boolean isInitialized() { + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.vision.v1.AnnotateFileResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.cloud.vision.v1.AnnotateFileResponse) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + private int bitField0_; + + private com.google.cloud.vision.v1.InputConfig inputConfig_ = null; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.InputConfig, com.google.cloud.vision.v1.InputConfig.Builder, com.google.cloud.vision.v1.InputConfigOrBuilder> inputConfigBuilder_; + /** + *
+     * Information about the file for which this response is generated.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public boolean hasInputConfig() { + return inputConfigBuilder_ != null || inputConfig_ != null; + } + /** + *
+     * Information about the file for which this response is generated.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public com.google.cloud.vision.v1.InputConfig getInputConfig() { + if (inputConfigBuilder_ == null) { + return inputConfig_ == null ? com.google.cloud.vision.v1.InputConfig.getDefaultInstance() : inputConfig_; + } else { + return inputConfigBuilder_.getMessage(); + } + } + /** + *
+     * Information about the file for which this response is generated.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public Builder setInputConfig(com.google.cloud.vision.v1.InputConfig value) { + if (inputConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + inputConfig_ = value; + onChanged(); + } else { + inputConfigBuilder_.setMessage(value); + } + + return this; + } + /** + *
+     * Information about the file for which this response is generated.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public Builder setInputConfig( + com.google.cloud.vision.v1.InputConfig.Builder builderForValue) { + if (inputConfigBuilder_ == null) { + inputConfig_ = builderForValue.build(); + onChanged(); + } else { + inputConfigBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + *
+     * Information about the file for which this response is generated.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public Builder mergeInputConfig(com.google.cloud.vision.v1.InputConfig value) { + if (inputConfigBuilder_ == null) { + if (inputConfig_ != null) { + inputConfig_ = + com.google.cloud.vision.v1.InputConfig.newBuilder(inputConfig_).mergeFrom(value).buildPartial(); + } else { + inputConfig_ = value; + } + onChanged(); + } else { + inputConfigBuilder_.mergeFrom(value); + } + + return this; + } + /** + *
+     * Information about the file for which this response is generated.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public Builder clearInputConfig() { + if (inputConfigBuilder_ == null) { + inputConfig_ = null; + onChanged(); + } else { + inputConfig_ = null; + inputConfigBuilder_ = null; + } + + return this; + } + /** + *
+     * Information about the file for which this response is generated.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public com.google.cloud.vision.v1.InputConfig.Builder getInputConfigBuilder() { + + onChanged(); + return getInputConfigFieldBuilder().getBuilder(); + } + /** + *
+     * Information about the file for which this response is generated.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public com.google.cloud.vision.v1.InputConfigOrBuilder getInputConfigOrBuilder() { + if (inputConfigBuilder_ != null) { + return inputConfigBuilder_.getMessageOrBuilder(); + } else { + return inputConfig_ == null ? + com.google.cloud.vision.v1.InputConfig.getDefaultInstance() : inputConfig_; + } + } + /** + *
+     * Information about the file for which this response is generated.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.InputConfig, com.google.cloud.vision.v1.InputConfig.Builder, com.google.cloud.vision.v1.InputConfigOrBuilder> + getInputConfigFieldBuilder() { + if (inputConfigBuilder_ == null) { + inputConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.InputConfig, com.google.cloud.vision.v1.InputConfig.Builder, com.google.cloud.vision.v1.InputConfigOrBuilder>( + getInputConfig(), + getParentForChildren(), + isClean()); + inputConfig_ = null; + } + return inputConfigBuilder_; + } + + private java.util.List responses_ = + java.util.Collections.emptyList(); + private void ensureResponsesIsMutable() { + if (!((bitField0_ & 0x00000002) == 0x00000002)) { + responses_ = new java.util.ArrayList(responses_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.AnnotateImageResponse, com.google.cloud.vision.v1.AnnotateImageResponse.Builder, com.google.cloud.vision.v1.AnnotateImageResponseOrBuilder> responsesBuilder_; + + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public java.util.List getResponsesList() { + if (responsesBuilder_ == null) { + return java.util.Collections.unmodifiableList(responses_); + } else { + return responsesBuilder_.getMessageList(); + } + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public int getResponsesCount() { + if (responsesBuilder_ == null) { + return responses_.size(); + } else { + return responsesBuilder_.getCount(); + } + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public com.google.cloud.vision.v1.AnnotateImageResponse getResponses(int index) { + if (responsesBuilder_ == null) { + return responses_.get(index); + } else { + return responsesBuilder_.getMessage(index); + } + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public Builder setResponses( + int index, com.google.cloud.vision.v1.AnnotateImageResponse value) { + if (responsesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureResponsesIsMutable(); + responses_.set(index, value); + onChanged(); + } else { + responsesBuilder_.setMessage(index, value); + } + return this; + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public Builder setResponses( + int index, com.google.cloud.vision.v1.AnnotateImageResponse.Builder builderForValue) { + if (responsesBuilder_ == null) { + ensureResponsesIsMutable(); + responses_.set(index, builderForValue.build()); + onChanged(); + } else { + responsesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public Builder addResponses(com.google.cloud.vision.v1.AnnotateImageResponse value) { + if (responsesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureResponsesIsMutable(); + responses_.add(value); + onChanged(); + } else { + responsesBuilder_.addMessage(value); + } + return this; + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public Builder addResponses( + int index, com.google.cloud.vision.v1.AnnotateImageResponse value) { + if (responsesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureResponsesIsMutable(); + responses_.add(index, value); + onChanged(); + } else { + responsesBuilder_.addMessage(index, value); + } + return this; + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public Builder addResponses( + com.google.cloud.vision.v1.AnnotateImageResponse.Builder builderForValue) { + if (responsesBuilder_ == null) { + ensureResponsesIsMutable(); + responses_.add(builderForValue.build()); + onChanged(); + } else { + responsesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public Builder addResponses( + int index, com.google.cloud.vision.v1.AnnotateImageResponse.Builder builderForValue) { + if (responsesBuilder_ == null) { + ensureResponsesIsMutable(); + responses_.add(index, builderForValue.build()); + onChanged(); + } else { + responsesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public Builder addAllResponses( + java.lang.Iterable values) { + if (responsesBuilder_ == null) { + ensureResponsesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll( + values, responses_); + onChanged(); + } else { + responsesBuilder_.addAllMessages(values); + } + return this; + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public Builder clearResponses() { + if (responsesBuilder_ == null) { + responses_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + responsesBuilder_.clear(); + } + return this; + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public Builder removeResponses(int index) { + if (responsesBuilder_ == null) { + ensureResponsesIsMutable(); + responses_.remove(index); + onChanged(); + } else { + responsesBuilder_.remove(index); + } + return this; + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public com.google.cloud.vision.v1.AnnotateImageResponse.Builder getResponsesBuilder( + int index) { + return getResponsesFieldBuilder().getBuilder(index); + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public com.google.cloud.vision.v1.AnnotateImageResponseOrBuilder getResponsesOrBuilder( + int index) { + if (responsesBuilder_ == null) { + return responses_.get(index); } else { + return responsesBuilder_.getMessageOrBuilder(index); + } + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public java.util.List + getResponsesOrBuilderList() { + if (responsesBuilder_ != null) { + return responsesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(responses_); + } + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public com.google.cloud.vision.v1.AnnotateImageResponse.Builder addResponsesBuilder() { + return getResponsesFieldBuilder().addBuilder( + com.google.cloud.vision.v1.AnnotateImageResponse.getDefaultInstance()); + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public com.google.cloud.vision.v1.AnnotateImageResponse.Builder addResponsesBuilder( + int index) { + return getResponsesFieldBuilder().addBuilder( + index, com.google.cloud.vision.v1.AnnotateImageResponse.getDefaultInstance()); + } + /** + *
+     * Individual responses to images found within the file.
+     * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + public java.util.List + getResponsesBuilderList() { + return getResponsesFieldBuilder().getBuilderList(); + } + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.AnnotateImageResponse, com.google.cloud.vision.v1.AnnotateImageResponse.Builder, com.google.cloud.vision.v1.AnnotateImageResponseOrBuilder> + getResponsesFieldBuilder() { + if (responsesBuilder_ == null) { + responsesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.AnnotateImageResponse, com.google.cloud.vision.v1.AnnotateImageResponse.Builder, com.google.cloud.vision.v1.AnnotateImageResponseOrBuilder>( + responses_, + ((bitField0_ & 0x00000002) == 0x00000002), + getParentForChildren(), + isClean()); + responses_ = null; + } + return responsesBuilder_; + } + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFieldsProto3(unknownFields); + } + + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.AnnotateFileResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.AnnotateFileResponse) + private static final com.google.cloud.vision.v1.AnnotateFileResponse DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.AnnotateFileResponse(); + } + + public static com.google.cloud.vision.v1.AnnotateFileResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public AnnotateFileResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new AnnotateFileResponse(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + public com.google.cloud.vision.v1.AnnotateFileResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + +} + diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateFileResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateFileResponseOrBuilder.java new file mode 100644 index 000000000000..1597910bba3f --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateFileResponseOrBuilder.java @@ -0,0 +1,78 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface AnnotateFileResponseOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.AnnotateFileResponse) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * Information about the file for which this response is generated.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + boolean hasInputConfig(); + /** + *
+   * Information about the file for which this response is generated.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + com.google.cloud.vision.v1.InputConfig getInputConfig(); + /** + *
+   * Information about the file for which this response is generated.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + com.google.cloud.vision.v1.InputConfigOrBuilder getInputConfigOrBuilder(); + + /** + *
+   * Individual responses to images found within the file.
+   * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + java.util.List + getResponsesList(); + /** + *
+   * Individual responses to images found within the file.
+   * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + com.google.cloud.vision.v1.AnnotateImageResponse getResponses(int index); + /** + *
+   * Individual responses to images found within the file.
+   * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + int getResponsesCount(); + /** + *
+   * Individual responses to images found within the file.
+   * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + java.util.List + getResponsesOrBuilderList(); + /** + *
+   * Individual responses to images found within the file.
+   * 
+ * + * repeated .google.cloud.vision.v1.AnnotateImageResponse responses = 2; + */ + com.google.cloud.vision.v1.AnnotateImageResponseOrBuilder getResponsesOrBuilder( + int index); +} diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateImageResponse.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateImageResponse.java index cc725278962b..5fd304e6d65e 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateImageResponse.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateImageResponse.java @@ -179,6 +179,19 @@ private AnnotateImageResponse( webDetection_ = subBuilder.buildPartial(); } + break; + } + case 170: { + com.google.cloud.vision.v1.ImageAnnotationContext.Builder subBuilder = null; + if (context_ != null) { + subBuilder = context_.toBuilder(); + } + context_ = input.readMessage(com.google.cloud.vision.v1.ImageAnnotationContext.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(context_); + context_ = subBuilder.buildPartial(); + } + break; } } @@ -709,6 +722,42 @@ public com.google.rpc.StatusOrBuilder getErrorOrBuilder() { return getError(); } + public static final int CONTEXT_FIELD_NUMBER = 21; + private com.google.cloud.vision.v1.ImageAnnotationContext context_; + /** + *
+   * If present, contextual information is needed to understand where this image
+   * comes from.
+   * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public boolean hasContext() { + return context_ != null; + } + /** + *
+   * If present, contextual information is needed to understand where this image
+   * comes from.
+   * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public com.google.cloud.vision.v1.ImageAnnotationContext getContext() { + return context_ == null ? com.google.cloud.vision.v1.ImageAnnotationContext.getDefaultInstance() : context_; + } + /** + *
+   * If present, contextual information is needed to understand where this image
+   * comes from.
+   * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public com.google.cloud.vision.v1.ImageAnnotationContextOrBuilder getContextOrBuilder() { + return getContext(); + } + private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -754,6 +803,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) if (webDetection_ != null) { output.writeMessage(13, getWebDetection()); } + if (context_ != null) { + output.writeMessage(21, getContext()); + } unknownFields.writeTo(output); } @@ -806,6 +858,10 @@ public int getSerializedSize() { size += com.google.protobuf.CodedOutputStream .computeMessageSize(13, getWebDetection()); } + if (context_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(21, getContext()); + } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; @@ -862,6 +918,11 @@ public boolean equals(final java.lang.Object obj) { result = result && getError() .equals(other.getError()); } + result = result && (hasContext() == other.hasContext()); + if (hasContext()) { + result = result && getContext() + .equals(other.getContext()); + } result = result && unknownFields.equals(other.unknownFields); return result; } @@ -917,6 +978,10 @@ public int hashCode() { hash = (37 * hash) + ERROR_FIELD_NUMBER; hash = (53 * hash) + getError().hashCode(); } + if (hasContext()) { + hash = (37 * hash) + CONTEXT_FIELD_NUMBER; + hash = (53 * hash) + getContext().hashCode(); + } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; @@ -1121,6 +1186,12 @@ public Builder clear() { error_ = null; errorBuilder_ = null; } + if (contextBuilder_ == null) { + context_ = null; + } else { + context_ = null; + contextBuilder_ = null; + } return this; } @@ -1220,6 +1291,11 @@ public com.google.cloud.vision.v1.AnnotateImageResponse buildPartial() { } else { result.error_ = errorBuilder_.build(); } + if (contextBuilder_ == null) { + result.context_ = context_; + } else { + result.context_ = contextBuilder_.build(); + } result.bitField0_ = to_bitField0_; onBuilt(); return result; @@ -1410,6 +1486,9 @@ public Builder mergeFrom(com.google.cloud.vision.v1.AnnotateImageResponse other) if (other.hasError()) { mergeError(other.getError()); } + if (other.hasContext()) { + mergeContext(other.getContext()); + } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; @@ -3960,6 +4039,168 @@ public com.google.rpc.StatusOrBuilder getErrorOrBuilder() { } return errorBuilder_; } + + private com.google.cloud.vision.v1.ImageAnnotationContext context_ = null; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.ImageAnnotationContext, com.google.cloud.vision.v1.ImageAnnotationContext.Builder, com.google.cloud.vision.v1.ImageAnnotationContextOrBuilder> contextBuilder_; + /** + *
+     * If present, contextual information is needed to understand where this image
+     * comes from.
+     * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public boolean hasContext() { + return contextBuilder_ != null || context_ != null; + } + /** + *
+     * If present, contextual information is needed to understand where this image
+     * comes from.
+     * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public com.google.cloud.vision.v1.ImageAnnotationContext getContext() { + if (contextBuilder_ == null) { + return context_ == null ? com.google.cloud.vision.v1.ImageAnnotationContext.getDefaultInstance() : context_; + } else { + return contextBuilder_.getMessage(); + } + } + /** + *
+     * If present, contextual information is needed to understand where this image
+     * comes from.
+     * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public Builder setContext(com.google.cloud.vision.v1.ImageAnnotationContext value) { + if (contextBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + context_ = value; + onChanged(); + } else { + contextBuilder_.setMessage(value); + } + + return this; + } + /** + *
+     * If present, contextual information is needed to understand where this image
+     * comes from.
+     * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public Builder setContext( + com.google.cloud.vision.v1.ImageAnnotationContext.Builder builderForValue) { + if (contextBuilder_ == null) { + context_ = builderForValue.build(); + onChanged(); + } else { + contextBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + *
+     * If present, contextual information is needed to understand where this image
+     * comes from.
+     * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public Builder mergeContext(com.google.cloud.vision.v1.ImageAnnotationContext value) { + if (contextBuilder_ == null) { + if (context_ != null) { + context_ = + com.google.cloud.vision.v1.ImageAnnotationContext.newBuilder(context_).mergeFrom(value).buildPartial(); + } else { + context_ = value; + } + onChanged(); + } else { + contextBuilder_.mergeFrom(value); + } + + return this; + } + /** + *
+     * If present, contextual information is needed to understand where this image
+     * comes from.
+     * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public Builder clearContext() { + if (contextBuilder_ == null) { + context_ = null; + onChanged(); + } else { + context_ = null; + contextBuilder_ = null; + } + + return this; + } + /** + *
+     * If present, contextual information is needed to understand where this image
+     * comes from.
+     * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public com.google.cloud.vision.v1.ImageAnnotationContext.Builder getContextBuilder() { + + onChanged(); + return getContextFieldBuilder().getBuilder(); + } + /** + *
+     * If present, contextual information is needed to understand where this image
+     * comes from.
+     * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + public com.google.cloud.vision.v1.ImageAnnotationContextOrBuilder getContextOrBuilder() { + if (contextBuilder_ != null) { + return contextBuilder_.getMessageOrBuilder(); + } else { + return context_ == null ? + com.google.cloud.vision.v1.ImageAnnotationContext.getDefaultInstance() : context_; + } + } + /** + *
+     * If present, contextual information is needed to understand where this image
+     * comes from.
+     * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.ImageAnnotationContext, com.google.cloud.vision.v1.ImageAnnotationContext.Builder, com.google.cloud.vision.v1.ImageAnnotationContextOrBuilder> + getContextFieldBuilder() { + if (contextBuilder_ == null) { + contextBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.ImageAnnotationContext, com.google.cloud.vision.v1.ImageAnnotationContext.Builder, com.google.cloud.vision.v1.ImageAnnotationContextOrBuilder>( + getContext(), + getParentForChildren(), + isClean()); + context_ = null; + } + return contextBuilder_; + } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFieldsProto3(unknownFields); diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateImageResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateImageResponseOrBuilder.java index e4e6a58da1cc..4daa4801b4a5 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateImageResponseOrBuilder.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AnnotateImageResponseOrBuilder.java @@ -391,4 +391,32 @@ com.google.cloud.vision.v1.EntityAnnotationOrBuilder getTextAnnotationsOrBuilder * .google.rpc.Status error = 9; */ com.google.rpc.StatusOrBuilder getErrorOrBuilder(); + + /** + *
+   * If present, contextual information is needed to understand where this image
+   * comes from.
+   * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + boolean hasContext(); + /** + *
+   * If present, contextual information is needed to understand where this image
+   * comes from.
+   * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + com.google.cloud.vision.v1.ImageAnnotationContext getContext(); + /** + *
+   * If present, contextual information is needed to understand where this image
+   * comes from.
+   * 
+ * + * .google.cloud.vision.v1.ImageAnnotationContext context = 21; + */ + com.google.cloud.vision.v1.ImageAnnotationContextOrBuilder getContextOrBuilder(); } diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileRequest.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileRequest.java new file mode 100644 index 000000000000..e2c3b337f233 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileRequest.java @@ -0,0 +1,1524 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +/** + *
+ * An offline file annotation request.
+ * 
+ * + * Protobuf type {@code google.cloud.vision.v1.AsyncAnnotateFileRequest} + */ +public final class AsyncAnnotateFileRequest extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.AsyncAnnotateFileRequest) + AsyncAnnotateFileRequestOrBuilder { +private static final long serialVersionUID = 0L; + // Use AsyncAnnotateFileRequest.newBuilder() to construct. + private AsyncAnnotateFileRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private AsyncAnnotateFileRequest() { + features_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private AsyncAnnotateFileRequest( + 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; + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + case 10: { + com.google.cloud.vision.v1.InputConfig.Builder subBuilder = null; + if (inputConfig_ != null) { + subBuilder = inputConfig_.toBuilder(); + } + inputConfig_ = input.readMessage(com.google.cloud.vision.v1.InputConfig.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(inputConfig_); + inputConfig_ = subBuilder.buildPartial(); + } + + break; + } + case 18: { + if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + features_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000002; + } + features_.add( + input.readMessage(com.google.cloud.vision.v1.Feature.parser(), extensionRegistry)); + break; + } + case 26: { + com.google.cloud.vision.v1.ImageContext.Builder subBuilder = null; + if (imageContext_ != null) { + subBuilder = imageContext_.toBuilder(); + } + imageContext_ = input.readMessage(com.google.cloud.vision.v1.ImageContext.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(imageContext_); + imageContext_ = subBuilder.buildPartial(); + } + + break; + } + case 34: { + com.google.cloud.vision.v1.OutputConfig.Builder subBuilder = null; + if (outputConfig_ != null) { + subBuilder = outputConfig_.toBuilder(); + } + outputConfig_ = input.readMessage(com.google.cloud.vision.v1.OutputConfig.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(outputConfig_); + outputConfig_ = subBuilder.buildPartial(); + } + + 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_ & 0x00000002) == 0x00000002)) { + features_ = java.util.Collections.unmodifiableList(features_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncAnnotateFileRequest_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncAnnotateFileRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.AsyncAnnotateFileRequest.class, com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder.class); + } + + private int bitField0_; + public static final int INPUT_CONFIG_FIELD_NUMBER = 1; + private com.google.cloud.vision.v1.InputConfig inputConfig_; + /** + *
+   * Required. Information about the input file.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public boolean hasInputConfig() { + return inputConfig_ != null; + } + /** + *
+   * Required. Information about the input file.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public com.google.cloud.vision.v1.InputConfig getInputConfig() { + return inputConfig_ == null ? com.google.cloud.vision.v1.InputConfig.getDefaultInstance() : inputConfig_; + } + /** + *
+   * Required. Information about the input file.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public com.google.cloud.vision.v1.InputConfigOrBuilder getInputConfigOrBuilder() { + return getInputConfig(); + } + + public static final int FEATURES_FIELD_NUMBER = 2; + private java.util.List features_; + /** + *
+   * Required. Requested features.
+   * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public java.util.List getFeaturesList() { + return features_; + } + /** + *
+   * Required. Requested features.
+   * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public java.util.List + getFeaturesOrBuilderList() { + return features_; + } + /** + *
+   * Required. Requested features.
+   * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public int getFeaturesCount() { + return features_.size(); + } + /** + *
+   * Required. Requested features.
+   * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public com.google.cloud.vision.v1.Feature getFeatures(int index) { + return features_.get(index); + } + /** + *
+   * Required. Requested features.
+   * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public com.google.cloud.vision.v1.FeatureOrBuilder getFeaturesOrBuilder( + int index) { + return features_.get(index); + } + + public static final int IMAGE_CONTEXT_FIELD_NUMBER = 3; + private com.google.cloud.vision.v1.ImageContext imageContext_; + /** + *
+   * Additional context that may accompany the image(s) in the file.
+   * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public boolean hasImageContext() { + return imageContext_ != null; + } + /** + *
+   * Additional context that may accompany the image(s) in the file.
+   * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public com.google.cloud.vision.v1.ImageContext getImageContext() { + return imageContext_ == null ? com.google.cloud.vision.v1.ImageContext.getDefaultInstance() : imageContext_; + } + /** + *
+   * Additional context that may accompany the image(s) in the file.
+   * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public com.google.cloud.vision.v1.ImageContextOrBuilder getImageContextOrBuilder() { + return getImageContext(); + } + + public static final int OUTPUT_CONFIG_FIELD_NUMBER = 4; + private com.google.cloud.vision.v1.OutputConfig outputConfig_; + /** + *
+   * Required. The desired output location and metadata (e.g. format).
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public boolean hasOutputConfig() { + return outputConfig_ != null; + } + /** + *
+   * Required. The desired output location and metadata (e.g. format).
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public com.google.cloud.vision.v1.OutputConfig getOutputConfig() { + return outputConfig_ == null ? com.google.cloud.vision.v1.OutputConfig.getDefaultInstance() : outputConfig_; + } + /** + *
+   * Required. The desired output location and metadata (e.g. format).
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public com.google.cloud.vision.v1.OutputConfigOrBuilder getOutputConfigOrBuilder() { + return getOutputConfig(); + } + + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + if (inputConfig_ != null) { + output.writeMessage(1, getInputConfig()); + } + for (int i = 0; i < features_.size(); i++) { + output.writeMessage(2, features_.get(i)); + } + if (imageContext_ != null) { + output.writeMessage(3, getImageContext()); + } + if (outputConfig_ != null) { + output.writeMessage(4, getOutputConfig()); + } + unknownFields.writeTo(output); + } + + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (inputConfig_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, getInputConfig()); + } + for (int i = 0; i < features_.size(); i++) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(2, features_.get(i)); + } + if (imageContext_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(3, getImageContext()); + } + if (outputConfig_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(4, getOutputConfig()); + } + 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.vision.v1.AsyncAnnotateFileRequest)) { + return super.equals(obj); + } + com.google.cloud.vision.v1.AsyncAnnotateFileRequest other = (com.google.cloud.vision.v1.AsyncAnnotateFileRequest) obj; + + boolean result = true; + result = result && (hasInputConfig() == other.hasInputConfig()); + if (hasInputConfig()) { + result = result && getInputConfig() + .equals(other.getInputConfig()); + } + result = result && getFeaturesList() + .equals(other.getFeaturesList()); + result = result && (hasImageContext() == other.hasImageContext()); + if (hasImageContext()) { + result = result && getImageContext() + .equals(other.getImageContext()); + } + result = result && (hasOutputConfig() == other.hasOutputConfig()); + if (hasOutputConfig()) { + result = result && getOutputConfig() + .equals(other.getOutputConfig()); + } + result = result && unknownFields.equals(other.unknownFields); + return result; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasInputConfig()) { + hash = (37 * hash) + INPUT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getInputConfig().hashCode(); + } + if (getFeaturesCount() > 0) { + hash = (37 * hash) + FEATURES_FIELD_NUMBER; + hash = (53 * hash) + getFeaturesList().hashCode(); + } + if (hasImageContext()) { + hash = (37 * hash) + IMAGE_CONTEXT_FIELD_NUMBER; + hash = (53 * hash) + getImageContext().hashCode(); + } + if (hasOutputConfig()) { + hash = (37 * hash) + OUTPUT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getOutputConfig().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.vision.v1.AsyncAnnotateFileRequest parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileRequest 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.vision.v1.AsyncAnnotateFileRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileRequest 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.vision.v1.AsyncAnnotateFileRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileRequest parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileRequest 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.vision.v1.AsyncAnnotateFileRequest parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileRequest 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.vision.v1.AsyncAnnotateFileRequest parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(com.google.cloud.vision.v1.AsyncAnnotateFileRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + 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 offline file annotation request.
+   * 
+ * + * Protobuf type {@code google.cloud.vision.v1.AsyncAnnotateFileRequest} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.AsyncAnnotateFileRequest) + com.google.cloud.vision.v1.AsyncAnnotateFileRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncAnnotateFileRequest_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncAnnotateFileRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.AsyncAnnotateFileRequest.class, com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder.class); + } + + // Construct using com.google.cloud.vision.v1.AsyncAnnotateFileRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + getFeaturesFieldBuilder(); + } + } + public Builder clear() { + super.clear(); + if (inputConfigBuilder_ == null) { + inputConfig_ = null; + } else { + inputConfig_ = null; + inputConfigBuilder_ = null; + } + if (featuresBuilder_ == null) { + features_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + } else { + featuresBuilder_.clear(); + } + if (imageContextBuilder_ == null) { + imageContext_ = null; + } else { + imageContext_ = null; + imageContextBuilder_ = null; + } + if (outputConfigBuilder_ == null) { + outputConfig_ = null; + } else { + outputConfig_ = null; + outputConfigBuilder_ = null; + } + return this; + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncAnnotateFileRequest_descriptor; + } + + public com.google.cloud.vision.v1.AsyncAnnotateFileRequest getDefaultInstanceForType() { + return com.google.cloud.vision.v1.AsyncAnnotateFileRequest.getDefaultInstance(); + } + + public com.google.cloud.vision.v1.AsyncAnnotateFileRequest build() { + com.google.cloud.vision.v1.AsyncAnnotateFileRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public com.google.cloud.vision.v1.AsyncAnnotateFileRequest buildPartial() { + com.google.cloud.vision.v1.AsyncAnnotateFileRequest result = new com.google.cloud.vision.v1.AsyncAnnotateFileRequest(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (inputConfigBuilder_ == null) { + result.inputConfig_ = inputConfig_; + } else { + result.inputConfig_ = inputConfigBuilder_.build(); + } + if (featuresBuilder_ == null) { + if (((bitField0_ & 0x00000002) == 0x00000002)) { + features_ = java.util.Collections.unmodifiableList(features_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.features_ = features_; + } else { + result.features_ = featuresBuilder_.build(); + } + if (imageContextBuilder_ == null) { + result.imageContext_ = imageContext_; + } else { + result.imageContext_ = imageContextBuilder_.build(); + } + if (outputConfigBuilder_ == null) { + result.outputConfig_ = outputConfig_; + } else { + result.outputConfig_ = outputConfigBuilder_.build(); + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + public Builder clone() { + return (Builder) super.clone(); + } + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.setField(field, value); + } + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return (Builder) super.clearField(field); + } + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return (Builder) super.clearOneof(oneof); + } + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, java.lang.Object value) { + return (Builder) super.setRepeatedField(field, index, value); + } + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.addRepeatedField(field, value); + } + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.vision.v1.AsyncAnnotateFileRequest) { + return mergeFrom((com.google.cloud.vision.v1.AsyncAnnotateFileRequest)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.vision.v1.AsyncAnnotateFileRequest other) { + if (other == com.google.cloud.vision.v1.AsyncAnnotateFileRequest.getDefaultInstance()) return this; + if (other.hasInputConfig()) { + mergeInputConfig(other.getInputConfig()); + } + if (featuresBuilder_ == null) { + if (!other.features_.isEmpty()) { + if (features_.isEmpty()) { + features_ = other.features_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureFeaturesIsMutable(); + features_.addAll(other.features_); + } + onChanged(); + } + } else { + if (!other.features_.isEmpty()) { + if (featuresBuilder_.isEmpty()) { + featuresBuilder_.dispose(); + featuresBuilder_ = null; + features_ = other.features_; + bitField0_ = (bitField0_ & ~0x00000002); + featuresBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? + getFeaturesFieldBuilder() : null; + } else { + featuresBuilder_.addAllMessages(other.features_); + } + } + } + if (other.hasImageContext()) { + mergeImageContext(other.getImageContext()); + } + if (other.hasOutputConfig()) { + mergeOutputConfig(other.getOutputConfig()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + public final boolean isInitialized() { + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.vision.v1.AsyncAnnotateFileRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.cloud.vision.v1.AsyncAnnotateFileRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + private int bitField0_; + + private com.google.cloud.vision.v1.InputConfig inputConfig_ = null; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.InputConfig, com.google.cloud.vision.v1.InputConfig.Builder, com.google.cloud.vision.v1.InputConfigOrBuilder> inputConfigBuilder_; + /** + *
+     * Required. Information about the input file.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public boolean hasInputConfig() { + return inputConfigBuilder_ != null || inputConfig_ != null; + } + /** + *
+     * Required. Information about the input file.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public com.google.cloud.vision.v1.InputConfig getInputConfig() { + if (inputConfigBuilder_ == null) { + return inputConfig_ == null ? com.google.cloud.vision.v1.InputConfig.getDefaultInstance() : inputConfig_; + } else { + return inputConfigBuilder_.getMessage(); + } + } + /** + *
+     * Required. Information about the input file.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public Builder setInputConfig(com.google.cloud.vision.v1.InputConfig value) { + if (inputConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + inputConfig_ = value; + onChanged(); + } else { + inputConfigBuilder_.setMessage(value); + } + + return this; + } + /** + *
+     * Required. Information about the input file.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public Builder setInputConfig( + com.google.cloud.vision.v1.InputConfig.Builder builderForValue) { + if (inputConfigBuilder_ == null) { + inputConfig_ = builderForValue.build(); + onChanged(); + } else { + inputConfigBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + *
+     * Required. Information about the input file.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public Builder mergeInputConfig(com.google.cloud.vision.v1.InputConfig value) { + if (inputConfigBuilder_ == null) { + if (inputConfig_ != null) { + inputConfig_ = + com.google.cloud.vision.v1.InputConfig.newBuilder(inputConfig_).mergeFrom(value).buildPartial(); + } else { + inputConfig_ = value; + } + onChanged(); + } else { + inputConfigBuilder_.mergeFrom(value); + } + + return this; + } + /** + *
+     * Required. Information about the input file.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public Builder clearInputConfig() { + if (inputConfigBuilder_ == null) { + inputConfig_ = null; + onChanged(); + } else { + inputConfig_ = null; + inputConfigBuilder_ = null; + } + + return this; + } + /** + *
+     * Required. Information about the input file.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public com.google.cloud.vision.v1.InputConfig.Builder getInputConfigBuilder() { + + onChanged(); + return getInputConfigFieldBuilder().getBuilder(); + } + /** + *
+     * Required. Information about the input file.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + public com.google.cloud.vision.v1.InputConfigOrBuilder getInputConfigOrBuilder() { + if (inputConfigBuilder_ != null) { + return inputConfigBuilder_.getMessageOrBuilder(); + } else { + return inputConfig_ == null ? + com.google.cloud.vision.v1.InputConfig.getDefaultInstance() : inputConfig_; + } + } + /** + *
+     * Required. Information about the input file.
+     * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.InputConfig, com.google.cloud.vision.v1.InputConfig.Builder, com.google.cloud.vision.v1.InputConfigOrBuilder> + getInputConfigFieldBuilder() { + if (inputConfigBuilder_ == null) { + inputConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.InputConfig, com.google.cloud.vision.v1.InputConfig.Builder, com.google.cloud.vision.v1.InputConfigOrBuilder>( + getInputConfig(), + getParentForChildren(), + isClean()); + inputConfig_ = null; + } + return inputConfigBuilder_; + } + + private java.util.List features_ = + java.util.Collections.emptyList(); + private void ensureFeaturesIsMutable() { + if (!((bitField0_ & 0x00000002) == 0x00000002)) { + features_ = new java.util.ArrayList(features_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.Feature, com.google.cloud.vision.v1.Feature.Builder, com.google.cloud.vision.v1.FeatureOrBuilder> featuresBuilder_; + + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public java.util.List getFeaturesList() { + if (featuresBuilder_ == null) { + return java.util.Collections.unmodifiableList(features_); + } else { + return featuresBuilder_.getMessageList(); + } + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public int getFeaturesCount() { + if (featuresBuilder_ == null) { + return features_.size(); + } else { + return featuresBuilder_.getCount(); + } + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public com.google.cloud.vision.v1.Feature getFeatures(int index) { + if (featuresBuilder_ == null) { + return features_.get(index); + } else { + return featuresBuilder_.getMessage(index); + } + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public Builder setFeatures( + int index, com.google.cloud.vision.v1.Feature value) { + if (featuresBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFeaturesIsMutable(); + features_.set(index, value); + onChanged(); + } else { + featuresBuilder_.setMessage(index, value); + } + return this; + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public Builder setFeatures( + int index, com.google.cloud.vision.v1.Feature.Builder builderForValue) { + if (featuresBuilder_ == null) { + ensureFeaturesIsMutable(); + features_.set(index, builderForValue.build()); + onChanged(); + } else { + featuresBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public Builder addFeatures(com.google.cloud.vision.v1.Feature value) { + if (featuresBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFeaturesIsMutable(); + features_.add(value); + onChanged(); + } else { + featuresBuilder_.addMessage(value); + } + return this; + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public Builder addFeatures( + int index, com.google.cloud.vision.v1.Feature value) { + if (featuresBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFeaturesIsMutable(); + features_.add(index, value); + onChanged(); + } else { + featuresBuilder_.addMessage(index, value); + } + return this; + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public Builder addFeatures( + com.google.cloud.vision.v1.Feature.Builder builderForValue) { + if (featuresBuilder_ == null) { + ensureFeaturesIsMutable(); + features_.add(builderForValue.build()); + onChanged(); + } else { + featuresBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public Builder addFeatures( + int index, com.google.cloud.vision.v1.Feature.Builder builderForValue) { + if (featuresBuilder_ == null) { + ensureFeaturesIsMutable(); + features_.add(index, builderForValue.build()); + onChanged(); + } else { + featuresBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public Builder addAllFeatures( + java.lang.Iterable values) { + if (featuresBuilder_ == null) { + ensureFeaturesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll( + values, features_); + onChanged(); + } else { + featuresBuilder_.addAllMessages(values); + } + return this; + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public Builder clearFeatures() { + if (featuresBuilder_ == null) { + features_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + featuresBuilder_.clear(); + } + return this; + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public Builder removeFeatures(int index) { + if (featuresBuilder_ == null) { + ensureFeaturesIsMutable(); + features_.remove(index); + onChanged(); + } else { + featuresBuilder_.remove(index); + } + return this; + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public com.google.cloud.vision.v1.Feature.Builder getFeaturesBuilder( + int index) { + return getFeaturesFieldBuilder().getBuilder(index); + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public com.google.cloud.vision.v1.FeatureOrBuilder getFeaturesOrBuilder( + int index) { + if (featuresBuilder_ == null) { + return features_.get(index); } else { + return featuresBuilder_.getMessageOrBuilder(index); + } + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public java.util.List + getFeaturesOrBuilderList() { + if (featuresBuilder_ != null) { + return featuresBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(features_); + } + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public com.google.cloud.vision.v1.Feature.Builder addFeaturesBuilder() { + return getFeaturesFieldBuilder().addBuilder( + com.google.cloud.vision.v1.Feature.getDefaultInstance()); + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public com.google.cloud.vision.v1.Feature.Builder addFeaturesBuilder( + int index) { + return getFeaturesFieldBuilder().addBuilder( + index, com.google.cloud.vision.v1.Feature.getDefaultInstance()); + } + /** + *
+     * Required. Requested features.
+     * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + public java.util.List + getFeaturesBuilderList() { + return getFeaturesFieldBuilder().getBuilderList(); + } + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.Feature, com.google.cloud.vision.v1.Feature.Builder, com.google.cloud.vision.v1.FeatureOrBuilder> + getFeaturesFieldBuilder() { + if (featuresBuilder_ == null) { + featuresBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.Feature, com.google.cloud.vision.v1.Feature.Builder, com.google.cloud.vision.v1.FeatureOrBuilder>( + features_, + ((bitField0_ & 0x00000002) == 0x00000002), + getParentForChildren(), + isClean()); + features_ = null; + } + return featuresBuilder_; + } + + private com.google.cloud.vision.v1.ImageContext imageContext_ = null; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.ImageContext, com.google.cloud.vision.v1.ImageContext.Builder, com.google.cloud.vision.v1.ImageContextOrBuilder> imageContextBuilder_; + /** + *
+     * Additional context that may accompany the image(s) in the file.
+     * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public boolean hasImageContext() { + return imageContextBuilder_ != null || imageContext_ != null; + } + /** + *
+     * Additional context that may accompany the image(s) in the file.
+     * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public com.google.cloud.vision.v1.ImageContext getImageContext() { + if (imageContextBuilder_ == null) { + return imageContext_ == null ? com.google.cloud.vision.v1.ImageContext.getDefaultInstance() : imageContext_; + } else { + return imageContextBuilder_.getMessage(); + } + } + /** + *
+     * Additional context that may accompany the image(s) in the file.
+     * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public Builder setImageContext(com.google.cloud.vision.v1.ImageContext value) { + if (imageContextBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + imageContext_ = value; + onChanged(); + } else { + imageContextBuilder_.setMessage(value); + } + + return this; + } + /** + *
+     * Additional context that may accompany the image(s) in the file.
+     * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public Builder setImageContext( + com.google.cloud.vision.v1.ImageContext.Builder builderForValue) { + if (imageContextBuilder_ == null) { + imageContext_ = builderForValue.build(); + onChanged(); + } else { + imageContextBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + *
+     * Additional context that may accompany the image(s) in the file.
+     * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public Builder mergeImageContext(com.google.cloud.vision.v1.ImageContext value) { + if (imageContextBuilder_ == null) { + if (imageContext_ != null) { + imageContext_ = + com.google.cloud.vision.v1.ImageContext.newBuilder(imageContext_).mergeFrom(value).buildPartial(); + } else { + imageContext_ = value; + } + onChanged(); + } else { + imageContextBuilder_.mergeFrom(value); + } + + return this; + } + /** + *
+     * Additional context that may accompany the image(s) in the file.
+     * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public Builder clearImageContext() { + if (imageContextBuilder_ == null) { + imageContext_ = null; + onChanged(); + } else { + imageContext_ = null; + imageContextBuilder_ = null; + } + + return this; + } + /** + *
+     * Additional context that may accompany the image(s) in the file.
+     * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public com.google.cloud.vision.v1.ImageContext.Builder getImageContextBuilder() { + + onChanged(); + return getImageContextFieldBuilder().getBuilder(); + } + /** + *
+     * Additional context that may accompany the image(s) in the file.
+     * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + public com.google.cloud.vision.v1.ImageContextOrBuilder getImageContextOrBuilder() { + if (imageContextBuilder_ != null) { + return imageContextBuilder_.getMessageOrBuilder(); + } else { + return imageContext_ == null ? + com.google.cloud.vision.v1.ImageContext.getDefaultInstance() : imageContext_; + } + } + /** + *
+     * Additional context that may accompany the image(s) in the file.
+     * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.ImageContext, com.google.cloud.vision.v1.ImageContext.Builder, com.google.cloud.vision.v1.ImageContextOrBuilder> + getImageContextFieldBuilder() { + if (imageContextBuilder_ == null) { + imageContextBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.ImageContext, com.google.cloud.vision.v1.ImageContext.Builder, com.google.cloud.vision.v1.ImageContextOrBuilder>( + getImageContext(), + getParentForChildren(), + isClean()); + imageContext_ = null; + } + return imageContextBuilder_; + } + + private com.google.cloud.vision.v1.OutputConfig outputConfig_ = null; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.OutputConfig, com.google.cloud.vision.v1.OutputConfig.Builder, com.google.cloud.vision.v1.OutputConfigOrBuilder> outputConfigBuilder_; + /** + *
+     * Required. The desired output location and metadata (e.g. format).
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public boolean hasOutputConfig() { + return outputConfigBuilder_ != null || outputConfig_ != null; + } + /** + *
+     * Required. The desired output location and metadata (e.g. format).
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public com.google.cloud.vision.v1.OutputConfig getOutputConfig() { + if (outputConfigBuilder_ == null) { + return outputConfig_ == null ? com.google.cloud.vision.v1.OutputConfig.getDefaultInstance() : outputConfig_; + } else { + return outputConfigBuilder_.getMessage(); + } + } + /** + *
+     * Required. The desired output location and metadata (e.g. format).
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public Builder setOutputConfig(com.google.cloud.vision.v1.OutputConfig value) { + if (outputConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + outputConfig_ = value; + onChanged(); + } else { + outputConfigBuilder_.setMessage(value); + } + + return this; + } + /** + *
+     * Required. The desired output location and metadata (e.g. format).
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public Builder setOutputConfig( + com.google.cloud.vision.v1.OutputConfig.Builder builderForValue) { + if (outputConfigBuilder_ == null) { + outputConfig_ = builderForValue.build(); + onChanged(); + } else { + outputConfigBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + *
+     * Required. The desired output location and metadata (e.g. format).
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public Builder mergeOutputConfig(com.google.cloud.vision.v1.OutputConfig value) { + if (outputConfigBuilder_ == null) { + if (outputConfig_ != null) { + outputConfig_ = + com.google.cloud.vision.v1.OutputConfig.newBuilder(outputConfig_).mergeFrom(value).buildPartial(); + } else { + outputConfig_ = value; + } + onChanged(); + } else { + outputConfigBuilder_.mergeFrom(value); + } + + return this; + } + /** + *
+     * Required. The desired output location and metadata (e.g. format).
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public Builder clearOutputConfig() { + if (outputConfigBuilder_ == null) { + outputConfig_ = null; + onChanged(); + } else { + outputConfig_ = null; + outputConfigBuilder_ = null; + } + + return this; + } + /** + *
+     * Required. The desired output location and metadata (e.g. format).
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public com.google.cloud.vision.v1.OutputConfig.Builder getOutputConfigBuilder() { + + onChanged(); + return getOutputConfigFieldBuilder().getBuilder(); + } + /** + *
+     * Required. The desired output location and metadata (e.g. format).
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + public com.google.cloud.vision.v1.OutputConfigOrBuilder getOutputConfigOrBuilder() { + if (outputConfigBuilder_ != null) { + return outputConfigBuilder_.getMessageOrBuilder(); + } else { + return outputConfig_ == null ? + com.google.cloud.vision.v1.OutputConfig.getDefaultInstance() : outputConfig_; + } + } + /** + *
+     * Required. The desired output location and metadata (e.g. format).
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.OutputConfig, com.google.cloud.vision.v1.OutputConfig.Builder, com.google.cloud.vision.v1.OutputConfigOrBuilder> + getOutputConfigFieldBuilder() { + if (outputConfigBuilder_ == null) { + outputConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.OutputConfig, com.google.cloud.vision.v1.OutputConfig.Builder, com.google.cloud.vision.v1.OutputConfigOrBuilder>( + getOutputConfig(), + getParentForChildren(), + isClean()); + outputConfig_ = null; + } + return outputConfigBuilder_; + } + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFieldsProto3(unknownFields); + } + + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.AsyncAnnotateFileRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.AsyncAnnotateFileRequest) + private static final com.google.cloud.vision.v1.AsyncAnnotateFileRequest DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.AsyncAnnotateFileRequest(); + } + + public static com.google.cloud.vision.v1.AsyncAnnotateFileRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public AsyncAnnotateFileRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new AsyncAnnotateFileRequest(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + public com.google.cloud.vision.v1.AsyncAnnotateFileRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + +} + diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileRequestOrBuilder.java new file mode 100644 index 000000000000..d1a997a06296 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileRequestOrBuilder.java @@ -0,0 +1,128 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface AsyncAnnotateFileRequestOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.AsyncAnnotateFileRequest) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * Required. Information about the input file.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + boolean hasInputConfig(); + /** + *
+   * Required. Information about the input file.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + com.google.cloud.vision.v1.InputConfig getInputConfig(); + /** + *
+   * Required. Information about the input file.
+   * 
+ * + * .google.cloud.vision.v1.InputConfig input_config = 1; + */ + com.google.cloud.vision.v1.InputConfigOrBuilder getInputConfigOrBuilder(); + + /** + *
+   * Required. Requested features.
+   * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + java.util.List + getFeaturesList(); + /** + *
+   * Required. Requested features.
+   * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + com.google.cloud.vision.v1.Feature getFeatures(int index); + /** + *
+   * Required. Requested features.
+   * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + int getFeaturesCount(); + /** + *
+   * Required. Requested features.
+   * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + java.util.List + getFeaturesOrBuilderList(); + /** + *
+   * Required. Requested features.
+   * 
+ * + * repeated .google.cloud.vision.v1.Feature features = 2; + */ + com.google.cloud.vision.v1.FeatureOrBuilder getFeaturesOrBuilder( + int index); + + /** + *
+   * Additional context that may accompany the image(s) in the file.
+   * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + boolean hasImageContext(); + /** + *
+   * Additional context that may accompany the image(s) in the file.
+   * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + com.google.cloud.vision.v1.ImageContext getImageContext(); + /** + *
+   * Additional context that may accompany the image(s) in the file.
+   * 
+ * + * .google.cloud.vision.v1.ImageContext image_context = 3; + */ + com.google.cloud.vision.v1.ImageContextOrBuilder getImageContextOrBuilder(); + + /** + *
+   * Required. The desired output location and metadata (e.g. format).
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + boolean hasOutputConfig(); + /** + *
+   * Required. The desired output location and metadata (e.g. format).
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + com.google.cloud.vision.v1.OutputConfig getOutputConfig(); + /** + *
+   * Required. The desired output location and metadata (e.g. format).
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 4; + */ + com.google.cloud.vision.v1.OutputConfigOrBuilder getOutputConfigOrBuilder(); +} diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileResponse.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileResponse.java new file mode 100644 index 000000000000..ec0014e39824 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileResponse.java @@ -0,0 +1,626 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +/** + *
+ * The response for a single offline file annotation request.
+ * 
+ * + * Protobuf type {@code google.cloud.vision.v1.AsyncAnnotateFileResponse} + */ +public final class AsyncAnnotateFileResponse extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.AsyncAnnotateFileResponse) + AsyncAnnotateFileResponseOrBuilder { +private static final long serialVersionUID = 0L; + // Use AsyncAnnotateFileResponse.newBuilder() to construct. + private AsyncAnnotateFileResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private AsyncAnnotateFileResponse() { + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private AsyncAnnotateFileResponse( + 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; + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + case 10: { + com.google.cloud.vision.v1.OutputConfig.Builder subBuilder = null; + if (outputConfig_ != null) { + subBuilder = outputConfig_.toBuilder(); + } + outputConfig_ = input.readMessage(com.google.cloud.vision.v1.OutputConfig.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(outputConfig_); + outputConfig_ = subBuilder.buildPartial(); + } + + 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.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncAnnotateFileResponse_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncAnnotateFileResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.AsyncAnnotateFileResponse.class, com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder.class); + } + + public static final int OUTPUT_CONFIG_FIELD_NUMBER = 1; + private com.google.cloud.vision.v1.OutputConfig outputConfig_; + /** + *
+   * The output location and metadata from AsyncAnnotateFileRequest.
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public boolean hasOutputConfig() { + return outputConfig_ != null; + } + /** + *
+   * The output location and metadata from AsyncAnnotateFileRequest.
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public com.google.cloud.vision.v1.OutputConfig getOutputConfig() { + return outputConfig_ == null ? com.google.cloud.vision.v1.OutputConfig.getDefaultInstance() : outputConfig_; + } + /** + *
+   * The output location and metadata from AsyncAnnotateFileRequest.
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public com.google.cloud.vision.v1.OutputConfigOrBuilder getOutputConfigOrBuilder() { + return getOutputConfig(); + } + + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + if (outputConfig_ != null) { + output.writeMessage(1, getOutputConfig()); + } + unknownFields.writeTo(output); + } + + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (outputConfig_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, getOutputConfig()); + } + 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.vision.v1.AsyncAnnotateFileResponse)) { + return super.equals(obj); + } + com.google.cloud.vision.v1.AsyncAnnotateFileResponse other = (com.google.cloud.vision.v1.AsyncAnnotateFileResponse) obj; + + boolean result = true; + result = result && (hasOutputConfig() == other.hasOutputConfig()); + if (hasOutputConfig()) { + result = result && getOutputConfig() + .equals(other.getOutputConfig()); + } + result = result && unknownFields.equals(other.unknownFields); + return result; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasOutputConfig()) { + hash = (37 * hash) + OUTPUT_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getOutputConfig().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.vision.v1.AsyncAnnotateFileResponse parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileResponse 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.vision.v1.AsyncAnnotateFileResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileResponse 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.vision.v1.AsyncAnnotateFileResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileResponse parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileResponse parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileResponse 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.vision.v1.AsyncAnnotateFileResponse parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileResponse 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.vision.v1.AsyncAnnotateFileResponse parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncAnnotateFileResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(com.google.cloud.vision.v1.AsyncAnnotateFileResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + 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; + } + /** + *
+   * The response for a single offline file annotation request.
+   * 
+ * + * Protobuf type {@code google.cloud.vision.v1.AsyncAnnotateFileResponse} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.AsyncAnnotateFileResponse) + com.google.cloud.vision.v1.AsyncAnnotateFileResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncAnnotateFileResponse_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncAnnotateFileResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.AsyncAnnotateFileResponse.class, com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder.class); + } + + // Construct using com.google.cloud.vision.v1.AsyncAnnotateFileResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + } + } + public Builder clear() { + super.clear(); + if (outputConfigBuilder_ == null) { + outputConfig_ = null; + } else { + outputConfig_ = null; + outputConfigBuilder_ = null; + } + return this; + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncAnnotateFileResponse_descriptor; + } + + public com.google.cloud.vision.v1.AsyncAnnotateFileResponse getDefaultInstanceForType() { + return com.google.cloud.vision.v1.AsyncAnnotateFileResponse.getDefaultInstance(); + } + + public com.google.cloud.vision.v1.AsyncAnnotateFileResponse build() { + com.google.cloud.vision.v1.AsyncAnnotateFileResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public com.google.cloud.vision.v1.AsyncAnnotateFileResponse buildPartial() { + com.google.cloud.vision.v1.AsyncAnnotateFileResponse result = new com.google.cloud.vision.v1.AsyncAnnotateFileResponse(this); + if (outputConfigBuilder_ == null) { + result.outputConfig_ = outputConfig_; + } else { + result.outputConfig_ = outputConfigBuilder_.build(); + } + onBuilt(); + return result; + } + + public Builder clone() { + return (Builder) super.clone(); + } + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.setField(field, value); + } + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return (Builder) super.clearField(field); + } + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return (Builder) super.clearOneof(oneof); + } + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, java.lang.Object value) { + return (Builder) super.setRepeatedField(field, index, value); + } + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.addRepeatedField(field, value); + } + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.vision.v1.AsyncAnnotateFileResponse) { + return mergeFrom((com.google.cloud.vision.v1.AsyncAnnotateFileResponse)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.vision.v1.AsyncAnnotateFileResponse other) { + if (other == com.google.cloud.vision.v1.AsyncAnnotateFileResponse.getDefaultInstance()) return this; + if (other.hasOutputConfig()) { + mergeOutputConfig(other.getOutputConfig()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + public final boolean isInitialized() { + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.vision.v1.AsyncAnnotateFileResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.cloud.vision.v1.AsyncAnnotateFileResponse) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.vision.v1.OutputConfig outputConfig_ = null; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.OutputConfig, com.google.cloud.vision.v1.OutputConfig.Builder, com.google.cloud.vision.v1.OutputConfigOrBuilder> outputConfigBuilder_; + /** + *
+     * The output location and metadata from AsyncAnnotateFileRequest.
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public boolean hasOutputConfig() { + return outputConfigBuilder_ != null || outputConfig_ != null; + } + /** + *
+     * The output location and metadata from AsyncAnnotateFileRequest.
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public com.google.cloud.vision.v1.OutputConfig getOutputConfig() { + if (outputConfigBuilder_ == null) { + return outputConfig_ == null ? com.google.cloud.vision.v1.OutputConfig.getDefaultInstance() : outputConfig_; + } else { + return outputConfigBuilder_.getMessage(); + } + } + /** + *
+     * The output location and metadata from AsyncAnnotateFileRequest.
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public Builder setOutputConfig(com.google.cloud.vision.v1.OutputConfig value) { + if (outputConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + outputConfig_ = value; + onChanged(); + } else { + outputConfigBuilder_.setMessage(value); + } + + return this; + } + /** + *
+     * The output location and metadata from AsyncAnnotateFileRequest.
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public Builder setOutputConfig( + com.google.cloud.vision.v1.OutputConfig.Builder builderForValue) { + if (outputConfigBuilder_ == null) { + outputConfig_ = builderForValue.build(); + onChanged(); + } else { + outputConfigBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + *
+     * The output location and metadata from AsyncAnnotateFileRequest.
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public Builder mergeOutputConfig(com.google.cloud.vision.v1.OutputConfig value) { + if (outputConfigBuilder_ == null) { + if (outputConfig_ != null) { + outputConfig_ = + com.google.cloud.vision.v1.OutputConfig.newBuilder(outputConfig_).mergeFrom(value).buildPartial(); + } else { + outputConfig_ = value; + } + onChanged(); + } else { + outputConfigBuilder_.mergeFrom(value); + } + + return this; + } + /** + *
+     * The output location and metadata from AsyncAnnotateFileRequest.
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public Builder clearOutputConfig() { + if (outputConfigBuilder_ == null) { + outputConfig_ = null; + onChanged(); + } else { + outputConfig_ = null; + outputConfigBuilder_ = null; + } + + return this; + } + /** + *
+     * The output location and metadata from AsyncAnnotateFileRequest.
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public com.google.cloud.vision.v1.OutputConfig.Builder getOutputConfigBuilder() { + + onChanged(); + return getOutputConfigFieldBuilder().getBuilder(); + } + /** + *
+     * The output location and metadata from AsyncAnnotateFileRequest.
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + public com.google.cloud.vision.v1.OutputConfigOrBuilder getOutputConfigOrBuilder() { + if (outputConfigBuilder_ != null) { + return outputConfigBuilder_.getMessageOrBuilder(); + } else { + return outputConfig_ == null ? + com.google.cloud.vision.v1.OutputConfig.getDefaultInstance() : outputConfig_; + } + } + /** + *
+     * The output location and metadata from AsyncAnnotateFileRequest.
+     * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.OutputConfig, com.google.cloud.vision.v1.OutputConfig.Builder, com.google.cloud.vision.v1.OutputConfigOrBuilder> + getOutputConfigFieldBuilder() { + if (outputConfigBuilder_ == null) { + outputConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.OutputConfig, com.google.cloud.vision.v1.OutputConfig.Builder, com.google.cloud.vision.v1.OutputConfigOrBuilder>( + getOutputConfig(), + getParentForChildren(), + isClean()); + outputConfig_ = null; + } + return outputConfigBuilder_; + } + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFieldsProto3(unknownFields); + } + + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.AsyncAnnotateFileResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.AsyncAnnotateFileResponse) + private static final com.google.cloud.vision.v1.AsyncAnnotateFileResponse DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.AsyncAnnotateFileResponse(); + } + + public static com.google.cloud.vision.v1.AsyncAnnotateFileResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public AsyncAnnotateFileResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new AsyncAnnotateFileResponse(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + public com.google.cloud.vision.v1.AsyncAnnotateFileResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + +} + diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileResponseOrBuilder.java new file mode 100644 index 000000000000..36b15dd011bb --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncAnnotateFileResponseOrBuilder.java @@ -0,0 +1,34 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface AsyncAnnotateFileResponseOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.AsyncAnnotateFileResponse) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * The output location and metadata from AsyncAnnotateFileRequest.
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + boolean hasOutputConfig(); + /** + *
+   * The output location and metadata from AsyncAnnotateFileRequest.
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + com.google.cloud.vision.v1.OutputConfig getOutputConfig(); + /** + *
+   * The output location and metadata from AsyncAnnotateFileRequest.
+   * 
+ * + * .google.cloud.vision.v1.OutputConfig output_config = 1; + */ + com.google.cloud.vision.v1.OutputConfigOrBuilder getOutputConfigOrBuilder(); +} diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesRequest.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesRequest.java new file mode 100644 index 000000000000..df368dd99d37 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesRequest.java @@ -0,0 +1,836 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +/** + *
+ * Multiple async file annotation requests are batched into a single service
+ * call.
+ * 
+ * + * Protobuf type {@code google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest} + */ +public final class AsyncBatchAnnotateFilesRequest extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest) + AsyncBatchAnnotateFilesRequestOrBuilder { +private static final long serialVersionUID = 0L; + // Use AsyncBatchAnnotateFilesRequest.newBuilder() to construct. + private AsyncBatchAnnotateFilesRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private AsyncBatchAnnotateFilesRequest() { + requests_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private AsyncBatchAnnotateFilesRequest( + 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; + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + case 10: { + if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + requests_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + requests_.add( + input.readMessage(com.google.cloud.vision.v1.AsyncAnnotateFileRequest.parser(), extensionRegistry)); + 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) == 0x00000001)) { + requests_ = java.util.Collections.unmodifiableList(requests_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesRequest_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest.class, com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest.Builder.class); + } + + public static final int REQUESTS_FIELD_NUMBER = 1; + private java.util.List requests_; + /** + *
+   * Individual async file annotation requests for this batch.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public java.util.List getRequestsList() { + return requests_; + } + /** + *
+   * Individual async file annotation requests for this batch.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public java.util.List + getRequestsOrBuilderList() { + return requests_; + } + /** + *
+   * Individual async file annotation requests for this batch.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public int getRequestsCount() { + return requests_.size(); + } + /** + *
+   * Individual async file annotation requests for this batch.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileRequest getRequests(int index) { + return requests_.get(index); + } + /** + *
+   * Individual async file annotation requests for this batch.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileRequestOrBuilder getRequestsOrBuilder( + int index) { + return requests_.get(index); + } + + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + for (int i = 0; i < requests_.size(); i++) { + output.writeMessage(1, requests_.get(i)); + } + unknownFields.writeTo(output); + } + + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < requests_.size(); i++) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, requests_.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.vision.v1.AsyncBatchAnnotateFilesRequest)) { + return super.equals(obj); + } + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest other = (com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest) obj; + + boolean result = true; + result = result && getRequestsList() + .equals(other.getRequestsList()); + result = result && unknownFields.equals(other.unknownFields); + return result; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getRequestsCount() > 0) { + hash = (37 * hash) + REQUESTS_FIELD_NUMBER; + hash = (53 * hash) + getRequestsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest 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.vision.v1.AsyncBatchAnnotateFilesRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest 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.vision.v1.AsyncBatchAnnotateFilesRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest 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.vision.v1.AsyncBatchAnnotateFilesRequest parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest 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.vision.v1.AsyncBatchAnnotateFilesRequest parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + 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; + } + /** + *
+   * Multiple async file annotation requests are batched into a single service
+   * call.
+   * 
+ * + * Protobuf type {@code google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest) + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesRequest_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest.class, com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest.Builder.class); + } + + // Construct using com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + getRequestsFieldBuilder(); + } + } + public Builder clear() { + super.clear(); + if (requestsBuilder_ == null) { + requests_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + requestsBuilder_.clear(); + } + return this; + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesRequest_descriptor; + } + + public com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest getDefaultInstanceForType() { + return com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest.getDefaultInstance(); + } + + public com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest build() { + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest buildPartial() { + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest result = new com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest(this); + int from_bitField0_ = bitField0_; + if (requestsBuilder_ == null) { + if (((bitField0_ & 0x00000001) == 0x00000001)) { + requests_ = java.util.Collections.unmodifiableList(requests_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.requests_ = requests_; + } else { + result.requests_ = requestsBuilder_.build(); + } + onBuilt(); + return result; + } + + public Builder clone() { + return (Builder) super.clone(); + } + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.setField(field, value); + } + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return (Builder) super.clearField(field); + } + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return (Builder) super.clearOneof(oneof); + } + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, java.lang.Object value) { + return (Builder) super.setRepeatedField(field, index, value); + } + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.addRepeatedField(field, value); + } + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest) { + return mergeFrom((com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest other) { + if (other == com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest.getDefaultInstance()) return this; + if (requestsBuilder_ == null) { + if (!other.requests_.isEmpty()) { + if (requests_.isEmpty()) { + requests_ = other.requests_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureRequestsIsMutable(); + requests_.addAll(other.requests_); + } + onChanged(); + } + } else { + if (!other.requests_.isEmpty()) { + if (requestsBuilder_.isEmpty()) { + requestsBuilder_.dispose(); + requestsBuilder_ = null; + requests_ = other.requests_; + bitField0_ = (bitField0_ & ~0x00000001); + requestsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? + getRequestsFieldBuilder() : null; + } else { + requestsBuilder_.addAllMessages(other.requests_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + public final boolean isInitialized() { + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + private int bitField0_; + + private java.util.List requests_ = + java.util.Collections.emptyList(); + private void ensureRequestsIsMutable() { + if (!((bitField0_ & 0x00000001) == 0x00000001)) { + requests_ = new java.util.ArrayList(requests_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.AsyncAnnotateFileRequest, com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder, com.google.cloud.vision.v1.AsyncAnnotateFileRequestOrBuilder> requestsBuilder_; + + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public java.util.List getRequestsList() { + if (requestsBuilder_ == null) { + return java.util.Collections.unmodifiableList(requests_); + } else { + return requestsBuilder_.getMessageList(); + } + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public int getRequestsCount() { + if (requestsBuilder_ == null) { + return requests_.size(); + } else { + return requestsBuilder_.getCount(); + } + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileRequest getRequests(int index) { + if (requestsBuilder_ == null) { + return requests_.get(index); + } else { + return requestsBuilder_.getMessage(index); + } + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public Builder setRequests( + int index, com.google.cloud.vision.v1.AsyncAnnotateFileRequest value) { + if (requestsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRequestsIsMutable(); + requests_.set(index, value); + onChanged(); + } else { + requestsBuilder_.setMessage(index, value); + } + return this; + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public Builder setRequests( + int index, com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder builderForValue) { + if (requestsBuilder_ == null) { + ensureRequestsIsMutable(); + requests_.set(index, builderForValue.build()); + onChanged(); + } else { + requestsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public Builder addRequests(com.google.cloud.vision.v1.AsyncAnnotateFileRequest value) { + if (requestsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRequestsIsMutable(); + requests_.add(value); + onChanged(); + } else { + requestsBuilder_.addMessage(value); + } + return this; + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public Builder addRequests( + int index, com.google.cloud.vision.v1.AsyncAnnotateFileRequest value) { + if (requestsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureRequestsIsMutable(); + requests_.add(index, value); + onChanged(); + } else { + requestsBuilder_.addMessage(index, value); + } + return this; + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public Builder addRequests( + com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder builderForValue) { + if (requestsBuilder_ == null) { + ensureRequestsIsMutable(); + requests_.add(builderForValue.build()); + onChanged(); + } else { + requestsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public Builder addRequests( + int index, com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder builderForValue) { + if (requestsBuilder_ == null) { + ensureRequestsIsMutable(); + requests_.add(index, builderForValue.build()); + onChanged(); + } else { + requestsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public Builder addAllRequests( + java.lang.Iterable values) { + if (requestsBuilder_ == null) { + ensureRequestsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll( + values, requests_); + onChanged(); + } else { + requestsBuilder_.addAllMessages(values); + } + return this; + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public Builder clearRequests() { + if (requestsBuilder_ == null) { + requests_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + requestsBuilder_.clear(); + } + return this; + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public Builder removeRequests(int index) { + if (requestsBuilder_ == null) { + ensureRequestsIsMutable(); + requests_.remove(index); + onChanged(); + } else { + requestsBuilder_.remove(index); + } + return this; + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder getRequestsBuilder( + int index) { + return getRequestsFieldBuilder().getBuilder(index); + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileRequestOrBuilder getRequestsOrBuilder( + int index) { + if (requestsBuilder_ == null) { + return requests_.get(index); } else { + return requestsBuilder_.getMessageOrBuilder(index); + } + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public java.util.List + getRequestsOrBuilderList() { + if (requestsBuilder_ != null) { + return requestsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(requests_); + } + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder addRequestsBuilder() { + return getRequestsFieldBuilder().addBuilder( + com.google.cloud.vision.v1.AsyncAnnotateFileRequest.getDefaultInstance()); + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder addRequestsBuilder( + int index) { + return getRequestsFieldBuilder().addBuilder( + index, com.google.cloud.vision.v1.AsyncAnnotateFileRequest.getDefaultInstance()); + } + /** + *
+     * Individual async file annotation requests for this batch.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + public java.util.List + getRequestsBuilderList() { + return getRequestsFieldBuilder().getBuilderList(); + } + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.AsyncAnnotateFileRequest, com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder, com.google.cloud.vision.v1.AsyncAnnotateFileRequestOrBuilder> + getRequestsFieldBuilder() { + if (requestsBuilder_ == null) { + requestsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.AsyncAnnotateFileRequest, com.google.cloud.vision.v1.AsyncAnnotateFileRequest.Builder, com.google.cloud.vision.v1.AsyncAnnotateFileRequestOrBuilder>( + requests_, + ((bitField0_ & 0x00000001) == 0x00000001), + getParentForChildren(), + isClean()); + requests_ = null; + } + return requestsBuilder_; + } + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFieldsProto3(unknownFields); + } + + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest) + private static final com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest(); + } + + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public AsyncBatchAnnotateFilesRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new AsyncBatchAnnotateFilesRequest(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + public com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + +} + diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesRequestOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesRequestOrBuilder.java new file mode 100644 index 000000000000..a56a419b5126 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesRequestOrBuilder.java @@ -0,0 +1,53 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface AsyncBatchAnnotateFilesRequestOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * Individual async file annotation requests for this batch.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + java.util.List + getRequestsList(); + /** + *
+   * Individual async file annotation requests for this batch.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + com.google.cloud.vision.v1.AsyncAnnotateFileRequest getRequests(int index); + /** + *
+   * Individual async file annotation requests for this batch.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + int getRequestsCount(); + /** + *
+   * Individual async file annotation requests for this batch.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + java.util.List + getRequestsOrBuilderList(); + /** + *
+   * Individual async file annotation requests for this batch.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileRequest requests = 1; + */ + com.google.cloud.vision.v1.AsyncAnnotateFileRequestOrBuilder getRequestsOrBuilder( + int index); +} diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesResponse.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesResponse.java new file mode 100644 index 000000000000..3107b23f498b --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesResponse.java @@ -0,0 +1,857 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +/** + *
+ * Response to an async batch file annotation request.
+ * 
+ * + * Protobuf type {@code google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse} + */ +public final class AsyncBatchAnnotateFilesResponse extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse) + AsyncBatchAnnotateFilesResponseOrBuilder { +private static final long serialVersionUID = 0L; + // Use AsyncBatchAnnotateFilesResponse.newBuilder() to construct. + private AsyncBatchAnnotateFilesResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private AsyncBatchAnnotateFilesResponse() { + responses_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private AsyncBatchAnnotateFilesResponse( + 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; + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + case 10: { + if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { + responses_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + responses_.add( + input.readMessage(com.google.cloud.vision.v1.AsyncAnnotateFileResponse.parser(), extensionRegistry)); + 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) == 0x00000001)) { + responses_ = java.util.Collections.unmodifiableList(responses_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesResponse_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse.class, com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse.Builder.class); + } + + public static final int RESPONSES_FIELD_NUMBER = 1; + private java.util.List responses_; + /** + *
+   * The list of file annotation responses, one for each request in
+   * AsyncBatchAnnotateFilesRequest.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public java.util.List getResponsesList() { + return responses_; + } + /** + *
+   * The list of file annotation responses, one for each request in
+   * AsyncBatchAnnotateFilesRequest.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public java.util.List + getResponsesOrBuilderList() { + return responses_; + } + /** + *
+   * The list of file annotation responses, one for each request in
+   * AsyncBatchAnnotateFilesRequest.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public int getResponsesCount() { + return responses_.size(); + } + /** + *
+   * The list of file annotation responses, one for each request in
+   * AsyncBatchAnnotateFilesRequest.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileResponse getResponses(int index) { + return responses_.get(index); + } + /** + *
+   * The list of file annotation responses, one for each request in
+   * AsyncBatchAnnotateFilesRequest.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileResponseOrBuilder getResponsesOrBuilder( + int index) { + return responses_.get(index); + } + + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + for (int i = 0; i < responses_.size(); i++) { + output.writeMessage(1, responses_.get(i)); + } + unknownFields.writeTo(output); + } + + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < responses_.size(); i++) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, responses_.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.vision.v1.AsyncBatchAnnotateFilesResponse)) { + return super.equals(obj); + } + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse other = (com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse) obj; + + boolean result = true; + result = result && getResponsesList() + .equals(other.getResponsesList()); + result = result && unknownFields.equals(other.unknownFields); + return result; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getResponsesCount() > 0) { + hash = (37 * hash) + RESPONSES_FIELD_NUMBER; + hash = (53 * hash) + getResponsesList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse 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.vision.v1.AsyncBatchAnnotateFilesResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse 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.vision.v1.AsyncBatchAnnotateFilesResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse 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.vision.v1.AsyncBatchAnnotateFilesResponse parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse 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.vision.v1.AsyncBatchAnnotateFilesResponse parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + public Builder toBuilder() { + return this == DEFAULT_INSTANCE + ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + *
+   * Response to an async batch file annotation request.
+   * 
+ * + * Protobuf type {@code google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse) + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesResponse_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse.class, com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse.Builder.class); + } + + // Construct using com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + getResponsesFieldBuilder(); + } + } + public Builder clear() { + super.clear(); + if (responsesBuilder_ == null) { + responses_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + responsesBuilder_.clear(); + } + return this; + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesResponse_descriptor; + } + + public com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse getDefaultInstanceForType() { + return com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse.getDefaultInstance(); + } + + public com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse build() { + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse buildPartial() { + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse result = new com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse(this); + int from_bitField0_ = bitField0_; + if (responsesBuilder_ == null) { + if (((bitField0_ & 0x00000001) == 0x00000001)) { + responses_ = java.util.Collections.unmodifiableList(responses_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.responses_ = responses_; + } else { + result.responses_ = responsesBuilder_.build(); + } + onBuilt(); + return result; + } + + public Builder clone() { + return (Builder) super.clone(); + } + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.setField(field, value); + } + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return (Builder) super.clearField(field); + } + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return (Builder) super.clearOneof(oneof); + } + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, java.lang.Object value) { + return (Builder) super.setRepeatedField(field, index, value); + } + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.addRepeatedField(field, value); + } + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse) { + return mergeFrom((com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse other) { + if (other == com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse.getDefaultInstance()) return this; + if (responsesBuilder_ == null) { + if (!other.responses_.isEmpty()) { + if (responses_.isEmpty()) { + responses_ = other.responses_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureResponsesIsMutable(); + responses_.addAll(other.responses_); + } + onChanged(); + } + } else { + if (!other.responses_.isEmpty()) { + if (responsesBuilder_.isEmpty()) { + responsesBuilder_.dispose(); + responsesBuilder_ = null; + responses_ = other.responses_; + bitField0_ = (bitField0_ & ~0x00000001); + responsesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? + getResponsesFieldBuilder() : null; + } else { + responsesBuilder_.addAllMessages(other.responses_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + public final boolean isInitialized() { + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + private int bitField0_; + + private java.util.List responses_ = + java.util.Collections.emptyList(); + private void ensureResponsesIsMutable() { + if (!((bitField0_ & 0x00000001) == 0x00000001)) { + responses_ = new java.util.ArrayList(responses_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.AsyncAnnotateFileResponse, com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder, com.google.cloud.vision.v1.AsyncAnnotateFileResponseOrBuilder> responsesBuilder_; + + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public java.util.List getResponsesList() { + if (responsesBuilder_ == null) { + return java.util.Collections.unmodifiableList(responses_); + } else { + return responsesBuilder_.getMessageList(); + } + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public int getResponsesCount() { + if (responsesBuilder_ == null) { + return responses_.size(); + } else { + return responsesBuilder_.getCount(); + } + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileResponse getResponses(int index) { + if (responsesBuilder_ == null) { + return responses_.get(index); + } else { + return responsesBuilder_.getMessage(index); + } + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public Builder setResponses( + int index, com.google.cloud.vision.v1.AsyncAnnotateFileResponse value) { + if (responsesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureResponsesIsMutable(); + responses_.set(index, value); + onChanged(); + } else { + responsesBuilder_.setMessage(index, value); + } + return this; + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public Builder setResponses( + int index, com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder builderForValue) { + if (responsesBuilder_ == null) { + ensureResponsesIsMutable(); + responses_.set(index, builderForValue.build()); + onChanged(); + } else { + responsesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public Builder addResponses(com.google.cloud.vision.v1.AsyncAnnotateFileResponse value) { + if (responsesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureResponsesIsMutable(); + responses_.add(value); + onChanged(); + } else { + responsesBuilder_.addMessage(value); + } + return this; + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public Builder addResponses( + int index, com.google.cloud.vision.v1.AsyncAnnotateFileResponse value) { + if (responsesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureResponsesIsMutable(); + responses_.add(index, value); + onChanged(); + } else { + responsesBuilder_.addMessage(index, value); + } + return this; + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public Builder addResponses( + com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder builderForValue) { + if (responsesBuilder_ == null) { + ensureResponsesIsMutable(); + responses_.add(builderForValue.build()); + onChanged(); + } else { + responsesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public Builder addResponses( + int index, com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder builderForValue) { + if (responsesBuilder_ == null) { + ensureResponsesIsMutable(); + responses_.add(index, builderForValue.build()); + onChanged(); + } else { + responsesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public Builder addAllResponses( + java.lang.Iterable values) { + if (responsesBuilder_ == null) { + ensureResponsesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll( + values, responses_); + onChanged(); + } else { + responsesBuilder_.addAllMessages(values); + } + return this; + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public Builder clearResponses() { + if (responsesBuilder_ == null) { + responses_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + responsesBuilder_.clear(); + } + return this; + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public Builder removeResponses(int index) { + if (responsesBuilder_ == null) { + ensureResponsesIsMutable(); + responses_.remove(index); + onChanged(); + } else { + responsesBuilder_.remove(index); + } + return this; + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder getResponsesBuilder( + int index) { + return getResponsesFieldBuilder().getBuilder(index); + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileResponseOrBuilder getResponsesOrBuilder( + int index) { + if (responsesBuilder_ == null) { + return responses_.get(index); } else { + return responsesBuilder_.getMessageOrBuilder(index); + } + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public java.util.List + getResponsesOrBuilderList() { + if (responsesBuilder_ != null) { + return responsesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(responses_); + } + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder addResponsesBuilder() { + return getResponsesFieldBuilder().addBuilder( + com.google.cloud.vision.v1.AsyncAnnotateFileResponse.getDefaultInstance()); + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder addResponsesBuilder( + int index) { + return getResponsesFieldBuilder().addBuilder( + index, com.google.cloud.vision.v1.AsyncAnnotateFileResponse.getDefaultInstance()); + } + /** + *
+     * The list of file annotation responses, one for each request in
+     * AsyncBatchAnnotateFilesRequest.
+     * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + public java.util.List + getResponsesBuilderList() { + return getResponsesFieldBuilder().getBuilderList(); + } + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.AsyncAnnotateFileResponse, com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder, com.google.cloud.vision.v1.AsyncAnnotateFileResponseOrBuilder> + getResponsesFieldBuilder() { + if (responsesBuilder_ == null) { + responsesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.AsyncAnnotateFileResponse, com.google.cloud.vision.v1.AsyncAnnotateFileResponse.Builder, com.google.cloud.vision.v1.AsyncAnnotateFileResponseOrBuilder>( + responses_, + ((bitField0_ & 0x00000001) == 0x00000001), + getParentForChildren(), + isClean()); + responses_ = null; + } + return responsesBuilder_; + } + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFieldsProto3(unknownFields); + } + + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse) + private static final com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse(); + } + + public static com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public AsyncBatchAnnotateFilesResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new AsyncBatchAnnotateFilesResponse(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + public com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + +} + diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesResponseOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesResponseOrBuilder.java new file mode 100644 index 000000000000..29a29014543a --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/AsyncBatchAnnotateFilesResponseOrBuilder.java @@ -0,0 +1,58 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface AsyncBatchAnnotateFilesResponseOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * The list of file annotation responses, one for each request in
+   * AsyncBatchAnnotateFilesRequest.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + java.util.List + getResponsesList(); + /** + *
+   * The list of file annotation responses, one for each request in
+   * AsyncBatchAnnotateFilesRequest.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + com.google.cloud.vision.v1.AsyncAnnotateFileResponse getResponses(int index); + /** + *
+   * The list of file annotation responses, one for each request in
+   * AsyncBatchAnnotateFilesRequest.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + int getResponsesCount(); + /** + *
+   * The list of file annotation responses, one for each request in
+   * AsyncBatchAnnotateFilesRequest.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + java.util.List + getResponsesOrBuilderList(); + /** + *
+   * The list of file annotation responses, one for each request in
+   * AsyncBatchAnnotateFilesRequest.
+   * 
+ * + * repeated .google.cloud.vision.v1.AsyncAnnotateFileResponse responses = 1; + */ + com.google.cloud.vision.v1.AsyncAnnotateFileResponseOrBuilder getResponsesOrBuilder( + int index); +} diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/BoundingPoly.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/BoundingPoly.java index ccbbe30fe87a..25f4ec64b791 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/BoundingPoly.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/BoundingPoly.java @@ -21,6 +21,7 @@ private BoundingPoly(com.google.protobuf.GeneratedMessageV3.Builder builder) } private BoundingPoly() { vertices_ = java.util.Collections.emptyList(); + normalizedVertices_ = java.util.Collections.emptyList(); } @java.lang.Override @@ -63,6 +64,15 @@ private BoundingPoly( input.readMessage(com.google.cloud.vision.v1.Vertex.parser(), extensionRegistry)); break; } + case 18: { + if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + normalizedVertices_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000002; + } + normalizedVertices_.add( + input.readMessage(com.google.cloud.vision.v1.NormalizedVertex.parser(), extensionRegistry)); + break; + } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -74,6 +84,9 @@ private BoundingPoly( if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { vertices_ = java.util.Collections.unmodifiableList(vertices_); } + if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) { + normalizedVertices_ = java.util.Collections.unmodifiableList(normalizedVertices_); + } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } @@ -145,6 +158,61 @@ public com.google.cloud.vision.v1.VertexOrBuilder getVerticesOrBuilder( return vertices_.get(index); } + public static final int NORMALIZED_VERTICES_FIELD_NUMBER = 2; + private java.util.List normalizedVertices_; + /** + *
+   * The bounding polygon normalized vertices.
+   * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public java.util.List getNormalizedVerticesList() { + return normalizedVertices_; + } + /** + *
+   * The bounding polygon normalized vertices.
+   * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public java.util.List + getNormalizedVerticesOrBuilderList() { + return normalizedVertices_; + } + /** + *
+   * The bounding polygon normalized vertices.
+   * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public int getNormalizedVerticesCount() { + return normalizedVertices_.size(); + } + /** + *
+   * The bounding polygon normalized vertices.
+   * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public com.google.cloud.vision.v1.NormalizedVertex getNormalizedVertices(int index) { + return normalizedVertices_.get(index); + } + /** + *
+   * The bounding polygon normalized vertices.
+   * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public com.google.cloud.vision.v1.NormalizedVertexOrBuilder getNormalizedVerticesOrBuilder( + int index) { + return normalizedVertices_.get(index); + } + private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -160,6 +228,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) for (int i = 0; i < vertices_.size(); i++) { output.writeMessage(1, vertices_.get(i)); } + for (int i = 0; i < normalizedVertices_.size(); i++) { + output.writeMessage(2, normalizedVertices_.get(i)); + } unknownFields.writeTo(output); } @@ -172,6 +243,10 @@ public int getSerializedSize() { size += com.google.protobuf.CodedOutputStream .computeMessageSize(1, vertices_.get(i)); } + for (int i = 0; i < normalizedVertices_.size(); i++) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(2, normalizedVertices_.get(i)); + } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; @@ -190,6 +265,8 @@ public boolean equals(final java.lang.Object obj) { boolean result = true; result = result && getVerticesList() .equals(other.getVerticesList()); + result = result && getNormalizedVerticesList() + .equals(other.getNormalizedVerticesList()); result = result && unknownFields.equals(other.unknownFields); return result; } @@ -205,6 +282,10 @@ public int hashCode() { hash = (37 * hash) + VERTICES_FIELD_NUMBER; hash = (53 * hash) + getVerticesList().hashCode(); } + if (getNormalizedVerticesCount() > 0) { + hash = (37 * hash) + NORMALIZED_VERTICES_FIELD_NUMBER; + hash = (53 * hash) + getNormalizedVerticesList().hashCode(); + } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; @@ -335,6 +416,7 @@ private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { getVerticesFieldBuilder(); + getNormalizedVerticesFieldBuilder(); } } public Builder clear() { @@ -345,6 +427,12 @@ public Builder clear() { } else { verticesBuilder_.clear(); } + if (normalizedVerticesBuilder_ == null) { + normalizedVertices_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + } else { + normalizedVerticesBuilder_.clear(); + } return this; } @@ -377,6 +465,15 @@ public com.google.cloud.vision.v1.BoundingPoly buildPartial() { } else { result.vertices_ = verticesBuilder_.build(); } + if (normalizedVerticesBuilder_ == null) { + if (((bitField0_ & 0x00000002) == 0x00000002)) { + normalizedVertices_ = java.util.Collections.unmodifiableList(normalizedVertices_); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.normalizedVertices_ = normalizedVertices_; + } else { + result.normalizedVertices_ = normalizedVerticesBuilder_.build(); + } onBuilt(); return result; } @@ -444,6 +541,32 @@ public Builder mergeFrom(com.google.cloud.vision.v1.BoundingPoly other) { } } } + if (normalizedVerticesBuilder_ == null) { + if (!other.normalizedVertices_.isEmpty()) { + if (normalizedVertices_.isEmpty()) { + normalizedVertices_ = other.normalizedVertices_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureNormalizedVerticesIsMutable(); + normalizedVertices_.addAll(other.normalizedVertices_); + } + onChanged(); + } + } else { + if (!other.normalizedVertices_.isEmpty()) { + if (normalizedVerticesBuilder_.isEmpty()) { + normalizedVerticesBuilder_.dispose(); + normalizedVerticesBuilder_ = null; + normalizedVertices_ = other.normalizedVertices_; + bitField0_ = (bitField0_ & ~0x00000002); + normalizedVerticesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? + getNormalizedVerticesFieldBuilder() : null; + } else { + normalizedVerticesBuilder_.addAllMessages(other.normalizedVertices_); + } + } + } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; @@ -783,6 +906,318 @@ public com.google.cloud.vision.v1.Vertex.Builder addVerticesBuilder( } return verticesBuilder_; } + + private java.util.List normalizedVertices_ = + java.util.Collections.emptyList(); + private void ensureNormalizedVerticesIsMutable() { + if (!((bitField0_ & 0x00000002) == 0x00000002)) { + normalizedVertices_ = new java.util.ArrayList(normalizedVertices_); + bitField0_ |= 0x00000002; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.NormalizedVertex, com.google.cloud.vision.v1.NormalizedVertex.Builder, com.google.cloud.vision.v1.NormalizedVertexOrBuilder> normalizedVerticesBuilder_; + + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public java.util.List getNormalizedVerticesList() { + if (normalizedVerticesBuilder_ == null) { + return java.util.Collections.unmodifiableList(normalizedVertices_); + } else { + return normalizedVerticesBuilder_.getMessageList(); + } + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public int getNormalizedVerticesCount() { + if (normalizedVerticesBuilder_ == null) { + return normalizedVertices_.size(); + } else { + return normalizedVerticesBuilder_.getCount(); + } + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public com.google.cloud.vision.v1.NormalizedVertex getNormalizedVertices(int index) { + if (normalizedVerticesBuilder_ == null) { + return normalizedVertices_.get(index); + } else { + return normalizedVerticesBuilder_.getMessage(index); + } + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public Builder setNormalizedVertices( + int index, com.google.cloud.vision.v1.NormalizedVertex value) { + if (normalizedVerticesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureNormalizedVerticesIsMutable(); + normalizedVertices_.set(index, value); + onChanged(); + } else { + normalizedVerticesBuilder_.setMessage(index, value); + } + return this; + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public Builder setNormalizedVertices( + int index, com.google.cloud.vision.v1.NormalizedVertex.Builder builderForValue) { + if (normalizedVerticesBuilder_ == null) { + ensureNormalizedVerticesIsMutable(); + normalizedVertices_.set(index, builderForValue.build()); + onChanged(); + } else { + normalizedVerticesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public Builder addNormalizedVertices(com.google.cloud.vision.v1.NormalizedVertex value) { + if (normalizedVerticesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureNormalizedVerticesIsMutable(); + normalizedVertices_.add(value); + onChanged(); + } else { + normalizedVerticesBuilder_.addMessage(value); + } + return this; + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public Builder addNormalizedVertices( + int index, com.google.cloud.vision.v1.NormalizedVertex value) { + if (normalizedVerticesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureNormalizedVerticesIsMutable(); + normalizedVertices_.add(index, value); + onChanged(); + } else { + normalizedVerticesBuilder_.addMessage(index, value); + } + return this; + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public Builder addNormalizedVertices( + com.google.cloud.vision.v1.NormalizedVertex.Builder builderForValue) { + if (normalizedVerticesBuilder_ == null) { + ensureNormalizedVerticesIsMutable(); + normalizedVertices_.add(builderForValue.build()); + onChanged(); + } else { + normalizedVerticesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public Builder addNormalizedVertices( + int index, com.google.cloud.vision.v1.NormalizedVertex.Builder builderForValue) { + if (normalizedVerticesBuilder_ == null) { + ensureNormalizedVerticesIsMutable(); + normalizedVertices_.add(index, builderForValue.build()); + onChanged(); + } else { + normalizedVerticesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public Builder addAllNormalizedVertices( + java.lang.Iterable values) { + if (normalizedVerticesBuilder_ == null) { + ensureNormalizedVerticesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll( + values, normalizedVertices_); + onChanged(); + } else { + normalizedVerticesBuilder_.addAllMessages(values); + } + return this; + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public Builder clearNormalizedVertices() { + if (normalizedVerticesBuilder_ == null) { + normalizedVertices_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + } else { + normalizedVerticesBuilder_.clear(); + } + return this; + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public Builder removeNormalizedVertices(int index) { + if (normalizedVerticesBuilder_ == null) { + ensureNormalizedVerticesIsMutable(); + normalizedVertices_.remove(index); + onChanged(); + } else { + normalizedVerticesBuilder_.remove(index); + } + return this; + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public com.google.cloud.vision.v1.NormalizedVertex.Builder getNormalizedVerticesBuilder( + int index) { + return getNormalizedVerticesFieldBuilder().getBuilder(index); + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public com.google.cloud.vision.v1.NormalizedVertexOrBuilder getNormalizedVerticesOrBuilder( + int index) { + if (normalizedVerticesBuilder_ == null) { + return normalizedVertices_.get(index); } else { + return normalizedVerticesBuilder_.getMessageOrBuilder(index); + } + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public java.util.List + getNormalizedVerticesOrBuilderList() { + if (normalizedVerticesBuilder_ != null) { + return normalizedVerticesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(normalizedVertices_); + } + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public com.google.cloud.vision.v1.NormalizedVertex.Builder addNormalizedVerticesBuilder() { + return getNormalizedVerticesFieldBuilder().addBuilder( + com.google.cloud.vision.v1.NormalizedVertex.getDefaultInstance()); + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public com.google.cloud.vision.v1.NormalizedVertex.Builder addNormalizedVerticesBuilder( + int index) { + return getNormalizedVerticesFieldBuilder().addBuilder( + index, com.google.cloud.vision.v1.NormalizedVertex.getDefaultInstance()); + } + /** + *
+     * The bounding polygon normalized vertices.
+     * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + public java.util.List + getNormalizedVerticesBuilderList() { + return getNormalizedVerticesFieldBuilder().getBuilderList(); + } + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.NormalizedVertex, com.google.cloud.vision.v1.NormalizedVertex.Builder, com.google.cloud.vision.v1.NormalizedVertexOrBuilder> + getNormalizedVerticesFieldBuilder() { + if (normalizedVerticesBuilder_ == null) { + normalizedVerticesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.vision.v1.NormalizedVertex, com.google.cloud.vision.v1.NormalizedVertex.Builder, com.google.cloud.vision.v1.NormalizedVertexOrBuilder>( + normalizedVertices_, + ((bitField0_ & 0x00000002) == 0x00000002), + getParentForChildren(), + isClean()); + normalizedVertices_ = null; + } + return normalizedVerticesBuilder_; + } public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFieldsProto3(unknownFields); diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/BoundingPolyOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/BoundingPolyOrBuilder.java index 730347650d55..ddae3582c7f2 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/BoundingPolyOrBuilder.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/BoundingPolyOrBuilder.java @@ -50,4 +50,48 @@ public interface BoundingPolyOrBuilder extends */ com.google.cloud.vision.v1.VertexOrBuilder getVerticesOrBuilder( int index); + + /** + *
+   * The bounding polygon normalized vertices.
+   * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + java.util.List + getNormalizedVerticesList(); + /** + *
+   * The bounding polygon normalized vertices.
+   * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + com.google.cloud.vision.v1.NormalizedVertex getNormalizedVertices(int index); + /** + *
+   * The bounding polygon normalized vertices.
+   * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + int getNormalizedVerticesCount(); + /** + *
+   * The bounding polygon normalized vertices.
+   * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + java.util.List + getNormalizedVerticesOrBuilderList(); + /** + *
+   * The bounding polygon normalized vertices.
+   * 
+ * + * repeated .google.cloud.vision.v1.NormalizedVertex normalized_vertices = 2; + */ + com.google.cloud.vision.v1.NormalizedVertexOrBuilder getNormalizedVerticesOrBuilder( + int index); } diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KindExpression.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsDestination.java similarity index 51% rename from google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KindExpression.java rename to google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsDestination.java index e1dc7d6e0027..101cf4784e3e 100644 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/KindExpression.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsDestination.java @@ -1,26 +1,26 @@ // Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto +// source: google/cloud/vision/v1/image_annotator.proto -package com.google.privacy.dlp.v2beta1; +package com.google.cloud.vision.v1; /** *
- * A representation of a Datastore kind.
+ * The Google Cloud Storage location where the output will be written to.
  * 
* - * Protobuf type {@code google.privacy.dlp.v2beta1.KindExpression} + * Protobuf type {@code google.cloud.vision.v1.GcsDestination} */ -public final class KindExpression extends +public final class GcsDestination extends com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.KindExpression) - KindExpressionOrBuilder { + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.GcsDestination) + GcsDestinationOrBuilder { private static final long serialVersionUID = 0L; - // Use KindExpression.newBuilder() to construct. - private KindExpression(com.google.protobuf.GeneratedMessageV3.Builder builder) { + // Use GcsDestination.newBuilder() to construct. + private GcsDestination(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private KindExpression() { - name_ = ""; + private GcsDestination() { + uri_ = ""; } @java.lang.Override @@ -28,7 +28,7 @@ private KindExpression() { getUnknownFields() { return this.unknownFields; } - private KindExpression( + private GcsDestination( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { @@ -57,7 +57,7 @@ private KindExpression( case 10: { java.lang.String s = input.readStringRequireUtf8(); - name_ = s; + uri_ = s; break; } } @@ -74,52 +74,74 @@ private KindExpression( } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_KindExpression_descriptor; + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_GcsDestination_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_KindExpression_fieldAccessorTable + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_GcsDestination_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.KindExpression.class, com.google.privacy.dlp.v2beta1.KindExpression.Builder.class); + com.google.cloud.vision.v1.GcsDestination.class, com.google.cloud.vision.v1.GcsDestination.Builder.class); } - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; + public static final int URI_FIELD_NUMBER = 1; + private volatile java.lang.Object uri_; /** *
-   * The name of the kind.
+   * Google Cloud Storage URI where the results will be stored. Results will
+   * be in JSON format and preceded by its corresponding input URI. This field
+   * can either represent a single file, or a prefix for multiple outputs.
+   * Prefixes must end in a `/`.
+   * Examples:
+   * *    File: gs://bucket-name/filename.json
+   * *    Prefix: gs://bucket-name/prefix/here/
+   * *    File: gs://bucket-name/prefix/here
+   * If multiple outputs, each response is still AnnotateFileResponse, each of
+   * which contains some subset of the full list of AnnotateImageResponse.
+   * Multiple outputs can happen if, for example, the output JSON is too large
+   * and overflows into multiple sharded files.
    * 
* - * string name = 1; + * string uri = 1; */ - public java.lang.String getName() { - java.lang.Object ref = name_; + public java.lang.String getUri() { + java.lang.Object ref = uri_; 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; + uri_ = s; return s; } } /** *
-   * The name of the kind.
+   * Google Cloud Storage URI where the results will be stored. Results will
+   * be in JSON format and preceded by its corresponding input URI. This field
+   * can either represent a single file, or a prefix for multiple outputs.
+   * Prefixes must end in a `/`.
+   * Examples:
+   * *    File: gs://bucket-name/filename.json
+   * *    Prefix: gs://bucket-name/prefix/here/
+   * *    File: gs://bucket-name/prefix/here
+   * If multiple outputs, each response is still AnnotateFileResponse, each of
+   * which contains some subset of the full list of AnnotateImageResponse.
+   * Multiple outputs can happen if, for example, the output JSON is too large
+   * and overflows into multiple sharded files.
    * 
* - * string name = 1; + * string uri = 1; */ public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; + getUriBytes() { + java.lang.Object ref = uri_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); - name_ = b; + uri_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; @@ -138,8 +160,8 @@ public final boolean isInitialized() { public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + if (!getUriBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, uri_); } unknownFields.writeTo(output); } @@ -149,8 +171,8 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - if (!getNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + if (!getUriBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, uri_); } size += unknownFields.getSerializedSize(); memoizedSize = size; @@ -162,14 +184,14 @@ public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } - if (!(obj instanceof com.google.privacy.dlp.v2beta1.KindExpression)) { + if (!(obj instanceof com.google.cloud.vision.v1.GcsDestination)) { return super.equals(obj); } - com.google.privacy.dlp.v2beta1.KindExpression other = (com.google.privacy.dlp.v2beta1.KindExpression) obj; + com.google.cloud.vision.v1.GcsDestination other = (com.google.cloud.vision.v1.GcsDestination) obj; boolean result = true; - result = result && getName() - .equals(other.getName()); + result = result && getUri() + .equals(other.getUri()); result = result && unknownFields.equals(other.unknownFields); return result; } @@ -181,76 +203,76 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + URI_FIELD_NUMBER; + hash = (53 * hash) + getUri().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } - public static com.google.privacy.dlp.v2beta1.KindExpression parseFrom( + public static com.google.cloud.vision.v1.GcsDestination parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.KindExpression parseFrom( + public static com.google.cloud.vision.v1.GcsDestination parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.privacy.dlp.v2beta1.KindExpression parseFrom( + public static com.google.cloud.vision.v1.GcsDestination parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.KindExpression parseFrom( + public static com.google.cloud.vision.v1.GcsDestination 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.privacy.dlp.v2beta1.KindExpression parseFrom(byte[] data) + public static com.google.cloud.vision.v1.GcsDestination parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.KindExpression parseFrom( + public static com.google.cloud.vision.v1.GcsDestination parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.privacy.dlp.v2beta1.KindExpression parseFrom(java.io.InputStream input) + public static com.google.cloud.vision.v1.GcsDestination parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.KindExpression parseFrom( + public static com.google.cloud.vision.v1.GcsDestination 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.privacy.dlp.v2beta1.KindExpression parseDelimitedFrom(java.io.InputStream input) + public static com.google.cloud.vision.v1.GcsDestination parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.KindExpression parseDelimitedFrom( + public static com.google.cloud.vision.v1.GcsDestination 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.privacy.dlp.v2beta1.KindExpression parseFrom( + public static com.google.cloud.vision.v1.GcsDestination parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.KindExpression parseFrom( + public static com.google.cloud.vision.v1.GcsDestination parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { @@ -262,7 +284,7 @@ public static com.google.privacy.dlp.v2beta1.KindExpression parseFrom( public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.KindExpression prototype) { + public static Builder newBuilder(com.google.cloud.vision.v1.GcsDestination prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { @@ -278,28 +300,28 @@ protected Builder newBuilderForType( } /** *
-   * A representation of a Datastore kind.
+   * The Google Cloud Storage location where the output will be written to.
    * 
* - * Protobuf type {@code google.privacy.dlp.v2beta1.KindExpression} + * Protobuf type {@code google.cloud.vision.v1.GcsDestination} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.KindExpression) - com.google.privacy.dlp.v2beta1.KindExpressionOrBuilder { + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.GcsDestination) + com.google.cloud.vision.v1.GcsDestinationOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_KindExpression_descriptor; + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_GcsDestination_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_KindExpression_fieldAccessorTable + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_GcsDestination_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.KindExpression.class, com.google.privacy.dlp.v2beta1.KindExpression.Builder.class); + com.google.cloud.vision.v1.GcsDestination.class, com.google.cloud.vision.v1.GcsDestination.Builder.class); } - // Construct using com.google.privacy.dlp.v2beta1.KindExpression.newBuilder() + // Construct using com.google.cloud.vision.v1.GcsDestination.newBuilder() private Builder() { maybeForceBuilderInitialization(); } @@ -316,31 +338,31 @@ private void maybeForceBuilderInitialization() { } public Builder clear() { super.clear(); - name_ = ""; + uri_ = ""; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_KindExpression_descriptor; + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_GcsDestination_descriptor; } - public com.google.privacy.dlp.v2beta1.KindExpression getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.KindExpression.getDefaultInstance(); + public com.google.cloud.vision.v1.GcsDestination getDefaultInstanceForType() { + return com.google.cloud.vision.v1.GcsDestination.getDefaultInstance(); } - public com.google.privacy.dlp.v2beta1.KindExpression build() { - com.google.privacy.dlp.v2beta1.KindExpression result = buildPartial(); + public com.google.cloud.vision.v1.GcsDestination build() { + com.google.cloud.vision.v1.GcsDestination result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - public com.google.privacy.dlp.v2beta1.KindExpression buildPartial() { - com.google.privacy.dlp.v2beta1.KindExpression result = new com.google.privacy.dlp.v2beta1.KindExpression(this); - result.name_ = name_; + public com.google.cloud.vision.v1.GcsDestination buildPartial() { + com.google.cloud.vision.v1.GcsDestination result = new com.google.cloud.vision.v1.GcsDestination(this); + result.uri_ = uri_; onBuilt(); return result; } @@ -372,18 +394,18 @@ public Builder addRepeatedField( return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.KindExpression) { - return mergeFrom((com.google.privacy.dlp.v2beta1.KindExpression)other); + if (other instanceof com.google.cloud.vision.v1.GcsDestination) { + return mergeFrom((com.google.cloud.vision.v1.GcsDestination)other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.KindExpression other) { - if (other == com.google.privacy.dlp.v2beta1.KindExpression.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; + public Builder mergeFrom(com.google.cloud.vision.v1.GcsDestination other) { + if (other == com.google.cloud.vision.v1.GcsDestination.getDefaultInstance()) return this; + if (!other.getUri().isEmpty()) { + uri_ = other.uri_; onChanged(); } this.mergeUnknownFields(other.unknownFields); @@ -399,11 +421,11 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.privacy.dlp.v2beta1.KindExpression parsedMessage = null; + com.google.cloud.vision.v1.GcsDestination parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.KindExpression) e.getUnfinishedMessage(); + parsedMessage = (com.google.cloud.vision.v1.GcsDestination) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -413,21 +435,32 @@ public Builder mergeFrom( return this; } - private java.lang.Object name_ = ""; + private java.lang.Object uri_ = ""; /** *
-     * The name of the kind.
+     * Google Cloud Storage URI where the results will be stored. Results will
+     * be in JSON format and preceded by its corresponding input URI. This field
+     * can either represent a single file, or a prefix for multiple outputs.
+     * Prefixes must end in a `/`.
+     * Examples:
+     * *    File: gs://bucket-name/filename.json
+     * *    Prefix: gs://bucket-name/prefix/here/
+     * *    File: gs://bucket-name/prefix/here
+     * If multiple outputs, each response is still AnnotateFileResponse, each of
+     * which contains some subset of the full list of AnnotateImageResponse.
+     * Multiple outputs can happen if, for example, the output JSON is too large
+     * and overflows into multiple sharded files.
      * 
* - * string name = 1; + * string uri = 1; */ - public java.lang.String getName() { - java.lang.Object ref = name_; + public java.lang.String getUri() { + java.lang.Object ref = uri_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); - name_ = s; + uri_ = s; return s; } else { return (java.lang.String) ref; @@ -435,19 +468,30 @@ public java.lang.String getName() { } /** *
-     * The name of the kind.
+     * Google Cloud Storage URI where the results will be stored. Results will
+     * be in JSON format and preceded by its corresponding input URI. This field
+     * can either represent a single file, or a prefix for multiple outputs.
+     * Prefixes must end in a `/`.
+     * Examples:
+     * *    File: gs://bucket-name/filename.json
+     * *    Prefix: gs://bucket-name/prefix/here/
+     * *    File: gs://bucket-name/prefix/here
+     * If multiple outputs, each response is still AnnotateFileResponse, each of
+     * which contains some subset of the full list of AnnotateImageResponse.
+     * Multiple outputs can happen if, for example, the output JSON is too large
+     * and overflows into multiple sharded files.
      * 
* - * string name = 1; + * string uri = 1; */ public com.google.protobuf.ByteString - getNameBytes() { - java.lang.Object ref = name_; + getUriBytes() { + java.lang.Object ref = uri_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); - name_ = b; + uri_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; @@ -455,49 +499,82 @@ public java.lang.String getName() { } /** *
-     * The name of the kind.
+     * Google Cloud Storage URI where the results will be stored. Results will
+     * be in JSON format and preceded by its corresponding input URI. This field
+     * can either represent a single file, or a prefix for multiple outputs.
+     * Prefixes must end in a `/`.
+     * Examples:
+     * *    File: gs://bucket-name/filename.json
+     * *    Prefix: gs://bucket-name/prefix/here/
+     * *    File: gs://bucket-name/prefix/here
+     * If multiple outputs, each response is still AnnotateFileResponse, each of
+     * which contains some subset of the full list of AnnotateImageResponse.
+     * Multiple outputs can happen if, for example, the output JSON is too large
+     * and overflows into multiple sharded files.
      * 
* - * string name = 1; + * string uri = 1; */ - public Builder setName( + public Builder setUri( java.lang.String value) { if (value == null) { throw new NullPointerException(); } - name_ = value; + uri_ = value; onChanged(); return this; } /** *
-     * The name of the kind.
+     * Google Cloud Storage URI where the results will be stored. Results will
+     * be in JSON format and preceded by its corresponding input URI. This field
+     * can either represent a single file, or a prefix for multiple outputs.
+     * Prefixes must end in a `/`.
+     * Examples:
+     * *    File: gs://bucket-name/filename.json
+     * *    Prefix: gs://bucket-name/prefix/here/
+     * *    File: gs://bucket-name/prefix/here
+     * If multiple outputs, each response is still AnnotateFileResponse, each of
+     * which contains some subset of the full list of AnnotateImageResponse.
+     * Multiple outputs can happen if, for example, the output JSON is too large
+     * and overflows into multiple sharded files.
      * 
* - * string name = 1; + * string uri = 1; */ - public Builder clearName() { + public Builder clearUri() { - name_ = getDefaultInstance().getName(); + uri_ = getDefaultInstance().getUri(); onChanged(); return this; } /** *
-     * The name of the kind.
+     * Google Cloud Storage URI where the results will be stored. Results will
+     * be in JSON format and preceded by its corresponding input URI. This field
+     * can either represent a single file, or a prefix for multiple outputs.
+     * Prefixes must end in a `/`.
+     * Examples:
+     * *    File: gs://bucket-name/filename.json
+     * *    Prefix: gs://bucket-name/prefix/here/
+     * *    File: gs://bucket-name/prefix/here
+     * If multiple outputs, each response is still AnnotateFileResponse, each of
+     * which contains some subset of the full list of AnnotateImageResponse.
+     * Multiple outputs can happen if, for example, the output JSON is too large
+     * and overflows into multiple sharded files.
      * 
* - * string name = 1; + * string uri = 1; */ - public Builder setNameBytes( + public Builder setUriBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - name_ = value; + uri_ = value; onChanged(); return this; } @@ -512,39 +589,39 @@ public final Builder mergeUnknownFields( } - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.KindExpression) + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.GcsDestination) } - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.KindExpression) - private static final com.google.privacy.dlp.v2beta1.KindExpression DEFAULT_INSTANCE; + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.GcsDestination) + private static final com.google.cloud.vision.v1.GcsDestination DEFAULT_INSTANCE; static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.KindExpression(); + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.GcsDestination(); } - public static com.google.privacy.dlp.v2beta1.KindExpression getDefaultInstance() { + public static com.google.cloud.vision.v1.GcsDestination getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public KindExpression parsePartialFrom( + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public GcsDestination parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new KindExpression(input, extensionRegistry); + return new GcsDestination(input, extensionRegistry); } }; - public static com.google.protobuf.Parser parser() { + public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override - public com.google.protobuf.Parser getParserForType() { + public com.google.protobuf.Parser getParserForType() { return PARSER; } - public com.google.privacy.dlp.v2beta1.KindExpression getDefaultInstanceForType() { + public com.google.cloud.vision.v1.GcsDestination getDefaultInstanceForType() { return DEFAULT_INSTANCE; } diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsDestinationOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsDestinationOrBuilder.java new file mode 100644 index 000000000000..50c3e1bc5053 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsDestinationOrBuilder.java @@ -0,0 +1,49 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface GcsDestinationOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.GcsDestination) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * Google Cloud Storage URI where the results will be stored. Results will
+   * be in JSON format and preceded by its corresponding input URI. This field
+   * can either represent a single file, or a prefix for multiple outputs.
+   * Prefixes must end in a `/`.
+   * Examples:
+   * *    File: gs://bucket-name/filename.json
+   * *    Prefix: gs://bucket-name/prefix/here/
+   * *    File: gs://bucket-name/prefix/here
+   * If multiple outputs, each response is still AnnotateFileResponse, each of
+   * which contains some subset of the full list of AnnotateImageResponse.
+   * Multiple outputs can happen if, for example, the output JSON is too large
+   * and overflows into multiple sharded files.
+   * 
+ * + * string uri = 1; + */ + java.lang.String getUri(); + /** + *
+   * Google Cloud Storage URI where the results will be stored. Results will
+   * be in JSON format and preceded by its corresponding input URI. This field
+   * can either represent a single file, or a prefix for multiple outputs.
+   * Prefixes must end in a `/`.
+   * Examples:
+   * *    File: gs://bucket-name/filename.json
+   * *    Prefix: gs://bucket-name/prefix/here/
+   * *    File: gs://bucket-name/prefix/here
+   * If multiple outputs, each response is still AnnotateFileResponse, each of
+   * which contains some subset of the full list of AnnotateImageResponse.
+   * Multiple outputs can happen if, for example, the output JSON is too large
+   * and overflows into multiple sharded files.
+   * 
+ * + * string uri = 1; + */ + com.google.protobuf.ByteString + getUriBytes(); +} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldId.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsSource.java similarity index 63% rename from google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldId.java rename to google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsSource.java index d1b50418924c..58f68067640e 100644 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/FieldId.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsSource.java @@ -1,26 +1,26 @@ // Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/storage.proto +// source: google/cloud/vision/v1/image_annotator.proto -package com.google.privacy.dlp.v2beta1; +package com.google.cloud.vision.v1; /** *
- * General identifier of a data field in a storage service.
+ * The Google Cloud Storage location where the input will be read from.
  * 
* - * Protobuf type {@code google.privacy.dlp.v2beta1.FieldId} + * Protobuf type {@code google.cloud.vision.v1.GcsSource} */ -public final class FieldId extends +public final class GcsSource extends com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.FieldId) - FieldIdOrBuilder { + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.GcsSource) + GcsSourceOrBuilder { private static final long serialVersionUID = 0L; - // Use FieldId.newBuilder() to construct. - private FieldId(com.google.protobuf.GeneratedMessageV3.Builder builder) { + // Use GcsSource.newBuilder() to construct. + private GcsSource(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private FieldId() { - columnName_ = ""; + private GcsSource() { + uri_ = ""; } @java.lang.Override @@ -28,7 +28,7 @@ private FieldId() { getUnknownFields() { return this.unknownFields; } - private FieldId( + private GcsSource( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { @@ -57,7 +57,7 @@ private FieldId( case 10: { java.lang.String s = input.readStringRequireUtf8(); - columnName_ = s; + uri_ = s; break; } } @@ -74,52 +74,54 @@ private FieldId( } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_FieldId_descriptor; + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_GcsSource_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_FieldId_fieldAccessorTable + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_GcsSource_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.FieldId.class, com.google.privacy.dlp.v2beta1.FieldId.Builder.class); + com.google.cloud.vision.v1.GcsSource.class, com.google.cloud.vision.v1.GcsSource.Builder.class); } - public static final int COLUMN_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object columnName_; + public static final int URI_FIELD_NUMBER = 1; + private volatile java.lang.Object uri_; /** *
-   * Name describing the field.
+   * Google Cloud Storage URI for the input file. This must only be a
+   * Google Cloud Storage object. Wildcards are not currently supported.
    * 
* - * string column_name = 1; + * string uri = 1; */ - public java.lang.String getColumnName() { - java.lang.Object ref = columnName_; + public java.lang.String getUri() { + java.lang.Object ref = uri_; 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(); - columnName_ = s; + uri_ = s; return s; } } /** *
-   * Name describing the field.
+   * Google Cloud Storage URI for the input file. This must only be a
+   * Google Cloud Storage object. Wildcards are not currently supported.
    * 
* - * string column_name = 1; + * string uri = 1; */ public com.google.protobuf.ByteString - getColumnNameBytes() { - java.lang.Object ref = columnName_; + getUriBytes() { + java.lang.Object ref = uri_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); - columnName_ = b; + uri_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; @@ -138,8 +140,8 @@ public final boolean isInitialized() { public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getColumnNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, columnName_); + if (!getUriBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, uri_); } unknownFields.writeTo(output); } @@ -149,8 +151,8 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - if (!getColumnNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, columnName_); + if (!getUriBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, uri_); } size += unknownFields.getSerializedSize(); memoizedSize = size; @@ -162,14 +164,14 @@ public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } - if (!(obj instanceof com.google.privacy.dlp.v2beta1.FieldId)) { + if (!(obj instanceof com.google.cloud.vision.v1.GcsSource)) { return super.equals(obj); } - com.google.privacy.dlp.v2beta1.FieldId other = (com.google.privacy.dlp.v2beta1.FieldId) obj; + com.google.cloud.vision.v1.GcsSource other = (com.google.cloud.vision.v1.GcsSource) obj; boolean result = true; - result = result && getColumnName() - .equals(other.getColumnName()); + result = result && getUri() + .equals(other.getUri()); result = result && unknownFields.equals(other.unknownFields); return result; } @@ -181,76 +183,76 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + COLUMN_NAME_FIELD_NUMBER; - hash = (53 * hash) + getColumnName().hashCode(); + hash = (37 * hash) + URI_FIELD_NUMBER; + hash = (53 * hash) + getUri().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } - public static com.google.privacy.dlp.v2beta1.FieldId parseFrom( + public static com.google.cloud.vision.v1.GcsSource parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.FieldId parseFrom( + public static com.google.cloud.vision.v1.GcsSource parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.privacy.dlp.v2beta1.FieldId parseFrom( + public static com.google.cloud.vision.v1.GcsSource parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.FieldId parseFrom( + public static com.google.cloud.vision.v1.GcsSource 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.privacy.dlp.v2beta1.FieldId parseFrom(byte[] data) + public static com.google.cloud.vision.v1.GcsSource parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.FieldId parseFrom( + public static com.google.cloud.vision.v1.GcsSource parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.privacy.dlp.v2beta1.FieldId parseFrom(java.io.InputStream input) + public static com.google.cloud.vision.v1.GcsSource parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.FieldId parseFrom( + public static com.google.cloud.vision.v1.GcsSource 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.privacy.dlp.v2beta1.FieldId parseDelimitedFrom(java.io.InputStream input) + public static com.google.cloud.vision.v1.GcsSource parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.FieldId parseDelimitedFrom( + public static com.google.cloud.vision.v1.GcsSource 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.privacy.dlp.v2beta1.FieldId parseFrom( + public static com.google.cloud.vision.v1.GcsSource parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.FieldId parseFrom( + public static com.google.cloud.vision.v1.GcsSource parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { @@ -262,7 +264,7 @@ public static com.google.privacy.dlp.v2beta1.FieldId parseFrom( public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.FieldId prototype) { + public static Builder newBuilder(com.google.cloud.vision.v1.GcsSource prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { @@ -278,28 +280,28 @@ protected Builder newBuilderForType( } /** *
-   * General identifier of a data field in a storage service.
+   * The Google Cloud Storage location where the input will be read from.
    * 
* - * Protobuf type {@code google.privacy.dlp.v2beta1.FieldId} + * Protobuf type {@code google.cloud.vision.v1.GcsSource} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.FieldId) - com.google.privacy.dlp.v2beta1.FieldIdOrBuilder { + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.GcsSource) + com.google.cloud.vision.v1.GcsSourceOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_FieldId_descriptor; + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_GcsSource_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_FieldId_fieldAccessorTable + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_GcsSource_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.FieldId.class, com.google.privacy.dlp.v2beta1.FieldId.Builder.class); + com.google.cloud.vision.v1.GcsSource.class, com.google.cloud.vision.v1.GcsSource.Builder.class); } - // Construct using com.google.privacy.dlp.v2beta1.FieldId.newBuilder() + // Construct using com.google.cloud.vision.v1.GcsSource.newBuilder() private Builder() { maybeForceBuilderInitialization(); } @@ -316,31 +318,31 @@ private void maybeForceBuilderInitialization() { } public Builder clear() { super.clear(); - columnName_ = ""; + uri_ = ""; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_FieldId_descriptor; + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_GcsSource_descriptor; } - public com.google.privacy.dlp.v2beta1.FieldId getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance(); + public com.google.cloud.vision.v1.GcsSource getDefaultInstanceForType() { + return com.google.cloud.vision.v1.GcsSource.getDefaultInstance(); } - public com.google.privacy.dlp.v2beta1.FieldId build() { - com.google.privacy.dlp.v2beta1.FieldId result = buildPartial(); + public com.google.cloud.vision.v1.GcsSource build() { + com.google.cloud.vision.v1.GcsSource result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - public com.google.privacy.dlp.v2beta1.FieldId buildPartial() { - com.google.privacy.dlp.v2beta1.FieldId result = new com.google.privacy.dlp.v2beta1.FieldId(this); - result.columnName_ = columnName_; + public com.google.cloud.vision.v1.GcsSource buildPartial() { + com.google.cloud.vision.v1.GcsSource result = new com.google.cloud.vision.v1.GcsSource(this); + result.uri_ = uri_; onBuilt(); return result; } @@ -372,18 +374,18 @@ public Builder addRepeatedField( return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.FieldId) { - return mergeFrom((com.google.privacy.dlp.v2beta1.FieldId)other); + if (other instanceof com.google.cloud.vision.v1.GcsSource) { + return mergeFrom((com.google.cloud.vision.v1.GcsSource)other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.FieldId other) { - if (other == com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance()) return this; - if (!other.getColumnName().isEmpty()) { - columnName_ = other.columnName_; + public Builder mergeFrom(com.google.cloud.vision.v1.GcsSource other) { + if (other == com.google.cloud.vision.v1.GcsSource.getDefaultInstance()) return this; + if (!other.getUri().isEmpty()) { + uri_ = other.uri_; onChanged(); } this.mergeUnknownFields(other.unknownFields); @@ -399,11 +401,11 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.privacy.dlp.v2beta1.FieldId parsedMessage = null; + com.google.cloud.vision.v1.GcsSource parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.FieldId) e.getUnfinishedMessage(); + parsedMessage = (com.google.cloud.vision.v1.GcsSource) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -413,21 +415,22 @@ public Builder mergeFrom( return this; } - private java.lang.Object columnName_ = ""; + private java.lang.Object uri_ = ""; /** *
-     * Name describing the field.
+     * Google Cloud Storage URI for the input file. This must only be a
+     * Google Cloud Storage object. Wildcards are not currently supported.
      * 
* - * string column_name = 1; + * string uri = 1; */ - public java.lang.String getColumnName() { - java.lang.Object ref = columnName_; + public java.lang.String getUri() { + java.lang.Object ref = uri_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); - columnName_ = s; + uri_ = s; return s; } else { return (java.lang.String) ref; @@ -435,19 +438,20 @@ public java.lang.String getColumnName() { } /** *
-     * Name describing the field.
+     * Google Cloud Storage URI for the input file. This must only be a
+     * Google Cloud Storage object. Wildcards are not currently supported.
      * 
* - * string column_name = 1; + * string uri = 1; */ public com.google.protobuf.ByteString - getColumnNameBytes() { - java.lang.Object ref = columnName_; + getUriBytes() { + java.lang.Object ref = uri_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); - columnName_ = b; + uri_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; @@ -455,49 +459,52 @@ public java.lang.String getColumnName() { } /** *
-     * Name describing the field.
+     * Google Cloud Storage URI for the input file. This must only be a
+     * Google Cloud Storage object. Wildcards are not currently supported.
      * 
* - * string column_name = 1; + * string uri = 1; */ - public Builder setColumnName( + public Builder setUri( java.lang.String value) { if (value == null) { throw new NullPointerException(); } - columnName_ = value; + uri_ = value; onChanged(); return this; } /** *
-     * Name describing the field.
+     * Google Cloud Storage URI for the input file. This must only be a
+     * Google Cloud Storage object. Wildcards are not currently supported.
      * 
* - * string column_name = 1; + * string uri = 1; */ - public Builder clearColumnName() { + public Builder clearUri() { - columnName_ = getDefaultInstance().getColumnName(); + uri_ = getDefaultInstance().getUri(); onChanged(); return this; } /** *
-     * Name describing the field.
+     * Google Cloud Storage URI for the input file. This must only be a
+     * Google Cloud Storage object. Wildcards are not currently supported.
      * 
* - * string column_name = 1; + * string uri = 1; */ - public Builder setColumnNameBytes( + public Builder setUriBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - columnName_ = value; + uri_ = value; onChanged(); return this; } @@ -512,39 +519,39 @@ public final Builder mergeUnknownFields( } - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.FieldId) + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.GcsSource) } - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.FieldId) - private static final com.google.privacy.dlp.v2beta1.FieldId DEFAULT_INSTANCE; + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.GcsSource) + private static final com.google.cloud.vision.v1.GcsSource DEFAULT_INSTANCE; static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.FieldId(); + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.GcsSource(); } - public static com.google.privacy.dlp.v2beta1.FieldId getDefaultInstance() { + public static com.google.cloud.vision.v1.GcsSource getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public FieldId parsePartialFrom( + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public GcsSource parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new FieldId(input, extensionRegistry); + return new GcsSource(input, extensionRegistry); } }; - public static com.google.protobuf.Parser parser() { + public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override - public com.google.protobuf.Parser getParserForType() { + public com.google.protobuf.Parser getParserForType() { return PARSER; } - public com.google.privacy.dlp.v2beta1.FieldId getDefaultInstanceForType() { + public com.google.cloud.vision.v1.GcsSource getDefaultInstanceForType() { return DEFAULT_INSTANCE; } diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsSourceOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsSourceOrBuilder.java new file mode 100644 index 000000000000..cf50ba9c6341 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GcsSourceOrBuilder.java @@ -0,0 +1,29 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface GcsSourceOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.GcsSource) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * Google Cloud Storage URI for the input file. This must only be a
+   * Google Cloud Storage object. Wildcards are not currently supported.
+   * 
+ * + * string uri = 1; + */ + java.lang.String getUri(); + /** + *
+   * Google Cloud Storage URI for the input file. This must only be a
+   * Google Cloud Storage object. Wildcards are not currently supported.
+   * 
+ * + * string uri = 1; + */ + com.google.protobuf.ByteString + getUriBytes(); +} diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GeometryProto.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GeometryProto.java index 2a53c2d94114..106c89d581aa 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GeometryProto.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/GeometryProto.java @@ -19,6 +19,11 @@ public static void registerAllExtensions( static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_vision_v1_Vertex_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_NormalizedVertex_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_NormalizedVertex_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_vision_v1_BoundingPoly_descriptor; static final @@ -40,13 +45,15 @@ public static void registerAllExtensions( java.lang.String[] descriptorData = { "\n%google/cloud/vision/v1/geometry.proto\022" + "\026google.cloud.vision.v1\"\036\n\006Vertex\022\t\n\001x\030\001" + - " \001(\005\022\t\n\001y\030\002 \001(\005\"@\n\014BoundingPoly\0220\n\010verti" + - "ces\030\001 \003(\0132\036.google.cloud.vision.v1.Verte" + - "x\"+\n\010Position\022\t\n\001x\030\001 \001(\002\022\t\n\001y\030\002 \001(\002\022\t\n\001z" + - "\030\003 \001(\002Bn\n\032com.google.cloud.vision.v1B\rGe" + - "ometryProtoP\001Z - * Record key for a finding in a Cloud Storage file. + * If an image was produced from a file (e.g. a PDF), this message gives + * information about the source of that image. * * - * Protobuf type {@code google.privacy.dlp.v2beta1.CloudStorageKey} + * Protobuf type {@code google.cloud.vision.v1.ImageAnnotationContext} */ -public final class CloudStorageKey extends +public final class ImageAnnotationContext extends com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.CloudStorageKey) - CloudStorageKeyOrBuilder { + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.ImageAnnotationContext) + ImageAnnotationContextOrBuilder { private static final long serialVersionUID = 0L; - // Use CloudStorageKey.newBuilder() to construct. - private CloudStorageKey(com.google.protobuf.GeneratedMessageV3.Builder builder) { + // Use ImageAnnotationContext.newBuilder() to construct. + private ImageAnnotationContext(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private CloudStorageKey() { - filePath_ = ""; - startOffset_ = 0L; + private ImageAnnotationContext() { + uri_ = ""; + pageNumber_ = 0; } @java.lang.Override @@ -29,7 +30,7 @@ private CloudStorageKey() { getUnknownFields() { return this.unknownFields; } - private CloudStorageKey( + private ImageAnnotationContext( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { @@ -58,12 +59,12 @@ private CloudStorageKey( case 10: { java.lang.String s = input.readStringRequireUtf8(); - filePath_ = s; + uri_ = s; break; } case 16: { - startOffset_ = input.readInt64(); + pageNumber_ = input.readInt32(); break; } } @@ -80,69 +81,70 @@ private CloudStorageKey( } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageKey_descriptor; + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_ImageAnnotationContext_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageKey_fieldAccessorTable + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_ImageAnnotationContext_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CloudStorageKey.class, com.google.privacy.dlp.v2beta1.CloudStorageKey.Builder.class); + com.google.cloud.vision.v1.ImageAnnotationContext.class, com.google.cloud.vision.v1.ImageAnnotationContext.Builder.class); } - public static final int FILE_PATH_FIELD_NUMBER = 1; - private volatile java.lang.Object filePath_; + public static final int URI_FIELD_NUMBER = 1; + private volatile java.lang.Object uri_; /** *
-   * Path to the file.
+   * The URI of the file used to produce the image.
    * 
* - * string file_path = 1; + * string uri = 1; */ - public java.lang.String getFilePath() { - java.lang.Object ref = filePath_; + public java.lang.String getUri() { + java.lang.Object ref = uri_; 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(); - filePath_ = s; + uri_ = s; return s; } } /** *
-   * Path to the file.
+   * The URI of the file used to produce the image.
    * 
* - * string file_path = 1; + * string uri = 1; */ public com.google.protobuf.ByteString - getFilePathBytes() { - java.lang.Object ref = filePath_; + getUriBytes() { + java.lang.Object ref = uri_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); - filePath_ = b; + uri_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } - public static final int START_OFFSET_FIELD_NUMBER = 2; - private long startOffset_; + public static final int PAGE_NUMBER_FIELD_NUMBER = 2; + private int pageNumber_; /** *
-   * Byte offset of the referenced data in the file.
+   * If the file was a PDF or TIFF, this field gives the page number within
+   * the file used to produce the image.
    * 
* - * int64 start_offset = 2; + * int32 page_number = 2; */ - public long getStartOffset() { - return startOffset_; + public int getPageNumber() { + return pageNumber_; } private byte memoizedIsInitialized = -1; @@ -157,11 +159,11 @@ public final boolean isInitialized() { public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!getFilePathBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, filePath_); + if (!getUriBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, uri_); } - if (startOffset_ != 0L) { - output.writeInt64(2, startOffset_); + if (pageNumber_ != 0) { + output.writeInt32(2, pageNumber_); } unknownFields.writeTo(output); } @@ -171,12 +173,12 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - if (!getFilePathBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, filePath_); + if (!getUriBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, uri_); } - if (startOffset_ != 0L) { + if (pageNumber_ != 0) { size += com.google.protobuf.CodedOutputStream - .computeInt64Size(2, startOffset_); + .computeInt32Size(2, pageNumber_); } size += unknownFields.getSerializedSize(); memoizedSize = size; @@ -188,16 +190,16 @@ public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } - if (!(obj instanceof com.google.privacy.dlp.v2beta1.CloudStorageKey)) { + if (!(obj instanceof com.google.cloud.vision.v1.ImageAnnotationContext)) { return super.equals(obj); } - com.google.privacy.dlp.v2beta1.CloudStorageKey other = (com.google.privacy.dlp.v2beta1.CloudStorageKey) obj; + com.google.cloud.vision.v1.ImageAnnotationContext other = (com.google.cloud.vision.v1.ImageAnnotationContext) obj; boolean result = true; - result = result && getFilePath() - .equals(other.getFilePath()); - result = result && (getStartOffset() - == other.getStartOffset()); + result = result && getUri() + .equals(other.getUri()); + result = result && (getPageNumber() + == other.getPageNumber()); result = result && unknownFields.equals(other.unknownFields); return result; } @@ -209,79 +211,78 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + FILE_PATH_FIELD_NUMBER; - hash = (53 * hash) + getFilePath().hashCode(); - hash = (37 * hash) + START_OFFSET_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getStartOffset()); + hash = (37 * hash) + URI_FIELD_NUMBER; + hash = (53 * hash) + getUri().hashCode(); + hash = (37 * hash) + PAGE_NUMBER_FIELD_NUMBER; + hash = (53 * hash) + getPageNumber(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } - public static com.google.privacy.dlp.v2beta1.CloudStorageKey parseFrom( + public static com.google.cloud.vision.v1.ImageAnnotationContext parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.CloudStorageKey parseFrom( + public static com.google.cloud.vision.v1.ImageAnnotationContext parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.privacy.dlp.v2beta1.CloudStorageKey parseFrom( + public static com.google.cloud.vision.v1.ImageAnnotationContext parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.CloudStorageKey parseFrom( + public static com.google.cloud.vision.v1.ImageAnnotationContext 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.privacy.dlp.v2beta1.CloudStorageKey parseFrom(byte[] data) + public static com.google.cloud.vision.v1.ImageAnnotationContext parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.CloudStorageKey parseFrom( + public static com.google.cloud.vision.v1.ImageAnnotationContext parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.privacy.dlp.v2beta1.CloudStorageKey parseFrom(java.io.InputStream input) + public static com.google.cloud.vision.v1.ImageAnnotationContext parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.CloudStorageKey parseFrom( + public static com.google.cloud.vision.v1.ImageAnnotationContext 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.privacy.dlp.v2beta1.CloudStorageKey parseDelimitedFrom(java.io.InputStream input) + public static com.google.cloud.vision.v1.ImageAnnotationContext parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.CloudStorageKey parseDelimitedFrom( + public static com.google.cloud.vision.v1.ImageAnnotationContext 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.privacy.dlp.v2beta1.CloudStorageKey parseFrom( + public static com.google.cloud.vision.v1.ImageAnnotationContext parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.CloudStorageKey parseFrom( + public static com.google.cloud.vision.v1.ImageAnnotationContext parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { @@ -293,7 +294,7 @@ public static com.google.privacy.dlp.v2beta1.CloudStorageKey parseFrom( public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.CloudStorageKey prototype) { + public static Builder newBuilder(com.google.cloud.vision.v1.ImageAnnotationContext prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { @@ -309,28 +310,29 @@ protected Builder newBuilderForType( } /** *
-   * Record key for a finding in a Cloud Storage file.
+   * If an image was produced from a file (e.g. a PDF), this message gives
+   * information about the source of that image.
    * 
* - * Protobuf type {@code google.privacy.dlp.v2beta1.CloudStorageKey} + * Protobuf type {@code google.cloud.vision.v1.ImageAnnotationContext} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.CloudStorageKey) - com.google.privacy.dlp.v2beta1.CloudStorageKeyOrBuilder { + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.ImageAnnotationContext) + com.google.cloud.vision.v1.ImageAnnotationContextOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageKey_descriptor; + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_ImageAnnotationContext_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageKey_fieldAccessorTable + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_ImageAnnotationContext_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.CloudStorageKey.class, com.google.privacy.dlp.v2beta1.CloudStorageKey.Builder.class); + com.google.cloud.vision.v1.ImageAnnotationContext.class, com.google.cloud.vision.v1.ImageAnnotationContext.Builder.class); } - // Construct using com.google.privacy.dlp.v2beta1.CloudStorageKey.newBuilder() + // Construct using com.google.cloud.vision.v1.ImageAnnotationContext.newBuilder() private Builder() { maybeForceBuilderInitialization(); } @@ -347,34 +349,34 @@ private void maybeForceBuilderInitialization() { } public Builder clear() { super.clear(); - filePath_ = ""; + uri_ = ""; - startOffset_ = 0L; + pageNumber_ = 0; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpStorage.internal_static_google_privacy_dlp_v2beta1_CloudStorageKey_descriptor; + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_ImageAnnotationContext_descriptor; } - public com.google.privacy.dlp.v2beta1.CloudStorageKey getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.CloudStorageKey.getDefaultInstance(); + public com.google.cloud.vision.v1.ImageAnnotationContext getDefaultInstanceForType() { + return com.google.cloud.vision.v1.ImageAnnotationContext.getDefaultInstance(); } - public com.google.privacy.dlp.v2beta1.CloudStorageKey build() { - com.google.privacy.dlp.v2beta1.CloudStorageKey result = buildPartial(); + public com.google.cloud.vision.v1.ImageAnnotationContext build() { + com.google.cloud.vision.v1.ImageAnnotationContext result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - public com.google.privacy.dlp.v2beta1.CloudStorageKey buildPartial() { - com.google.privacy.dlp.v2beta1.CloudStorageKey result = new com.google.privacy.dlp.v2beta1.CloudStorageKey(this); - result.filePath_ = filePath_; - result.startOffset_ = startOffset_; + public com.google.cloud.vision.v1.ImageAnnotationContext buildPartial() { + com.google.cloud.vision.v1.ImageAnnotationContext result = new com.google.cloud.vision.v1.ImageAnnotationContext(this); + result.uri_ = uri_; + result.pageNumber_ = pageNumber_; onBuilt(); return result; } @@ -406,22 +408,22 @@ public Builder addRepeatedField( return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.CloudStorageKey) { - return mergeFrom((com.google.privacy.dlp.v2beta1.CloudStorageKey)other); + if (other instanceof com.google.cloud.vision.v1.ImageAnnotationContext) { + return mergeFrom((com.google.cloud.vision.v1.ImageAnnotationContext)other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.CloudStorageKey other) { - if (other == com.google.privacy.dlp.v2beta1.CloudStorageKey.getDefaultInstance()) return this; - if (!other.getFilePath().isEmpty()) { - filePath_ = other.filePath_; + public Builder mergeFrom(com.google.cloud.vision.v1.ImageAnnotationContext other) { + if (other == com.google.cloud.vision.v1.ImageAnnotationContext.getDefaultInstance()) return this; + if (!other.getUri().isEmpty()) { + uri_ = other.uri_; onChanged(); } - if (other.getStartOffset() != 0L) { - setStartOffset(other.getStartOffset()); + if (other.getPageNumber() != 0) { + setPageNumber(other.getPageNumber()); } this.mergeUnknownFields(other.unknownFields); onChanged(); @@ -436,11 +438,11 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.privacy.dlp.v2beta1.CloudStorageKey parsedMessage = null; + com.google.cloud.vision.v1.ImageAnnotationContext parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.CloudStorageKey) e.getUnfinishedMessage(); + parsedMessage = (com.google.cloud.vision.v1.ImageAnnotationContext) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -450,21 +452,21 @@ public Builder mergeFrom( return this; } - private java.lang.Object filePath_ = ""; + private java.lang.Object uri_ = ""; /** *
-     * Path to the file.
+     * The URI of the file used to produce the image.
      * 
* - * string file_path = 1; + * string uri = 1; */ - public java.lang.String getFilePath() { - java.lang.Object ref = filePath_; + public java.lang.String getUri() { + java.lang.Object ref = uri_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); - filePath_ = s; + uri_ = s; return s; } else { return (java.lang.String) ref; @@ -472,19 +474,19 @@ public java.lang.String getFilePath() { } /** *
-     * Path to the file.
+     * The URI of the file used to produce the image.
      * 
* - * string file_path = 1; + * string uri = 1; */ public com.google.protobuf.ByteString - getFilePathBytes() { - java.lang.Object ref = filePath_; + getUriBytes() { + java.lang.Object ref = uri_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); - filePath_ = b; + uri_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; @@ -492,87 +494,90 @@ public java.lang.String getFilePath() { } /** *
-     * Path to the file.
+     * The URI of the file used to produce the image.
      * 
* - * string file_path = 1; + * string uri = 1; */ - public Builder setFilePath( + public Builder setUri( java.lang.String value) { if (value == null) { throw new NullPointerException(); } - filePath_ = value; + uri_ = value; onChanged(); return this; } /** *
-     * Path to the file.
+     * The URI of the file used to produce the image.
      * 
* - * string file_path = 1; + * string uri = 1; */ - public Builder clearFilePath() { + public Builder clearUri() { - filePath_ = getDefaultInstance().getFilePath(); + uri_ = getDefaultInstance().getUri(); onChanged(); return this; } /** *
-     * Path to the file.
+     * The URI of the file used to produce the image.
      * 
* - * string file_path = 1; + * string uri = 1; */ - public Builder setFilePathBytes( + public Builder setUriBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); - filePath_ = value; + uri_ = value; onChanged(); return this; } - private long startOffset_ ; + private int pageNumber_ ; /** *
-     * Byte offset of the referenced data in the file.
+     * If the file was a PDF or TIFF, this field gives the page number within
+     * the file used to produce the image.
      * 
* - * int64 start_offset = 2; + * int32 page_number = 2; */ - public long getStartOffset() { - return startOffset_; + public int getPageNumber() { + return pageNumber_; } /** *
-     * Byte offset of the referenced data in the file.
+     * If the file was a PDF or TIFF, this field gives the page number within
+     * the file used to produce the image.
      * 
* - * int64 start_offset = 2; + * int32 page_number = 2; */ - public Builder setStartOffset(long value) { + public Builder setPageNumber(int value) { - startOffset_ = value; + pageNumber_ = value; onChanged(); return this; } /** *
-     * Byte offset of the referenced data in the file.
+     * If the file was a PDF or TIFF, this field gives the page number within
+     * the file used to produce the image.
      * 
* - * int64 start_offset = 2; + * int32 page_number = 2; */ - public Builder clearStartOffset() { + public Builder clearPageNumber() { - startOffset_ = 0L; + pageNumber_ = 0; onChanged(); return this; } @@ -587,39 +592,39 @@ public final Builder mergeUnknownFields( } - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.CloudStorageKey) + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.ImageAnnotationContext) } - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.CloudStorageKey) - private static final com.google.privacy.dlp.v2beta1.CloudStorageKey DEFAULT_INSTANCE; + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.ImageAnnotationContext) + private static final com.google.cloud.vision.v1.ImageAnnotationContext DEFAULT_INSTANCE; static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.CloudStorageKey(); + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.ImageAnnotationContext(); } - public static com.google.privacy.dlp.v2beta1.CloudStorageKey getDefaultInstance() { + public static com.google.cloud.vision.v1.ImageAnnotationContext getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public CloudStorageKey parsePartialFrom( + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public ImageAnnotationContext parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CloudStorageKey(input, extensionRegistry); + return new ImageAnnotationContext(input, extensionRegistry); } }; - public static com.google.protobuf.Parser parser() { + public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override - public com.google.protobuf.Parser getParserForType() { + public com.google.protobuf.Parser getParserForType() { return PARSER; } - public com.google.privacy.dlp.v2beta1.CloudStorageKey getDefaultInstanceForType() { + public com.google.cloud.vision.v1.ImageAnnotationContext getDefaultInstanceForType() { return DEFAULT_INSTANCE; } diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotationContextOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotationContextOrBuilder.java new file mode 100644 index 000000000000..1012c84d9e4e --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotationContextOrBuilder.java @@ -0,0 +1,37 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface ImageAnnotationContextOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.ImageAnnotationContext) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * The URI of the file used to produce the image.
+   * 
+ * + * string uri = 1; + */ + java.lang.String getUri(); + /** + *
+   * The URI of the file used to produce the image.
+   * 
+ * + * string uri = 1; + */ + com.google.protobuf.ByteString + getUriBytes(); + + /** + *
+   * If the file was a PDF or TIFF, this field gives the page number within
+   * the file used to produce the image.
+   * 
+ * + * int32 page_number = 2; + */ + int getPageNumber(); +} diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorProto.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorProto.java index 6e083af6e416..5ca7f37d3d83 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorProto.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorProto.java @@ -109,11 +109,21 @@ public static void registerAllExtensions( static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_vision_v1_AnnotateImageRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_ImageAnnotationContext_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_ImageAnnotationContext_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_vision_v1_AnnotateImageResponse_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_vision_v1_AnnotateImageResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_AnnotateFileResponse_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_AnnotateFileResponse_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_vision_v1_BatchAnnotateImagesRequest_descriptor; static final @@ -124,6 +134,51 @@ public static void registerAllExtensions( static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_vision_v1_BatchAnnotateImagesResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_AsyncAnnotateFileRequest_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_AsyncAnnotateFileRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_AsyncAnnotateFileResponse_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_AsyncAnnotateFileResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesRequest_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesResponse_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_AsyncBatchAnnotateFilesResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_InputConfig_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_InputConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_OutputConfig_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_OutputConfig_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_GcsSource_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_GcsSource_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_GcsDestination_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_GcsDestination_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_vision_v1_OperationMetadata_descriptor; + static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_vision_v1_OperationMetadata_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { @@ -138,143 +193,183 @@ public static void registerAllExtensions( "pi/annotations.proto\032%google/cloud/visio" + "n/v1/geometry.proto\032,google/cloud/vision" + "/v1/text_annotation.proto\032*google/cloud/" + - "vision/v1/web_detection.proto\032\027google/rp" + - "c/status.proto\032\027google/type/color.proto\032" + - "\030google/type/latlng.proto\"\332\002\n\007Feature\0222\n" + - "\004type\030\001 \001(\0162$.google.cloud.vision.v1.Fea" + - "ture.Type\022\023\n\013max_results\030\002 \001(\005\022\r\n\005model\030" + - "\003 \001(\t\"\366\001\n\004Type\022\024\n\020TYPE_UNSPECIFIED\020\000\022\022\n\016" + - "FACE_DETECTION\020\001\022\026\n\022LANDMARK_DETECTION\020\002" + - "\022\022\n\016LOGO_DETECTION\020\003\022\023\n\017LABEL_DETECTION\020" + - "\004\022\022\n\016TEXT_DETECTION\020\005\022\033\n\027DOCUMENT_TEXT_D" + - "ETECTION\020\013\022\031\n\025SAFE_SEARCH_DETECTION\020\006\022\024\n" + - "\020IMAGE_PROPERTIES\020\007\022\016\n\nCROP_HINTS\020\t\022\021\n\rW" + - "EB_DETECTION\020\n\"7\n\013ImageSource\022\025\n\rgcs_ima" + - "ge_uri\030\001 \001(\t\022\021\n\timage_uri\030\002 \001(\t\"M\n\005Image" + - "\022\017\n\007content\030\001 \001(\014\0223\n\006source\030\002 \001(\0132#.goog" + - "le.cloud.vision.v1.ImageSource\"\307\r\n\016FaceA" + - "nnotation\022;\n\rbounding_poly\030\001 \001(\0132$.googl" + - "e.cloud.vision.v1.BoundingPoly\022>\n\020fd_bou" + - "nding_poly\030\002 \001(\0132$.google.cloud.vision.v" + - "1.BoundingPoly\022B\n\tlandmarks\030\003 \003(\0132/.goog" + - "le.cloud.vision.v1.FaceAnnotation.Landma" + - "rk\022\022\n\nroll_angle\030\004 \001(\002\022\021\n\tpan_angle\030\005 \001(" + - "\002\022\022\n\ntilt_angle\030\006 \001(\002\022\034\n\024detection_confi" + - "dence\030\007 \001(\002\022\036\n\026landmarking_confidence\030\010 " + - "\001(\002\022:\n\016joy_likelihood\030\t \001(\0162\".google.clo" + - "ud.vision.v1.Likelihood\022=\n\021sorrow_likeli" + - "hood\030\n \001(\0162\".google.cloud.vision.v1.Like" + - "lihood\022<\n\020anger_likelihood\030\013 \001(\0162\".googl" + - "e.cloud.vision.v1.Likelihood\022?\n\023surprise" + - "_likelihood\030\014 \001(\0162\".google.cloud.vision." + - "v1.Likelihood\022D\n\030under_exposed_likelihoo" + - "d\030\r \001(\0162\".google.cloud.vision.v1.Likelih" + - "ood\022>\n\022blurred_likelihood\030\016 \001(\0162\".google" + - ".cloud.vision.v1.Likelihood\022?\n\023headwear_" + - "likelihood\030\017 \001(\0162\".google.cloud.vision.v" + - "1.Likelihood\032\271\007\n\010Landmark\022B\n\004type\030\003 \001(\0162" + - "4.google.cloud.vision.v1.FaceAnnotation." + - "Landmark.Type\0222\n\010position\030\004 \001(\0132 .google" + - ".cloud.vision.v1.Position\"\264\006\n\004Type\022\024\n\020UN" + - "KNOWN_LANDMARK\020\000\022\014\n\010LEFT_EYE\020\001\022\r\n\tRIGHT_" + - "EYE\020\002\022\030\n\024LEFT_OF_LEFT_EYEBROW\020\003\022\031\n\025RIGHT" + - "_OF_LEFT_EYEBROW\020\004\022\031\n\025LEFT_OF_RIGHT_EYEB" + - "ROW\020\005\022\032\n\026RIGHT_OF_RIGHT_EYEBROW\020\006\022\031\n\025MID" + - "POINT_BETWEEN_EYES\020\007\022\014\n\010NOSE_TIP\020\010\022\r\n\tUP" + - "PER_LIP\020\t\022\r\n\tLOWER_LIP\020\n\022\016\n\nMOUTH_LEFT\020\013" + - "\022\017\n\013MOUTH_RIGHT\020\014\022\020\n\014MOUTH_CENTER\020\r\022\025\n\021N" + - "OSE_BOTTOM_RIGHT\020\016\022\024\n\020NOSE_BOTTOM_LEFT\020\017" + - "\022\026\n\022NOSE_BOTTOM_CENTER\020\020\022\031\n\025LEFT_EYE_TOP" + - "_BOUNDARY\020\021\022\031\n\025LEFT_EYE_RIGHT_CORNER\020\022\022\034" + - "\n\030LEFT_EYE_BOTTOM_BOUNDARY\020\023\022\030\n\024LEFT_EYE" + - "_LEFT_CORNER\020\024\022\032\n\026RIGHT_EYE_TOP_BOUNDARY" + - "\020\025\022\032\n\026RIGHT_EYE_RIGHT_CORNER\020\026\022\035\n\031RIGHT_" + - "EYE_BOTTOM_BOUNDARY\020\027\022\031\n\025RIGHT_EYE_LEFT_" + - "CORNER\020\030\022\037\n\033LEFT_EYEBROW_UPPER_MIDPOINT\020" + - "\031\022 \n\034RIGHT_EYEBROW_UPPER_MIDPOINT\020\032\022\024\n\020L" + - "EFT_EAR_TRAGION\020\033\022\025\n\021RIGHT_EAR_TRAGION\020\034" + - "\022\022\n\016LEFT_EYE_PUPIL\020\035\022\023\n\017RIGHT_EYE_PUPIL\020" + - "\036\022\025\n\021FOREHEAD_GLABELLA\020\037\022\021\n\rCHIN_GNATHIO" + - "N\020 \022\024\n\020CHIN_LEFT_GONION\020!\022\025\n\021CHIN_RIGHT_" + - "GONION\020\"\"4\n\014LocationInfo\022$\n\007lat_lng\030\001 \001(" + - "\0132\023.google.type.LatLng\"=\n\010Property\022\014\n\004na" + - "me\030\001 \001(\t\022\r\n\005value\030\002 \001(\t\022\024\n\014uint64_value\030" + - "\003 \001(\004\"\247\002\n\020EntityAnnotation\022\013\n\003mid\030\001 \001(\t\022" + - "\016\n\006locale\030\002 \001(\t\022\023\n\013description\030\003 \001(\t\022\r\n\005" + - "score\030\004 \001(\002\022\022\n\nconfidence\030\005 \001(\002\022\022\n\ntopic" + - "ality\030\006 \001(\002\022;\n\rbounding_poly\030\007 \001(\0132$.goo" + - "gle.cloud.vision.v1.BoundingPoly\0227\n\tloca" + - "tions\030\010 \003(\0132$.google.cloud.vision.v1.Loc" + - "ationInfo\0224\n\nproperties\030\t \003(\0132 .google.c" + - "loud.vision.v1.Property\"\231\002\n\024SafeSearchAn" + - "notation\0221\n\005adult\030\001 \001(\0162\".google.cloud.v" + - "ision.v1.Likelihood\0221\n\005spoof\030\002 \001(\0162\".goo" + - "gle.cloud.vision.v1.Likelihood\0223\n\007medica" + - "l\030\003 \001(\0162\".google.cloud.vision.v1.Likelih" + - "ood\0224\n\010violence\030\004 \001(\0162\".google.cloud.vis" + - "ion.v1.Likelihood\0220\n\004racy\030\t \001(\0162\".google" + - ".cloud.vision.v1.Likelihood\"a\n\013LatLongRe" + - "ct\022(\n\013min_lat_lng\030\001 \001(\0132\023.google.type.La" + - "tLng\022(\n\013max_lat_lng\030\002 \001(\0132\023.google.type." + - "LatLng\"U\n\tColorInfo\022!\n\005color\030\001 \001(\0132\022.goo" + - "gle.type.Color\022\r\n\005score\030\002 \001(\002\022\026\n\016pixel_f" + - "raction\030\003 \001(\002\"M\n\030DominantColorsAnnotatio" + - "n\0221\n\006colors\030\001 \003(\0132!.google.cloud.vision." + - "v1.ColorInfo\"\\\n\017ImageProperties\022I\n\017domin" + - "ant_colors\030\001 \001(\01320.google.cloud.vision.v" + - "1.DominantColorsAnnotation\"x\n\010CropHint\022;" + - "\n\rbounding_poly\030\001 \001(\0132$.google.cloud.vis" + - "ion.v1.BoundingPoly\022\022\n\nconfidence\030\002 \001(\002\022" + - "\033\n\023importance_fraction\030\003 \001(\002\"K\n\023CropHint" + - "sAnnotation\0224\n\ncrop_hints\030\001 \003(\0132 .google" + - ".cloud.vision.v1.CropHint\"(\n\017CropHintsPa" + - "rams\022\025\n\raspect_ratios\030\001 \003(\002\"1\n\022WebDetect" + - "ionParams\022\033\n\023include_geo_results\030\002 \001(\010\"\360" + - "\001\n\014ImageContext\022:\n\rlat_long_rect\030\001 \001(\0132#" + - ".google.cloud.vision.v1.LatLongRect\022\026\n\016l" + - "anguage_hints\030\002 \003(\t\022B\n\021crop_hints_params" + - "\030\004 \001(\0132\'.google.cloud.vision.v1.CropHint" + - "sParams\022H\n\024web_detection_params\030\006 \001(\0132*." + - "google.cloud.vision.v1.WebDetectionParam" + - "s\"\264\001\n\024AnnotateImageRequest\022,\n\005image\030\001 \001(" + - "\0132\035.google.cloud.vision.v1.Image\0221\n\010feat" + - "ures\030\002 \003(\0132\037.google.cloud.vision.v1.Feat" + - "ure\022;\n\rimage_context\030\003 \001(\0132$.google.clou" + - "d.vision.v1.ImageContext\"\374\005\n\025AnnotateIma" + - "geResponse\022@\n\020face_annotations\030\001 \003(\0132&.g" + - "oogle.cloud.vision.v1.FaceAnnotation\022F\n\024" + - "landmark_annotations\030\002 \003(\0132(.google.clou" + - "d.vision.v1.EntityAnnotation\022B\n\020logo_ann" + - "otations\030\003 \003(\0132(.google.cloud.vision.v1." + - "EntityAnnotation\022C\n\021label_annotations\030\004 " + - "\003(\0132(.google.cloud.vision.v1.EntityAnnot" + - "ation\022B\n\020text_annotations\030\005 \003(\0132(.google" + - ".cloud.vision.v1.EntityAnnotation\022D\n\024ful" + - "l_text_annotation\030\014 \001(\0132&.google.cloud.v" + - "ision.v1.TextAnnotation\022L\n\026safe_search_a" + - "nnotation\030\006 \001(\0132,.google.cloud.vision.v1" + - ".SafeSearchAnnotation\022L\n\033image_propertie" + - "s_annotation\030\010 \001(\0132\'.google.cloud.vision" + - ".v1.ImageProperties\022J\n\025crop_hints_annota" + - "tion\030\013 \001(\0132+.google.cloud.vision.v1.Crop" + - "HintsAnnotation\022;\n\rweb_detection\030\r \001(\0132$" + - ".google.cloud.vision.v1.WebDetection\022!\n\005" + - "error\030\t \001(\0132\022.google.rpc.Status\"\\\n\032Batch" + - "AnnotateImagesRequest\022>\n\010requests\030\001 \003(\0132" + - ",.google.cloud.vision.v1.AnnotateImageRe" + - "quest\"_\n\033BatchAnnotateImagesResponse\022@\n\t" + - "responses\030\001 \003(\0132-.google.cloud.vision.v1" + - ".AnnotateImageResponse*e\n\nLikelihood\022\013\n\007" + - "UNKNOWN\020\000\022\021\n\rVERY_UNLIKELY\020\001\022\014\n\010UNLIKELY" + - "\020\002\022\014\n\010POSSIBLE\020\003\022\n\n\006LIKELY\020\004\022\017\n\013VERY_LIK" + - "ELY\020\0052\261\001\n\016ImageAnnotator\022\236\001\n\023BatchAnnota" + - "teImages\0222.google.cloud.vision.v1.BatchA" + - "nnotateImagesRequest\0323.google.cloud.visi" + - "on.v1.BatchAnnotateImagesResponse\"\036\202\323\344\223\002" + - "\030\"\023/v1/images:annotate:\001*Bt\n\032com.google." + - "cloud.vision.v1B\023ImageAnnotatorProtoP\001Z<" + - "google.golang.org/genproto/googleapis/cl" + - "oud/vision/v1;vision\370\001\001b\006proto3" + "vision/v1/web_detection.proto\032#google/lo" + + "ngrunning/operations.proto\032\037google/proto" + + "buf/timestamp.proto\032\027google/rpc/status.p" + + "roto\032\027google/type/color.proto\032\030google/ty" + + "pe/latlng.proto\"\332\002\n\007Feature\0222\n\004type\030\001 \001(" + + "\0162$.google.cloud.vision.v1.Feature.Type\022" + + "\023\n\013max_results\030\002 \001(\005\022\r\n\005model\030\003 \001(\t\"\366\001\n\004" + + "Type\022\024\n\020TYPE_UNSPECIFIED\020\000\022\022\n\016FACE_DETEC" + + "TION\020\001\022\026\n\022LANDMARK_DETECTION\020\002\022\022\n\016LOGO_D" + + "ETECTION\020\003\022\023\n\017LABEL_DETECTION\020\004\022\022\n\016TEXT_" + + "DETECTION\020\005\022\033\n\027DOCUMENT_TEXT_DETECTION\020\013" + + "\022\031\n\025SAFE_SEARCH_DETECTION\020\006\022\024\n\020IMAGE_PRO" + + "PERTIES\020\007\022\016\n\nCROP_HINTS\020\t\022\021\n\rWEB_DETECTI" + + "ON\020\n\"7\n\013ImageSource\022\025\n\rgcs_image_uri\030\001 \001" + + "(\t\022\021\n\timage_uri\030\002 \001(\t\"M\n\005Image\022\017\n\007conten" + + "t\030\001 \001(\014\0223\n\006source\030\002 \001(\0132#.google.cloud.v" + + "ision.v1.ImageSource\"\307\r\n\016FaceAnnotation\022" + + ";\n\rbounding_poly\030\001 \001(\0132$.google.cloud.vi" + + "sion.v1.BoundingPoly\022>\n\020fd_bounding_poly" + + "\030\002 \001(\0132$.google.cloud.vision.v1.Bounding" + + "Poly\022B\n\tlandmarks\030\003 \003(\0132/.google.cloud.v" + + "ision.v1.FaceAnnotation.Landmark\022\022\n\nroll" + + "_angle\030\004 \001(\002\022\021\n\tpan_angle\030\005 \001(\002\022\022\n\ntilt_" + + "angle\030\006 \001(\002\022\034\n\024detection_confidence\030\007 \001(" + + "\002\022\036\n\026landmarking_confidence\030\010 \001(\002\022:\n\016joy" + + "_likelihood\030\t \001(\0162\".google.cloud.vision." + + "v1.Likelihood\022=\n\021sorrow_likelihood\030\n \001(\016" + + "2\".google.cloud.vision.v1.Likelihood\022<\n\020" + + "anger_likelihood\030\013 \001(\0162\".google.cloud.vi" + + "sion.v1.Likelihood\022?\n\023surprise_likelihoo" + + "d\030\014 \001(\0162\".google.cloud.vision.v1.Likelih" + + "ood\022D\n\030under_exposed_likelihood\030\r \001(\0162\"." + + "google.cloud.vision.v1.Likelihood\022>\n\022blu" + + "rred_likelihood\030\016 \001(\0162\".google.cloud.vis" + + "ion.v1.Likelihood\022?\n\023headwear_likelihood" + + "\030\017 \001(\0162\".google.cloud.vision.v1.Likeliho" + + "od\032\271\007\n\010Landmark\022B\n\004type\030\003 \001(\01624.google.c" + + "loud.vision.v1.FaceAnnotation.Landmark.T" + + "ype\0222\n\010position\030\004 \001(\0132 .google.cloud.vis" + + "ion.v1.Position\"\264\006\n\004Type\022\024\n\020UNKNOWN_LAND" + + "MARK\020\000\022\014\n\010LEFT_EYE\020\001\022\r\n\tRIGHT_EYE\020\002\022\030\n\024L" + + "EFT_OF_LEFT_EYEBROW\020\003\022\031\n\025RIGHT_OF_LEFT_E" + + "YEBROW\020\004\022\031\n\025LEFT_OF_RIGHT_EYEBROW\020\005\022\032\n\026R" + + "IGHT_OF_RIGHT_EYEBROW\020\006\022\031\n\025MIDPOINT_BETW" + + "EEN_EYES\020\007\022\014\n\010NOSE_TIP\020\010\022\r\n\tUPPER_LIP\020\t\022" + + "\r\n\tLOWER_LIP\020\n\022\016\n\nMOUTH_LEFT\020\013\022\017\n\013MOUTH_" + + "RIGHT\020\014\022\020\n\014MOUTH_CENTER\020\r\022\025\n\021NOSE_BOTTOM" + + "_RIGHT\020\016\022\024\n\020NOSE_BOTTOM_LEFT\020\017\022\026\n\022NOSE_B" + + "OTTOM_CENTER\020\020\022\031\n\025LEFT_EYE_TOP_BOUNDARY\020" + + "\021\022\031\n\025LEFT_EYE_RIGHT_CORNER\020\022\022\034\n\030LEFT_EYE" + + "_BOTTOM_BOUNDARY\020\023\022\030\n\024LEFT_EYE_LEFT_CORN" + + "ER\020\024\022\032\n\026RIGHT_EYE_TOP_BOUNDARY\020\025\022\032\n\026RIGH" + + "T_EYE_RIGHT_CORNER\020\026\022\035\n\031RIGHT_EYE_BOTTOM" + + "_BOUNDARY\020\027\022\031\n\025RIGHT_EYE_LEFT_CORNER\020\030\022\037" + + "\n\033LEFT_EYEBROW_UPPER_MIDPOINT\020\031\022 \n\034RIGHT" + + "_EYEBROW_UPPER_MIDPOINT\020\032\022\024\n\020LEFT_EAR_TR" + + "AGION\020\033\022\025\n\021RIGHT_EAR_TRAGION\020\034\022\022\n\016LEFT_E" + + "YE_PUPIL\020\035\022\023\n\017RIGHT_EYE_PUPIL\020\036\022\025\n\021FOREH" + + "EAD_GLABELLA\020\037\022\021\n\rCHIN_GNATHION\020 \022\024\n\020CHI" + + "N_LEFT_GONION\020!\022\025\n\021CHIN_RIGHT_GONION\020\"\"4" + + "\n\014LocationInfo\022$\n\007lat_lng\030\001 \001(\0132\023.google" + + ".type.LatLng\"=\n\010Property\022\014\n\004name\030\001 \001(\t\022\r" + + "\n\005value\030\002 \001(\t\022\024\n\014uint64_value\030\003 \001(\004\"\247\002\n\020" + + "EntityAnnotation\022\013\n\003mid\030\001 \001(\t\022\016\n\006locale\030" + + "\002 \001(\t\022\023\n\013description\030\003 \001(\t\022\r\n\005score\030\004 \001(" + + "\002\022\022\n\nconfidence\030\005 \001(\002\022\022\n\ntopicality\030\006 \001(" + + "\002\022;\n\rbounding_poly\030\007 \001(\0132$.google.cloud." + + "vision.v1.BoundingPoly\0227\n\tlocations\030\010 \003(" + + "\0132$.google.cloud.vision.v1.LocationInfo\022" + + "4\n\nproperties\030\t \003(\0132 .google.cloud.visio" + + "n.v1.Property\"\231\002\n\024SafeSearchAnnotation\0221" + + "\n\005adult\030\001 \001(\0162\".google.cloud.vision.v1.L" + + "ikelihood\0221\n\005spoof\030\002 \001(\0162\".google.cloud." + + "vision.v1.Likelihood\0223\n\007medical\030\003 \001(\0162\"." + + "google.cloud.vision.v1.Likelihood\0224\n\010vio" + + "lence\030\004 \001(\0162\".google.cloud.vision.v1.Lik" + + "elihood\0220\n\004racy\030\t \001(\0162\".google.cloud.vis" + + "ion.v1.Likelihood\"a\n\013LatLongRect\022(\n\013min_" + + "lat_lng\030\001 \001(\0132\023.google.type.LatLng\022(\n\013ma" + + "x_lat_lng\030\002 \001(\0132\023.google.type.LatLng\"U\n\t" + + "ColorInfo\022!\n\005color\030\001 \001(\0132\022.google.type.C" + + "olor\022\r\n\005score\030\002 \001(\002\022\026\n\016pixel_fraction\030\003 " + + "\001(\002\"M\n\030DominantColorsAnnotation\0221\n\006color" + + "s\030\001 \003(\0132!.google.cloud.vision.v1.ColorIn" + + "fo\"\\\n\017ImageProperties\022I\n\017dominant_colors" + + "\030\001 \001(\01320.google.cloud.vision.v1.Dominant" + + "ColorsAnnotation\"x\n\010CropHint\022;\n\rbounding" + + "_poly\030\001 \001(\0132$.google.cloud.vision.v1.Bou" + + "ndingPoly\022\022\n\nconfidence\030\002 \001(\002\022\033\n\023importa" + + "nce_fraction\030\003 \001(\002\"K\n\023CropHintsAnnotatio" + + "n\0224\n\ncrop_hints\030\001 \003(\0132 .google.cloud.vis" + + "ion.v1.CropHint\"(\n\017CropHintsParams\022\025\n\ras" + + "pect_ratios\030\001 \003(\002\"1\n\022WebDetectionParams\022" + + "\033\n\023include_geo_results\030\002 \001(\010\"\360\001\n\014ImageCo" + + "ntext\022:\n\rlat_long_rect\030\001 \001(\0132#.google.cl" + + "oud.vision.v1.LatLongRect\022\026\n\016language_hi" + + "nts\030\002 \003(\t\022B\n\021crop_hints_params\030\004 \001(\0132\'.g" + + "oogle.cloud.vision.v1.CropHintsParams\022H\n" + + "\024web_detection_params\030\006 \001(\0132*.google.clo" + + "ud.vision.v1.WebDetectionParams\"\264\001\n\024Anno" + + "tateImageRequest\022,\n\005image\030\001 \001(\0132\035.google" + + ".cloud.vision.v1.Image\0221\n\010features\030\002 \003(\013" + + "2\037.google.cloud.vision.v1.Feature\022;\n\rima" + + "ge_context\030\003 \001(\0132$.google.cloud.vision.v" + + "1.ImageContext\":\n\026ImageAnnotationContext" + + "\022\013\n\003uri\030\001 \001(\t\022\023\n\013page_number\030\002 \001(\005\"\275\006\n\025A" + + "nnotateImageResponse\022@\n\020face_annotations" + + "\030\001 \003(\0132&.google.cloud.vision.v1.FaceAnno" + + "tation\022F\n\024landmark_annotations\030\002 \003(\0132(.g" + + "oogle.cloud.vision.v1.EntityAnnotation\022B" + + "\n\020logo_annotations\030\003 \003(\0132(.google.cloud." + + "vision.v1.EntityAnnotation\022C\n\021label_anno" + + "tations\030\004 \003(\0132(.google.cloud.vision.v1.E" + + "ntityAnnotation\022B\n\020text_annotations\030\005 \003(" + + "\0132(.google.cloud.vision.v1.EntityAnnotat" + + "ion\022D\n\024full_text_annotation\030\014 \001(\0132&.goog" + + "le.cloud.vision.v1.TextAnnotation\022L\n\026saf" + + "e_search_annotation\030\006 \001(\0132,.google.cloud" + + ".vision.v1.SafeSearchAnnotation\022L\n\033image" + + "_properties_annotation\030\010 \001(\0132\'.google.cl" + + "oud.vision.v1.ImageProperties\022J\n\025crop_hi" + + "nts_annotation\030\013 \001(\0132+.google.cloud.visi" + + "on.v1.CropHintsAnnotation\022;\n\rweb_detecti" + + "on\030\r \001(\0132$.google.cloud.vision.v1.WebDet" + + "ection\022!\n\005error\030\t \001(\0132\022.google.rpc.Statu" + + "s\022?\n\007context\030\025 \001(\0132..google.cloud.vision" + + ".v1.ImageAnnotationContext\"\223\001\n\024AnnotateF" + + "ileResponse\0229\n\014input_config\030\001 \001(\0132#.goog" + + "le.cloud.vision.v1.InputConfig\022@\n\trespon" + + "ses\030\002 \003(\0132-.google.cloud.vision.v1.Annot" + + "ateImageResponse\"\\\n\032BatchAnnotateImagesR" + + "equest\022>\n\010requests\030\001 \003(\0132,.google.cloud." + + "vision.v1.AnnotateImageRequest\"_\n\033BatchA" + + "nnotateImagesResponse\022@\n\tresponses\030\001 \003(\013" + + "2-.google.cloud.vision.v1.AnnotateImageR" + + "esponse\"\202\002\n\030AsyncAnnotateFileRequest\0229\n\014" + + "input_config\030\001 \001(\0132#.google.cloud.vision" + + ".v1.InputConfig\0221\n\010features\030\002 \003(\0132\037.goog" + + "le.cloud.vision.v1.Feature\022;\n\rimage_cont" + + "ext\030\003 \001(\0132$.google.cloud.vision.v1.Image" + + "Context\022;\n\routput_config\030\004 \001(\0132$.google." + + "cloud.vision.v1.OutputConfig\"X\n\031AsyncAnn" + + "otateFileResponse\022;\n\routput_config\030\001 \001(\013" + + "2$.google.cloud.vision.v1.OutputConfig\"d" + + "\n\036AsyncBatchAnnotateFilesRequest\022B\n\010requ" + + "ests\030\001 \003(\01320.google.cloud.vision.v1.Asyn" + + "cAnnotateFileRequest\"g\n\037AsyncBatchAnnota" + + "teFilesResponse\022D\n\tresponses\030\001 \003(\01321.goo" + + "gle.cloud.vision.v1.AsyncAnnotateFileRes" + + "ponse\"W\n\013InputConfig\0225\n\ngcs_source\030\001 \001(\013" + + "2!.google.cloud.vision.v1.GcsSource\022\021\n\tm" + + "ime_type\030\002 \001(\t\"c\n\014OutputConfig\022?\n\017gcs_de" + + "stination\030\001 \001(\0132&.google.cloud.vision.v1" + + ".GcsDestination\022\022\n\nbatch_size\030\002 \001(\005\"\030\n\tG" + + "csSource\022\013\n\003uri\030\001 \001(\t\"\035\n\016GcsDestination\022" + + "\013\n\003uri\030\001 \001(\t\"\210\002\n\021OperationMetadata\022>\n\005st" + + "ate\030\001 \001(\0162/.google.cloud.vision.v1.Opera" + + "tionMetadata.State\022/\n\013create_time\030\005 \001(\0132" + + "\032.google.protobuf.Timestamp\022/\n\013update_ti" + + "me\030\006 \001(\0132\032.google.protobuf.Timestamp\"Q\n\005" + + "State\022\025\n\021STATE_UNSPECIFIED\020\000\022\013\n\007CREATED\020" + + "\001\022\013\n\007RUNNING\020\002\022\010\n\004DONE\020\003\022\r\n\tCANCELLED\020\004*" + + "e\n\nLikelihood\022\013\n\007UNKNOWN\020\000\022\021\n\rVERY_UNLIK" + + "ELY\020\001\022\014\n\010UNLIKELY\020\002\022\014\n\010POSSIBLE\020\003\022\n\n\006LIK" + + "ELY\020\004\022\017\n\013VERY_LIKELY\020\0052\315\002\n\016ImageAnnotato" + + "r\022\236\001\n\023BatchAnnotateImages\0222.google.cloud" + + ".vision.v1.BatchAnnotateImagesRequest\0323." + + "google.cloud.vision.v1.BatchAnnotateImag" + + "esResponse\"\036\202\323\344\223\002\030\"\023/v1/images:annotate:" + + "\001*\022\231\001\n\027AsyncBatchAnnotateFiles\0226.google." + + "cloud.vision.v1.AsyncBatchAnnotateFilesR" + + "equest\032\035.google.longrunning.Operation\"\'\202" + + "\323\344\223\002!\"\034/v1/files:asyncBatchAnnotate:\001*Bt" + + "\n\032com.google.cloud.vision.v1B\023ImageAnnot" + + "atorProtoP\001Z - * lat/long rectangle that specifies the location of the image. + * Not used. * * * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -144,7 +144,7 @@ public boolean hasLatLongRect() { } /** *
-   * lat/long rectangle that specifies the location of the image.
+   * Not used.
    * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -154,7 +154,7 @@ public com.google.cloud.vision.v1.LatLongRect getLatLongRect() { } /** *
-   * lat/long rectangle that specifies the location of the image.
+   * Not used.
    * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -705,7 +705,7 @@ public Builder mergeFrom( com.google.cloud.vision.v1.LatLongRect, com.google.cloud.vision.v1.LatLongRect.Builder, com.google.cloud.vision.v1.LatLongRectOrBuilder> latLongRectBuilder_; /** *
-     * lat/long rectangle that specifies the location of the image.
+     * Not used.
      * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -715,7 +715,7 @@ public boolean hasLatLongRect() { } /** *
-     * lat/long rectangle that specifies the location of the image.
+     * Not used.
      * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -729,7 +729,7 @@ public com.google.cloud.vision.v1.LatLongRect getLatLongRect() { } /** *
-     * lat/long rectangle that specifies the location of the image.
+     * Not used.
      * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -749,7 +749,7 @@ public Builder setLatLongRect(com.google.cloud.vision.v1.LatLongRect value) { } /** *
-     * lat/long rectangle that specifies the location of the image.
+     * Not used.
      * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -767,7 +767,7 @@ public Builder setLatLongRect( } /** *
-     * lat/long rectangle that specifies the location of the image.
+     * Not used.
      * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -789,7 +789,7 @@ public Builder mergeLatLongRect(com.google.cloud.vision.v1.LatLongRect value) { } /** *
-     * lat/long rectangle that specifies the location of the image.
+     * Not used.
      * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -807,7 +807,7 @@ public Builder clearLatLongRect() { } /** *
-     * lat/long rectangle that specifies the location of the image.
+     * Not used.
      * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -819,7 +819,7 @@ public com.google.cloud.vision.v1.LatLongRect.Builder getLatLongRectBuilder() { } /** *
-     * lat/long rectangle that specifies the location of the image.
+     * Not used.
      * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -834,7 +834,7 @@ public com.google.cloud.vision.v1.LatLongRectOrBuilder getLatLongRectOrBuilder() } /** *
-     * lat/long rectangle that specifies the location of the image.
+     * Not used.
      * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageContextOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageContextOrBuilder.java index c8dff92c7b04..8d9c20f89b4b 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageContextOrBuilder.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/ImageContextOrBuilder.java @@ -9,7 +9,7 @@ public interface ImageContextOrBuilder extends /** *
-   * lat/long rectangle that specifies the location of the image.
+   * Not used.
    * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -17,7 +17,7 @@ public interface ImageContextOrBuilder extends boolean hasLatLongRect(); /** *
-   * lat/long rectangle that specifies the location of the image.
+   * Not used.
    * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; @@ -25,7 +25,7 @@ public interface ImageContextOrBuilder extends com.google.cloud.vision.v1.LatLongRect getLatLongRect(); /** *
-   * lat/long rectangle that specifies the location of the image.
+   * Not used.
    * 
* * .google.cloud.vision.v1.LatLongRect lat_long_rect = 1; diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/InputConfig.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/InputConfig.java new file mode 100644 index 000000000000..89522f830730 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/InputConfig.java @@ -0,0 +1,788 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +/** + *
+ * The desired input location and metadata.
+ * 
+ * + * Protobuf type {@code google.cloud.vision.v1.InputConfig} + */ +public final class InputConfig extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.InputConfig) + InputConfigOrBuilder { +private static final long serialVersionUID = 0L; + // Use InputConfig.newBuilder() to construct. + private InputConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private InputConfig() { + mimeType_ = ""; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private InputConfig( + 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; + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + case 10: { + com.google.cloud.vision.v1.GcsSource.Builder subBuilder = null; + if (gcsSource_ != null) { + subBuilder = gcsSource_.toBuilder(); + } + gcsSource_ = input.readMessage(com.google.cloud.vision.v1.GcsSource.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(gcsSource_); + gcsSource_ = subBuilder.buildPartial(); + } + + break; + } + case 18: { + java.lang.String s = input.readStringRequireUtf8(); + + mimeType_ = s; + 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.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_InputConfig_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_InputConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.InputConfig.class, com.google.cloud.vision.v1.InputConfig.Builder.class); + } + + public static final int GCS_SOURCE_FIELD_NUMBER = 1; + private com.google.cloud.vision.v1.GcsSource gcsSource_; + /** + *
+   * The Google Cloud Storage location to read the input from.
+   * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public boolean hasGcsSource() { + return gcsSource_ != null; + } + /** + *
+   * The Google Cloud Storage location to read the input from.
+   * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public com.google.cloud.vision.v1.GcsSource getGcsSource() { + return gcsSource_ == null ? com.google.cloud.vision.v1.GcsSource.getDefaultInstance() : gcsSource_; + } + /** + *
+   * The Google Cloud Storage location to read the input from.
+   * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public com.google.cloud.vision.v1.GcsSourceOrBuilder getGcsSourceOrBuilder() { + return getGcsSource(); + } + + public static final int MIME_TYPE_FIELD_NUMBER = 2; + private volatile java.lang.Object mimeType_; + /** + *
+   * The type of the file. Currently only "application/pdf" and "image/tiff"
+   * are supported. Wildcards are not supported.
+   * 
+ * + * string mime_type = 2; + */ + public java.lang.String getMimeType() { + java.lang.Object ref = mimeType_; + 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(); + mimeType_ = s; + return s; + } + } + /** + *
+   * The type of the file. Currently only "application/pdf" and "image/tiff"
+   * are supported. Wildcards are not supported.
+   * 
+ * + * string mime_type = 2; + */ + public com.google.protobuf.ByteString + getMimeTypeBytes() { + java.lang.Object ref = mimeType_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + mimeType_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + if (gcsSource_ != null) { + output.writeMessage(1, getGcsSource()); + } + if (!getMimeTypeBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, mimeType_); + } + unknownFields.writeTo(output); + } + + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (gcsSource_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, getGcsSource()); + } + if (!getMimeTypeBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, mimeType_); + } + 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.vision.v1.InputConfig)) { + return super.equals(obj); + } + com.google.cloud.vision.v1.InputConfig other = (com.google.cloud.vision.v1.InputConfig) obj; + + boolean result = true; + result = result && (hasGcsSource() == other.hasGcsSource()); + if (hasGcsSource()) { + result = result && getGcsSource() + .equals(other.getGcsSource()); + } + result = result && getMimeType() + .equals(other.getMimeType()); + result = result && unknownFields.equals(other.unknownFields); + return result; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasGcsSource()) { + hash = (37 * hash) + GCS_SOURCE_FIELD_NUMBER; + hash = (53 * hash) + getGcsSource().hashCode(); + } + hash = (37 * hash) + MIME_TYPE_FIELD_NUMBER; + hash = (53 * hash) + getMimeType().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.vision.v1.InputConfig parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.InputConfig 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.vision.v1.InputConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.InputConfig 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.vision.v1.InputConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.InputConfig parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.google.cloud.vision.v1.InputConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.InputConfig 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.vision.v1.InputConfig parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.InputConfig 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.vision.v1.InputConfig parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.InputConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(com.google.cloud.vision.v1.InputConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + 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; + } + /** + *
+   * The desired input location and metadata.
+   * 
+ * + * Protobuf type {@code google.cloud.vision.v1.InputConfig} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.InputConfig) + com.google.cloud.vision.v1.InputConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_InputConfig_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_InputConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.InputConfig.class, com.google.cloud.vision.v1.InputConfig.Builder.class); + } + + // Construct using com.google.cloud.vision.v1.InputConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + } + } + public Builder clear() { + super.clear(); + if (gcsSourceBuilder_ == null) { + gcsSource_ = null; + } else { + gcsSource_ = null; + gcsSourceBuilder_ = null; + } + mimeType_ = ""; + + return this; + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_InputConfig_descriptor; + } + + public com.google.cloud.vision.v1.InputConfig getDefaultInstanceForType() { + return com.google.cloud.vision.v1.InputConfig.getDefaultInstance(); + } + + public com.google.cloud.vision.v1.InputConfig build() { + com.google.cloud.vision.v1.InputConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public com.google.cloud.vision.v1.InputConfig buildPartial() { + com.google.cloud.vision.v1.InputConfig result = new com.google.cloud.vision.v1.InputConfig(this); + if (gcsSourceBuilder_ == null) { + result.gcsSource_ = gcsSource_; + } else { + result.gcsSource_ = gcsSourceBuilder_.build(); + } + result.mimeType_ = mimeType_; + onBuilt(); + return result; + } + + public Builder clone() { + return (Builder) super.clone(); + } + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.setField(field, value); + } + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return (Builder) super.clearField(field); + } + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return (Builder) super.clearOneof(oneof); + } + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, java.lang.Object value) { + return (Builder) super.setRepeatedField(field, index, value); + } + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.addRepeatedField(field, value); + } + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.vision.v1.InputConfig) { + return mergeFrom((com.google.cloud.vision.v1.InputConfig)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.vision.v1.InputConfig other) { + if (other == com.google.cloud.vision.v1.InputConfig.getDefaultInstance()) return this; + if (other.hasGcsSource()) { + mergeGcsSource(other.getGcsSource()); + } + if (!other.getMimeType().isEmpty()) { + mimeType_ = other.mimeType_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + public final boolean isInitialized() { + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.vision.v1.InputConfig parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.cloud.vision.v1.InputConfig) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.vision.v1.GcsSource gcsSource_ = null; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.GcsSource, com.google.cloud.vision.v1.GcsSource.Builder, com.google.cloud.vision.v1.GcsSourceOrBuilder> gcsSourceBuilder_; + /** + *
+     * The Google Cloud Storage location to read the input from.
+     * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public boolean hasGcsSource() { + return gcsSourceBuilder_ != null || gcsSource_ != null; + } + /** + *
+     * The Google Cloud Storage location to read the input from.
+     * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public com.google.cloud.vision.v1.GcsSource getGcsSource() { + if (gcsSourceBuilder_ == null) { + return gcsSource_ == null ? com.google.cloud.vision.v1.GcsSource.getDefaultInstance() : gcsSource_; + } else { + return gcsSourceBuilder_.getMessage(); + } + } + /** + *
+     * The Google Cloud Storage location to read the input from.
+     * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public Builder setGcsSource(com.google.cloud.vision.v1.GcsSource value) { + if (gcsSourceBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + gcsSource_ = value; + onChanged(); + } else { + gcsSourceBuilder_.setMessage(value); + } + + return this; + } + /** + *
+     * The Google Cloud Storage location to read the input from.
+     * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public Builder setGcsSource( + com.google.cloud.vision.v1.GcsSource.Builder builderForValue) { + if (gcsSourceBuilder_ == null) { + gcsSource_ = builderForValue.build(); + onChanged(); + } else { + gcsSourceBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + *
+     * The Google Cloud Storage location to read the input from.
+     * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public Builder mergeGcsSource(com.google.cloud.vision.v1.GcsSource value) { + if (gcsSourceBuilder_ == null) { + if (gcsSource_ != null) { + gcsSource_ = + com.google.cloud.vision.v1.GcsSource.newBuilder(gcsSource_).mergeFrom(value).buildPartial(); + } else { + gcsSource_ = value; + } + onChanged(); + } else { + gcsSourceBuilder_.mergeFrom(value); + } + + return this; + } + /** + *
+     * The Google Cloud Storage location to read the input from.
+     * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public Builder clearGcsSource() { + if (gcsSourceBuilder_ == null) { + gcsSource_ = null; + onChanged(); + } else { + gcsSource_ = null; + gcsSourceBuilder_ = null; + } + + return this; + } + /** + *
+     * The Google Cloud Storage location to read the input from.
+     * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public com.google.cloud.vision.v1.GcsSource.Builder getGcsSourceBuilder() { + + onChanged(); + return getGcsSourceFieldBuilder().getBuilder(); + } + /** + *
+     * The Google Cloud Storage location to read the input from.
+     * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + public com.google.cloud.vision.v1.GcsSourceOrBuilder getGcsSourceOrBuilder() { + if (gcsSourceBuilder_ != null) { + return gcsSourceBuilder_.getMessageOrBuilder(); + } else { + return gcsSource_ == null ? + com.google.cloud.vision.v1.GcsSource.getDefaultInstance() : gcsSource_; + } + } + /** + *
+     * The Google Cloud Storage location to read the input from.
+     * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.GcsSource, com.google.cloud.vision.v1.GcsSource.Builder, com.google.cloud.vision.v1.GcsSourceOrBuilder> + getGcsSourceFieldBuilder() { + if (gcsSourceBuilder_ == null) { + gcsSourceBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.GcsSource, com.google.cloud.vision.v1.GcsSource.Builder, com.google.cloud.vision.v1.GcsSourceOrBuilder>( + getGcsSource(), + getParentForChildren(), + isClean()); + gcsSource_ = null; + } + return gcsSourceBuilder_; + } + + private java.lang.Object mimeType_ = ""; + /** + *
+     * The type of the file. Currently only "application/pdf" and "image/tiff"
+     * are supported. Wildcards are not supported.
+     * 
+ * + * string mime_type = 2; + */ + public java.lang.String getMimeType() { + java.lang.Object ref = mimeType_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = + (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + mimeType_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + *
+     * The type of the file. Currently only "application/pdf" and "image/tiff"
+     * are supported. Wildcards are not supported.
+     * 
+ * + * string mime_type = 2; + */ + public com.google.protobuf.ByteString + getMimeTypeBytes() { + java.lang.Object ref = mimeType_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + mimeType_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + *
+     * The type of the file. Currently only "application/pdf" and "image/tiff"
+     * are supported. Wildcards are not supported.
+     * 
+ * + * string mime_type = 2; + */ + public Builder setMimeType( + java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + mimeType_ = value; + onChanged(); + return this; + } + /** + *
+     * The type of the file. Currently only "application/pdf" and "image/tiff"
+     * are supported. Wildcards are not supported.
+     * 
+ * + * string mime_type = 2; + */ + public Builder clearMimeType() { + + mimeType_ = getDefaultInstance().getMimeType(); + onChanged(); + return this; + } + /** + *
+     * The type of the file. Currently only "application/pdf" and "image/tiff"
+     * are supported. Wildcards are not supported.
+     * 
+ * + * string mime_type = 2; + */ + public Builder setMimeTypeBytes( + com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + mimeType_ = value; + onChanged(); + return this; + } + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFieldsProto3(unknownFields); + } + + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.InputConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.InputConfig) + private static final com.google.cloud.vision.v1.InputConfig DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.InputConfig(); + } + + public static com.google.cloud.vision.v1.InputConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public InputConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new InputConfig(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + public com.google.cloud.vision.v1.InputConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + +} + diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/InputConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/InputConfigOrBuilder.java new file mode 100644 index 000000000000..7521ddb3d636 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/InputConfigOrBuilder.java @@ -0,0 +1,54 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface InputConfigOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.InputConfig) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * The Google Cloud Storage location to read the input from.
+   * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + boolean hasGcsSource(); + /** + *
+   * The Google Cloud Storage location to read the input from.
+   * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + com.google.cloud.vision.v1.GcsSource getGcsSource(); + /** + *
+   * The Google Cloud Storage location to read the input from.
+   * 
+ * + * .google.cloud.vision.v1.GcsSource gcs_source = 1; + */ + com.google.cloud.vision.v1.GcsSourceOrBuilder getGcsSourceOrBuilder(); + + /** + *
+   * The type of the file. Currently only "application/pdf" and "image/tiff"
+   * are supported. Wildcards are not supported.
+   * 
+ * + * string mime_type = 2; + */ + java.lang.String getMimeType(); + /** + *
+   * The type of the file. Currently only "application/pdf" and "image/tiff"
+   * are supported. Wildcards are not supported.
+   * 
+ * + * string mime_type = 2; + */ + com.google.protobuf.ByteString + getMimeTypeBytes(); +} diff --git a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Range.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/NormalizedVertex.java similarity index 59% rename from google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Range.java rename to google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/NormalizedVertex.java index 188895244717..c0b59403d655 100644 --- a/google-api-grpc/proto-google-cloud-dlp-v2beta1/src/main/java/com/google/privacy/dlp/v2beta1/Range.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/NormalizedVertex.java @@ -1,27 +1,29 @@ // Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/privacy/dlp/v2beta1/dlp.proto +// source: google/cloud/vision/v1/geometry.proto -package com.google.privacy.dlp.v2beta1; +package com.google.cloud.vision.v1; /** *
- * Generic half-open interval [start, end)
+ * A vertex represents a 2D point in the image.
+ * NOTE: the normalized vertex coordinates are relative to the original image
+ * and range from 0 to 1.
  * 
* - * Protobuf type {@code google.privacy.dlp.v2beta1.Range} + * Protobuf type {@code google.cloud.vision.v1.NormalizedVertex} */ -public final class Range extends +public final class NormalizedVertex extends com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.Range) - RangeOrBuilder { + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.NormalizedVertex) + NormalizedVertexOrBuilder { private static final long serialVersionUID = 0L; - // Use Range.newBuilder() to construct. - private Range(com.google.protobuf.GeneratedMessageV3.Builder builder) { + // Use NormalizedVertex.newBuilder() to construct. + private NormalizedVertex(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private Range() { - start_ = 0L; - end_ = 0L; + private NormalizedVertex() { + x_ = 0F; + y_ = 0F; } @java.lang.Override @@ -29,7 +31,7 @@ private Range() { getUnknownFields() { return this.unknownFields; } - private Range( + private NormalizedVertex( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { @@ -55,14 +57,14 @@ private Range( } break; } - case 8: { + case 13: { - start_ = input.readInt64(); + x_ = input.readFloat(); break; } - case 16: { + case 21: { - end_ = input.readInt64(); + y_ = input.readFloat(); break; } } @@ -79,40 +81,40 @@ private Range( } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Range_descriptor; + return com.google.cloud.vision.v1.GeometryProto.internal_static_google_cloud_vision_v1_NormalizedVertex_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Range_fieldAccessorTable + return com.google.cloud.vision.v1.GeometryProto.internal_static_google_cloud_vision_v1_NormalizedVertex_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Range.class, com.google.privacy.dlp.v2beta1.Range.Builder.class); + com.google.cloud.vision.v1.NormalizedVertex.class, com.google.cloud.vision.v1.NormalizedVertex.Builder.class); } - public static final int START_FIELD_NUMBER = 1; - private long start_; + public static final int X_FIELD_NUMBER = 1; + private float x_; /** *
-   * Index of the first character of the range (inclusive).
+   * X coordinate.
    * 
* - * int64 start = 1; + * float x = 1; */ - public long getStart() { - return start_; + public float getX() { + return x_; } - public static final int END_FIELD_NUMBER = 2; - private long end_; + public static final int Y_FIELD_NUMBER = 2; + private float y_; /** *
-   * Index of the last character of the range (exclusive).
+   * Y coordinate.
    * 
* - * int64 end = 2; + * float y = 2; */ - public long getEnd() { - return end_; + public float getY() { + return y_; } private byte memoizedIsInitialized = -1; @@ -127,11 +129,11 @@ public final boolean isInitialized() { public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (start_ != 0L) { - output.writeInt64(1, start_); + if (x_ != 0F) { + output.writeFloat(1, x_); } - if (end_ != 0L) { - output.writeInt64(2, end_); + if (y_ != 0F) { + output.writeFloat(2, y_); } unknownFields.writeTo(output); } @@ -141,13 +143,13 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - if (start_ != 0L) { + if (x_ != 0F) { size += com.google.protobuf.CodedOutputStream - .computeInt64Size(1, start_); + .computeFloatSize(1, x_); } - if (end_ != 0L) { + if (y_ != 0F) { size += com.google.protobuf.CodedOutputStream - .computeInt64Size(2, end_); + .computeFloatSize(2, y_); } size += unknownFields.getSerializedSize(); memoizedSize = size; @@ -159,16 +161,20 @@ public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } - if (!(obj instanceof com.google.privacy.dlp.v2beta1.Range)) { + if (!(obj instanceof com.google.cloud.vision.v1.NormalizedVertex)) { return super.equals(obj); } - com.google.privacy.dlp.v2beta1.Range other = (com.google.privacy.dlp.v2beta1.Range) obj; + com.google.cloud.vision.v1.NormalizedVertex other = (com.google.cloud.vision.v1.NormalizedVertex) obj; boolean result = true; - result = result && (getStart() - == other.getStart()); - result = result && (getEnd() - == other.getEnd()); + result = result && ( + java.lang.Float.floatToIntBits(getX()) + == java.lang.Float.floatToIntBits( + other.getX())); + result = result && ( + java.lang.Float.floatToIntBits(getY()) + == java.lang.Float.floatToIntBits( + other.getY())); result = result && unknownFields.equals(other.unknownFields); return result; } @@ -180,80 +186,80 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + START_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getStart()); - hash = (37 * hash) + END_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong( - getEnd()); + hash = (37 * hash) + X_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits( + getX()); + hash = (37 * hash) + Y_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits( + getY()); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } - public static com.google.privacy.dlp.v2beta1.Range parseFrom( + public static com.google.cloud.vision.v1.NormalizedVertex parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.Range parseFrom( + public static com.google.cloud.vision.v1.NormalizedVertex parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.privacy.dlp.v2beta1.Range parseFrom( + public static com.google.cloud.vision.v1.NormalizedVertex parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.Range parseFrom( + public static com.google.cloud.vision.v1.NormalizedVertex 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.privacy.dlp.v2beta1.Range parseFrom(byte[] data) + public static com.google.cloud.vision.v1.NormalizedVertex parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.privacy.dlp.v2beta1.Range parseFrom( + public static com.google.cloud.vision.v1.NormalizedVertex parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.privacy.dlp.v2beta1.Range parseFrom(java.io.InputStream input) + public static com.google.cloud.vision.v1.NormalizedVertex parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.Range parseFrom( + public static com.google.cloud.vision.v1.NormalizedVertex 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.privacy.dlp.v2beta1.Range parseDelimitedFrom(java.io.InputStream input) + public static com.google.cloud.vision.v1.NormalizedVertex parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.Range parseDelimitedFrom( + public static com.google.cloud.vision.v1.NormalizedVertex 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.privacy.dlp.v2beta1.Range parseFrom( + public static com.google.cloud.vision.v1.NormalizedVertex parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } - public static com.google.privacy.dlp.v2beta1.Range parseFrom( + public static com.google.cloud.vision.v1.NormalizedVertex parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { @@ -265,7 +271,7 @@ public static com.google.privacy.dlp.v2beta1.Range parseFrom( public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(com.google.privacy.dlp.v2beta1.Range prototype) { + public static Builder newBuilder(com.google.cloud.vision.v1.NormalizedVertex prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } public Builder toBuilder() { @@ -281,28 +287,30 @@ protected Builder newBuilderForType( } /** *
-   * Generic half-open interval [start, end)
+   * A vertex represents a 2D point in the image.
+   * NOTE: the normalized vertex coordinates are relative to the original image
+   * and range from 0 to 1.
    * 
* - * Protobuf type {@code google.privacy.dlp.v2beta1.Range} + * Protobuf type {@code google.cloud.vision.v1.NormalizedVertex} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.Range) - com.google.privacy.dlp.v2beta1.RangeOrBuilder { + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.NormalizedVertex) + com.google.cloud.vision.v1.NormalizedVertexOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Range_descriptor; + return com.google.cloud.vision.v1.GeometryProto.internal_static_google_cloud_vision_v1_NormalizedVertex_descriptor; } protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Range_fieldAccessorTable + return com.google.cloud.vision.v1.GeometryProto.internal_static_google_cloud_vision_v1_NormalizedVertex_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.privacy.dlp.v2beta1.Range.class, com.google.privacy.dlp.v2beta1.Range.Builder.class); + com.google.cloud.vision.v1.NormalizedVertex.class, com.google.cloud.vision.v1.NormalizedVertex.Builder.class); } - // Construct using com.google.privacy.dlp.v2beta1.Range.newBuilder() + // Construct using com.google.cloud.vision.v1.NormalizedVertex.newBuilder() private Builder() { maybeForceBuilderInitialization(); } @@ -319,34 +327,34 @@ private void maybeForceBuilderInitialization() { } public Builder clear() { super.clear(); - start_ = 0L; + x_ = 0F; - end_ = 0L; + y_ = 0F; return this; } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_Range_descriptor; + return com.google.cloud.vision.v1.GeometryProto.internal_static_google_cloud_vision_v1_NormalizedVertex_descriptor; } - public com.google.privacy.dlp.v2beta1.Range getDefaultInstanceForType() { - return com.google.privacy.dlp.v2beta1.Range.getDefaultInstance(); + public com.google.cloud.vision.v1.NormalizedVertex getDefaultInstanceForType() { + return com.google.cloud.vision.v1.NormalizedVertex.getDefaultInstance(); } - public com.google.privacy.dlp.v2beta1.Range build() { - com.google.privacy.dlp.v2beta1.Range result = buildPartial(); + public com.google.cloud.vision.v1.NormalizedVertex build() { + com.google.cloud.vision.v1.NormalizedVertex result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - public com.google.privacy.dlp.v2beta1.Range buildPartial() { - com.google.privacy.dlp.v2beta1.Range result = new com.google.privacy.dlp.v2beta1.Range(this); - result.start_ = start_; - result.end_ = end_; + public com.google.cloud.vision.v1.NormalizedVertex buildPartial() { + com.google.cloud.vision.v1.NormalizedVertex result = new com.google.cloud.vision.v1.NormalizedVertex(this); + result.x_ = x_; + result.y_ = y_; onBuilt(); return result; } @@ -378,21 +386,21 @@ public Builder addRepeatedField( return (Builder) super.addRepeatedField(field, value); } public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.privacy.dlp.v2beta1.Range) { - return mergeFrom((com.google.privacy.dlp.v2beta1.Range)other); + if (other instanceof com.google.cloud.vision.v1.NormalizedVertex) { + return mergeFrom((com.google.cloud.vision.v1.NormalizedVertex)other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(com.google.privacy.dlp.v2beta1.Range other) { - if (other == com.google.privacy.dlp.v2beta1.Range.getDefaultInstance()) return this; - if (other.getStart() != 0L) { - setStart(other.getStart()); + public Builder mergeFrom(com.google.cloud.vision.v1.NormalizedVertex other) { + if (other == com.google.cloud.vision.v1.NormalizedVertex.getDefaultInstance()) return this; + if (other.getX() != 0F) { + setX(other.getX()); } - if (other.getEnd() != 0L) { - setEnd(other.getEnd()); + if (other.getY() != 0F) { + setY(other.getY()); } this.mergeUnknownFields(other.unknownFields); onChanged(); @@ -407,11 +415,11 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.privacy.dlp.v2beta1.Range parsedMessage = null; + com.google.cloud.vision.v1.NormalizedVertex parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.privacy.dlp.v2beta1.Range) e.getUnfinishedMessage(); + parsedMessage = (com.google.cloud.vision.v1.NormalizedVertex) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -421,78 +429,78 @@ public Builder mergeFrom( return this; } - private long start_ ; + private float x_ ; /** *
-     * Index of the first character of the range (inclusive).
+     * X coordinate.
      * 
* - * int64 start = 1; + * float x = 1; */ - public long getStart() { - return start_; + public float getX() { + return x_; } /** *
-     * Index of the first character of the range (inclusive).
+     * X coordinate.
      * 
* - * int64 start = 1; + * float x = 1; */ - public Builder setStart(long value) { + public Builder setX(float value) { - start_ = value; + x_ = value; onChanged(); return this; } /** *
-     * Index of the first character of the range (inclusive).
+     * X coordinate.
      * 
* - * int64 start = 1; + * float x = 1; */ - public Builder clearStart() { + public Builder clearX() { - start_ = 0L; + x_ = 0F; onChanged(); return this; } - private long end_ ; + private float y_ ; /** *
-     * Index of the last character of the range (exclusive).
+     * Y coordinate.
      * 
* - * int64 end = 2; + * float y = 2; */ - public long getEnd() { - return end_; + public float getY() { + return y_; } /** *
-     * Index of the last character of the range (exclusive).
+     * Y coordinate.
      * 
* - * int64 end = 2; + * float y = 2; */ - public Builder setEnd(long value) { + public Builder setY(float value) { - end_ = value; + y_ = value; onChanged(); return this; } /** *
-     * Index of the last character of the range (exclusive).
+     * Y coordinate.
      * 
* - * int64 end = 2; + * float y = 2; */ - public Builder clearEnd() { + public Builder clearY() { - end_ = 0L; + y_ = 0F; onChanged(); return this; } @@ -507,39 +515,39 @@ public final Builder mergeUnknownFields( } - // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.Range) + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.NormalizedVertex) } - // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.Range) - private static final com.google.privacy.dlp.v2beta1.Range DEFAULT_INSTANCE; + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.NormalizedVertex) + private static final com.google.cloud.vision.v1.NormalizedVertex DEFAULT_INSTANCE; static { - DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.Range(); + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.NormalizedVertex(); } - public static com.google.privacy.dlp.v2beta1.Range getDefaultInstance() { + public static com.google.cloud.vision.v1.NormalizedVertex getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - public Range parsePartialFrom( + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public NormalizedVertex parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Range(input, extensionRegistry); + return new NormalizedVertex(input, extensionRegistry); } }; - public static com.google.protobuf.Parser parser() { + public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override - public com.google.protobuf.Parser getParserForType() { + public com.google.protobuf.Parser getParserForType() { return PARSER; } - public com.google.privacy.dlp.v2beta1.Range getDefaultInstanceForType() { + public com.google.cloud.vision.v1.NormalizedVertex getDefaultInstanceForType() { return DEFAULT_INSTANCE; } diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/NormalizedVertexOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/NormalizedVertexOrBuilder.java new file mode 100644 index 000000000000..14d7ed4008be --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/NormalizedVertexOrBuilder.java @@ -0,0 +1,27 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/geometry.proto + +package com.google.cloud.vision.v1; + +public interface NormalizedVertexOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.NormalizedVertex) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * X coordinate.
+   * 
+ * + * float x = 1; + */ + float getX(); + + /** + *
+   * Y coordinate.
+   * 
+ * + * float y = 2; + */ + float getY(); +} diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OperationMetadata.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OperationMetadata.java new file mode 100644 index 000000000000..51c7344925a5 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OperationMetadata.java @@ -0,0 +1,1135 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +/** + *
+ * Contains metadata for the BatchAnnotateImages operation.
+ * 
+ * + * Protobuf type {@code google.cloud.vision.v1.OperationMetadata} + */ +public final class OperationMetadata extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.OperationMetadata) + OperationMetadataOrBuilder { +private static final long serialVersionUID = 0L; + // Use OperationMetadata.newBuilder() to construct. + private OperationMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private OperationMetadata() { + state_ = 0; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private OperationMetadata( + 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; + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + case 8: { + int rawValue = input.readEnum(); + + state_ = rawValue; + 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; + } + } + } + } 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.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_OperationMetadata_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_OperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.OperationMetadata.class, com.google.cloud.vision.v1.OperationMetadata.Builder.class); + } + + /** + *
+   * Batch operation states.
+   * 
+ * + * Protobuf enum {@code google.cloud.vision.v1.OperationMetadata.State} + */ + public enum State + implements com.google.protobuf.ProtocolMessageEnum { + /** + *
+     * Invalid.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + *
+     * Request is received.
+     * 
+ * + * CREATED = 1; + */ + CREATED(1), + /** + *
+     * Request is actively being processed.
+     * 
+ * + * RUNNING = 2; + */ + RUNNING(2), + /** + *
+     * The batch processing is done.
+     * 
+ * + * DONE = 3; + */ + DONE(3), + /** + *
+     * The batch processing was cancelled.
+     * 
+ * + * CANCELLED = 4; + */ + CANCELLED(4), + UNRECOGNIZED(-1), + ; + + /** + *
+     * Invalid.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + /** + *
+     * Request is received.
+     * 
+ * + * CREATED = 1; + */ + public static final int CREATED_VALUE = 1; + /** + *
+     * Request is actively being processed.
+     * 
+ * + * RUNNING = 2; + */ + public static final int RUNNING_VALUE = 2; + /** + *
+     * The batch processing is done.
+     * 
+ * + * DONE = 3; + */ + public static final int DONE_VALUE = 3; + /** + *
+     * The batch processing was cancelled.
+     * 
+ * + * CANCELLED = 4; + */ + public static final int CANCELLED_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; + } + + /** + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + public static State forNumber(int value) { + switch (value) { + case 0: return STATE_UNSPECIFIED; + case 1: return CREATED; + case 2: return RUNNING; + case 3: return DONE; + case 4: return CANCELLED; + default: return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + private static final com.google.protobuf.Internal.EnumLiteMap< + State> internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor + getValueDescriptor() { + 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.vision.v1.OperationMetadata.getDescriptor().getEnumTypes().get(0); + } + + private static final State[] VALUES = values(); + + public static State valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException( + "EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.vision.v1.OperationMetadata.State) + } + + public static final int STATE_FIELD_NUMBER = 1; + private int state_; + /** + *
+   * Current state of the batch operation.
+   * 
+ * + * .google.cloud.vision.v1.OperationMetadata.State state = 1; + */ + public int getStateValue() { + return state_; + } + /** + *
+   * Current state of the batch operation.
+   * 
+ * + * .google.cloud.vision.v1.OperationMetadata.State state = 1; + */ + public com.google.cloud.vision.v1.OperationMetadata.State getState() { + com.google.cloud.vision.v1.OperationMetadata.State result = com.google.cloud.vision.v1.OperationMetadata.State.valueOf(state_); + return result == null ? com.google.cloud.vision.v1.OperationMetadata.State.UNRECOGNIZED : result; + } + + public static final int CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createTime_; + /** + *
+   * The time when the batch request was received.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + *
+   * The time when the batch request was received.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + *
+   * The time when the batch request was received.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp updateTime_; + /** + *
+   * The time when the operation result was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + *
+   * The time when the operation result was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + *
+   * The time when the operation result was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + if (state_ != com.google.cloud.vision.v1.OperationMetadata.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(1, state_); + } + if (createTime_ != null) { + output.writeMessage(5, getCreateTime()); + } + if (updateTime_ != null) { + output.writeMessage(6, getUpdateTime()); + } + unknownFields.writeTo(output); + } + + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (state_ != com.google.cloud.vision.v1.OperationMetadata.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream + .computeEnumSize(1, state_); + } + 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.vision.v1.OperationMetadata)) { + return super.equals(obj); + } + com.google.cloud.vision.v1.OperationMetadata other = (com.google.cloud.vision.v1.OperationMetadata) obj; + + boolean result = true; + result = result && state_ == other.state_; + result = result && (hasCreateTime() == other.hasCreateTime()); + if (hasCreateTime()) { + result = result && getCreateTime() + .equals(other.getCreateTime()); + } + result = result && (hasUpdateTime() == other.hasUpdateTime()); + if (hasUpdateTime()) { + result = result && getUpdateTime() + .equals(other.getUpdateTime()); + } + result = result && unknownFields.equals(other.unknownFields); + return result; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + if (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.vision.v1.OperationMetadata parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.OperationMetadata 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.vision.v1.OperationMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.OperationMetadata 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.vision.v1.OperationMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.OperationMetadata parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.google.cloud.vision.v1.OperationMetadata parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.OperationMetadata 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.vision.v1.OperationMetadata parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.OperationMetadata 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.vision.v1.OperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.OperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(com.google.cloud.vision.v1.OperationMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + 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; + } + /** + *
+   * Contains metadata for the BatchAnnotateImages operation.
+   * 
+ * + * Protobuf type {@code google.cloud.vision.v1.OperationMetadata} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.OperationMetadata) + com.google.cloud.vision.v1.OperationMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_OperationMetadata_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_OperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.OperationMetadata.class, com.google.cloud.vision.v1.OperationMetadata.Builder.class); + } + + // Construct using com.google.cloud.vision.v1.OperationMetadata.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + } + } + public Builder clear() { + super.clear(); + state_ = 0; + + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + return this; + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_OperationMetadata_descriptor; + } + + public com.google.cloud.vision.v1.OperationMetadata getDefaultInstanceForType() { + return com.google.cloud.vision.v1.OperationMetadata.getDefaultInstance(); + } + + public com.google.cloud.vision.v1.OperationMetadata build() { + com.google.cloud.vision.v1.OperationMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public com.google.cloud.vision.v1.OperationMetadata buildPartial() { + com.google.cloud.vision.v1.OperationMetadata result = new com.google.cloud.vision.v1.OperationMetadata(this); + result.state_ = state_; + 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; + } + + public Builder clone() { + return (Builder) super.clone(); + } + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.setField(field, value); + } + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return (Builder) super.clearField(field); + } + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return (Builder) super.clearOneof(oneof); + } + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, java.lang.Object value) { + return (Builder) super.setRepeatedField(field, index, value); + } + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.addRepeatedField(field, value); + } + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.vision.v1.OperationMetadata) { + return mergeFrom((com.google.cloud.vision.v1.OperationMetadata)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.vision.v1.OperationMetadata other) { + if (other == com.google.cloud.vision.v1.OperationMetadata.getDefaultInstance()) return this; + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + public final boolean isInitialized() { + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.vision.v1.OperationMetadata parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.cloud.vision.v1.OperationMetadata) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int state_ = 0; + /** + *
+     * Current state of the batch operation.
+     * 
+ * + * .google.cloud.vision.v1.OperationMetadata.State state = 1; + */ + public int getStateValue() { + return state_; + } + /** + *
+     * Current state of the batch operation.
+     * 
+ * + * .google.cloud.vision.v1.OperationMetadata.State state = 1; + */ + public Builder setStateValue(int value) { + state_ = value; + onChanged(); + return this; + } + /** + *
+     * Current state of the batch operation.
+     * 
+ * + * .google.cloud.vision.v1.OperationMetadata.State state = 1; + */ + public com.google.cloud.vision.v1.OperationMetadata.State getState() { + com.google.cloud.vision.v1.OperationMetadata.State result = com.google.cloud.vision.v1.OperationMetadata.State.valueOf(state_); + return result == null ? com.google.cloud.vision.v1.OperationMetadata.State.UNRECOGNIZED : result; + } + /** + *
+     * Current state of the batch operation.
+     * 
+ * + * .google.cloud.vision.v1.OperationMetadata.State state = 1; + */ + public Builder setState(com.google.cloud.vision.v1.OperationMetadata.State value) { + if (value == null) { + throw new NullPointerException(); + } + + state_ = value.getNumber(); + onChanged(); + return this; + } + /** + *
+     * Current state of the batch operation.
+     * 
+ * + * .google.cloud.vision.v1.OperationMetadata.State state = 1; + */ + public Builder clearState() { + + state_ = 0; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_ = null; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; + /** + *
+     * The time when the batch request was received.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + *
+     * The time when the batch request was received.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + /** + *
+     * The time when the batch request was received.
+     * 
+ * + * .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; + } + /** + *
+     * The time when the batch request was received.
+     * 
+ * + * .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; + } + /** + *
+     * The time when the batch request was received.
+     * 
+ * + * .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; + } + /** + *
+     * The time when the batch request was received.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + *
+     * The time when the batch request was received.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + *
+     * The time when the batch request was received.
+     * 
+ * + * .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_; + } + } + /** + *
+     * The time when the batch request was received.
+     * 
+ * + * .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_ = null; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> updateTimeBuilder_; + /** + *
+     * The time when the operation result was last updated.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + *
+     * The time when the operation result was last updated.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + /** + *
+     * The time when the operation result was last updated.
+     * 
+ * + * .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; + } + /** + *
+     * The time when the operation result was last updated.
+     * 
+ * + * .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; + } + /** + *
+     * The time when the operation result was last updated.
+     * 
+ * + * .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; + } + /** + *
+     * The time when the operation result was last updated.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + *
+     * The time when the operation result was last updated.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + *
+     * The time when the operation result was last updated.
+     * 
+ * + * .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_; + } + } + /** + *
+     * The time when the operation result was last updated.
+     * 
+ * + * .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_; + } + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFieldsProto3(unknownFields); + } + + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.OperationMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.OperationMetadata) + private static final com.google.cloud.vision.v1.OperationMetadata DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.OperationMetadata(); + } + + public static com.google.cloud.vision.v1.OperationMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public OperationMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new OperationMetadata(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + public com.google.cloud.vision.v1.OperationMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + +} + diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OperationMetadataOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OperationMetadataOrBuilder.java new file mode 100644 index 000000000000..a3bbf7700ff5 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OperationMetadataOrBuilder.java @@ -0,0 +1,76 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface OperationMetadataOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.OperationMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * Current state of the batch operation.
+   * 
+ * + * .google.cloud.vision.v1.OperationMetadata.State state = 1; + */ + int getStateValue(); + /** + *
+   * Current state of the batch operation.
+   * 
+ * + * .google.cloud.vision.v1.OperationMetadata.State state = 1; + */ + com.google.cloud.vision.v1.OperationMetadata.State getState(); + + /** + *
+   * The time when the batch request was received.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + boolean hasCreateTime(); + /** + *
+   * The time when the batch request was received.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + *
+   * The time when the batch request was received.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5; + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + *
+   * The time when the operation result was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + boolean hasUpdateTime(); + /** + *
+   * The time when the operation result was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + *
+   * The time when the operation result was last updated.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6; + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); +} diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OutputConfig.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OutputConfig.java new file mode 100644 index 000000000000..f6ace2e26a61 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OutputConfig.java @@ -0,0 +1,732 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +/** + *
+ * The desired output location and metadata.
+ * 
+ * + * Protobuf type {@code google.cloud.vision.v1.OutputConfig} + */ +public final class OutputConfig extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:google.cloud.vision.v1.OutputConfig) + OutputConfigOrBuilder { +private static final long serialVersionUID = 0L; + // Use OutputConfig.newBuilder() to construct. + private OutputConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private OutputConfig() { + batchSize_ = 0; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private OutputConfig( + 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; + default: { + if (!parseUnknownFieldProto3( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + case 10: { + com.google.cloud.vision.v1.GcsDestination.Builder subBuilder = null; + if (gcsDestination_ != null) { + subBuilder = gcsDestination_.toBuilder(); + } + gcsDestination_ = input.readMessage(com.google.cloud.vision.v1.GcsDestination.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(gcsDestination_); + gcsDestination_ = subBuilder.buildPartial(); + } + + break; + } + case 16: { + + batchSize_ = input.readInt32(); + 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.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_OutputConfig_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_OutputConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.OutputConfig.class, com.google.cloud.vision.v1.OutputConfig.Builder.class); + } + + public static final int GCS_DESTINATION_FIELD_NUMBER = 1; + private com.google.cloud.vision.v1.GcsDestination gcsDestination_; + /** + *
+   * The Google Cloud Storage location to write the output(s) to.
+   * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public boolean hasGcsDestination() { + return gcsDestination_ != null; + } + /** + *
+   * The Google Cloud Storage location to write the output(s) to.
+   * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public com.google.cloud.vision.v1.GcsDestination getGcsDestination() { + return gcsDestination_ == null ? com.google.cloud.vision.v1.GcsDestination.getDefaultInstance() : gcsDestination_; + } + /** + *
+   * The Google Cloud Storage location to write the output(s) to.
+   * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public com.google.cloud.vision.v1.GcsDestinationOrBuilder getGcsDestinationOrBuilder() { + return getGcsDestination(); + } + + public static final int BATCH_SIZE_FIELD_NUMBER = 2; + private int batchSize_; + /** + *
+   * The max number of response protos to put into each output JSON file on
+   * Google Cloud Storage.
+   * The valid range is [1, 100]. If not specified, the default value is 20.
+   * For example, for one pdf file with 100 pages, 100 response protos will
+   * be generated. If `batch_size` = 20, then 5 json files each
+   * containing 20 response protos will be written under the prefix
+   * `gcs_destination`.`uri`.
+   * Currently, batch_size only applies to GcsDestination, with potential future
+   * support for other output configurations.
+   * 
+ * + * int32 batch_size = 2; + */ + public int getBatchSize() { + return batchSize_; + } + + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + if (gcsDestination_ != null) { + output.writeMessage(1, getGcsDestination()); + } + if (batchSize_ != 0) { + output.writeInt32(2, batchSize_); + } + unknownFields.writeTo(output); + } + + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (gcsDestination_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, getGcsDestination()); + } + if (batchSize_ != 0) { + size += com.google.protobuf.CodedOutputStream + .computeInt32Size(2, batchSize_); + } + 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.vision.v1.OutputConfig)) { + return super.equals(obj); + } + com.google.cloud.vision.v1.OutputConfig other = (com.google.cloud.vision.v1.OutputConfig) obj; + + boolean result = true; + result = result && (hasGcsDestination() == other.hasGcsDestination()); + if (hasGcsDestination()) { + result = result && getGcsDestination() + .equals(other.getGcsDestination()); + } + result = result && (getBatchSize() + == other.getBatchSize()); + result = result && unknownFields.equals(other.unknownFields); + return result; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasGcsDestination()) { + hash = (37 * hash) + GCS_DESTINATION_FIELD_NUMBER; + hash = (53 * hash) + getGcsDestination().hashCode(); + } + hash = (37 * hash) + BATCH_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getBatchSize(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.vision.v1.OutputConfig parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.OutputConfig 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.vision.v1.OutputConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.OutputConfig 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.vision.v1.OutputConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static com.google.cloud.vision.v1.OutputConfig parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static com.google.cloud.vision.v1.OutputConfig parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.OutputConfig 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.vision.v1.OutputConfig parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.OutputConfig 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.vision.v1.OutputConfig parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static com.google.cloud.vision.v1.OutputConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(com.google.cloud.vision.v1.OutputConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + 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; + } + /** + *
+   * The desired output location and metadata.
+   * 
+ * + * Protobuf type {@code google.cloud.vision.v1.OutputConfig} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:google.cloud.vision.v1.OutputConfig) + com.google.cloud.vision.v1.OutputConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_OutputConfig_descriptor; + } + + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_OutputConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.vision.v1.OutputConfig.class, com.google.cloud.vision.v1.OutputConfig.Builder.class); + } + + // Construct using com.google.cloud.vision.v1.OutputConfig.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + } + } + public Builder clear() { + super.clear(); + if (gcsDestinationBuilder_ == null) { + gcsDestination_ = null; + } else { + gcsDestination_ = null; + gcsDestinationBuilder_ = null; + } + batchSize_ = 0; + + return this; + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return com.google.cloud.vision.v1.ImageAnnotatorProto.internal_static_google_cloud_vision_v1_OutputConfig_descriptor; + } + + public com.google.cloud.vision.v1.OutputConfig getDefaultInstanceForType() { + return com.google.cloud.vision.v1.OutputConfig.getDefaultInstance(); + } + + public com.google.cloud.vision.v1.OutputConfig build() { + com.google.cloud.vision.v1.OutputConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public com.google.cloud.vision.v1.OutputConfig buildPartial() { + com.google.cloud.vision.v1.OutputConfig result = new com.google.cloud.vision.v1.OutputConfig(this); + if (gcsDestinationBuilder_ == null) { + result.gcsDestination_ = gcsDestination_; + } else { + result.gcsDestination_ = gcsDestinationBuilder_.build(); + } + result.batchSize_ = batchSize_; + onBuilt(); + return result; + } + + public Builder clone() { + return (Builder) super.clone(); + } + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.setField(field, value); + } + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return (Builder) super.clearField(field); + } + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return (Builder) super.clearOneof(oneof); + } + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, java.lang.Object value) { + return (Builder) super.setRepeatedField(field, index, value); + } + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return (Builder) super.addRepeatedField(field, value); + } + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.vision.v1.OutputConfig) { + return mergeFrom((com.google.cloud.vision.v1.OutputConfig)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.vision.v1.OutputConfig other) { + if (other == com.google.cloud.vision.v1.OutputConfig.getDefaultInstance()) return this; + if (other.hasGcsDestination()) { + mergeGcsDestination(other.getGcsDestination()); + } + if (other.getBatchSize() != 0) { + setBatchSize(other.getBatchSize()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + public final boolean isInitialized() { + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.vision.v1.OutputConfig parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.cloud.vision.v1.OutputConfig) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.vision.v1.GcsDestination gcsDestination_ = null; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.GcsDestination, com.google.cloud.vision.v1.GcsDestination.Builder, com.google.cloud.vision.v1.GcsDestinationOrBuilder> gcsDestinationBuilder_; + /** + *
+     * The Google Cloud Storage location to write the output(s) to.
+     * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public boolean hasGcsDestination() { + return gcsDestinationBuilder_ != null || gcsDestination_ != null; + } + /** + *
+     * The Google Cloud Storage location to write the output(s) to.
+     * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public com.google.cloud.vision.v1.GcsDestination getGcsDestination() { + if (gcsDestinationBuilder_ == null) { + return gcsDestination_ == null ? com.google.cloud.vision.v1.GcsDestination.getDefaultInstance() : gcsDestination_; + } else { + return gcsDestinationBuilder_.getMessage(); + } + } + /** + *
+     * The Google Cloud Storage location to write the output(s) to.
+     * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public Builder setGcsDestination(com.google.cloud.vision.v1.GcsDestination value) { + if (gcsDestinationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + gcsDestination_ = value; + onChanged(); + } else { + gcsDestinationBuilder_.setMessage(value); + } + + return this; + } + /** + *
+     * The Google Cloud Storage location to write the output(s) to.
+     * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public Builder setGcsDestination( + com.google.cloud.vision.v1.GcsDestination.Builder builderForValue) { + if (gcsDestinationBuilder_ == null) { + gcsDestination_ = builderForValue.build(); + onChanged(); + } else { + gcsDestinationBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + *
+     * The Google Cloud Storage location to write the output(s) to.
+     * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public Builder mergeGcsDestination(com.google.cloud.vision.v1.GcsDestination value) { + if (gcsDestinationBuilder_ == null) { + if (gcsDestination_ != null) { + gcsDestination_ = + com.google.cloud.vision.v1.GcsDestination.newBuilder(gcsDestination_).mergeFrom(value).buildPartial(); + } else { + gcsDestination_ = value; + } + onChanged(); + } else { + gcsDestinationBuilder_.mergeFrom(value); + } + + return this; + } + /** + *
+     * The Google Cloud Storage location to write the output(s) to.
+     * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public Builder clearGcsDestination() { + if (gcsDestinationBuilder_ == null) { + gcsDestination_ = null; + onChanged(); + } else { + gcsDestination_ = null; + gcsDestinationBuilder_ = null; + } + + return this; + } + /** + *
+     * The Google Cloud Storage location to write the output(s) to.
+     * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public com.google.cloud.vision.v1.GcsDestination.Builder getGcsDestinationBuilder() { + + onChanged(); + return getGcsDestinationFieldBuilder().getBuilder(); + } + /** + *
+     * The Google Cloud Storage location to write the output(s) to.
+     * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + public com.google.cloud.vision.v1.GcsDestinationOrBuilder getGcsDestinationOrBuilder() { + if (gcsDestinationBuilder_ != null) { + return gcsDestinationBuilder_.getMessageOrBuilder(); + } else { + return gcsDestination_ == null ? + com.google.cloud.vision.v1.GcsDestination.getDefaultInstance() : gcsDestination_; + } + } + /** + *
+     * The Google Cloud Storage location to write the output(s) to.
+     * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.GcsDestination, com.google.cloud.vision.v1.GcsDestination.Builder, com.google.cloud.vision.v1.GcsDestinationOrBuilder> + getGcsDestinationFieldBuilder() { + if (gcsDestinationBuilder_ == null) { + gcsDestinationBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.vision.v1.GcsDestination, com.google.cloud.vision.v1.GcsDestination.Builder, com.google.cloud.vision.v1.GcsDestinationOrBuilder>( + getGcsDestination(), + getParentForChildren(), + isClean()); + gcsDestination_ = null; + } + return gcsDestinationBuilder_; + } + + private int batchSize_ ; + /** + *
+     * The max number of response protos to put into each output JSON file on
+     * Google Cloud Storage.
+     * The valid range is [1, 100]. If not specified, the default value is 20.
+     * For example, for one pdf file with 100 pages, 100 response protos will
+     * be generated. If `batch_size` = 20, then 5 json files each
+     * containing 20 response protos will be written under the prefix
+     * `gcs_destination`.`uri`.
+     * Currently, batch_size only applies to GcsDestination, with potential future
+     * support for other output configurations.
+     * 
+ * + * int32 batch_size = 2; + */ + public int getBatchSize() { + return batchSize_; + } + /** + *
+     * The max number of response protos to put into each output JSON file on
+     * Google Cloud Storage.
+     * The valid range is [1, 100]. If not specified, the default value is 20.
+     * For example, for one pdf file with 100 pages, 100 response protos will
+     * be generated. If `batch_size` = 20, then 5 json files each
+     * containing 20 response protos will be written under the prefix
+     * `gcs_destination`.`uri`.
+     * Currently, batch_size only applies to GcsDestination, with potential future
+     * support for other output configurations.
+     * 
+ * + * int32 batch_size = 2; + */ + public Builder setBatchSize(int value) { + + batchSize_ = value; + onChanged(); + return this; + } + /** + *
+     * The max number of response protos to put into each output JSON file on
+     * Google Cloud Storage.
+     * The valid range is [1, 100]. If not specified, the default value is 20.
+     * For example, for one pdf file with 100 pages, 100 response protos will
+     * be generated. If `batch_size` = 20, then 5 json files each
+     * containing 20 response protos will be written under the prefix
+     * `gcs_destination`.`uri`.
+     * Currently, batch_size only applies to GcsDestination, with potential future
+     * support for other output configurations.
+     * 
+ * + * int32 batch_size = 2; + */ + public Builder clearBatchSize() { + + batchSize_ = 0; + onChanged(); + return this; + } + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFieldsProto3(unknownFields); + } + + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + + // @@protoc_insertion_point(builder_scope:google.cloud.vision.v1.OutputConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.vision.v1.OutputConfig) + private static final com.google.cloud.vision.v1.OutputConfig DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new com.google.cloud.vision.v1.OutputConfig(); + } + + public static com.google.cloud.vision.v1.OutputConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + public OutputConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new OutputConfig(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + public com.google.cloud.vision.v1.OutputConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + +} + diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OutputConfigOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OutputConfigOrBuilder.java new file mode 100644 index 000000000000..b277bf822a99 --- /dev/null +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/OutputConfigOrBuilder.java @@ -0,0 +1,51 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/vision/v1/image_annotator.proto + +package com.google.cloud.vision.v1; + +public interface OutputConfigOrBuilder extends + // @@protoc_insertion_point(interface_extends:google.cloud.vision.v1.OutputConfig) + com.google.protobuf.MessageOrBuilder { + + /** + *
+   * The Google Cloud Storage location to write the output(s) to.
+   * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + boolean hasGcsDestination(); + /** + *
+   * The Google Cloud Storage location to write the output(s) to.
+   * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + com.google.cloud.vision.v1.GcsDestination getGcsDestination(); + /** + *
+   * The Google Cloud Storage location to write the output(s) to.
+   * 
+ * + * .google.cloud.vision.v1.GcsDestination gcs_destination = 1; + */ + com.google.cloud.vision.v1.GcsDestinationOrBuilder getGcsDestinationOrBuilder(); + + /** + *
+   * The max number of response protos to put into each output JSON file on
+   * Google Cloud Storage.
+   * The valid range is [1, 100]. If not specified, the default value is 20.
+   * For example, for one pdf file with 100 pages, 100 response protos will
+   * be generated. If `batch_size` = 20, then 5 json files each
+   * containing 20 response protos will be written under the prefix
+   * `gcs_destination`.`uri`.
+   * Currently, batch_size only applies to GcsDestination, with potential future
+   * support for other output configurations.
+   * 
+ * + * int32 batch_size = 2; + */ + int getBatchSize(); +} diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/Page.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/Page.java index de5c7ac3c5dc..582de7e24420 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/Page.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/Page.java @@ -159,7 +159,8 @@ public com.google.cloud.vision.v1.TextAnnotation.TextPropertyOrBuilder getProper private int width_; /** *
-   * Page width in pixels.
+   * Page width. For PDFs the unit is points. For images (including
+   * TIFFs) the unit is pixels.
    * 
* * int32 width = 2; @@ -172,7 +173,8 @@ public int getWidth() { private int height_; /** *
-   * Page height in pixels.
+   * Page height. For PDFs the unit is points. For images (including
+   * TIFFs) the unit is pixels.
    * 
* * int32 height = 3; @@ -818,7 +820,8 @@ public com.google.cloud.vision.v1.TextAnnotation.TextPropertyOrBuilder getProper private int width_ ; /** *
-     * Page width in pixels.
+     * Page width. For PDFs the unit is points. For images (including
+     * TIFFs) the unit is pixels.
      * 
* * int32 width = 2; @@ -828,7 +831,8 @@ public int getWidth() { } /** *
-     * Page width in pixels.
+     * Page width. For PDFs the unit is points. For images (including
+     * TIFFs) the unit is pixels.
      * 
* * int32 width = 2; @@ -841,7 +845,8 @@ public Builder setWidth(int value) { } /** *
-     * Page width in pixels.
+     * Page width. For PDFs the unit is points. For images (including
+     * TIFFs) the unit is pixels.
      * 
* * int32 width = 2; @@ -856,7 +861,8 @@ public Builder clearWidth() { private int height_ ; /** *
-     * Page height in pixels.
+     * Page height. For PDFs the unit is points. For images (including
+     * TIFFs) the unit is pixels.
      * 
* * int32 height = 3; @@ -866,7 +872,8 @@ public int getHeight() { } /** *
-     * Page height in pixels.
+     * Page height. For PDFs the unit is points. For images (including
+     * TIFFs) the unit is pixels.
      * 
* * int32 height = 3; @@ -879,7 +886,8 @@ public Builder setHeight(int value) { } /** *
-     * Page height in pixels.
+     * Page height. For PDFs the unit is points. For images (including
+     * TIFFs) the unit is pixels.
      * 
* * int32 height = 3; diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/PageOrBuilder.java b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/PageOrBuilder.java index b81ac9d3c65e..47b44e264bd9 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/PageOrBuilder.java +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/java/com/google/cloud/vision/v1/PageOrBuilder.java @@ -34,7 +34,8 @@ public interface PageOrBuilder extends /** *
-   * Page width in pixels.
+   * Page width. For PDFs the unit is points. For images (including
+   * TIFFs) the unit is pixels.
    * 
* * int32 width = 2; @@ -43,7 +44,8 @@ public interface PageOrBuilder extends /** *
-   * Page height in pixels.
+   * Page height. For PDFs the unit is points. For images (including
+   * TIFFs) the unit is pixels.
    * 
* * int32 height = 3; diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/geometry.proto b/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/geometry.proto index c1b35a940133..8470002875c3 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/geometry.proto +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/geometry.proto @@ -33,10 +33,24 @@ message Vertex { int32 y = 2; } +// A vertex represents a 2D point in the image. +// NOTE: the normalized vertex coordinates are relative to the original image +// and range from 0 to 1. +message NormalizedVertex { + // X coordinate. + float x = 1; + + // Y coordinate. + float y = 2; +}; + // A bounding polygon for the detected image annotation. message BoundingPoly { // The bounding polygon vertices. repeated Vertex vertices = 1; + + // The bounding polygon normalized vertices. + repeated NormalizedVertex normalized_vertices = 2; } // A 3D position in the image, used primarily for Face detection landmarks. diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/image_annotator.proto b/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/image_annotator.proto index 3978db04ebee..21db4c41e897 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/image_annotator.proto +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/image_annotator.proto @@ -20,6 +20,8 @@ import "google/api/annotations.proto"; import "google/cloud/vision/v1/geometry.proto"; import "google/cloud/vision/v1/text_annotation.proto"; import "google/cloud/vision/v1/web_detection.proto"; +import "google/longrunning/operations.proto"; +import "google/protobuf/timestamp.proto"; import "google/rpc/status.proto"; import "google/type/color.proto"; import "google/type/latlng.proto"; @@ -37,7 +39,24 @@ option java_package = "com.google.cloud.vision.v1"; service ImageAnnotator { // Run image detection and annotation for a batch of images. rpc BatchAnnotateImages(BatchAnnotateImagesRequest) returns (BatchAnnotateImagesResponse) { - option (google.api.http) = { post: "/v1/images:annotate" body: "*" }; + option (google.api.http) = { + post: "/v1/images:annotate" + body: "*" + }; + } + + // Run asynchronous image detection and annotation for a list of generic + // files, such as PDF files, which may contain multiple pages and multiple + // images per page. Progress and results can be retrieved through the + // `google.longrunning.Operations` interface. + // `Operation.metadata` contains `OperationMetadata` (metadata). + // `Operation.response` contains `AsyncBatchAnnotateFilesResponse` (results). + rpc AsyncBatchAnnotateFiles(AsyncBatchAnnotateFilesRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/files:asyncBatchAnnotate" + body: "*" + }; } } @@ -492,7 +511,7 @@ message WebDetectionParams { // Image context and/or feature-specific parameters. message ImageContext { - // lat/long rectangle that specifies the location of the image. + // Not used. LatLongRect lat_long_rect = 1; // List of languages to use for TEXT_DETECTION. In most cases, an empty value @@ -525,6 +544,17 @@ message AnnotateImageRequest { ImageContext image_context = 3; } +// If an image was produced from a file (e.g. a PDF), this message gives +// information about the source of that image. +message ImageAnnotationContext { + // The URI of the file used to produce the image. + string uri = 1; + + // If the file was a PDF or TIFF, this field gives the page number within + // the file used to produce the image. + int32 page_number = 2; +} + // Response to an image annotation request. message AnnotateImageResponse { // If present, face detection has completed successfully. @@ -564,6 +594,20 @@ message AnnotateImageResponse { // Note that filled-in image annotations are guaranteed to be // correct, even when `error` is set. google.rpc.Status error = 9; + + // If present, contextual information is needed to understand where this image + // comes from. + ImageAnnotationContext context = 21; +} + +// Response to a single file annotation request. A file may contain one or more +// images, which individually have their own responses. +message AnnotateFileResponse { + // Information about the file for which this response is generated. + InputConfig input_config = 1; + + // Individual responses to images found within the file. + repeated AnnotateImageResponse responses = 2; } // Multiple image annotation requests are batched into a single service call. @@ -578,6 +622,127 @@ message BatchAnnotateImagesResponse { repeated AnnotateImageResponse responses = 1; } +// An offline file annotation request. +message AsyncAnnotateFileRequest { + // Required. Information about the input file. + InputConfig input_config = 1; + + // Required. Requested features. + repeated Feature features = 2; + + // Additional context that may accompany the image(s) in the file. + ImageContext image_context = 3; + + // Required. The desired output location and metadata (e.g. format). + OutputConfig output_config = 4; +} + +// The response for a single offline file annotation request. +message AsyncAnnotateFileResponse { + // The output location and metadata from AsyncAnnotateFileRequest. + OutputConfig output_config = 1; +} + +// Multiple async file annotation requests are batched into a single service +// call. +message AsyncBatchAnnotateFilesRequest { + // Individual async file annotation requests for this batch. + repeated AsyncAnnotateFileRequest requests = 1; +} + +// Response to an async batch file annotation request. +message AsyncBatchAnnotateFilesResponse { + // The list of file annotation responses, one for each request in + // AsyncBatchAnnotateFilesRequest. + repeated AsyncAnnotateFileResponse responses = 1; +} + +// The desired input location and metadata. +message InputConfig { + // The Google Cloud Storage location to read the input from. + GcsSource gcs_source = 1; + + // The type of the file. Currently only "application/pdf" and "image/tiff" + // are supported. Wildcards are not supported. + string mime_type = 2; +} + +// The desired output location and metadata. +message OutputConfig { + // The Google Cloud Storage location to write the output(s) to. + GcsDestination gcs_destination = 1; + + // The max number of response protos to put into each output JSON file on + // Google Cloud Storage. + // The valid range is [1, 100]. If not specified, the default value is 20. + // + // For example, for one pdf file with 100 pages, 100 response protos will + // be generated. If `batch_size` = 20, then 5 json files each + // containing 20 response protos will be written under the prefix + // `gcs_destination`.`uri`. + // + // Currently, batch_size only applies to GcsDestination, with potential future + // support for other output configurations. + int32 batch_size = 2; +} + +// The Google Cloud Storage location where the input will be read from. +message GcsSource { + // Google Cloud Storage URI for the input file. This must only be a + // Google Cloud Storage object. Wildcards are not currently supported. + string uri = 1; +} + +// The Google Cloud Storage location where the output will be written to. +message GcsDestination { + // Google Cloud Storage URI where the results will be stored. Results will + // be in JSON format and preceded by its corresponding input URI. This field + // can either represent a single file, or a prefix for multiple outputs. + // Prefixes must end in a `/`. + // + // Examples: + // + // * File: gs://bucket-name/filename.json + // * Prefix: gs://bucket-name/prefix/here/ + // * File: gs://bucket-name/prefix/here + // + // If multiple outputs, each response is still AnnotateFileResponse, each of + // which contains some subset of the full list of AnnotateImageResponse. + // Multiple outputs can happen if, for example, the output JSON is too large + // and overflows into multiple sharded files. + string uri = 1; +} + +// Contains metadata for the BatchAnnotateImages operation. +message OperationMetadata { + // Batch operation states. + enum State { + // Invalid. + STATE_UNSPECIFIED = 0; + + // Request is received. + CREATED = 1; + + // Request is actively being processed. + RUNNING = 2; + + // The batch processing is done. + DONE = 3; + + // The batch processing was cancelled. + CANCELLED = 4; + } + + // Current state of the batch operation. + State state = 1; + + // The time when the batch request was received. + google.protobuf.Timestamp create_time = 5; + + // The time when the operation result was last updated. + google.protobuf.Timestamp update_time = 6; +} + // A bucketized representation of likelihood, which is intended to give clients // highly stable results across model upgrades. enum Likelihood { diff --git a/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/text_annotation.proto b/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/text_annotation.proto index bf825d59b5ad..714b57e17125 100644 --- a/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/text_annotation.proto +++ b/google-api-grpc/proto-google-cloud-vision-v1/src/main/proto/google/cloud/vision/v1/text_annotation.proto @@ -97,10 +97,12 @@ message Page { // Additional information detected on the page. TextAnnotation.TextProperty property = 1; - // Page width in pixels. + // Page width. For PDFs the unit is points. For images (including + // TIFFs) the unit is pixels. int32 width = 2; - // Page height in pixels. + // Page height. For PDFs the unit is points. For images (including + // TIFFs) the unit is pixels. int32 height = 3; // List of blocks of text, images etc on this page. diff --git a/google-api-grpc/proto-google-cloud-websecurityscanner-v1alpha/pom.xml b/google-api-grpc/proto-google-cloud-websecurityscanner-v1alpha/pom.xml index 6d21909cbe79..14661ebff117 100644 --- a/google-api-grpc/proto-google-cloud-websecurityscanner-v1alpha/pom.xml +++ b/google-api-grpc/proto-google-cloud-websecurityscanner-v1alpha/pom.xml @@ -28,4 +28,4 @@ compile - + \ No newline at end of file diff --git a/google-cloud-bom/pom.xml b/google-cloud-bom/pom.xml index 619d9479698e..b469435083c6 100644 --- a/google-cloud-bom/pom.xml +++ b/google-cloud-bom/pom.xml @@ -394,16 +394,6 @@ 0.47.1-beta-SNAPSHOT test-jar - - com.google.api.grpc - proto-google-cloud-dlp-v2beta1 - 0.12.1-SNAPSHOT - - - com.google.api.grpc - grpc-google-cloud-dlp-v2beta1 - 0.12.1-SNAPSHOT - com.google.api.grpc proto-google-cloud-dlp-v2 @@ -901,13 +891,13 @@ com.google.api.grpc - proto-google-cloud-cloudiot-v1 - 0.12.1-SNAPSHOT + proto-google-cloud-iot-v1 + 0.12.1-SNAPSHOT com.google.api.grpc - grpc-google-cloud-cloudiot-v1 - 0.12.1-SNAPSHOT + grpc-google-cloud-iot-v1 + 0.12.1-SNAPSHOT com.google.api.grpc diff --git a/google-cloud-clients/google-cloud-bigquerydatatransfer/src/main/java/com/google/cloud/bigquery/datatransfer/v1/stub/GrpcDataTransferServiceCallableFactory.java b/google-cloud-clients/google-cloud-bigquerydatatransfer/src/main/java/com/google/cloud/bigquery/datatransfer/v1/stub/GrpcDataTransferServiceCallableFactory.java index d1df3a741bfc..279f20a71d4f 100644 --- a/google-cloud-clients/google-cloud-bigquerydatatransfer/src/main/java/com/google/cloud/bigquery/datatransfer/v1/stub/GrpcDataTransferServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-bigquerydatatransfer/src/main/java/com/google/cloud/bigquery/datatransfer/v1/stub/GrpcDataTransferServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableInstanceAdminClient.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableInstanceAdminClient.java index 4c4b3c400999..e50a09b1c0be 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableInstanceAdminClient.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableInstanceAdminClient.java @@ -203,6 +203,8 @@ public BigtableInstanceAdminStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -234,6 +236,8 @@ public final OperationsClient getOperationsClient() { * must be left blank. Currently exactly one cluster must be specified. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createInstanceAsync( ProjectName parent, String instanceId, Instance instance, Map clusters) { @@ -274,6 +278,8 @@ public final OperationFuture createInstanceAsy * must be left blank. Currently exactly one cluster must be specified. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createInstanceAsync( String parent, String instanceId, Instance instance, Map clusters) { @@ -312,6 +318,8 @@ public final OperationFuture createInstanceAsy * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createInstanceAsync( CreateInstanceRequest request) { return createInstanceOperationCallable().futureCall(request); @@ -341,6 +349,7 @@ public final OperationFuture createInstanceAsy * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable createInstanceOperationCallable() { return stub.createInstanceOperationCallable(); @@ -579,6 +588,8 @@ public final UnaryCallable listInst * set. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture partialUpdateInstanceAsync( Instance instance, FieldMask updateMask) { @@ -611,6 +622,8 @@ public final OperationFuture partialUpdateInst * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture partialUpdateInstanceAsync( PartialUpdateInstanceRequest request) { return partialUpdateInstanceOperationCallable().futureCall(request); @@ -636,6 +649,7 @@ public final OperationFuture partialUpdateInst * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable partialUpdateInstanceOperationCallable() { return stub.partialUpdateInstanceOperationCallable(); @@ -780,6 +794,8 @@ public final UnaryCallable deleteInstanceCallable( * @param cluster The cluster to be created. Fields marked `OutputOnly` must be left blank. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createClusterAsync( InstanceName parent, String clusterId, Cluster cluster) { @@ -814,6 +830,8 @@ public final OperationFuture createClusterAsync( * @param cluster The cluster to be created. Fields marked `OutputOnly` must be left blank. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createClusterAsync( String parent, String clusterId, Cluster cluster) { @@ -849,6 +867,8 @@ public final OperationFuture createClusterAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createClusterAsync( CreateClusterRequest request) { return createClusterOperationCallable().futureCall(request); @@ -876,6 +896,7 @@ public final OperationFuture createClusterAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable createClusterOperationCallable() { return stub.createClusterOperationCallable(); @@ -1120,6 +1141,8 @@ public final UnaryCallable listCluste * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateClusterAsync(Cluster request) { return updateClusterOperationCallable().futureCall(request); } @@ -1146,6 +1169,7 @@ public final OperationFuture updateClusterAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable updateClusterOperationCallable() { return stub.updateClusterOperationCallable(); @@ -1706,6 +1730,8 @@ public final ListAppProfilesPagedResponse listAppProfiles(ListAppProfilesRequest * fields will be replaced. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateAppProfileAsync( AppProfile appProfile, FieldMask updateMask) { @@ -1743,6 +1769,8 @@ public final OperationFuture updateAppProf * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateAppProfileAsync( UpdateAppProfileRequest request) { return updateAppProfileOperationCallable().futureCall(request); @@ -1773,6 +1801,7 @@ public final OperationFuture updateAppProf * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable updateAppProfileOperationCallable() { return stub.updateAppProfileOperationCallable(); diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableInstanceAdminSettings.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableInstanceAdminSettings.java index 54463a4ecafd..be3c9e201fc9 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableInstanceAdminSettings.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableInstanceAdminSettings.java @@ -101,6 +101,8 @@ public UnaryCallSettings createInstanceSetting } /** Returns the object with the settings used for calls to createInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings createInstanceOperationSettings() { return ((BigtableInstanceAdminStubSettings) getStubSettings()) @@ -124,6 +126,8 @@ public UnaryCallSettings listInstan } /** Returns the object with the settings used for calls to partialUpdateInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings partialUpdateInstanceOperationSettings() { return ((BigtableInstanceAdminStubSettings) getStubSettings()) @@ -141,6 +145,8 @@ public UnaryCallSettings createClusterSettings( } /** Returns the object with the settings used for calls to createCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings createClusterOperationSettings() { return ((BigtableInstanceAdminStubSettings) getStubSettings()).createClusterOperationSettings(); @@ -162,6 +168,8 @@ public UnaryCallSettings updateClusterSettings() { } /** Returns the object with the settings used for calls to updateCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings updateClusterOperationSettings() { return ((BigtableInstanceAdminStubSettings) getStubSettings()).updateClusterOperationSettings(); @@ -195,6 +203,8 @@ public UnaryCallSettings updateAppProfileSet } /** Returns the object with the settings used for calls to updateAppProfile. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings updateAppProfileOperationSettings() { return ((BigtableInstanceAdminStubSettings) getStubSettings()) @@ -326,6 +336,8 @@ public UnaryCallSettings.Builder createInstanc } /** Returns the builder for the settings used for calls to createInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder createInstanceOperationSettings() { return getStubSettingsBuilder().createInstanceOperationSettings(); @@ -349,6 +361,8 @@ public UnaryCallSettings.Builder getInstanceSettin } /** Returns the builder for the settings used for calls to partialUpdateInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< PartialUpdateInstanceRequest, Instance, UpdateInstanceMetadata> partialUpdateInstanceOperationSettings() { @@ -366,6 +380,8 @@ public UnaryCallSettings.Builder createClusterS } /** Returns the builder for the settings used for calls to createCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder createClusterOperationSettings() { return getStubSettingsBuilder().createClusterOperationSettings(); @@ -388,6 +404,8 @@ public UnaryCallSettings.Builder updateClusterSettings() { } /** Returns the builder for the settings used for calls to updateCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder updateClusterOperationSettings() { return getStubSettingsBuilder().updateClusterOperationSettings(); @@ -423,6 +441,8 @@ public UnaryCallSettings.Builder getAppProfile } /** Returns the builder for the settings used for calls to updateAppProfile. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< UpdateAppProfileRequest, AppProfile, UpdateAppProfileMetadata> updateAppProfileOperationSettings() { diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminClient.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminClient.java index 13723c290e5c..07fac64c4f88 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminClient.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminClient.java @@ -195,6 +195,8 @@ public BigtableTableAdminStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -352,6 +354,8 @@ public final UnaryCallable createTableCallable() { * `projects/<project>/instances/<instance>/clusters/<cluster>/snapshots/<snapshot>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createTableFromSnapshotAsync( InstanceName parent, String tableId, SnapshotName sourceSnapshot) { @@ -394,6 +398,8 @@ public final OperationFuture createTable * `projects/<project>/instances/<instance>/clusters/<cluster>/snapshots/<snapshot>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createTableFromSnapshotAsync( String parent, String tableId, String sourceSnapshot) { @@ -435,6 +441,8 @@ public final OperationFuture createTable * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createTableFromSnapshotAsync( CreateTableFromSnapshotRequest request) { return createTableFromSnapshotOperationCallable().futureCall(request); @@ -468,6 +476,7 @@ public final OperationFuture createTable * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable< CreateTableFromSnapshotRequest, Table, CreateTableFromSnapshotMetadata> createTableFromSnapshotOperationCallable() { @@ -1277,6 +1286,8 @@ public final CheckConsistencyResponse checkConsistency(CheckConsistencyRequest r * @param description Description of the snapshot. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture snapshotTableAsync( TableName name, ClusterName cluster, SnapshotName snapshotId, String description) { @@ -1322,6 +1333,8 @@ public final OperationFuture snapshotTableAsync * @param description Description of the snapshot. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture snapshotTableAsync( String name, String cluster, String snapshotId, String description) { @@ -1366,6 +1379,8 @@ public final OperationFuture snapshotTableAsync * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture snapshotTableAsync( SnapshotTableRequest request) { return snapshotTableOperationCallable().futureCall(request); @@ -1401,6 +1416,7 @@ public final OperationFuture snapshotTableAsync * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable snapshotTableOperationCallable() { return stub.snapshotTableOperationCallable(); diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettings.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettings.java index 549efc4fd9a4..ef3e2f867530 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettings.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettings.java @@ -99,6 +99,8 @@ public UnaryCallSettings createTableSettings() { } /** Returns the object with the settings used for calls to createTableFromSnapshot. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings< CreateTableFromSnapshotRequest, Table, CreateTableFromSnapshotMetadata> createTableFromSnapshotOperationSettings() { @@ -150,6 +152,8 @@ public UnaryCallSettings snapshotTableSettings( } /** Returns the object with the settings used for calls to snapshotTable. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings snapshotTableOperationSettings() { return ((BigtableTableAdminStubSettings) getStubSettings()).snapshotTableOperationSettings(); @@ -280,6 +284,8 @@ public UnaryCallSettings.Builder createTableSettings( } /** Returns the builder for the settings used for calls to createTableFromSnapshot. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< CreateTableFromSnapshotRequest, Table, CreateTableFromSnapshotMetadata> createTableFromSnapshotOperationSettings() { @@ -332,6 +338,8 @@ public UnaryCallSettings.Builder snapshotTableS } /** Returns the builder for the settings used for calls to snapshotTable. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder snapshotTableOperationSettings() { return getStubSettingsBuilder().snapshotTableOperationSettings(); diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStub.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStub.java index 473c4624e22d..aaccdb4d5045 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStub.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStub.java @@ -66,10 +66,12 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class BigtableInstanceAdminStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createInstanceOperationCallable() { throw new UnsupportedOperationException("Not implemented: createInstanceOperationCallable()"); @@ -87,6 +89,7 @@ public UnaryCallable listInstancesC throw new UnsupportedOperationException("Not implemented: listInstancesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable partialUpdateInstanceOperationCallable() { throw new UnsupportedOperationException( @@ -101,6 +104,7 @@ public UnaryCallable deleteInstanceCallable() { throw new UnsupportedOperationException("Not implemented: deleteInstanceCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createClusterOperationCallable() { throw new UnsupportedOperationException("Not implemented: createClusterOperationCallable()"); @@ -118,6 +122,7 @@ public UnaryCallable listClustersCall throw new UnsupportedOperationException("Not implemented: listClustersCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateClusterOperationCallable() { throw new UnsupportedOperationException("Not implemented: updateClusterOperationCallable()"); @@ -148,6 +153,7 @@ public UnaryCallable listAppPro throw new UnsupportedOperationException("Not implemented: listAppProfilesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateAppProfileOperationCallable() { throw new UnsupportedOperationException("Not implemented: updateAppProfileOperationCallable()"); diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStubSettings.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStubSettings.java index 91970f6cf56b..c24aa6a73ea8 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStubSettings.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStubSettings.java @@ -169,6 +169,7 @@ public UnaryCallSettings createInstanceSetting } /** Returns the object with the settings used for calls to createInstance. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings createInstanceOperationSettings() { return createInstanceOperationSettings; @@ -191,6 +192,7 @@ public UnaryCallSettings listInstan } /** Returns the object with the settings used for calls to partialUpdateInstance. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings partialUpdateInstanceOperationSettings() { return partialUpdateInstanceOperationSettings; @@ -207,6 +209,7 @@ public UnaryCallSettings createClusterSettings( } /** Returns the object with the settings used for calls to createCluster. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings createClusterOperationSettings() { return createClusterOperationSettings; @@ -228,6 +231,7 @@ public UnaryCallSettings updateClusterSettings() { } /** Returns the object with the settings used for calls to updateCluster. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings updateClusterOperationSettings() { return updateClusterOperationSettings; @@ -261,6 +265,7 @@ public UnaryCallSettings updateAppProfileSet } /** Returns the object with the settings used for calls to updateAppProfile. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings updateAppProfileOperationSettings() { return updateAppProfileOperationSettings; @@ -888,6 +893,8 @@ public UnaryCallSettings.Builder createInstanc } /** Returns the builder for the settings used for calls to createInstance. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder createInstanceOperationSettings() { return createInstanceOperationSettings; @@ -911,6 +918,8 @@ public UnaryCallSettings.Builder getInstanceSettin } /** Returns the builder for the settings used for calls to partialUpdateInstance. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< PartialUpdateInstanceRequest, Instance, UpdateInstanceMetadata> partialUpdateInstanceOperationSettings() { @@ -928,6 +937,8 @@ public UnaryCallSettings.Builder createClusterS } /** Returns the builder for the settings used for calls to createCluster. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder createClusterOperationSettings() { return createClusterOperationSettings; @@ -950,6 +961,8 @@ public UnaryCallSettings.Builder updateClusterSettings() { } /** Returns the builder for the settings used for calls to updateCluster. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder updateClusterOperationSettings() { return updateClusterOperationSettings; @@ -985,6 +998,8 @@ public UnaryCallSettings.Builder getAppProfile } /** Returns the builder for the settings used for calls to updateAppProfile. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< UpdateAppProfileRequest, AppProfile, UpdateAppProfileMetadata> updateAppProfileOperationSettings() { diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStub.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStub.java index fb77fa19a55f..f1a4d26078e4 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStub.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStub.java @@ -58,6 +58,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class BigtableTableAdminStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -66,6 +67,7 @@ public UnaryCallable createTableCallable() { throw new UnsupportedOperationException("Not implemented: createTableCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createTableFromSnapshotOperationCallable() { throw new UnsupportedOperationException( @@ -111,6 +113,7 @@ public UnaryCallable dropRowRangeCallable() { throw new UnsupportedOperationException("Not implemented: checkConsistencyCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable snapshotTableOperationCallable() { throw new UnsupportedOperationException("Not implemented: snapshotTableOperationCallable()"); diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStubSettings.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStubSettings.java index b8450494aa27..1713def0773c 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStubSettings.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStubSettings.java @@ -156,6 +156,7 @@ public UnaryCallSettings createTableSettings() { } /** Returns the object with the settings used for calls to createTableFromSnapshot. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings< CreateTableFromSnapshotRequest, Table, CreateTableFromSnapshotMetadata> createTableFromSnapshotOperationSettings() { @@ -206,6 +207,7 @@ public UnaryCallSettings snapshotTableSettings( } /** Returns the object with the settings used for calls to snapshotTable. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings snapshotTableOperationSettings() { return snapshotTableOperationSettings; @@ -754,6 +756,8 @@ public UnaryCallSettings.Builder createTableSettings( } /** Returns the builder for the settings used for calls to createTableFromSnapshot. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< CreateTableFromSnapshotRequest, Table, CreateTableFromSnapshotMetadata> createTableFromSnapshotOperationSettings() { @@ -806,6 +810,8 @@ public UnaryCallSettings.Builder snapshotTableS } /** Returns the builder for the settings used for calls to snapshotTable. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder snapshotTableOperationSettings() { return snapshotTableOperationSettings; diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableInstanceAdminCallableFactory.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableInstanceAdminCallableFactory.java index 6ab24bfc5469..db114a739fdf 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableInstanceAdminCallableFactory.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableInstanceAdminCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableInstanceAdminStub.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableInstanceAdminStub.java index d522df2fff3f..82c29c13b08e 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableInstanceAdminStub.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableInstanceAdminStub.java @@ -647,10 +647,12 @@ public Map extract(TestIamPermissionsRequest request) { backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createInstanceOperationCallable() { return createInstanceOperationCallable; @@ -668,6 +670,7 @@ public UnaryCallable listInstancesC return listInstancesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable partialUpdateInstanceOperationCallable() { return partialUpdateInstanceOperationCallable; @@ -681,6 +684,7 @@ public UnaryCallable deleteInstanceCallable() { return deleteInstanceCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createClusterOperationCallable() { return createClusterOperationCallable; @@ -698,6 +702,7 @@ public UnaryCallable listClustersCall return listClustersCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateClusterOperationCallable() { return updateClusterOperationCallable; @@ -728,6 +733,7 @@ public UnaryCallable listAppPro return listAppProfilesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateAppProfileOperationCallable() { return updateAppProfileOperationCallable; diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminCallableFactory.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminCallableFactory.java index 95f4eb2ff199..909ef138a617 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminCallableFactory.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminStub.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminStub.java index 233c7d453aea..8313842143d6 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminStub.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminStub.java @@ -494,6 +494,7 @@ public Map extract(DeleteSnapshotRequest request) { backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -502,6 +503,7 @@ public UnaryCallable createTableCallable() { return createTableCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createTableFromSnapshotOperationCallable() { return createTableFromSnapshotOperationCallable; @@ -546,6 +548,7 @@ public UnaryCallable dropRowRangeCallable() { return checkConsistencyCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable snapshotTableOperationCallable() { return snapshotTableOperationCallable; diff --git a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/GrpcBigtableCallableFactory.java b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/GrpcBigtableCallableFactory.java index 1940ec35ae00..3ca32d14cb25 100644 --- a/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/GrpcBigtableCallableFactory.java +++ b/google-cloud-clients/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/GrpcBigtableCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-container/src/main/java/com/google/cloud/container/v1/stub/GrpcClusterManagerCallableFactory.java b/google-cloud-clients/google-cloud-container/src/main/java/com/google/cloud/container/v1/stub/GrpcClusterManagerCallableFactory.java index 24408ba65a92..8196e08725cc 100644 --- a/google-cloud-clients/google-cloud-container/src/main/java/com/google/cloud/container/v1/stub/GrpcClusterManagerCallableFactory.java +++ b/google-cloud-clients/google-cloud-container/src/main/java/com/google/cloud/container/v1/stub/GrpcClusterManagerCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/ClusterControllerClient.java b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/ClusterControllerClient.java index a4a59275800a..6557032e4c05 100644 --- a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/ClusterControllerClient.java +++ b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/ClusterControllerClient.java @@ -168,6 +168,8 @@ public ClusterControllerStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -193,6 +195,8 @@ public final OperationsClient getOperationsClient() { * @param cluster Required. The cluster to create. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createClusterAsync( String projectId, String region, Cluster cluster) { @@ -228,6 +232,8 @@ public final OperationFuture createClusterAsy * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createClusterAsync( CreateClusterRequest request) { return createClusterOperationCallable().futureCall(request); @@ -255,6 +261,7 @@ public final OperationFuture createClusterAsy * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable createClusterOperationCallable() { return stub.createClusterOperationCallable(); @@ -313,6 +320,8 @@ public final UnaryCallable createClusterCallabl * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateClusterAsync( UpdateClusterRequest request) { return updateClusterOperationCallable().futureCall(request); @@ -344,6 +353,7 @@ public final OperationFuture updateClusterAsy * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable updateClusterOperationCallable() { return stub.updateClusterOperationCallable(); @@ -400,6 +410,8 @@ public final UnaryCallable updateClusterCallabl * @param clusterName Required. The cluster name. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture deleteClusterAsync( String projectId, String region, String clusterName) { @@ -435,6 +447,8 @@ public final OperationFuture deleteClusterAsync * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture deleteClusterAsync( DeleteClusterRequest request) { return deleteClusterOperationCallable().futureCall(request); @@ -462,6 +476,7 @@ public final OperationFuture deleteClusterAsync * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable deleteClusterOperationCallable() { return stub.deleteClusterOperationCallable(); @@ -714,6 +729,8 @@ public final UnaryCallable listCluste * @param clusterName Required. The cluster name. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture diagnoseClusterAsync( String projectId, String region, String clusterName) { @@ -750,6 +767,8 @@ public final OperationFuture diagnoseClusterAsync * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture diagnoseClusterAsync( DiagnoseClusterRequest request) { return diagnoseClusterOperationCallable().futureCall(request); @@ -778,6 +797,7 @@ public final OperationFuture diagnoseClusterAsync * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable diagnoseClusterOperationCallable() { return stub.diagnoseClusterOperationCallable(); diff --git a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/ClusterControllerSettings.java b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/ClusterControllerSettings.java index 3b6e7ec6cce8..da346afa0a14 100644 --- a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/ClusterControllerSettings.java +++ b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/ClusterControllerSettings.java @@ -71,6 +71,8 @@ public UnaryCallSettings createClusterSettings( } /** Returns the object with the settings used for calls to createCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings createClusterOperationSettings() { return ((ClusterControllerStubSettings) getStubSettings()).createClusterOperationSettings(); @@ -82,6 +84,8 @@ public UnaryCallSettings updateClusterSettings( } /** Returns the object with the settings used for calls to updateCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings updateClusterOperationSettings() { return ((ClusterControllerStubSettings) getStubSettings()).updateClusterOperationSettings(); @@ -93,6 +97,8 @@ public UnaryCallSettings deleteClusterSettings( } /** Returns the object with the settings used for calls to deleteCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings deleteClusterOperationSettings() { return ((ClusterControllerStubSettings) getStubSettings()).deleteClusterOperationSettings(); @@ -115,6 +121,8 @@ public UnaryCallSettings diagnoseClusterSetti } /** Returns the object with the settings used for calls to diagnoseCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings diagnoseClusterOperationSettings() { return ((ClusterControllerStubSettings) getStubSettings()).diagnoseClusterOperationSettings(); @@ -223,6 +231,8 @@ public UnaryCallSettings.Builder createClusterS } /** Returns the builder for the settings used for calls to createCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder createClusterOperationSettings() { return getStubSettingsBuilder().createClusterOperationSettings(); @@ -234,6 +244,8 @@ public UnaryCallSettings.Builder updateClusterS } /** Returns the builder for the settings used for calls to updateCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder updateClusterOperationSettings() { return getStubSettingsBuilder().updateClusterOperationSettings(); @@ -245,6 +257,8 @@ public UnaryCallSettings.Builder deleteClusterS } /** Returns the builder for the settings used for calls to deleteCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder deleteClusterOperationSettings() { return getStubSettingsBuilder().deleteClusterOperationSettings(); @@ -268,6 +282,8 @@ public UnaryCallSettings.Builder diagnoseClus } /** Returns the builder for the settings used for calls to diagnoseCluster. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder diagnoseClusterOperationSettings() { return getStubSettingsBuilder().diagnoseClusterOperationSettings(); diff --git a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/ClusterControllerStub.java b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/ClusterControllerStub.java index 59e3c9f72187..b50c37666113 100644 --- a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/ClusterControllerStub.java +++ b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/ClusterControllerStub.java @@ -46,10 +46,12 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class ClusterControllerStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createClusterOperationCallable() { throw new UnsupportedOperationException("Not implemented: createClusterOperationCallable()"); @@ -59,6 +61,7 @@ public UnaryCallable createClusterCallable() { throw new UnsupportedOperationException("Not implemented: createClusterCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateClusterOperationCallable() { throw new UnsupportedOperationException("Not implemented: updateClusterOperationCallable()"); @@ -68,6 +71,7 @@ public UnaryCallable updateClusterCallable() { throw new UnsupportedOperationException("Not implemented: updateClusterCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable deleteClusterOperationCallable() { throw new UnsupportedOperationException("Not implemented: deleteClusterOperationCallable()"); @@ -89,6 +93,7 @@ public UnaryCallable listClustersCall throw new UnsupportedOperationException("Not implemented: listClustersCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable diagnoseClusterOperationCallable() { throw new UnsupportedOperationException("Not implemented: diagnoseClusterOperationCallable()"); diff --git a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/ClusterControllerStubSettings.java b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/ClusterControllerStubSettings.java index 1a67a5c9dfbe..85b2d5e65b39 100644 --- a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/ClusterControllerStubSettings.java +++ b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/ClusterControllerStubSettings.java @@ -120,6 +120,7 @@ public UnaryCallSettings createClusterSettings( } /** Returns the object with the settings used for calls to createCluster. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings createClusterOperationSettings() { return createClusterOperationSettings; @@ -131,6 +132,7 @@ public UnaryCallSettings updateClusterSettings( } /** Returns the object with the settings used for calls to updateCluster. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings updateClusterOperationSettings() { return updateClusterOperationSettings; @@ -142,6 +144,7 @@ public UnaryCallSettings deleteClusterSettings( } /** Returns the object with the settings used for calls to deleteCluster. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings deleteClusterOperationSettings() { return deleteClusterOperationSettings; @@ -164,6 +167,7 @@ public UnaryCallSettings diagnoseClusterSetti } /** Returns the object with the settings used for calls to diagnoseCluster. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings diagnoseClusterOperationSettings() { return diagnoseClusterOperationSettings; @@ -581,6 +585,8 @@ public UnaryCallSettings.Builder createClusterS } /** Returns the builder for the settings used for calls to createCluster. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder createClusterOperationSettings() { return createClusterOperationSettings; @@ -592,6 +598,8 @@ public UnaryCallSettings.Builder updateClusterS } /** Returns the builder for the settings used for calls to updateCluster. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder updateClusterOperationSettings() { return updateClusterOperationSettings; @@ -603,6 +611,8 @@ public UnaryCallSettings.Builder deleteClusterS } /** Returns the builder for the settings used for calls to deleteCluster. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder deleteClusterOperationSettings() { return deleteClusterOperationSettings; @@ -626,6 +636,8 @@ public UnaryCallSettings.Builder diagnoseClus } /** Returns the builder for the settings used for calls to diagnoseCluster. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder diagnoseClusterOperationSettings() { return diagnoseClusterOperationSettings; diff --git a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcClusterControllerCallableFactory.java b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcClusterControllerCallableFactory.java index 083602d293db..7f395b7574bf 100644 --- a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcClusterControllerCallableFactory.java +++ b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcClusterControllerCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcClusterControllerStub.java b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcClusterControllerStub.java index 3776d2a67920..8096ad9d00c4 100644 --- a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcClusterControllerStub.java +++ b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcClusterControllerStub.java @@ -243,10 +243,12 @@ protected GrpcClusterControllerStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createClusterOperationCallable() { return createClusterOperationCallable; @@ -256,6 +258,7 @@ public UnaryCallable createClusterCallable() { return createClusterCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateClusterOperationCallable() { return updateClusterOperationCallable; @@ -265,6 +268,7 @@ public UnaryCallable updateClusterCallable() { return updateClusterCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable deleteClusterOperationCallable() { return deleteClusterOperationCallable; @@ -286,6 +290,7 @@ public UnaryCallable listClustersCall return listClustersCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable diagnoseClusterOperationCallable() { return diagnoseClusterOperationCallable; diff --git a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcJobControllerCallableFactory.java b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcJobControllerCallableFactory.java index d3de83649fb8..824370dc9aaf 100644 --- a/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcJobControllerCallableFactory.java +++ b/google-cloud-clients/google-cloud-dataproc/src/main/java/com/google/cloud/dataproc/v1/stub/GrpcJobControllerCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/AgentsClient.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/AgentsClient.java index 81f30e7a0999..a4b7270dbfe9 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/AgentsClient.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/AgentsClient.java @@ -185,6 +185,8 @@ public AgentsStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -458,6 +460,8 @@ public final UnaryCallable searchAgen * `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture trainAgentAsync(ProjectName parent) { TrainAgentRequest request = @@ -485,6 +489,8 @@ public final OperationFuture trainAgentAsync(ProjectName parent) * `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture trainAgentAsync(String parent) { TrainAgentRequest request = TrainAgentRequest.newBuilder().setParent(parent).build(); @@ -513,6 +519,8 @@ public final OperationFuture trainAgentAsync(String parent) { * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") private final OperationFuture trainAgentAsync(TrainAgentRequest request) { return trainAgentOperationCallable().futureCall(request); } @@ -538,6 +546,7 @@ private final OperationFuture trainAgentAsync(TrainAgentRequest r * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable trainAgentOperationCallable() { return stub.trainAgentOperationCallable(); } @@ -588,6 +597,8 @@ public final UnaryCallable trainAgentCallable() { * `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture exportAgentAsync(ProjectName parent) { ExportAgentRequest request = @@ -618,6 +629,8 @@ public final OperationFuture exportAgentAsync(Proje * `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture exportAgentAsync(String parent) { ExportAgentRequest request = ExportAgentRequest.newBuilder().setParent(parent).build(); @@ -647,6 +660,8 @@ public final OperationFuture exportAgentAsync(Strin * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture exportAgentAsync( ExportAgentRequest request) { return exportAgentOperationCallable().futureCall(request); @@ -674,6 +689,7 @@ public final OperationFuture exportAgentAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable exportAgentOperationCallable() { return stub.exportAgentOperationCallable(); @@ -730,6 +746,8 @@ public final UnaryCallable exportAgentCallable() * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture importAgentAsync(ImportAgentRequest request) { return importAgentOperationCallable().futureCall(request); } @@ -758,6 +776,7 @@ public final OperationFuture importAgentAsync(ImportAgentRequest * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable importAgentOperationCallable() { return stub.importAgentOperationCallable(); } @@ -815,6 +834,8 @@ public final UnaryCallable importAgentCallable() * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture restoreAgentAsync(RestoreAgentRequest request) { return restoreAgentOperationCallable().futureCall(request); } @@ -843,6 +864,7 @@ public final OperationFuture restoreAgentAsync(RestoreAgentReques * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable restoreAgentOperationCallable() { return stub.restoreAgentOperationCallable(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/AgentsSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/AgentsSettings.java index e8bbd8545218..fbcaedbdf6d8 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/AgentsSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/AgentsSettings.java @@ -83,6 +83,8 @@ public UnaryCallSettings trainAgentSettings() { } /** Returns the object with the settings used for calls to trainAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings trainAgentOperationSettings() { return ((AgentsStubSettings) getStubSettings()).trainAgentOperationSettings(); } @@ -93,6 +95,8 @@ public UnaryCallSettings exportAgentSettings() { } /** Returns the object with the settings used for calls to exportAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings exportAgentOperationSettings() { return ((AgentsStubSettings) getStubSettings()).exportAgentOperationSettings(); @@ -104,6 +108,8 @@ public UnaryCallSettings importAgentSettings() { } /** Returns the object with the settings used for calls to importAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings importAgentOperationSettings() { return ((AgentsStubSettings) getStubSettings()).importAgentOperationSettings(); } @@ -114,6 +120,8 @@ public UnaryCallSettings restoreAgentSettings() } /** Returns the object with the settings used for calls to restoreAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings restoreAgentOperationSettings() { return ((AgentsStubSettings) getStubSettings()).restoreAgentOperationSettings(); } @@ -232,6 +240,8 @@ public UnaryCallSettings.Builder trainAgentSetting } /** Returns the builder for the settings used for calls to trainAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder trainAgentOperationSettings() { return getStubSettingsBuilder().trainAgentOperationSettings(); @@ -243,6 +253,8 @@ public UnaryCallSettings.Builder exportAgentSetti } /** Returns the builder for the settings used for calls to exportAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder exportAgentOperationSettings() { return getStubSettingsBuilder().exportAgentOperationSettings(); @@ -254,6 +266,8 @@ public UnaryCallSettings.Builder importAgentSetti } /** Returns the builder for the settings used for calls to importAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder importAgentOperationSettings() { return getStubSettingsBuilder().importAgentOperationSettings(); @@ -265,6 +279,8 @@ public UnaryCallSettings.Builder restoreAgentSet } /** Returns the builder for the settings used for calls to restoreAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder restoreAgentOperationSettings() { return getStubSettingsBuilder().restoreAgentOperationSettings(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/EntityTypesClient.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/EntityTypesClient.java index 3e8fa7eccf62..68359602ee1f 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/EntityTypesClient.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/EntityTypesClient.java @@ -189,6 +189,8 @@ public EntityTypesStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -935,6 +937,8 @@ public final UnaryCallable deleteEntityTypeCalla * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntityTypesAsync( BatchUpdateEntityTypesRequest request) { return batchUpdateEntityTypesOperationCallable().futureCall(request); @@ -962,6 +966,7 @@ public final OperationFuture batchUpdate * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable< BatchUpdateEntityTypesRequest, BatchUpdateEntityTypesResponse, Struct> batchUpdateEntityTypesOperationCallable() { @@ -1018,6 +1023,8 @@ public final OperationFuture batchUpdate * same agent as `parent`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntityTypesAsync( ProjectAgentName parent, List entityTypeNames) { @@ -1052,6 +1059,8 @@ public final OperationFuture batchDeleteEntityTypesAsync( * same agent as `parent`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntityTypesAsync( String parent, List entityTypeNames) { @@ -1087,6 +1096,8 @@ public final OperationFuture batchDeleteEntityTypesAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntityTypesAsync( BatchDeleteEntityTypesRequest request) { return batchDeleteEntityTypesOperationCallable().futureCall(request); @@ -1115,6 +1126,7 @@ public final OperationFuture batchDeleteEntityTypesAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchDeleteEntityTypesOperationCallable() { return stub.batchDeleteEntityTypesOperationCallable(); @@ -1170,6 +1182,8 @@ public final OperationFuture batchDeleteEntityTypesAsync( * @param entities Required. The collection of entities to create. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchCreateEntitiesAsync( EntityTypeName parent, List entities) { @@ -1203,6 +1217,8 @@ public final OperationFuture batchCreateEntitiesAsync( * @param entities Required. The collection of entities to create. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchCreateEntitiesAsync( String parent, List entities) { @@ -1238,6 +1254,8 @@ public final OperationFuture batchCreateEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchCreateEntitiesAsync( EntityTypeName parent, List entities, String languageCode) { @@ -1277,6 +1295,8 @@ public final OperationFuture batchCreateEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchCreateEntitiesAsync( String parent, List entities, String languageCode) { @@ -1313,6 +1333,8 @@ public final OperationFuture batchCreateEntitiesAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchCreateEntitiesAsync( BatchCreateEntitiesRequest request) { return batchCreateEntitiesOperationCallable().futureCall(request); @@ -1341,6 +1363,7 @@ public final OperationFuture batchCreateEntitiesAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchCreateEntitiesOperationCallable() { return stub.batchCreateEntitiesOperationCallable(); @@ -1395,6 +1418,8 @@ public final UnaryCallable batchCreateEnt * @param entities Required. The collection of new entities to replace the existing entities. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntitiesAsync( EntityTypeName parent, List entities) { @@ -1428,6 +1453,8 @@ public final OperationFuture batchUpdateEntitiesAsync( * @param entities Required. The collection of new entities to replace the existing entities. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntitiesAsync( String parent, List entities) { @@ -1463,6 +1490,8 @@ public final OperationFuture batchUpdateEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntitiesAsync( EntityTypeName parent, List entities, String languageCode) { @@ -1502,6 +1531,8 @@ public final OperationFuture batchUpdateEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntitiesAsync( String parent, List entities, String languageCode) { @@ -1538,6 +1569,8 @@ public final OperationFuture batchUpdateEntitiesAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntitiesAsync( BatchUpdateEntitiesRequest request) { return batchUpdateEntitiesOperationCallable().futureCall(request); @@ -1566,6 +1599,7 @@ public final OperationFuture batchUpdateEntitiesAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchUpdateEntitiesOperationCallable() { return stub.batchUpdateEntitiesOperationCallable(); @@ -1621,6 +1655,8 @@ public final UnaryCallable batchUpdateEnt * are not fully-qualified names, i.e. they don't start with `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntitiesAsync( EntityTypeName parent, List entityValues) { @@ -1655,6 +1691,8 @@ public final OperationFuture batchDeleteEntitiesAsync( * are not fully-qualified names, i.e. they don't start with `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntitiesAsync( String parent, List entityValues) { @@ -1694,6 +1732,8 @@ public final OperationFuture batchDeleteEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntitiesAsync( EntityTypeName parent, List entityValues, String languageCode) { @@ -1734,6 +1774,8 @@ public final OperationFuture batchDeleteEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntitiesAsync( String parent, List entityValues, String languageCode) { @@ -1770,6 +1812,8 @@ public final OperationFuture batchDeleteEntitiesAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntitiesAsync( BatchDeleteEntitiesRequest request) { return batchDeleteEntitiesOperationCallable().futureCall(request); @@ -1798,6 +1842,7 @@ public final OperationFuture batchDeleteEntitiesAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchDeleteEntitiesOperationCallable() { return stub.batchDeleteEntitiesOperationCallable(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/EntityTypesSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/EntityTypesSettings.java index cb15281745c8..b4a1b64dc267 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/EntityTypesSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/EntityTypesSettings.java @@ -100,6 +100,8 @@ public UnaryCallSettings deleteEntityTypeSetting } /** Returns the object with the settings used for calls to batchUpdateEntityTypes. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings< BatchUpdateEntityTypesRequest, BatchUpdateEntityTypesResponse, Struct> batchUpdateEntityTypesOperationSettings() { @@ -113,6 +115,8 @@ public UnaryCallSettings deleteEntityTypeSetting } /** Returns the object with the settings used for calls to batchDeleteEntityTypes. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchDeleteEntityTypesOperationSettings() { return ((EntityTypesStubSettings) getStubSettings()).batchDeleteEntityTypesOperationSettings(); @@ -124,6 +128,8 @@ public UnaryCallSettings batchCreateEntit } /** Returns the object with the settings used for calls to batchCreateEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchCreateEntitiesOperationSettings() { return ((EntityTypesStubSettings) getStubSettings()).batchCreateEntitiesOperationSettings(); @@ -135,6 +141,8 @@ public UnaryCallSettings batchUpdateEntit } /** Returns the object with the settings used for calls to batchUpdateEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchUpdateEntitiesOperationSettings() { return ((EntityTypesStubSettings) getStubSettings()).batchUpdateEntitiesOperationSettings(); @@ -146,6 +154,8 @@ public UnaryCallSettings batchDeleteEntit } /** Returns the object with the settings used for calls to batchDeleteEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchDeleteEntitiesOperationSettings() { return ((EntityTypesStubSettings) getStubSettings()).batchDeleteEntitiesOperationSettings(); @@ -283,6 +293,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchUpdateEntityTypes. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< BatchUpdateEntityTypesRequest, BatchUpdateEntityTypesResponse, Struct> batchUpdateEntityTypesOperationSettings() { @@ -296,6 +308,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchDeleteEntityTypes. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteEntityTypesOperationSettings() { return getStubSettingsBuilder().batchDeleteEntityTypesOperationSettings(); @@ -308,6 +322,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchCreateEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder batchCreateEntitiesOperationSettings() { return getStubSettingsBuilder().batchCreateEntitiesOperationSettings(); @@ -320,6 +336,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchUpdateEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder batchUpdateEntitiesOperationSettings() { return getStubSettingsBuilder().batchUpdateEntitiesOperationSettings(); @@ -332,6 +350,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchDeleteEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteEntitiesOperationSettings() { return getStubSettingsBuilder().batchDeleteEntitiesOperationSettings(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/IntentsClient.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/IntentsClient.java index 4236f07e4b52..d9d5f7e62fdf 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/IntentsClient.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/IntentsClient.java @@ -190,6 +190,8 @@ public IntentsStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -945,6 +947,8 @@ public final UnaryCallable deleteIntentCallable() { * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateIntentsAsync( BatchUpdateIntentsRequest request) { return batchUpdateIntentsOperationCallable().futureCall(request); @@ -973,6 +977,7 @@ public final OperationFuture batchUpdateInte * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchUpdateIntentsOperationCallable() { return stub.batchUpdateIntentsOperationCallable(); @@ -1027,6 +1032,8 @@ public final UnaryCallable batchUpdateInte * in. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteIntentsAsync( ProjectAgentName parent, List intents) { @@ -1060,6 +1067,8 @@ public final OperationFuture batchDeleteIntentsAsync( * in. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteIntentsAsync( String parent, List intents) { @@ -1091,6 +1100,8 @@ public final OperationFuture batchDeleteIntentsAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteIntentsAsync( BatchDeleteIntentsRequest request) { return batchDeleteIntentsOperationCallable().futureCall(request); @@ -1118,6 +1129,7 @@ public final OperationFuture batchDeleteIntentsAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchDeleteIntentsOperationCallable() { return stub.batchDeleteIntentsOperationCallable(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/IntentsSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/IntentsSettings.java index 9aaec3c7295d..19503dbc022d 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/IntentsSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/IntentsSettings.java @@ -98,6 +98,8 @@ public UnaryCallSettings batchUpdateIntent } /** Returns the object with the settings used for calls to batchUpdateIntents. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchUpdateIntentsOperationSettings() { return ((IntentsStubSettings) getStubSettings()).batchUpdateIntentsOperationSettings(); @@ -109,6 +111,8 @@ public UnaryCallSettings batchDeleteIntent } /** Returns the object with the settings used for calls to batchDeleteIntents. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchDeleteIntentsOperationSettings() { return ((IntentsStubSettings) getStubSettings()).batchDeleteIntentsOperationSettings(); @@ -244,6 +248,8 @@ public UnaryCallSettings.Builder deleteIntentSetting } /** Returns the builder for the settings used for calls to batchUpdateIntents. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< BatchUpdateIntentsRequest, BatchUpdateIntentsResponse, Struct> batchUpdateIntentsOperationSettings() { @@ -257,6 +263,8 @@ public UnaryCallSettings.Builder deleteIntentSetting } /** Returns the builder for the settings used for calls to batchDeleteIntents. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteIntentsOperationSettings() { return getStubSettingsBuilder().batchDeleteIntentsOperationSettings(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/AgentsStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/AgentsStub.java index e74de468836b..2590b644249d 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/AgentsStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/AgentsStub.java @@ -46,6 +46,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class AgentsStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -62,6 +63,7 @@ public UnaryCallable searchAgentsCall throw new UnsupportedOperationException("Not implemented: searchAgentsCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable trainAgentOperationCallable() { throw new UnsupportedOperationException("Not implemented: trainAgentOperationCallable()"); } @@ -70,6 +72,7 @@ public UnaryCallable trainAgentCallable() { throw new UnsupportedOperationException("Not implemented: trainAgentCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable exportAgentOperationCallable() { throw new UnsupportedOperationException("Not implemented: exportAgentOperationCallable()"); @@ -79,6 +82,7 @@ public UnaryCallable exportAgentCallable() { throw new UnsupportedOperationException("Not implemented: exportAgentCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable importAgentOperationCallable() { throw new UnsupportedOperationException("Not implemented: importAgentOperationCallable()"); } @@ -87,6 +91,7 @@ public UnaryCallable importAgentCallable() { throw new UnsupportedOperationException("Not implemented: importAgentCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable restoreAgentOperationCallable() { throw new UnsupportedOperationException("Not implemented: restoreAgentOperationCallable()"); } diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/AgentsStubSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/AgentsStubSettings.java index 7d6d7911b17a..0a2c3699c540 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/AgentsStubSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/AgentsStubSettings.java @@ -130,6 +130,7 @@ public UnaryCallSettings trainAgentSettings() { } /** Returns the object with the settings used for calls to trainAgent. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings trainAgentOperationSettings() { return trainAgentOperationSettings; } @@ -140,6 +141,7 @@ public UnaryCallSettings exportAgentSettings() { } /** Returns the object with the settings used for calls to exportAgent. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings exportAgentOperationSettings() { return exportAgentOperationSettings; @@ -151,6 +153,7 @@ public UnaryCallSettings importAgentSettings() { } /** Returns the object with the settings used for calls to importAgent. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings importAgentOperationSettings() { return importAgentOperationSettings; } @@ -161,6 +164,7 @@ public UnaryCallSettings restoreAgentSettings() } /** Returns the object with the settings used for calls to restoreAgent. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings restoreAgentOperationSettings() { return restoreAgentOperationSettings; } @@ -580,6 +584,8 @@ public UnaryCallSettings.Builder trainAgentSetting } /** Returns the builder for the settings used for calls to trainAgent. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder trainAgentOperationSettings() { return trainAgentOperationSettings; @@ -591,6 +597,8 @@ public UnaryCallSettings.Builder exportAgentSetti } /** Returns the builder for the settings used for calls to exportAgent. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder exportAgentOperationSettings() { return exportAgentOperationSettings; @@ -602,6 +610,8 @@ public UnaryCallSettings.Builder importAgentSetti } /** Returns the builder for the settings used for calls to importAgent. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder importAgentOperationSettings() { return importAgentOperationSettings; @@ -613,6 +623,8 @@ public UnaryCallSettings.Builder restoreAgentSet } /** Returns the builder for the settings used for calls to restoreAgent. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder restoreAgentOperationSettings() { return restoreAgentOperationSettings; diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/EntityTypesStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/EntityTypesStub.java index bd9aaf796880..b3e26e770a59 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/EntityTypesStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/EntityTypesStub.java @@ -50,6 +50,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class EntityTypesStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -79,6 +80,7 @@ public UnaryCallable deleteEntityTypeCallable() throw new UnsupportedOperationException("Not implemented: deleteEntityTypeCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateEntityTypesOperationCallable() { throw new UnsupportedOperationException( @@ -89,6 +91,7 @@ public UnaryCallable batchUpdateEntity throw new UnsupportedOperationException("Not implemented: batchUpdateEntityTypesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteEntityTypesOperationCallable() { throw new UnsupportedOperationException( @@ -99,6 +102,7 @@ public UnaryCallable batchDeleteEntity throw new UnsupportedOperationException("Not implemented: batchDeleteEntityTypesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchCreateEntitiesOperationCallable() { throw new UnsupportedOperationException( @@ -109,6 +113,7 @@ public UnaryCallable batchCreateEntitiesC throw new UnsupportedOperationException("Not implemented: batchCreateEntitiesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateEntitiesOperationCallable() { throw new UnsupportedOperationException( @@ -119,6 +124,7 @@ public UnaryCallable batchUpdateEntitiesC throw new UnsupportedOperationException("Not implemented: batchUpdateEntitiesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteEntitiesOperationCallable() { throw new UnsupportedOperationException( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/EntityTypesStubSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/EntityTypesStubSettings.java index 63eab4ab18cd..894cae3c3d8a 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/EntityTypesStubSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/EntityTypesStubSettings.java @@ -164,6 +164,7 @@ public UnaryCallSettings deleteEntityTypeSetting } /** Returns the object with the settings used for calls to batchUpdateEntityTypes. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings< BatchUpdateEntityTypesRequest, BatchUpdateEntityTypesResponse, Struct> batchUpdateEntityTypesOperationSettings() { @@ -177,6 +178,7 @@ public UnaryCallSettings deleteEntityTypeSetting } /** Returns the object with the settings used for calls to batchDeleteEntityTypes. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchDeleteEntityTypesOperationSettings() { return batchDeleteEntityTypesOperationSettings; @@ -188,6 +190,7 @@ public UnaryCallSettings batchCreateEntit } /** Returns the object with the settings used for calls to batchCreateEntities. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchCreateEntitiesOperationSettings() { return batchCreateEntitiesOperationSettings; @@ -199,6 +202,7 @@ public UnaryCallSettings batchUpdateEntit } /** Returns the object with the settings used for calls to batchUpdateEntities. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchUpdateEntitiesOperationSettings() { return batchUpdateEntitiesOperationSettings; @@ -210,6 +214,7 @@ public UnaryCallSettings batchDeleteEntit } /** Returns the object with the settings used for calls to batchDeleteEntities. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchDeleteEntitiesOperationSettings() { return batchDeleteEntitiesOperationSettings; @@ -752,6 +757,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchUpdateEntityTypes. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< BatchUpdateEntityTypesRequest, BatchUpdateEntityTypesResponse, Struct> batchUpdateEntityTypesOperationSettings() { @@ -765,6 +772,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchDeleteEntityTypes. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteEntityTypesOperationSettings() { return batchDeleteEntityTypesOperationSettings; @@ -777,6 +786,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchCreateEntities. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder batchCreateEntitiesOperationSettings() { return batchCreateEntitiesOperationSettings; @@ -789,6 +800,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchUpdateEntities. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder batchUpdateEntitiesOperationSettings() { return batchUpdateEntitiesOperationSettings; @@ -801,6 +814,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchDeleteEntities. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteEntitiesOperationSettings() { return batchDeleteEntitiesOperationSettings; diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcAgentsCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcAgentsCallableFactory.java index 746ef93d2b01..1abd43d88db3 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcAgentsCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcAgentsCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcAgentsStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcAgentsStub.java index d8e1a330b344..2370136ec49e 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcAgentsStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcAgentsStub.java @@ -228,6 +228,7 @@ protected GrpcAgentsStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -244,6 +245,7 @@ public UnaryCallable searchAgentsCall return searchAgentsCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable trainAgentOperationCallable() { return trainAgentOperationCallable; } @@ -252,6 +254,7 @@ public UnaryCallable trainAgentCallable() { return trainAgentCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable exportAgentOperationCallable() { return exportAgentOperationCallable; @@ -261,6 +264,7 @@ public UnaryCallable exportAgentCallable() { return exportAgentCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable importAgentOperationCallable() { return importAgentOperationCallable; } @@ -269,6 +273,7 @@ public UnaryCallable importAgentCallable() { return importAgentCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable restoreAgentOperationCallable() { return restoreAgentOperationCallable; } diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcContextsCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcContextsCallableFactory.java index 36652044b421..7e106cdbe48a 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcContextsCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcContextsCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcEntityTypesCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcEntityTypesCallableFactory.java index 90b69220ef49..f21c1414fb7e 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcEntityTypesCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcEntityTypesCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcEntityTypesStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcEntityTypesStub.java index 3b3d666cdecf..3b4f8aaa8893 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcEntityTypesStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcEntityTypesStub.java @@ -341,6 +341,7 @@ protected GrpcEntityTypesStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -370,6 +371,7 @@ public UnaryCallable deleteEntityTypeCallable() return deleteEntityTypeCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateEntityTypesOperationCallable() { return batchUpdateEntityTypesOperationCallable; @@ -379,6 +381,7 @@ public UnaryCallable batchUpdateEntity return batchUpdateEntityTypesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteEntityTypesOperationCallable() { return batchDeleteEntityTypesOperationCallable; @@ -388,6 +391,7 @@ public UnaryCallable batchDeleteEntity return batchDeleteEntityTypesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchCreateEntitiesOperationCallable() { return batchCreateEntitiesOperationCallable; @@ -397,6 +401,7 @@ public UnaryCallable batchCreateEntitiesC return batchCreateEntitiesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateEntitiesOperationCallable() { return batchUpdateEntitiesOperationCallable; @@ -406,6 +411,7 @@ public UnaryCallable batchUpdateEntitiesC return batchUpdateEntitiesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteEntitiesOperationCallable() { return batchDeleteEntitiesOperationCallable; diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcIntentsCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcIntentsCallableFactory.java index 172ff0e0b32c..eb4cf23f5fac 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcIntentsCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcIntentsCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcIntentsStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcIntentsStub.java index 124e63e676ba..63e843b6d59a 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcIntentsStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcIntentsStub.java @@ -238,6 +238,7 @@ protected GrpcIntentsStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -266,6 +267,7 @@ public UnaryCallable deleteIntentCallable() { return deleteIntentCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateIntentsOperationCallable() { return batchUpdateIntentsOperationCallable; @@ -275,6 +277,7 @@ public UnaryCallable batchUpdateIntentsCal return batchUpdateIntentsCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteIntentsOperationCallable() { return batchDeleteIntentsOperationCallable; diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcSessionEntityTypesCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcSessionEntityTypesCallableFactory.java index 0cb5ba7889ba..dc16a421fc7b 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcSessionEntityTypesCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcSessionEntityTypesCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcSessionsCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcSessionsCallableFactory.java index e8441107fdd5..134072196528 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcSessionsCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/GrpcSessionsCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/IntentsStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/IntentsStub.java index 8552affb6d43..3952a17ffdc5 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/IntentsStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/IntentsStub.java @@ -47,6 +47,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class IntentsStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -75,6 +76,7 @@ public UnaryCallable deleteIntentCallable() { throw new UnsupportedOperationException("Not implemented: deleteIntentCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateIntentsOperationCallable() { throw new UnsupportedOperationException( @@ -85,6 +87,7 @@ public UnaryCallable batchUpdateIntentsCal throw new UnsupportedOperationException("Not implemented: batchUpdateIntentsCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteIntentsOperationCallable() { throw new UnsupportedOperationException( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/IntentsStubSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/IntentsStubSettings.java index d92a01838600..d5b02b07e881 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/IntentsStubSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/stub/IntentsStubSettings.java @@ -143,6 +143,7 @@ public UnaryCallSettings batchUpdateIntent } /** Returns the object with the settings used for calls to batchUpdateIntents. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchUpdateIntentsOperationSettings() { return batchUpdateIntentsOperationSettings; @@ -154,6 +155,7 @@ public UnaryCallSettings batchDeleteIntent } /** Returns the object with the settings used for calls to batchDeleteIntents. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchDeleteIntentsOperationSettings() { return batchDeleteIntentsOperationSettings; @@ -555,6 +557,8 @@ public UnaryCallSettings.Builder deleteIntentSetting } /** Returns the builder for the settings used for calls to batchUpdateIntents. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< BatchUpdateIntentsRequest, BatchUpdateIntentsResponse, Struct> batchUpdateIntentsOperationSettings() { @@ -568,6 +572,8 @@ public UnaryCallSettings.Builder deleteIntentSetting } /** Returns the builder for the settings used for calls to batchDeleteIntents. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteIntentsOperationSettings() { return batchDeleteIntentsOperationSettings; diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/AgentsClient.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/AgentsClient.java index 7de000e5b96a..f8735431acb8 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/AgentsClient.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/AgentsClient.java @@ -185,6 +185,8 @@ public AgentsStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -458,6 +460,8 @@ public final UnaryCallable searchAgen * `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture trainAgentAsync(ProjectName parent) { TrainAgentRequest request = @@ -485,6 +489,8 @@ public final OperationFuture trainAgentAsync(ProjectName parent) * `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture trainAgentAsync(String parent) { TrainAgentRequest request = TrainAgentRequest.newBuilder().setParent(parent).build(); @@ -513,6 +519,8 @@ public final OperationFuture trainAgentAsync(String parent) { * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") private final OperationFuture trainAgentAsync(TrainAgentRequest request) { return trainAgentOperationCallable().futureCall(request); } @@ -538,6 +546,7 @@ private final OperationFuture trainAgentAsync(TrainAgentRequest r * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable trainAgentOperationCallable() { return stub.trainAgentOperationCallable(); } @@ -588,6 +597,8 @@ public final UnaryCallable trainAgentCallable() { * `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture exportAgentAsync(ProjectName parent) { ExportAgentRequest request = @@ -618,6 +629,8 @@ public final OperationFuture exportAgentAsync(Proje * `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture exportAgentAsync(String parent) { ExportAgentRequest request = ExportAgentRequest.newBuilder().setParent(parent).build(); @@ -647,6 +660,8 @@ public final OperationFuture exportAgentAsync(Strin * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture exportAgentAsync( ExportAgentRequest request) { return exportAgentOperationCallable().futureCall(request); @@ -674,6 +689,7 @@ public final OperationFuture exportAgentAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable exportAgentOperationCallable() { return stub.exportAgentOperationCallable(); @@ -730,6 +746,8 @@ public final UnaryCallable exportAgentCallable() * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture importAgentAsync(ImportAgentRequest request) { return importAgentOperationCallable().futureCall(request); } @@ -758,6 +776,7 @@ public final OperationFuture importAgentAsync(ImportAgentRequest * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable importAgentOperationCallable() { return stub.importAgentOperationCallable(); } @@ -815,6 +834,8 @@ public final UnaryCallable importAgentCallable() * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture restoreAgentAsync(RestoreAgentRequest request) { return restoreAgentOperationCallable().futureCall(request); } @@ -843,6 +864,7 @@ public final OperationFuture restoreAgentAsync(RestoreAgentReques * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable restoreAgentOperationCallable() { return stub.restoreAgentOperationCallable(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/AgentsSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/AgentsSettings.java index 3e75caa65a4d..a4a34c7fc860 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/AgentsSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/AgentsSettings.java @@ -83,6 +83,8 @@ public UnaryCallSettings trainAgentSettings() { } /** Returns the object with the settings used for calls to trainAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings trainAgentOperationSettings() { return ((AgentsStubSettings) getStubSettings()).trainAgentOperationSettings(); } @@ -93,6 +95,8 @@ public UnaryCallSettings exportAgentSettings() { } /** Returns the object with the settings used for calls to exportAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings exportAgentOperationSettings() { return ((AgentsStubSettings) getStubSettings()).exportAgentOperationSettings(); @@ -104,6 +108,8 @@ public UnaryCallSettings importAgentSettings() { } /** Returns the object with the settings used for calls to importAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings importAgentOperationSettings() { return ((AgentsStubSettings) getStubSettings()).importAgentOperationSettings(); } @@ -114,6 +120,8 @@ public UnaryCallSettings restoreAgentSettings() } /** Returns the object with the settings used for calls to restoreAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings restoreAgentOperationSettings() { return ((AgentsStubSettings) getStubSettings()).restoreAgentOperationSettings(); } @@ -232,6 +240,8 @@ public UnaryCallSettings.Builder trainAgentSetting } /** Returns the builder for the settings used for calls to trainAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder trainAgentOperationSettings() { return getStubSettingsBuilder().trainAgentOperationSettings(); @@ -243,6 +253,8 @@ public UnaryCallSettings.Builder exportAgentSetti } /** Returns the builder for the settings used for calls to exportAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder exportAgentOperationSettings() { return getStubSettingsBuilder().exportAgentOperationSettings(); @@ -254,6 +266,8 @@ public UnaryCallSettings.Builder importAgentSetti } /** Returns the builder for the settings used for calls to importAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder importAgentOperationSettings() { return getStubSettingsBuilder().importAgentOperationSettings(); @@ -265,6 +279,8 @@ public UnaryCallSettings.Builder restoreAgentSet } /** Returns the builder for the settings used for calls to restoreAgent. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder restoreAgentOperationSettings() { return getStubSettingsBuilder().restoreAgentOperationSettings(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/EntityTypesClient.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/EntityTypesClient.java index 7cfa0fd4c924..4f2be73334fd 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/EntityTypesClient.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/EntityTypesClient.java @@ -189,6 +189,8 @@ public EntityTypesStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -935,6 +937,8 @@ public final UnaryCallable deleteEntityTypeCalla * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntityTypesAsync( BatchUpdateEntityTypesRequest request) { return batchUpdateEntityTypesOperationCallable().futureCall(request); @@ -962,6 +966,7 @@ public final OperationFuture batchUpdate * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable< BatchUpdateEntityTypesRequest, BatchUpdateEntityTypesResponse, Struct> batchUpdateEntityTypesOperationCallable() { @@ -1018,6 +1023,8 @@ public final OperationFuture batchUpdate * same agent as `parent`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntityTypesAsync( ProjectAgentName parent, List entityTypeNames) { @@ -1052,6 +1059,8 @@ public final OperationFuture batchDeleteEntityTypesAsync( * same agent as `parent`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntityTypesAsync( String parent, List entityTypeNames) { @@ -1087,6 +1096,8 @@ public final OperationFuture batchDeleteEntityTypesAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntityTypesAsync( BatchDeleteEntityTypesRequest request) { return batchDeleteEntityTypesOperationCallable().futureCall(request); @@ -1115,6 +1126,7 @@ public final OperationFuture batchDeleteEntityTypesAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchDeleteEntityTypesOperationCallable() { return stub.batchDeleteEntityTypesOperationCallable(); @@ -1170,6 +1182,8 @@ public final OperationFuture batchDeleteEntityTypesAsync( * @param entities Required. The collection of entities to create. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchCreateEntitiesAsync( EntityTypeName parent, List entities) { @@ -1203,6 +1217,8 @@ public final OperationFuture batchCreateEntitiesAsync( * @param entities Required. The collection of entities to create. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchCreateEntitiesAsync( String parent, List entities) { @@ -1238,6 +1254,8 @@ public final OperationFuture batchCreateEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchCreateEntitiesAsync( EntityTypeName parent, List entities, String languageCode) { @@ -1277,6 +1295,8 @@ public final OperationFuture batchCreateEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchCreateEntitiesAsync( String parent, List entities, String languageCode) { @@ -1313,6 +1333,8 @@ public final OperationFuture batchCreateEntitiesAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchCreateEntitiesAsync( BatchCreateEntitiesRequest request) { return batchCreateEntitiesOperationCallable().futureCall(request); @@ -1341,6 +1363,7 @@ public final OperationFuture batchCreateEntitiesAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchCreateEntitiesOperationCallable() { return stub.batchCreateEntitiesOperationCallable(); @@ -1395,6 +1418,8 @@ public final UnaryCallable batchCreateEnt * @param entities Required. The collection of new entities to replace the existing entities. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntitiesAsync( EntityTypeName parent, List entities) { @@ -1428,6 +1453,8 @@ public final OperationFuture batchUpdateEntitiesAsync( * @param entities Required. The collection of new entities to replace the existing entities. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntitiesAsync( String parent, List entities) { @@ -1463,6 +1490,8 @@ public final OperationFuture batchUpdateEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntitiesAsync( EntityTypeName parent, List entities, String languageCode) { @@ -1502,6 +1531,8 @@ public final OperationFuture batchUpdateEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntitiesAsync( String parent, List entities, String languageCode) { @@ -1538,6 +1569,8 @@ public final OperationFuture batchUpdateEntitiesAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateEntitiesAsync( BatchUpdateEntitiesRequest request) { return batchUpdateEntitiesOperationCallable().futureCall(request); @@ -1566,6 +1599,7 @@ public final OperationFuture batchUpdateEntitiesAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchUpdateEntitiesOperationCallable() { return stub.batchUpdateEntitiesOperationCallable(); @@ -1621,6 +1655,8 @@ public final UnaryCallable batchUpdateEnt * are not fully-qualified names, i.e. they don't start with `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntitiesAsync( EntityTypeName parent, List entityValues) { @@ -1655,6 +1691,8 @@ public final OperationFuture batchDeleteEntitiesAsync( * are not fully-qualified names, i.e. they don't start with `projects/<Project ID>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntitiesAsync( String parent, List entityValues) { @@ -1694,6 +1732,8 @@ public final OperationFuture batchDeleteEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntitiesAsync( EntityTypeName parent, List entityValues, String languageCode) { @@ -1734,6 +1774,8 @@ public final OperationFuture batchDeleteEntitiesAsync( * must be enabled in the agent, before they can be used. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntitiesAsync( String parent, List entityValues, String languageCode) { @@ -1770,6 +1812,8 @@ public final OperationFuture batchDeleteEntitiesAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteEntitiesAsync( BatchDeleteEntitiesRequest request) { return batchDeleteEntitiesOperationCallable().futureCall(request); @@ -1798,6 +1842,7 @@ public final OperationFuture batchDeleteEntitiesAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchDeleteEntitiesOperationCallable() { return stub.batchDeleteEntitiesOperationCallable(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/EntityTypesSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/EntityTypesSettings.java index a33e64d84f38..1e913fd08769 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/EntityTypesSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/EntityTypesSettings.java @@ -100,6 +100,8 @@ public UnaryCallSettings deleteEntityTypeSetting } /** Returns the object with the settings used for calls to batchUpdateEntityTypes. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings< BatchUpdateEntityTypesRequest, BatchUpdateEntityTypesResponse, Struct> batchUpdateEntityTypesOperationSettings() { @@ -113,6 +115,8 @@ public UnaryCallSettings deleteEntityTypeSetting } /** Returns the object with the settings used for calls to batchDeleteEntityTypes. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchDeleteEntityTypesOperationSettings() { return ((EntityTypesStubSettings) getStubSettings()).batchDeleteEntityTypesOperationSettings(); @@ -124,6 +128,8 @@ public UnaryCallSettings batchCreateEntit } /** Returns the object with the settings used for calls to batchCreateEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchCreateEntitiesOperationSettings() { return ((EntityTypesStubSettings) getStubSettings()).batchCreateEntitiesOperationSettings(); @@ -135,6 +141,8 @@ public UnaryCallSettings batchUpdateEntit } /** Returns the object with the settings used for calls to batchUpdateEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchUpdateEntitiesOperationSettings() { return ((EntityTypesStubSettings) getStubSettings()).batchUpdateEntitiesOperationSettings(); @@ -146,6 +154,8 @@ public UnaryCallSettings batchDeleteEntit } /** Returns the object with the settings used for calls to batchDeleteEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchDeleteEntitiesOperationSettings() { return ((EntityTypesStubSettings) getStubSettings()).batchDeleteEntitiesOperationSettings(); @@ -283,6 +293,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchUpdateEntityTypes. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< BatchUpdateEntityTypesRequest, BatchUpdateEntityTypesResponse, Struct> batchUpdateEntityTypesOperationSettings() { @@ -296,6 +308,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchDeleteEntityTypes. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteEntityTypesOperationSettings() { return getStubSettingsBuilder().batchDeleteEntityTypesOperationSettings(); @@ -308,6 +322,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchCreateEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder batchCreateEntitiesOperationSettings() { return getStubSettingsBuilder().batchCreateEntitiesOperationSettings(); @@ -320,6 +336,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchUpdateEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder batchUpdateEntitiesOperationSettings() { return getStubSettingsBuilder().batchUpdateEntitiesOperationSettings(); @@ -332,6 +350,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchDeleteEntities. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteEntitiesOperationSettings() { return getStubSettingsBuilder().batchDeleteEntitiesOperationSettings(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/IntentsClient.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/IntentsClient.java index 3387221b7ade..785a832af714 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/IntentsClient.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/IntentsClient.java @@ -190,6 +190,8 @@ public IntentsStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -945,6 +947,8 @@ public final UnaryCallable deleteIntentCallable() { * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchUpdateIntentsAsync( BatchUpdateIntentsRequest request) { return batchUpdateIntentsOperationCallable().futureCall(request); @@ -973,6 +977,7 @@ public final OperationFuture batchUpdateInte * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchUpdateIntentsOperationCallable() { return stub.batchUpdateIntentsOperationCallable(); @@ -1027,6 +1032,8 @@ public final UnaryCallable batchUpdateInte * in. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteIntentsAsync( ProjectName parent, List intents) { @@ -1060,6 +1067,8 @@ public final OperationFuture batchDeleteIntentsAsync( * in. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteIntentsAsync( String parent, List intents) { @@ -1091,6 +1100,8 @@ public final OperationFuture batchDeleteIntentsAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture batchDeleteIntentsAsync( BatchDeleteIntentsRequest request) { return batchDeleteIntentsOperationCallable().futureCall(request); @@ -1118,6 +1129,7 @@ public final OperationFuture batchDeleteIntentsAsync( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable batchDeleteIntentsOperationCallable() { return stub.batchDeleteIntentsOperationCallable(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/IntentsSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/IntentsSettings.java index 91a160b4a677..7fcfd322053b 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/IntentsSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/IntentsSettings.java @@ -98,6 +98,8 @@ public UnaryCallSettings batchUpdateIntent } /** Returns the object with the settings used for calls to batchUpdateIntents. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchUpdateIntentsOperationSettings() { return ((IntentsStubSettings) getStubSettings()).batchUpdateIntentsOperationSettings(); @@ -109,6 +111,8 @@ public UnaryCallSettings batchDeleteIntent } /** Returns the object with the settings used for calls to batchDeleteIntents. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings batchDeleteIntentsOperationSettings() { return ((IntentsStubSettings) getStubSettings()).batchDeleteIntentsOperationSettings(); @@ -244,6 +248,8 @@ public UnaryCallSettings.Builder deleteIntentSetting } /** Returns the builder for the settings used for calls to batchUpdateIntents. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< BatchUpdateIntentsRequest, BatchUpdateIntentsResponse, Struct> batchUpdateIntentsOperationSettings() { @@ -257,6 +263,8 @@ public UnaryCallSettings.Builder deleteIntentSetting } /** Returns the builder for the settings used for calls to batchDeleteIntents. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteIntentsOperationSettings() { return getStubSettingsBuilder().batchDeleteIntentsOperationSettings(); diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/AgentsStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/AgentsStub.java index 3109c2aa9d29..b499a09d9363 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/AgentsStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/AgentsStub.java @@ -46,6 +46,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class AgentsStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -62,6 +63,7 @@ public UnaryCallable searchAgentsCall throw new UnsupportedOperationException("Not implemented: searchAgentsCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable trainAgentOperationCallable() { throw new UnsupportedOperationException("Not implemented: trainAgentOperationCallable()"); } @@ -70,6 +72,7 @@ public UnaryCallable trainAgentCallable() { throw new UnsupportedOperationException("Not implemented: trainAgentCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable exportAgentOperationCallable() { throw new UnsupportedOperationException("Not implemented: exportAgentOperationCallable()"); @@ -79,6 +82,7 @@ public UnaryCallable exportAgentCallable() { throw new UnsupportedOperationException("Not implemented: exportAgentCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable importAgentOperationCallable() { throw new UnsupportedOperationException("Not implemented: importAgentOperationCallable()"); } @@ -87,6 +91,7 @@ public UnaryCallable importAgentCallable() { throw new UnsupportedOperationException("Not implemented: importAgentCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable restoreAgentOperationCallable() { throw new UnsupportedOperationException("Not implemented: restoreAgentOperationCallable()"); } diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/AgentsStubSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/AgentsStubSettings.java index b96ea8a99afc..903679697993 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/AgentsStubSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/AgentsStubSettings.java @@ -130,6 +130,7 @@ public UnaryCallSettings trainAgentSettings() { } /** Returns the object with the settings used for calls to trainAgent. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings trainAgentOperationSettings() { return trainAgentOperationSettings; } @@ -140,6 +141,7 @@ public UnaryCallSettings exportAgentSettings() { } /** Returns the object with the settings used for calls to exportAgent. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings exportAgentOperationSettings() { return exportAgentOperationSettings; @@ -151,6 +153,7 @@ public UnaryCallSettings importAgentSettings() { } /** Returns the object with the settings used for calls to importAgent. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings importAgentOperationSettings() { return importAgentOperationSettings; } @@ -161,6 +164,7 @@ public UnaryCallSettings restoreAgentSettings() } /** Returns the object with the settings used for calls to restoreAgent. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings restoreAgentOperationSettings() { return restoreAgentOperationSettings; } @@ -580,6 +584,8 @@ public UnaryCallSettings.Builder trainAgentSetting } /** Returns the builder for the settings used for calls to trainAgent. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder trainAgentOperationSettings() { return trainAgentOperationSettings; @@ -591,6 +597,8 @@ public UnaryCallSettings.Builder exportAgentSetti } /** Returns the builder for the settings used for calls to exportAgent. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder exportAgentOperationSettings() { return exportAgentOperationSettings; @@ -602,6 +610,8 @@ public UnaryCallSettings.Builder importAgentSetti } /** Returns the builder for the settings used for calls to importAgent. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder importAgentOperationSettings() { return importAgentOperationSettings; @@ -613,6 +623,8 @@ public UnaryCallSettings.Builder restoreAgentSet } /** Returns the builder for the settings used for calls to restoreAgent. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder restoreAgentOperationSettings() { return restoreAgentOperationSettings; diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/EntityTypesStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/EntityTypesStub.java index 1584bcc405a9..e6df8fb988ea 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/EntityTypesStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/EntityTypesStub.java @@ -50,6 +50,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class EntityTypesStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -79,6 +80,7 @@ public UnaryCallable deleteEntityTypeCallable() throw new UnsupportedOperationException("Not implemented: deleteEntityTypeCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateEntityTypesOperationCallable() { throw new UnsupportedOperationException( @@ -89,6 +91,7 @@ public UnaryCallable batchUpdateEntity throw new UnsupportedOperationException("Not implemented: batchUpdateEntityTypesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteEntityTypesOperationCallable() { throw new UnsupportedOperationException( @@ -99,6 +102,7 @@ public UnaryCallable batchDeleteEntity throw new UnsupportedOperationException("Not implemented: batchDeleteEntityTypesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchCreateEntitiesOperationCallable() { throw new UnsupportedOperationException( @@ -109,6 +113,7 @@ public UnaryCallable batchCreateEntitiesC throw new UnsupportedOperationException("Not implemented: batchCreateEntitiesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateEntitiesOperationCallable() { throw new UnsupportedOperationException( @@ -119,6 +124,7 @@ public UnaryCallable batchUpdateEntitiesC throw new UnsupportedOperationException("Not implemented: batchUpdateEntitiesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteEntitiesOperationCallable() { throw new UnsupportedOperationException( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/EntityTypesStubSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/EntityTypesStubSettings.java index 52bd4343aec6..b89de7ad6286 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/EntityTypesStubSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/EntityTypesStubSettings.java @@ -164,6 +164,7 @@ public UnaryCallSettings deleteEntityTypeSetting } /** Returns the object with the settings used for calls to batchUpdateEntityTypes. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings< BatchUpdateEntityTypesRequest, BatchUpdateEntityTypesResponse, Struct> batchUpdateEntityTypesOperationSettings() { @@ -177,6 +178,7 @@ public UnaryCallSettings deleteEntityTypeSetting } /** Returns the object with the settings used for calls to batchDeleteEntityTypes. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchDeleteEntityTypesOperationSettings() { return batchDeleteEntityTypesOperationSettings; @@ -188,6 +190,7 @@ public UnaryCallSettings batchCreateEntit } /** Returns the object with the settings used for calls to batchCreateEntities. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchCreateEntitiesOperationSettings() { return batchCreateEntitiesOperationSettings; @@ -199,6 +202,7 @@ public UnaryCallSettings batchUpdateEntit } /** Returns the object with the settings used for calls to batchUpdateEntities. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchUpdateEntitiesOperationSettings() { return batchUpdateEntitiesOperationSettings; @@ -210,6 +214,7 @@ public UnaryCallSettings batchDeleteEntit } /** Returns the object with the settings used for calls to batchDeleteEntities. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchDeleteEntitiesOperationSettings() { return batchDeleteEntitiesOperationSettings; @@ -752,6 +757,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchUpdateEntityTypes. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< BatchUpdateEntityTypesRequest, BatchUpdateEntityTypesResponse, Struct> batchUpdateEntityTypesOperationSettings() { @@ -765,6 +772,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchDeleteEntityTypes. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteEntityTypesOperationSettings() { return batchDeleteEntityTypesOperationSettings; @@ -777,6 +786,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchCreateEntities. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder batchCreateEntitiesOperationSettings() { return batchCreateEntitiesOperationSettings; @@ -789,6 +800,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchUpdateEntities. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder batchUpdateEntitiesOperationSettings() { return batchUpdateEntitiesOperationSettings; @@ -801,6 +814,8 @@ public UnaryCallSettings.Builder deleteEntityTyp } /** Returns the builder for the settings used for calls to batchDeleteEntities. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteEntitiesOperationSettings() { return batchDeleteEntitiesOperationSettings; diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcAgentsCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcAgentsCallableFactory.java index 3d5c58c1508b..a499e26d2a17 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcAgentsCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcAgentsCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcAgentsStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcAgentsStub.java index c0815b35ebf8..8b4aebda7287 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcAgentsStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcAgentsStub.java @@ -228,6 +228,7 @@ protected GrpcAgentsStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -244,6 +245,7 @@ public UnaryCallable searchAgentsCall return searchAgentsCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable trainAgentOperationCallable() { return trainAgentOperationCallable; } @@ -252,6 +254,7 @@ public UnaryCallable trainAgentCallable() { return trainAgentCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable exportAgentOperationCallable() { return exportAgentOperationCallable; @@ -261,6 +264,7 @@ public UnaryCallable exportAgentCallable() { return exportAgentCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable importAgentOperationCallable() { return importAgentOperationCallable; } @@ -269,6 +273,7 @@ public UnaryCallable importAgentCallable() { return importAgentCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable restoreAgentOperationCallable() { return restoreAgentOperationCallable; } diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcContextsCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcContextsCallableFactory.java index cae4940ca102..d1cfdaec0f4d 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcContextsCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcContextsCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcEntityTypesCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcEntityTypesCallableFactory.java index dba62989a9d8..f56b84a9168d 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcEntityTypesCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcEntityTypesCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcEntityTypesStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcEntityTypesStub.java index a005eee6844a..e099720d4fce 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcEntityTypesStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcEntityTypesStub.java @@ -343,6 +343,7 @@ protected GrpcEntityTypesStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -372,6 +373,7 @@ public UnaryCallable deleteEntityTypeCallable() return deleteEntityTypeCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateEntityTypesOperationCallable() { return batchUpdateEntityTypesOperationCallable; @@ -381,6 +383,7 @@ public UnaryCallable batchUpdateEntity return batchUpdateEntityTypesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteEntityTypesOperationCallable() { return batchDeleteEntityTypesOperationCallable; @@ -390,6 +393,7 @@ public UnaryCallable batchDeleteEntity return batchDeleteEntityTypesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchCreateEntitiesOperationCallable() { return batchCreateEntitiesOperationCallable; @@ -399,6 +403,7 @@ public UnaryCallable batchCreateEntitiesC return batchCreateEntitiesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateEntitiesOperationCallable() { return batchUpdateEntitiesOperationCallable; @@ -408,6 +413,7 @@ public UnaryCallable batchUpdateEntitiesC return batchUpdateEntitiesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteEntitiesOperationCallable() { return batchDeleteEntitiesOperationCallable; diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcIntentsCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcIntentsCallableFactory.java index 4f7be6caac2a..470dca03db22 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcIntentsCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcIntentsCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcIntentsStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcIntentsStub.java index 40fc70bb01bd..57a2e1e84b19 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcIntentsStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcIntentsStub.java @@ -238,6 +238,7 @@ protected GrpcIntentsStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -266,6 +267,7 @@ public UnaryCallable deleteIntentCallable() { return deleteIntentCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateIntentsOperationCallable() { return batchUpdateIntentsOperationCallable; @@ -275,6 +277,7 @@ public UnaryCallable batchUpdateIntentsCal return batchUpdateIntentsCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteIntentsOperationCallable() { return batchDeleteIntentsOperationCallable; diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcSessionEntityTypesCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcSessionEntityTypesCallableFactory.java index aaab39641e88..a3eec682dc83 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcSessionEntityTypesCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcSessionEntityTypesCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcSessionsCallableFactory.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcSessionsCallableFactory.java index 106c97a78eb1..c727d45085d5 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcSessionsCallableFactory.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/GrpcSessionsCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/IntentsStub.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/IntentsStub.java index 985e43b96edb..6d68ef3b3a2b 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/IntentsStub.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/IntentsStub.java @@ -47,6 +47,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class IntentsStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -75,6 +76,7 @@ public UnaryCallable deleteIntentCallable() { throw new UnsupportedOperationException("Not implemented: deleteIntentCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchUpdateIntentsOperationCallable() { throw new UnsupportedOperationException( @@ -85,6 +87,7 @@ public UnaryCallable batchUpdateIntentsCal throw new UnsupportedOperationException("Not implemented: batchUpdateIntentsCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable batchDeleteIntentsOperationCallable() { throw new UnsupportedOperationException( diff --git a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/IntentsStubSettings.java b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/IntentsStubSettings.java index 53ae7ff297e7..e0f9267bd893 100644 --- a/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/IntentsStubSettings.java +++ b/google-cloud-clients/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2beta1/stub/IntentsStubSettings.java @@ -143,6 +143,7 @@ public UnaryCallSettings batchUpdateIntent } /** Returns the object with the settings used for calls to batchUpdateIntents. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchUpdateIntentsOperationSettings() { return batchUpdateIntentsOperationSettings; @@ -154,6 +155,7 @@ public UnaryCallSettings batchDeleteIntent } /** Returns the object with the settings used for calls to batchDeleteIntents. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings batchDeleteIntentsOperationSettings() { return batchDeleteIntentsOperationSettings; @@ -555,6 +557,8 @@ public UnaryCallSettings.Builder deleteIntentSetting } /** Returns the builder for the settings used for calls to batchUpdateIntents. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< BatchUpdateIntentsRequest, BatchUpdateIntentsResponse, Struct> batchUpdateIntentsOperationSettings() { @@ -568,6 +572,8 @@ public UnaryCallSettings.Builder deleteIntentSetting } /** Returns the builder for the settings used for calls to batchDeleteIntents. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder batchDeleteIntentsOperationSettings() { return batchDeleteIntentsOperationSettings; diff --git a/google-cloud-clients/google-cloud-dlp/pom.xml b/google-cloud-clients/google-cloud-dlp/pom.xml index a744eabf8848..8d2d4f981c99 100644 --- a/google-cloud-clients/google-cloud-dlp/pom.xml +++ b/google-cloud-clients/google-cloud-dlp/pom.xml @@ -15,7 +15,7 @@ 0.47.1-alpha-SNAPSHOT
- google-cloud-dlp-v2beta1 + google-cloud-dlp @@ -26,10 +26,6 @@ ${project.groupId} google-cloud-core-grpc - - com.google.api.grpc - proto-google-cloud-dlp-v2beta1 - com.google.api.grpc proto-google-cloud-dlp-v2 @@ -67,11 +63,6 @@ objenesis test - - com.google.api.grpc - grpc-google-cloud-dlp-v2beta1 - test - com.google.api.grpc grpc-google-cloud-dlp-v2 diff --git a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2/stub/GrpcDlpServiceCallableFactory.java b/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2/stub/GrpcDlpServiceCallableFactory.java index 130b3fe2da24..58b835b1514b 100644 --- a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2/stub/GrpcDlpServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2/stub/GrpcDlpServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/Colors.java b/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/Colors.java deleted file mode 100644 index 1ec834cf27d1..000000000000 --- a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/Colors.java +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2018 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.dlp.v2beta1; - -import com.google.privacy.dlp.v2beta1.Color; - -public class Colors { - - private Colors() {} - - public static final Color asDlpColor(java.awt.Color c) { - return Color.newBuilder() - .setBlue(c.getBlue()) - .setGreen(c.getGreen()) - .setRed(c.getRed()) - .build(); - } - - public static final java.awt.Color asAwtColor(Color c) { - return new java.awt.Color(c.getRed() / 255, c.getGreen() / 255, c.getBlue() / 255); - } -} diff --git a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/DlpServiceClient.java b/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/DlpServiceClient.java deleted file mode 100644 index 0f0beed6d943..000000000000 --- a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/DlpServiceClient.java +++ /dev/null @@ -1,1080 +0,0 @@ -/* - * Copyright 2018 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.dlp.v2beta1; - -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.longrunning.OperationFuture; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloud.dlp.v2beta1.stub.DlpServiceStub; -import com.google.cloud.dlp.v2beta1.stub.DlpServiceStubSettings; -import com.google.longrunning.Operation; -import com.google.longrunning.OperationsClient; -import com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest; -import com.google.privacy.dlp.v2beta1.BigQueryTable; -import com.google.privacy.dlp.v2beta1.ContentItem; -import com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyConfig; -import com.google.privacy.dlp.v2beta1.DeidentifyContentRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentResponse; -import com.google.privacy.dlp.v2beta1.InspectConfig; -import com.google.privacy.dlp.v2beta1.InspectContentRequest; -import com.google.privacy.dlp.v2beta1.InspectContentResponse; -import com.google.privacy.dlp.v2beta1.InspectOperationMetadata; -import com.google.privacy.dlp.v2beta1.InspectOperationResult; -import com.google.privacy.dlp.v2beta1.ListInfoTypesRequest; -import com.google.privacy.dlp.v2beta1.ListInfoTypesResponse; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse; -import com.google.privacy.dlp.v2beta1.OutputStorageConfig; -import com.google.privacy.dlp.v2beta1.PrivacyMetric; -import com.google.privacy.dlp.v2beta1.RedactContentRequest; -import com.google.privacy.dlp.v2beta1.RedactContentResponse; -import com.google.privacy.dlp.v2beta1.ResultName; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult; -import com.google.privacy.dlp.v2beta1.StorageConfig; -import java.io.IOException; -import java.util.List; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND SERVICE -/** - * Service Description: The DLP API is a service that allows clients to detect the presence of - * Personally Identifiable Information (PII) and other privacy-sensitive data in user-supplied, - * unstructured data streams, like text blocks or images. The service also includes methods for - * sensitive data redaction and scheduling of data scans on Google Cloud Platform based data sets. - * - *

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

- * 
- * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
- *   String name = "EMAIL_ADDRESS";
- *   InfoType infoTypesElement = InfoType.newBuilder()
- *     .setName(name)
- *     .build();
- *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
- *   InspectConfig inspectConfig = InspectConfig.newBuilder()
- *     .addAllInfoTypes(infoTypes)
- *     .build();
- *   String type = "text/plain";
- *   String value = "My email is example{@literal @}example.com.";
- *   ContentItem itemsElement = ContentItem.newBuilder()
- *     .setType(type)
- *     .setValue(value)
- *     .build();
- *   List<ContentItem> items = Arrays.asList(itemsElement);
- *   InspectContentResponse response = dlpServiceClient.inspectContent(inspectConfig, items);
- * }
- * 
- * 
- * - *

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

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

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

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

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

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

To customize credentials: - * - *

- * 
- * DlpServiceSettings dlpServiceSettings =
- *     DlpServiceSettings.newBuilder()
- *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
- *         .build();
- * DlpServiceClient dlpServiceClient =
- *     DlpServiceClient.create(dlpServiceSettings);
- * 
- * 
- * - * To customize the endpoint: - * - *
- * 
- * DlpServiceSettings dlpServiceSettings =
- *     DlpServiceSettings.newBuilder().setEndpoint(myEndpoint).build();
- * DlpServiceClient dlpServiceClient =
- *     DlpServiceClient.create(dlpServiceSettings);
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class DlpServiceClient implements BackgroundResource { - private final DlpServiceSettings settings; - private final DlpServiceStub stub; - private final OperationsClient operationsClient; - - /** Constructs an instance of DlpServiceClient with default settings. */ - public static final DlpServiceClient create() throws IOException { - return create(DlpServiceSettings.newBuilder().build()); - } - - /** - * Constructs an instance of DlpServiceClient, using the given settings. The channels are created - * based on the settings passed in, or defaults for any settings that are not set. - */ - public static final DlpServiceClient create(DlpServiceSettings settings) throws IOException { - return new DlpServiceClient(settings); - } - - /** - * Constructs an instance of DlpServiceClient, using the given stub for making calls. This is for - * advanced usage - prefer to use DlpServiceSettings}. - */ - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public static final DlpServiceClient create(DlpServiceStub stub) { - return new DlpServiceClient(stub); - } - - /** - * Constructs an instance of DlpServiceClient, using the given settings. This is protected so that - * it is easy to make a subclass, but otherwise, the static factory methods should be preferred. - */ - protected DlpServiceClient(DlpServiceSettings settings) throws IOException { - this.settings = settings; - this.stub = ((DlpServiceStubSettings) settings.getStubSettings()).createStub(); - this.operationsClient = OperationsClient.create(this.stub.getOperationsStub()); - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - protected DlpServiceClient(DlpServiceStub stub) { - this.settings = null; - this.stub = stub; - this.operationsClient = OperationsClient.create(this.stub.getOperationsStub()); - } - - public final DlpServiceSettings getSettings() { - return settings; - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public DlpServiceStub getStub() { - return stub; - } - - /** - * Returns the OperationsClient that can be used to query the status of a long-running operation - * returned by another API method call. - */ - public final OperationsClient getOperationsClient() { - return operationsClient; - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Finds potentially sensitive info in a list of strings. This method has limits on input size, - * processing time, and output size. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String name = "EMAIL_ADDRESS";
-   *   InfoType infoTypesElement = InfoType.newBuilder()
-   *     .setName(name)
-   *     .build();
-   *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder()
-   *     .addAllInfoTypes(infoTypes)
-   *     .build();
-   *   String type = "text/plain";
-   *   String value = "My email is example{@literal @}example.com.";
-   *   ContentItem itemsElement = ContentItem.newBuilder()
-   *     .setType(type)
-   *     .setValue(value)
-   *     .build();
-   *   List<ContentItem> items = Arrays.asList(itemsElement);
-   *   InspectContentResponse response = dlpServiceClient.inspectContent(inspectConfig, items);
-   * }
-   * 
- * - * @param inspectConfig Configuration for the inspector. - * @param items The list of items to inspect. Items in a single request are considered "related" - * unless inspect_config.independent_inputs is true. Up to 100 are allowed per request. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final InspectContentResponse inspectContent( - InspectConfig inspectConfig, List items) { - - InspectContentRequest request = - InspectContentRequest.newBuilder() - .setInspectConfig(inspectConfig) - .addAllItems(items) - .build(); - return inspectContent(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Finds potentially sensitive info in a list of strings. This method has limits on input size, - * processing time, and output size. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String name = "EMAIL_ADDRESS";
-   *   InfoType infoTypesElement = InfoType.newBuilder()
-   *     .setName(name)
-   *     .build();
-   *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder()
-   *     .addAllInfoTypes(infoTypes)
-   *     .build();
-   *   String type = "text/plain";
-   *   String value = "My email is example{@literal @}example.com.";
-   *   ContentItem itemsElement = ContentItem.newBuilder()
-   *     .setType(type)
-   *     .setValue(value)
-   *     .build();
-   *   List<ContentItem> items = Arrays.asList(itemsElement);
-   *   InspectContentRequest request = InspectContentRequest.newBuilder()
-   *     .setInspectConfig(inspectConfig)
-   *     .addAllItems(items)
-   *     .build();
-   *   InspectContentResponse response = dlpServiceClient.inspectContent(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final InspectContentResponse inspectContent(InspectContentRequest request) { - return inspectContentCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Finds potentially sensitive info in a list of strings. This method has limits on input size, - * processing time, and output size. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String name = "EMAIL_ADDRESS";
-   *   InfoType infoTypesElement = InfoType.newBuilder()
-   *     .setName(name)
-   *     .build();
-   *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder()
-   *     .addAllInfoTypes(infoTypes)
-   *     .build();
-   *   String type = "text/plain";
-   *   String value = "My email is example{@literal @}example.com.";
-   *   ContentItem itemsElement = ContentItem.newBuilder()
-   *     .setType(type)
-   *     .setValue(value)
-   *     .build();
-   *   List<ContentItem> items = Arrays.asList(itemsElement);
-   *   InspectContentRequest request = InspectContentRequest.newBuilder()
-   *     .setInspectConfig(inspectConfig)
-   *     .addAllItems(items)
-   *     .build();
-   *   ApiFuture<InspectContentResponse> future = dlpServiceClient.inspectContentCallable().futureCall(request);
-   *   // Do something
-   *   InspectContentResponse response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable - inspectContentCallable() { - return stub.inspectContentCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Redacts potentially sensitive info from a list of strings. This method has limits on input - * size, processing time, and output size. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String name = "EMAIL_ADDRESS";
-   *   InfoType infoTypesElement = InfoType.newBuilder()
-   *     .setName(name)
-   *     .build();
-   *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder()
-   *     .addAllInfoTypes(infoTypes)
-   *     .build();
-   *   String type = "text/plain";
-   *   String value = "My email is example{@literal @}example.com.";
-   *   ContentItem itemsElement = ContentItem.newBuilder()
-   *     .setType(type)
-   *     .setValue(value)
-   *     .build();
-   *   List<ContentItem> items = Arrays.asList(itemsElement);
-   *   String name2 = "EMAIL_ADDRESS";
-   *   InfoType infoType = InfoType.newBuilder()
-   *     .setName(name2)
-   *     .build();
-   *   String replaceWith = "REDACTED";
-   *   RedactContentRequest.ReplaceConfig replaceConfigsElement = RedactContentRequest.ReplaceConfig.newBuilder()
-   *     .setInfoType(infoType)
-   *     .setReplaceWith(replaceWith)
-   *     .build();
-   *   List<RedactContentRequest.ReplaceConfig> replaceConfigs = Arrays.asList(replaceConfigsElement);
-   *   RedactContentRequest request = RedactContentRequest.newBuilder()
-   *     .setInspectConfig(inspectConfig)
-   *     .addAllItems(items)
-   *     .addAllReplaceConfigs(replaceConfigs)
-   *     .build();
-   *   RedactContentResponse response = dlpServiceClient.redactContent(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final RedactContentResponse redactContent(RedactContentRequest request) { - return redactContentCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Redacts potentially sensitive info from a list of strings. This method has limits on input - * size, processing time, and output size. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String name = "EMAIL_ADDRESS";
-   *   InfoType infoTypesElement = InfoType.newBuilder()
-   *     .setName(name)
-   *     .build();
-   *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder()
-   *     .addAllInfoTypes(infoTypes)
-   *     .build();
-   *   String type = "text/plain";
-   *   String value = "My email is example{@literal @}example.com.";
-   *   ContentItem itemsElement = ContentItem.newBuilder()
-   *     .setType(type)
-   *     .setValue(value)
-   *     .build();
-   *   List<ContentItem> items = Arrays.asList(itemsElement);
-   *   String name2 = "EMAIL_ADDRESS";
-   *   InfoType infoType = InfoType.newBuilder()
-   *     .setName(name2)
-   *     .build();
-   *   String replaceWith = "REDACTED";
-   *   RedactContentRequest.ReplaceConfig replaceConfigsElement = RedactContentRequest.ReplaceConfig.newBuilder()
-   *     .setInfoType(infoType)
-   *     .setReplaceWith(replaceWith)
-   *     .build();
-   *   List<RedactContentRequest.ReplaceConfig> replaceConfigs = Arrays.asList(replaceConfigsElement);
-   *   RedactContentRequest request = RedactContentRequest.newBuilder()
-   *     .setInspectConfig(inspectConfig)
-   *     .addAllItems(items)
-   *     .addAllReplaceConfigs(replaceConfigs)
-   *     .build();
-   *   ApiFuture<RedactContentResponse> future = dlpServiceClient.redactContentCallable().futureCall(request);
-   *   // Do something
-   *   RedactContentResponse response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable redactContentCallable() { - return stub.redactContentCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * De-identifies potentially sensitive info from a list of strings. This method has limits on - * input size and output size. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   DeidentifyConfig deidentifyConfig = DeidentifyConfig.newBuilder().build();
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder().build();
-   *   List<ContentItem> items = new ArrayList<>();
-   *   DeidentifyContentResponse response = dlpServiceClient.deidentifyContent(deidentifyConfig, inspectConfig, items);
-   * }
-   * 
- * - * @param deidentifyConfig Configuration for the de-identification of the list of content items. - * @param inspectConfig Configuration for the inspector. - * @param items The list of items to inspect. Up to 100 are allowed per request. All items will be - * treated as text/*. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final DeidentifyContentResponse deidentifyContent( - DeidentifyConfig deidentifyConfig, InspectConfig inspectConfig, List items) { - - DeidentifyContentRequest request = - DeidentifyContentRequest.newBuilder() - .setDeidentifyConfig(deidentifyConfig) - .setInspectConfig(inspectConfig) - .addAllItems(items) - .build(); - return deidentifyContent(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * De-identifies potentially sensitive info from a list of strings. This method has limits on - * input size and output size. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   DeidentifyConfig deidentifyConfig = DeidentifyConfig.newBuilder().build();
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder().build();
-   *   List<ContentItem> items = new ArrayList<>();
-   *   DeidentifyContentRequest request = DeidentifyContentRequest.newBuilder()
-   *     .setDeidentifyConfig(deidentifyConfig)
-   *     .setInspectConfig(inspectConfig)
-   *     .addAllItems(items)
-   *     .build();
-   *   DeidentifyContentResponse response = dlpServiceClient.deidentifyContent(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final DeidentifyContentResponse deidentifyContent(DeidentifyContentRequest request) { - return deidentifyContentCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * De-identifies potentially sensitive info from a list of strings. This method has limits on - * input size and output size. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   DeidentifyConfig deidentifyConfig = DeidentifyConfig.newBuilder().build();
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder().build();
-   *   List<ContentItem> items = new ArrayList<>();
-   *   DeidentifyContentRequest request = DeidentifyContentRequest.newBuilder()
-   *     .setDeidentifyConfig(deidentifyConfig)
-   *     .setInspectConfig(inspectConfig)
-   *     .addAllItems(items)
-   *     .build();
-   *   ApiFuture<DeidentifyContentResponse> future = dlpServiceClient.deidentifyContentCallable().futureCall(request);
-   *   // Do something
-   *   DeidentifyContentResponse response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable - deidentifyContentCallable() { - return stub.deidentifyContentCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Schedules a job to compute risk analysis metrics over content in a Google Cloud Platform - * repository. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   PrivacyMetric privacyMetric = PrivacyMetric.newBuilder().build();
-   *   BigQueryTable sourceTable = BigQueryTable.newBuilder().build();
-   *   RiskAnalysisOperationResult response = dlpServiceClient.analyzeDataSourceRiskAsync(privacyMetric, sourceTable).get();
-   * }
-   * 
- * - * @param privacyMetric Privacy metric to compute. - * @param sourceTable Input dataset to compute metrics over. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture - analyzeDataSourceRiskAsync(PrivacyMetric privacyMetric, BigQueryTable sourceTable) { - - AnalyzeDataSourceRiskRequest request = - AnalyzeDataSourceRiskRequest.newBuilder() - .setPrivacyMetric(privacyMetric) - .setSourceTable(sourceTable) - .build(); - return analyzeDataSourceRiskAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Schedules a job to compute risk analysis metrics over content in a Google Cloud Platform - * repository. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   PrivacyMetric privacyMetric = PrivacyMetric.newBuilder().build();
-   *   BigQueryTable sourceTable = BigQueryTable.newBuilder().build();
-   *   AnalyzeDataSourceRiskRequest request = AnalyzeDataSourceRiskRequest.newBuilder()
-   *     .setPrivacyMetric(privacyMetric)
-   *     .setSourceTable(sourceTable)
-   *     .build();
-   *   RiskAnalysisOperationResult response = dlpServiceClient.analyzeDataSourceRiskAsync(request).get();
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture - analyzeDataSourceRiskAsync(AnalyzeDataSourceRiskRequest request) { - return analyzeDataSourceRiskOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Schedules a job to compute risk analysis metrics over content in a Google Cloud Platform - * repository. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   PrivacyMetric privacyMetric = PrivacyMetric.newBuilder().build();
-   *   BigQueryTable sourceTable = BigQueryTable.newBuilder().build();
-   *   AnalyzeDataSourceRiskRequest request = AnalyzeDataSourceRiskRequest.newBuilder()
-   *     .setPrivacyMetric(privacyMetric)
-   *     .setSourceTable(sourceTable)
-   *     .build();
-   *   OperationFuture<Operation> future = dlpServiceClient.analyzeDataSourceRiskOperationCallable().futureCall(request);
-   *   // Do something
-   *   RiskAnalysisOperationResult response = future.get();
-   * }
-   * 
- */ - public final OperationCallable< - AnalyzeDataSourceRiskRequest, RiskAnalysisOperationResult, RiskAnalysisOperationMetadata> - analyzeDataSourceRiskOperationCallable() { - return stub.analyzeDataSourceRiskOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Schedules a job to compute risk analysis metrics over content in a Google Cloud Platform - * repository. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   PrivacyMetric privacyMetric = PrivacyMetric.newBuilder().build();
-   *   BigQueryTable sourceTable = BigQueryTable.newBuilder().build();
-   *   AnalyzeDataSourceRiskRequest request = AnalyzeDataSourceRiskRequest.newBuilder()
-   *     .setPrivacyMetric(privacyMetric)
-   *     .setSourceTable(sourceTable)
-   *     .build();
-   *   ApiFuture<Operation> future = dlpServiceClient.analyzeDataSourceRiskCallable().futureCall(request);
-   *   // Do something
-   *   Operation response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable - analyzeDataSourceRiskCallable() { - return stub.analyzeDataSourceRiskCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Schedules a job scanning content in a Google Cloud Platform data repository. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String name = "EMAIL_ADDRESS";
-   *   InfoType infoTypesElement = InfoType.newBuilder()
-   *     .setName(name)
-   *     .build();
-   *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder()
-   *     .addAllInfoTypes(infoTypes)
-   *     .build();
-   *   String url = "gs://example_bucket/example_file.png";
-   *   CloudStorageOptions.FileSet fileSet = CloudStorageOptions.FileSet.newBuilder()
-   *     .setUrl(url)
-   *     .build();
-   *   CloudStorageOptions cloudStorageOptions = CloudStorageOptions.newBuilder()
-   *     .setFileSet(fileSet)
-   *     .build();
-   *   StorageConfig storageConfig = StorageConfig.newBuilder()
-   *     .setCloudStorageOptions(cloudStorageOptions)
-   *     .build();
-   *   OutputStorageConfig outputConfig = OutputStorageConfig.newBuilder().build();
-   *   InspectOperationResult response = dlpServiceClient.createInspectOperationAsync(inspectConfig, storageConfig, outputConfig).get();
-   * }
-   * 
- * - * @param inspectConfig Configuration for the inspector. - * @param storageConfig Specification of the data set to process. - * @param outputConfig Optional location to store findings. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture - createInspectOperationAsync( - InspectConfig inspectConfig, - StorageConfig storageConfig, - OutputStorageConfig outputConfig) { - - CreateInspectOperationRequest request = - CreateInspectOperationRequest.newBuilder() - .setInspectConfig(inspectConfig) - .setStorageConfig(storageConfig) - .setOutputConfig(outputConfig) - .build(); - return createInspectOperationAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Schedules a job scanning content in a Google Cloud Platform data repository. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String name = "EMAIL_ADDRESS";
-   *   InfoType infoTypesElement = InfoType.newBuilder()
-   *     .setName(name)
-   *     .build();
-   *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder()
-   *     .addAllInfoTypes(infoTypes)
-   *     .build();
-   *   String url = "gs://example_bucket/example_file.png";
-   *   CloudStorageOptions.FileSet fileSet = CloudStorageOptions.FileSet.newBuilder()
-   *     .setUrl(url)
-   *     .build();
-   *   CloudStorageOptions cloudStorageOptions = CloudStorageOptions.newBuilder()
-   *     .setFileSet(fileSet)
-   *     .build();
-   *   StorageConfig storageConfig = StorageConfig.newBuilder()
-   *     .setCloudStorageOptions(cloudStorageOptions)
-   *     .build();
-   *   OutputStorageConfig outputConfig = OutputStorageConfig.newBuilder().build();
-   *   CreateInspectOperationRequest request = CreateInspectOperationRequest.newBuilder()
-   *     .setInspectConfig(inspectConfig)
-   *     .setStorageConfig(storageConfig)
-   *     .setOutputConfig(outputConfig)
-   *     .build();
-   *   InspectOperationResult response = dlpServiceClient.createInspectOperationAsync(request).get();
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture - createInspectOperationAsync(CreateInspectOperationRequest request) { - return createInspectOperationOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Schedules a job scanning content in a Google Cloud Platform data repository. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String name = "EMAIL_ADDRESS";
-   *   InfoType infoTypesElement = InfoType.newBuilder()
-   *     .setName(name)
-   *     .build();
-   *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder()
-   *     .addAllInfoTypes(infoTypes)
-   *     .build();
-   *   String url = "gs://example_bucket/example_file.png";
-   *   CloudStorageOptions.FileSet fileSet = CloudStorageOptions.FileSet.newBuilder()
-   *     .setUrl(url)
-   *     .build();
-   *   CloudStorageOptions cloudStorageOptions = CloudStorageOptions.newBuilder()
-   *     .setFileSet(fileSet)
-   *     .build();
-   *   StorageConfig storageConfig = StorageConfig.newBuilder()
-   *     .setCloudStorageOptions(cloudStorageOptions)
-   *     .build();
-   *   OutputStorageConfig outputConfig = OutputStorageConfig.newBuilder().build();
-   *   CreateInspectOperationRequest request = CreateInspectOperationRequest.newBuilder()
-   *     .setInspectConfig(inspectConfig)
-   *     .setStorageConfig(storageConfig)
-   *     .setOutputConfig(outputConfig)
-   *     .build();
-   *   OperationFuture<Operation> future = dlpServiceClient.createInspectOperationOperationCallable().futureCall(request);
-   *   // Do something
-   *   InspectOperationResult response = future.get();
-   * }
-   * 
- */ - public final OperationCallable< - CreateInspectOperationRequest, InspectOperationResult, InspectOperationMetadata> - createInspectOperationOperationCallable() { - return stub.createInspectOperationOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Schedules a job scanning content in a Google Cloud Platform data repository. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String name = "EMAIL_ADDRESS";
-   *   InfoType infoTypesElement = InfoType.newBuilder()
-   *     .setName(name)
-   *     .build();
-   *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
-   *   InspectConfig inspectConfig = InspectConfig.newBuilder()
-   *     .addAllInfoTypes(infoTypes)
-   *     .build();
-   *   String url = "gs://example_bucket/example_file.png";
-   *   CloudStorageOptions.FileSet fileSet = CloudStorageOptions.FileSet.newBuilder()
-   *     .setUrl(url)
-   *     .build();
-   *   CloudStorageOptions cloudStorageOptions = CloudStorageOptions.newBuilder()
-   *     .setFileSet(fileSet)
-   *     .build();
-   *   StorageConfig storageConfig = StorageConfig.newBuilder()
-   *     .setCloudStorageOptions(cloudStorageOptions)
-   *     .build();
-   *   OutputStorageConfig outputConfig = OutputStorageConfig.newBuilder().build();
-   *   CreateInspectOperationRequest request = CreateInspectOperationRequest.newBuilder()
-   *     .setInspectConfig(inspectConfig)
-   *     .setStorageConfig(storageConfig)
-   *     .setOutputConfig(outputConfig)
-   *     .build();
-   *   ApiFuture<Operation> future = dlpServiceClient.createInspectOperationCallable().futureCall(request);
-   *   // Do something
-   *   Operation response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable - createInspectOperationCallable() { - return stub.createInspectOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns list of results for given inspect operation result set id. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   ResultName name = ResultName.of("[RESULT]");
-   *   ListInspectFindingsResponse response = dlpServiceClient.listInspectFindings(name);
-   * }
-   * 
- * - * @param name Identifier of the results set returned as metadata of the longrunning operation - * created by a call to InspectDataSource. Should be in the format of `inspect/results/{id}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListInspectFindingsResponse listInspectFindings(ResultName name) { - - ListInspectFindingsRequest request = - ListInspectFindingsRequest.newBuilder() - .setName(name == null ? null : name.toString()) - .build(); - return listInspectFindings(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns list of results for given inspect operation result set id. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   ResultName name = ResultName.of("[RESULT]");
-   *   ListInspectFindingsResponse response = dlpServiceClient.listInspectFindings(name.toString());
-   * }
-   * 
- * - * @param name Identifier of the results set returned as metadata of the longrunning operation - * created by a call to InspectDataSource. Should be in the format of `inspect/results/{id}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListInspectFindingsResponse listInspectFindings(String name) { - - ListInspectFindingsRequest request = - ListInspectFindingsRequest.newBuilder().setName(name).build(); - return listInspectFindings(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns list of results for given inspect operation result set id. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   ResultName name = ResultName.of("[RESULT]");
-   *   ListInspectFindingsRequest request = ListInspectFindingsRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   ListInspectFindingsResponse response = dlpServiceClient.listInspectFindings(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListInspectFindingsResponse listInspectFindings(ListInspectFindingsRequest request) { - return listInspectFindingsCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns list of results for given inspect operation result set id. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   ResultName name = ResultName.of("[RESULT]");
-   *   ListInspectFindingsRequest request = ListInspectFindingsRequest.newBuilder()
-   *     .setName(name.toString())
-   *     .build();
-   *   ApiFuture<ListInspectFindingsResponse> future = dlpServiceClient.listInspectFindingsCallable().futureCall(request);
-   *   // Do something
-   *   ListInspectFindingsResponse response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable - listInspectFindingsCallable() { - return stub.listInspectFindingsCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns sensitive information types for given category. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String category = "PII";
-   *   String languageCode = "en";
-   *   ListInfoTypesResponse response = dlpServiceClient.listInfoTypes(category, languageCode);
-   * }
-   * 
- * - * @param category Category name as returned by ListRootCategories. - * @param languageCode Optional BCP-47 language code for localized info type friendly names. If - * omitted, or if localized strings are not available, en-US strings will be returned. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListInfoTypesResponse listInfoTypes(String category, String languageCode) { - - ListInfoTypesRequest request = - ListInfoTypesRequest.newBuilder() - .setCategory(category) - .setLanguageCode(languageCode) - .build(); - return listInfoTypes(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns sensitive information types for given category. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String category = "PII";
-   *   String languageCode = "en";
-   *   ListInfoTypesRequest request = ListInfoTypesRequest.newBuilder()
-   *     .setCategory(category)
-   *     .setLanguageCode(languageCode)
-   *     .build();
-   *   ListInfoTypesResponse response = dlpServiceClient.listInfoTypes(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListInfoTypesResponse listInfoTypes(ListInfoTypesRequest request) { - return listInfoTypesCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns sensitive information types for given category. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String category = "PII";
-   *   String languageCode = "en";
-   *   ListInfoTypesRequest request = ListInfoTypesRequest.newBuilder()
-   *     .setCategory(category)
-   *     .setLanguageCode(languageCode)
-   *     .build();
-   *   ApiFuture<ListInfoTypesResponse> future = dlpServiceClient.listInfoTypesCallable().futureCall(request);
-   *   // Do something
-   *   ListInfoTypesResponse response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable listInfoTypesCallable() { - return stub.listInfoTypesCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the list of root categories of sensitive information. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String languageCode = "en";
-   *   ListRootCategoriesResponse response = dlpServiceClient.listRootCategories(languageCode);
-   * }
-   * 
- * - * @param languageCode Optional language code for localized friendly category names. If omitted or - * if localized strings are not available, en-US strings will be returned. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListRootCategoriesResponse listRootCategories(String languageCode) { - - ListRootCategoriesRequest request = - ListRootCategoriesRequest.newBuilder().setLanguageCode(languageCode).build(); - return listRootCategories(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the list of root categories of sensitive information. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String languageCode = "en";
-   *   ListRootCategoriesRequest request = ListRootCategoriesRequest.newBuilder()
-   *     .setLanguageCode(languageCode)
-   *     .build();
-   *   ListRootCategoriesResponse response = dlpServiceClient.listRootCategories(request);
-   * }
-   * 
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - private final ListRootCategoriesResponse listRootCategories(ListRootCategoriesRequest request) { - return listRootCategoriesCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD - /** - * Returns the list of root categories of sensitive information. - * - *

Sample code: - * - *


-   * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
-   *   String languageCode = "en";
-   *   ListRootCategoriesRequest request = ListRootCategoriesRequest.newBuilder()
-   *     .setLanguageCode(languageCode)
-   *     .build();
-   *   ApiFuture<ListRootCategoriesResponse> future = dlpServiceClient.listRootCategoriesCallable().futureCall(request);
-   *   // Do something
-   *   ListRootCategoriesResponse response = future.get();
-   * }
-   * 
- */ - public final UnaryCallable - listRootCategoriesCallable() { - return stub.listRootCategoriesCallable(); - } - - @Override - public final void close() { - stub.close(); - } - - @Override - public void shutdown() { - stub.shutdown(); - } - - @Override - public boolean isShutdown() { - return stub.isShutdown(); - } - - @Override - public boolean isTerminated() { - return stub.isTerminated(); - } - - @Override - public void shutdownNow() { - stub.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return stub.awaitTermination(duration, unit); - } -} diff --git a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/DlpServiceSettings.java b/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/DlpServiceSettings.java deleted file mode 100644 index d05cae011268..000000000000 --- a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/DlpServiceSettings.java +++ /dev/null @@ -1,305 +0,0 @@ -/* - * Copyright 2018 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.dlp.v2beta1; - -import com.google.api.core.ApiFunction; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.GoogleCredentialsProvider; -import com.google.api.gax.core.InstantiatingExecutorProvider; -import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.ClientSettings; -import com.google.api.gax.rpc.OperationCallSettings; -import com.google.api.gax.rpc.TransportChannelProvider; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.cloud.dlp.v2beta1.stub.DlpServiceStubSettings; -import com.google.longrunning.Operation; -import com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest; -import com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentResponse; -import com.google.privacy.dlp.v2beta1.InspectContentRequest; -import com.google.privacy.dlp.v2beta1.InspectContentResponse; -import com.google.privacy.dlp.v2beta1.InspectOperationMetadata; -import com.google.privacy.dlp.v2beta1.InspectOperationResult; -import com.google.privacy.dlp.v2beta1.ListInfoTypesRequest; -import com.google.privacy.dlp.v2beta1.ListInfoTypesResponse; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse; -import com.google.privacy.dlp.v2beta1.RedactContentRequest; -import com.google.privacy.dlp.v2beta1.RedactContentResponse; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult; -import java.io.IOException; -import java.util.List; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Settings class to configure an instance of {@link DlpServiceClient}. - * - *

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

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

The builder of this class is recursive, so contained classes are themselves builders. When - * build() is called, the tree of builders is called to create the complete settings object. For - * example, to set the total timeout of inspectContent to 30 seconds: - * - *

- * 
- * DlpServiceSettings.Builder dlpServiceSettingsBuilder =
- *     DlpServiceSettings.newBuilder();
- * dlpServiceSettingsBuilder.inspectContentSettings().getRetrySettings().toBuilder()
- *     .setTotalTimeout(Duration.ofSeconds(30));
- * DlpServiceSettings dlpServiceSettings = dlpServiceSettingsBuilder.build();
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class DlpServiceSettings extends ClientSettings { - /** Returns the object with the settings used for calls to inspectContent. */ - public UnaryCallSettings inspectContentSettings() { - return ((DlpServiceStubSettings) getStubSettings()).inspectContentSettings(); - } - - /** Returns the object with the settings used for calls to redactContent. */ - public UnaryCallSettings redactContentSettings() { - return ((DlpServiceStubSettings) getStubSettings()).redactContentSettings(); - } - - /** Returns the object with the settings used for calls to deidentifyContent. */ - public UnaryCallSettings - deidentifyContentSettings() { - return ((DlpServiceStubSettings) getStubSettings()).deidentifyContentSettings(); - } - - /** Returns the object with the settings used for calls to analyzeDataSourceRisk. */ - public UnaryCallSettings - analyzeDataSourceRiskSettings() { - return ((DlpServiceStubSettings) getStubSettings()).analyzeDataSourceRiskSettings(); - } - - /** Returns the object with the settings used for calls to analyzeDataSourceRisk. */ - public OperationCallSettings< - AnalyzeDataSourceRiskRequest, RiskAnalysisOperationResult, RiskAnalysisOperationMetadata> - analyzeDataSourceRiskOperationSettings() { - return ((DlpServiceStubSettings) getStubSettings()).analyzeDataSourceRiskOperationSettings(); - } - - /** Returns the object with the settings used for calls to createInspectOperation. */ - public UnaryCallSettings - createInspectOperationSettings() { - return ((DlpServiceStubSettings) getStubSettings()).createInspectOperationSettings(); - } - - /** Returns the object with the settings used for calls to createInspectOperation. */ - public OperationCallSettings< - CreateInspectOperationRequest, InspectOperationResult, InspectOperationMetadata> - createInspectOperationOperationSettings() { - return ((DlpServiceStubSettings) getStubSettings()).createInspectOperationOperationSettings(); - } - - /** Returns the object with the settings used for calls to listInspectFindings. */ - public UnaryCallSettings - listInspectFindingsSettings() { - return ((DlpServiceStubSettings) getStubSettings()).listInspectFindingsSettings(); - } - - /** Returns the object with the settings used for calls to listInfoTypes. */ - public UnaryCallSettings listInfoTypesSettings() { - return ((DlpServiceStubSettings) getStubSettings()).listInfoTypesSettings(); - } - - /** Returns the object with the settings used for calls to listRootCategories. */ - public UnaryCallSettings - listRootCategoriesSettings() { - return ((DlpServiceStubSettings) getStubSettings()).listRootCategoriesSettings(); - } - - public static final DlpServiceSettings create(DlpServiceStubSettings stub) throws IOException { - return new DlpServiceSettings.Builder(stub.toBuilder()).build(); - } - - /** Returns a builder for the default ExecutorProvider for this service. */ - public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { - return DlpServiceStubSettings.defaultExecutorProviderBuilder(); - } - - /** Returns the default service endpoint. */ - public static String getDefaultEndpoint() { - return DlpServiceStubSettings.getDefaultEndpoint(); - } - - /** Returns the default service scopes. */ - public static List getDefaultServiceScopes() { - return DlpServiceStubSettings.getDefaultServiceScopes(); - } - - /** Returns a builder for the default credentials for this service. */ - public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { - return DlpServiceStubSettings.defaultCredentialsProviderBuilder(); - } - - /** Returns a builder for the default ChannelProvider for this service. */ - public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { - return DlpServiceStubSettings.defaultGrpcTransportProviderBuilder(); - } - - public static TransportChannelProvider defaultTransportChannelProvider() { - return DlpServiceStubSettings.defaultTransportChannelProvider(); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { - return DlpServiceStubSettings.defaultApiClientHeaderProviderBuilder(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder() { - return Builder.createDefault(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder(ClientContext clientContext) { - return new Builder(clientContext); - } - - /** Returns a builder containing all the values of this settings class. */ - public Builder toBuilder() { - return new Builder(this); - } - - protected DlpServiceSettings(Builder settingsBuilder) throws IOException { - super(settingsBuilder); - } - - /** Builder for DlpServiceSettings. */ - public static class Builder extends ClientSettings.Builder { - protected Builder() throws IOException { - this((ClientContext) null); - } - - protected Builder(ClientContext clientContext) { - super(DlpServiceStubSettings.newBuilder(clientContext)); - } - - private static Builder createDefault() { - return new Builder(DlpServiceStubSettings.newBuilder()); - } - - protected Builder(DlpServiceSettings settings) { - super(settings.getStubSettings().toBuilder()); - } - - protected Builder(DlpServiceStubSettings.Builder stubSettings) { - super(stubSettings); - } - - public DlpServiceStubSettings.Builder getStubSettingsBuilder() { - return ((DlpServiceStubSettings.Builder) getStubSettings()); - } - - // NEXT_MAJOR_VER: remove 'throws Exception' - /** - * Applies the given settings updater function to all of the unary API methods in this service. - * - *

Note: This method does not support applying settings to streaming methods. - */ - public Builder applyToAllUnaryMethods( - ApiFunction, Void> settingsUpdater) throws Exception { - super.applyToAllUnaryMethods( - getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); - return this; - } - - /** Returns the builder for the settings used for calls to inspectContent. */ - public UnaryCallSettings.Builder - inspectContentSettings() { - return getStubSettingsBuilder().inspectContentSettings(); - } - - /** Returns the builder for the settings used for calls to redactContent. */ - public UnaryCallSettings.Builder - redactContentSettings() { - return getStubSettingsBuilder().redactContentSettings(); - } - - /** Returns the builder for the settings used for calls to deidentifyContent. */ - public UnaryCallSettings.Builder - deidentifyContentSettings() { - return getStubSettingsBuilder().deidentifyContentSettings(); - } - - /** Returns the builder for the settings used for calls to analyzeDataSourceRisk. */ - public UnaryCallSettings.Builder - analyzeDataSourceRiskSettings() { - return getStubSettingsBuilder().analyzeDataSourceRiskSettings(); - } - - /** Returns the builder for the settings used for calls to analyzeDataSourceRisk. */ - public OperationCallSettings.Builder< - AnalyzeDataSourceRiskRequest, RiskAnalysisOperationResult, - RiskAnalysisOperationMetadata> - analyzeDataSourceRiskOperationSettings() { - return getStubSettingsBuilder().analyzeDataSourceRiskOperationSettings(); - } - - /** Returns the builder for the settings used for calls to createInspectOperation. */ - public UnaryCallSettings.Builder - createInspectOperationSettings() { - return getStubSettingsBuilder().createInspectOperationSettings(); - } - - /** Returns the builder for the settings used for calls to createInspectOperation. */ - public OperationCallSettings.Builder< - CreateInspectOperationRequest, InspectOperationResult, InspectOperationMetadata> - createInspectOperationOperationSettings() { - return getStubSettingsBuilder().createInspectOperationOperationSettings(); - } - - /** Returns the builder for the settings used for calls to listInspectFindings. */ - public UnaryCallSettings.Builder - listInspectFindingsSettings() { - return getStubSettingsBuilder().listInspectFindingsSettings(); - } - - /** Returns the builder for the settings used for calls to listInfoTypes. */ - public UnaryCallSettings.Builder - listInfoTypesSettings() { - return getStubSettingsBuilder().listInfoTypesSettings(); - } - - /** Returns the builder for the settings used for calls to listRootCategories. */ - public UnaryCallSettings.Builder - listRootCategoriesSettings() { - return getStubSettingsBuilder().listRootCategoriesSettings(); - } - - @Override - public DlpServiceSettings build() throws IOException { - return new DlpServiceSettings(this); - } - } -} diff --git a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/package-info.java b/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/package-info.java deleted file mode 100644 index f96190535ddd..000000000000 --- a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/package-info.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright 2018 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * 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. - */ - -/** - * A client to DLP API. - * - *

The interfaces provided are listed below, along with usage samples. - * - *

================ DlpServiceClient ================ - * - *

Service Description: The DLP API is a service that allows clients to detect the presence of - * Personally Identifiable Information (PII) and other privacy-sensitive data in user-supplied, - * unstructured data streams, like text blocks or images. The service also includes methods for - * sensitive data redaction and scheduling of data scans on Google Cloud Platform based data sets. - * - *

Sample for DlpServiceClient: - * - *

- * 
- * try (DlpServiceClient dlpServiceClient = DlpServiceClient.create()) {
- *   String name = "EMAIL_ADDRESS";
- *   InfoType infoTypesElement = InfoType.newBuilder()
- *     .setName(name)
- *     .build();
- *   List<InfoType> infoTypes = Arrays.asList(infoTypesElement);
- *   InspectConfig inspectConfig = InspectConfig.newBuilder()
- *     .addAllInfoTypes(infoTypes)
- *     .build();
- *   String type = "text/plain";
- *   String value = "My email is example{@literal @}example.com.";
- *   ContentItem itemsElement = ContentItem.newBuilder()
- *     .setType(type)
- *     .setValue(value)
- *     .build();
- *   List<ContentItem> items = Arrays.asList(itemsElement);
- *   InspectContentResponse response = dlpServiceClient.inspectContent(inspectConfig, items);
- * }
- * 
- * 
- */ -package com.google.cloud.dlp.v2beta1; diff --git a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/DlpServiceStub.java b/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/DlpServiceStub.java deleted file mode 100644 index 9db574d0e575..000000000000 --- a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/DlpServiceStub.java +++ /dev/null @@ -1,109 +0,0 @@ -/* - * Copyright 2018 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.dlp.v2beta1.stub; - -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.longrunning.Operation; -import com.google.longrunning.stub.OperationsStub; -import com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest; -import com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentResponse; -import com.google.privacy.dlp.v2beta1.InspectContentRequest; -import com.google.privacy.dlp.v2beta1.InspectContentResponse; -import com.google.privacy.dlp.v2beta1.InspectOperationMetadata; -import com.google.privacy.dlp.v2beta1.InspectOperationResult; -import com.google.privacy.dlp.v2beta1.ListInfoTypesRequest; -import com.google.privacy.dlp.v2beta1.ListInfoTypesResponse; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse; -import com.google.privacy.dlp.v2beta1.RedactContentRequest; -import com.google.privacy.dlp.v2beta1.RedactContentResponse; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Base stub class for DLP API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator") -@BetaApi("A restructuring of stub classes is planned, so this may break in the future") -public abstract class DlpServiceStub implements BackgroundResource { - - public OperationsStub getOperationsStub() { - throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); - } - - public UnaryCallable inspectContentCallable() { - throw new UnsupportedOperationException("Not implemented: inspectContentCallable()"); - } - - public UnaryCallable redactContentCallable() { - throw new UnsupportedOperationException("Not implemented: redactContentCallable()"); - } - - public UnaryCallable - deidentifyContentCallable() { - throw new UnsupportedOperationException("Not implemented: deidentifyContentCallable()"); - } - - public OperationCallable< - AnalyzeDataSourceRiskRequest, RiskAnalysisOperationResult, RiskAnalysisOperationMetadata> - analyzeDataSourceRiskOperationCallable() { - throw new UnsupportedOperationException( - "Not implemented: analyzeDataSourceRiskOperationCallable()"); - } - - public UnaryCallable analyzeDataSourceRiskCallable() { - throw new UnsupportedOperationException("Not implemented: analyzeDataSourceRiskCallable()"); - } - - public OperationCallable< - CreateInspectOperationRequest, InspectOperationResult, InspectOperationMetadata> - createInspectOperationOperationCallable() { - throw new UnsupportedOperationException( - "Not implemented: createInspectOperationOperationCallable()"); - } - - public UnaryCallable createInspectOperationCallable() { - throw new UnsupportedOperationException("Not implemented: createInspectOperationCallable()"); - } - - public UnaryCallable - listInspectFindingsCallable() { - throw new UnsupportedOperationException("Not implemented: listInspectFindingsCallable()"); - } - - public UnaryCallable listInfoTypesCallable() { - throw new UnsupportedOperationException("Not implemented: listInfoTypesCallable()"); - } - - public UnaryCallable - listRootCategoriesCallable() { - throw new UnsupportedOperationException("Not implemented: listRootCategoriesCallable()"); - } - - @Override - public abstract void close(); -} diff --git a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/DlpServiceStubSettings.java b/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/DlpServiceStubSettings.java deleted file mode 100644 index b2ae514a205c..000000000000 --- a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/DlpServiceStubSettings.java +++ /dev/null @@ -1,579 +0,0 @@ -/* - * Copyright 2018 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.dlp.v2beta1.stub; - -import com.google.api.core.ApiFunction; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.GaxProperties; -import com.google.api.gax.core.GoogleCredentialsProvider; -import com.google.api.gax.core.InstantiatingExecutorProvider; -import com.google.api.gax.grpc.GaxGrpcProperties; -import com.google.api.gax.grpc.GrpcTransportChannel; -import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; -import com.google.api.gax.grpc.ProtoOperationTransformers; -import com.google.api.gax.longrunning.OperationSnapshot; -import com.google.api.gax.longrunning.OperationTimedPollAlgorithm; -import com.google.api.gax.retrying.RetrySettings; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.OperationCallSettings; -import com.google.api.gax.rpc.StatusCode; -import com.google.api.gax.rpc.StubSettings; -import com.google.api.gax.rpc.TransportChannelProvider; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.common.collect.ImmutableList; -import com.google.common.collect.ImmutableMap; -import com.google.common.collect.ImmutableSet; -import com.google.common.collect.Lists; -import com.google.longrunning.Operation; -import com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest; -import com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentResponse; -import com.google.privacy.dlp.v2beta1.InspectContentRequest; -import com.google.privacy.dlp.v2beta1.InspectContentResponse; -import com.google.privacy.dlp.v2beta1.InspectOperationMetadata; -import com.google.privacy.dlp.v2beta1.InspectOperationResult; -import com.google.privacy.dlp.v2beta1.ListInfoTypesRequest; -import com.google.privacy.dlp.v2beta1.ListInfoTypesResponse; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse; -import com.google.privacy.dlp.v2beta1.RedactContentRequest; -import com.google.privacy.dlp.v2beta1.RedactContentResponse; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult; -import java.io.IOException; -import java.util.List; -import javax.annotation.Generated; -import org.threeten.bp.Duration; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * Settings class to configure an instance of {@link DlpServiceStub}. - * - *

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

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

The builder of this class is recursive, so contained classes are themselves builders. When - * build() is called, the tree of builders is called to create the complete settings object. For - * example, to set the total timeout of inspectContent to 30 seconds: - * - *

- * 
- * DlpServiceStubSettings.Builder dlpServiceSettingsBuilder =
- *     DlpServiceStubSettings.newBuilder();
- * dlpServiceSettingsBuilder.inspectContentSettings().getRetrySettings().toBuilder()
- *     .setTotalTimeout(Duration.ofSeconds(30));
- * DlpServiceStubSettings dlpServiceSettings = dlpServiceSettingsBuilder.build();
- * 
- * 
- */ -@Generated("by gapic-generator") -@BetaApi -public class DlpServiceStubSettings extends StubSettings { - /** The default scopes of the service. */ - private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); - - private final UnaryCallSettings - inspectContentSettings; - private final UnaryCallSettings - redactContentSettings; - private final UnaryCallSettings - deidentifyContentSettings; - private final UnaryCallSettings - analyzeDataSourceRiskSettings; - private final OperationCallSettings< - AnalyzeDataSourceRiskRequest, RiskAnalysisOperationResult, RiskAnalysisOperationMetadata> - analyzeDataSourceRiskOperationSettings; - private final UnaryCallSettings - createInspectOperationSettings; - private final OperationCallSettings< - CreateInspectOperationRequest, InspectOperationResult, InspectOperationMetadata> - createInspectOperationOperationSettings; - private final UnaryCallSettings - listInspectFindingsSettings; - private final UnaryCallSettings - listInfoTypesSettings; - private final UnaryCallSettings - listRootCategoriesSettings; - - /** Returns the object with the settings used for calls to inspectContent. */ - public UnaryCallSettings inspectContentSettings() { - return inspectContentSettings; - } - - /** Returns the object with the settings used for calls to redactContent. */ - public UnaryCallSettings redactContentSettings() { - return redactContentSettings; - } - - /** Returns the object with the settings used for calls to deidentifyContent. */ - public UnaryCallSettings - deidentifyContentSettings() { - return deidentifyContentSettings; - } - - /** Returns the object with the settings used for calls to analyzeDataSourceRisk. */ - public UnaryCallSettings - analyzeDataSourceRiskSettings() { - return analyzeDataSourceRiskSettings; - } - - /** Returns the object with the settings used for calls to analyzeDataSourceRisk. */ - public OperationCallSettings< - AnalyzeDataSourceRiskRequest, RiskAnalysisOperationResult, RiskAnalysisOperationMetadata> - analyzeDataSourceRiskOperationSettings() { - return analyzeDataSourceRiskOperationSettings; - } - - /** Returns the object with the settings used for calls to createInspectOperation. */ - public UnaryCallSettings - createInspectOperationSettings() { - return createInspectOperationSettings; - } - - /** Returns the object with the settings used for calls to createInspectOperation. */ - public OperationCallSettings< - CreateInspectOperationRequest, InspectOperationResult, InspectOperationMetadata> - createInspectOperationOperationSettings() { - return createInspectOperationOperationSettings; - } - - /** Returns the object with the settings used for calls to listInspectFindings. */ - public UnaryCallSettings - listInspectFindingsSettings() { - return listInspectFindingsSettings; - } - - /** Returns the object with the settings used for calls to listInfoTypes. */ - public UnaryCallSettings listInfoTypesSettings() { - return listInfoTypesSettings; - } - - /** Returns the object with the settings used for calls to listRootCategories. */ - public UnaryCallSettings - listRootCategoriesSettings() { - return listRootCategoriesSettings; - } - - @BetaApi("A restructuring of stub classes is planned, so this may break in the future") - public DlpServiceStub createStub() throws IOException { - if (getTransportChannelProvider() - .getTransportName() - .equals(GrpcTransportChannel.getGrpcTransportName())) { - return GrpcDlpServiceStub.create(this); - } else { - throw new UnsupportedOperationException( - "Transport not supported: " + getTransportChannelProvider().getTransportName()); - } - } - - /** Returns a builder for the default ExecutorProvider for this service. */ - public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { - return InstantiatingExecutorProvider.newBuilder(); - } - - /** Returns the default service endpoint. */ - public static String getDefaultEndpoint() { - return "dlp.googleapis.com:443"; - } - - /** Returns the default service scopes. */ - public static List getDefaultServiceScopes() { - return DEFAULT_SERVICE_SCOPES; - } - - /** Returns a builder for the default credentials for this service. */ - public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { - return GoogleCredentialsProvider.newBuilder().setScopesToApply(DEFAULT_SERVICE_SCOPES); - } - - /** Returns a builder for the default ChannelProvider for this service. */ - public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { - return InstantiatingGrpcChannelProvider.newBuilder(); - } - - public static TransportChannelProvider defaultTransportChannelProvider() { - return defaultGrpcTransportProviderBuilder().build(); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { - return ApiClientHeaderProvider.newBuilder() - .setGeneratedLibToken( - "gapic", GaxProperties.getLibraryVersion(DlpServiceStubSettings.class)) - .setTransportToken( - GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder() { - return Builder.createDefault(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder(ClientContext clientContext) { - return new Builder(clientContext); - } - - /** Returns a builder containing all the values of this settings class. */ - public Builder toBuilder() { - return new Builder(this); - } - - protected DlpServiceStubSettings(Builder settingsBuilder) throws IOException { - super(settingsBuilder); - - inspectContentSettings = settingsBuilder.inspectContentSettings().build(); - redactContentSettings = settingsBuilder.redactContentSettings().build(); - deidentifyContentSettings = settingsBuilder.deidentifyContentSettings().build(); - analyzeDataSourceRiskSettings = settingsBuilder.analyzeDataSourceRiskSettings().build(); - analyzeDataSourceRiskOperationSettings = - settingsBuilder.analyzeDataSourceRiskOperationSettings().build(); - createInspectOperationSettings = settingsBuilder.createInspectOperationSettings().build(); - createInspectOperationOperationSettings = - settingsBuilder.createInspectOperationOperationSettings().build(); - listInspectFindingsSettings = settingsBuilder.listInspectFindingsSettings().build(); - listInfoTypesSettings = settingsBuilder.listInfoTypesSettings().build(); - listRootCategoriesSettings = settingsBuilder.listRootCategoriesSettings().build(); - } - - /** Builder for DlpServiceStubSettings. */ - public static class Builder extends StubSettings.Builder { - private final ImmutableList> unaryMethodSettingsBuilders; - - private final UnaryCallSettings.Builder - inspectContentSettings; - private final UnaryCallSettings.Builder - redactContentSettings; - private final UnaryCallSettings.Builder - deidentifyContentSettings; - private final UnaryCallSettings.Builder - analyzeDataSourceRiskSettings; - private final OperationCallSettings.Builder< - AnalyzeDataSourceRiskRequest, RiskAnalysisOperationResult, - RiskAnalysisOperationMetadata> - analyzeDataSourceRiskOperationSettings; - private final UnaryCallSettings.Builder - createInspectOperationSettings; - private final OperationCallSettings.Builder< - CreateInspectOperationRequest, InspectOperationResult, InspectOperationMetadata> - createInspectOperationOperationSettings; - private final UnaryCallSettings.Builder - listInspectFindingsSettings; - private final UnaryCallSettings.Builder - listInfoTypesSettings; - private final UnaryCallSettings.Builder - listRootCategoriesSettings; - - private static final ImmutableMap> - RETRYABLE_CODE_DEFINITIONS; - - static { - ImmutableMap.Builder> definitions = - ImmutableMap.builder(); - definitions.put( - "idempotent", - ImmutableSet.copyOf( - Lists.newArrayList( - StatusCode.Code.DEADLINE_EXCEEDED, StatusCode.Code.UNAVAILABLE))); - definitions.put("non_idempotent", ImmutableSet.copyOf(Lists.newArrayList())); - RETRYABLE_CODE_DEFINITIONS = definitions.build(); - } - - private static final ImmutableMap RETRY_PARAM_DEFINITIONS; - - static { - ImmutableMap.Builder definitions = ImmutableMap.builder(); - RetrySettings settings = null; - settings = - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(100L)) - .setRetryDelayMultiplier(1.3) - .setMaxRetryDelay(Duration.ofMillis(60000L)) - .setInitialRpcTimeout(Duration.ofMillis(20000L)) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ofMillis(20000L)) - .setTotalTimeout(Duration.ofMillis(600000L)) - .build(); - definitions.put("default", settings); - RETRY_PARAM_DEFINITIONS = definitions.build(); - } - - protected Builder() { - this((ClientContext) null); - } - - protected Builder(ClientContext clientContext) { - super(clientContext); - - inspectContentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - redactContentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - deidentifyContentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - analyzeDataSourceRiskSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - analyzeDataSourceRiskOperationSettings = OperationCallSettings.newBuilder(); - - createInspectOperationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - createInspectOperationOperationSettings = OperationCallSettings.newBuilder(); - - listInspectFindingsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - listInfoTypesSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - listRootCategoriesSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - - unaryMethodSettingsBuilders = - ImmutableList.>of( - inspectContentSettings, - redactContentSettings, - deidentifyContentSettings, - analyzeDataSourceRiskSettings, - createInspectOperationSettings, - listInspectFindingsSettings, - listInfoTypesSettings, - listRootCategoriesSettings); - - initDefaults(this); - } - - private static Builder createDefault() { - Builder builder = new Builder((ClientContext) null); - builder.setTransportChannelProvider(defaultTransportChannelProvider()); - builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); - builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); - builder.setEndpoint(getDefaultEndpoint()); - return initDefaults(builder); - } - - private static Builder initDefaults(Builder builder) { - - builder - .inspectContentSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .redactContentSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .deidentifyContentSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .analyzeDataSourceRiskSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .createInspectOperationSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .listInspectFindingsSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .listInfoTypesSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - - builder - .listRootCategoriesSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); - builder - .analyzeDataSourceRiskOperationSettings() - .setInitialCallSettings( - UnaryCallSettings - .newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create( - RiskAnalysisOperationResult.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create( - RiskAnalysisOperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(20000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) // ignored - .setRpcTimeoutMultiplier(1.0) // ignored - .setMaxRpcTimeout(Duration.ZERO) // ignored - .setTotalTimeout(Duration.ofMillis(86400000L)) - .build())); - builder - .createInspectOperationOperationSettings() - .setInitialCallSettings( - UnaryCallSettings - .newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create(InspectOperationResult.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create(InspectOperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(20000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) // ignored - .setRpcTimeoutMultiplier(1.0) // ignored - .setMaxRpcTimeout(Duration.ZERO) // ignored - .setTotalTimeout(Duration.ofMillis(86400000L)) - .build())); - - return builder; - } - - protected Builder(DlpServiceStubSettings settings) { - super(settings); - - inspectContentSettings = settings.inspectContentSettings.toBuilder(); - redactContentSettings = settings.redactContentSettings.toBuilder(); - deidentifyContentSettings = settings.deidentifyContentSettings.toBuilder(); - analyzeDataSourceRiskSettings = settings.analyzeDataSourceRiskSettings.toBuilder(); - analyzeDataSourceRiskOperationSettings = - settings.analyzeDataSourceRiskOperationSettings.toBuilder(); - createInspectOperationSettings = settings.createInspectOperationSettings.toBuilder(); - createInspectOperationOperationSettings = - settings.createInspectOperationOperationSettings.toBuilder(); - listInspectFindingsSettings = settings.listInspectFindingsSettings.toBuilder(); - listInfoTypesSettings = settings.listInfoTypesSettings.toBuilder(); - listRootCategoriesSettings = settings.listRootCategoriesSettings.toBuilder(); - - unaryMethodSettingsBuilders = - ImmutableList.>of( - inspectContentSettings, - redactContentSettings, - deidentifyContentSettings, - analyzeDataSourceRiskSettings, - createInspectOperationSettings, - listInspectFindingsSettings, - listInfoTypesSettings, - listRootCategoriesSettings); - } - - // NEXT_MAJOR_VER: remove 'throws Exception' - /** - * Applies the given settings updater function to all of the unary API methods in this service. - * - *

Note: This method does not support applying settings to streaming methods. - */ - public Builder applyToAllUnaryMethods( - ApiFunction, Void> settingsUpdater) throws Exception { - super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); - return this; - } - - public ImmutableList> unaryMethodSettingsBuilders() { - return unaryMethodSettingsBuilders; - } - - /** Returns the builder for the settings used for calls to inspectContent. */ - public UnaryCallSettings.Builder - inspectContentSettings() { - return inspectContentSettings; - } - - /** Returns the builder for the settings used for calls to redactContent. */ - public UnaryCallSettings.Builder - redactContentSettings() { - return redactContentSettings; - } - - /** Returns the builder for the settings used for calls to deidentifyContent. */ - public UnaryCallSettings.Builder - deidentifyContentSettings() { - return deidentifyContentSettings; - } - - /** Returns the builder for the settings used for calls to analyzeDataSourceRisk. */ - public UnaryCallSettings.Builder - analyzeDataSourceRiskSettings() { - return analyzeDataSourceRiskSettings; - } - - /** Returns the builder for the settings used for calls to analyzeDataSourceRisk. */ - public OperationCallSettings.Builder< - AnalyzeDataSourceRiskRequest, RiskAnalysisOperationResult, - RiskAnalysisOperationMetadata> - analyzeDataSourceRiskOperationSettings() { - return analyzeDataSourceRiskOperationSettings; - } - - /** Returns the builder for the settings used for calls to createInspectOperation. */ - public UnaryCallSettings.Builder - createInspectOperationSettings() { - return createInspectOperationSettings; - } - - /** Returns the builder for the settings used for calls to createInspectOperation. */ - public OperationCallSettings.Builder< - CreateInspectOperationRequest, InspectOperationResult, InspectOperationMetadata> - createInspectOperationOperationSettings() { - return createInspectOperationOperationSettings; - } - - /** Returns the builder for the settings used for calls to listInspectFindings. */ - public UnaryCallSettings.Builder - listInspectFindingsSettings() { - return listInspectFindingsSettings; - } - - /** Returns the builder for the settings used for calls to listInfoTypes. */ - public UnaryCallSettings.Builder - listInfoTypesSettings() { - return listInfoTypesSettings; - } - - /** Returns the builder for the settings used for calls to listRootCategories. */ - public UnaryCallSettings.Builder - listRootCategoriesSettings() { - return listRootCategoriesSettings; - } - - @Override - public DlpServiceStubSettings build() throws IOException { - return new DlpServiceStubSettings(this); - } - } -} diff --git a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/GrpcDlpServiceStub.java b/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/GrpcDlpServiceStub.java deleted file mode 100644 index 779035a7e2f5..000000000000 --- a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/GrpcDlpServiceStub.java +++ /dev/null @@ -1,373 +0,0 @@ -/* - * Copyright 2018 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.dlp.v2beta1.stub; - -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.core.BackgroundResourceAggregation; -import com.google.api.gax.grpc.GrpcCallSettings; -import com.google.api.gax.grpc.GrpcStubCallableFactory; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.longrunning.Operation; -import com.google.longrunning.stub.GrpcOperationsStub; -import com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest; -import com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentResponse; -import com.google.privacy.dlp.v2beta1.InspectContentRequest; -import com.google.privacy.dlp.v2beta1.InspectContentResponse; -import com.google.privacy.dlp.v2beta1.InspectOperationMetadata; -import com.google.privacy.dlp.v2beta1.InspectOperationResult; -import com.google.privacy.dlp.v2beta1.ListInfoTypesRequest; -import com.google.privacy.dlp.v2beta1.ListInfoTypesResponse; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse; -import com.google.privacy.dlp.v2beta1.RedactContentRequest; -import com.google.privacy.dlp.v2beta1.RedactContentResponse; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationMetadata; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult; -import io.grpc.MethodDescriptor; -import io.grpc.protobuf.ProtoUtils; -import java.io.IOException; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS -/** - * gRPC stub implementation for DLP API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator") -@BetaApi("A restructuring of stub classes is planned, so this may break in the future") -public class GrpcDlpServiceStub extends DlpServiceStub { - - private static final MethodDescriptor - inspectContentMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.privacy.dlp.v2beta1.DlpService/InspectContent") - .setRequestMarshaller( - ProtoUtils.marshaller(InspectContentRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(InspectContentResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor - redactContentMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.privacy.dlp.v2beta1.DlpService/RedactContent") - .setRequestMarshaller( - ProtoUtils.marshaller(RedactContentRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(RedactContentResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor - deidentifyContentMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.privacy.dlp.v2beta1.DlpService/DeidentifyContent") - .setRequestMarshaller( - ProtoUtils.marshaller(DeidentifyContentRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(DeidentifyContentResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor - analyzeDataSourceRiskMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.privacy.dlp.v2beta1.DlpService/AnalyzeDataSourceRisk") - .setRequestMarshaller( - ProtoUtils.marshaller(AnalyzeDataSourceRiskRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - private static final MethodDescriptor - createInspectOperationMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.privacy.dlp.v2beta1.DlpService/CreateInspectOperation") - .setRequestMarshaller( - ProtoUtils.marshaller(CreateInspectOperationRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - private static final MethodDescriptor - listInspectFindingsMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.privacy.dlp.v2beta1.DlpService/ListInspectFindings") - .setRequestMarshaller( - ProtoUtils.marshaller(ListInspectFindingsRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(ListInspectFindingsResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor - listInfoTypesMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.privacy.dlp.v2beta1.DlpService/ListInfoTypes") - .setRequestMarshaller( - ProtoUtils.marshaller(ListInfoTypesRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(ListInfoTypesResponse.getDefaultInstance())) - .build(); - private static final MethodDescriptor - listRootCategoriesMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.privacy.dlp.v2beta1.DlpService/ListRootCategories") - .setRequestMarshaller( - ProtoUtils.marshaller(ListRootCategoriesRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(ListRootCategoriesResponse.getDefaultInstance())) - .build(); - - private final BackgroundResource backgroundResources; - private final GrpcOperationsStub operationsStub; - - private final UnaryCallable inspectContentCallable; - private final UnaryCallable redactContentCallable; - private final UnaryCallable - deidentifyContentCallable; - private final UnaryCallable - analyzeDataSourceRiskCallable; - private final OperationCallable< - AnalyzeDataSourceRiskRequest, RiskAnalysisOperationResult, RiskAnalysisOperationMetadata> - analyzeDataSourceRiskOperationCallable; - private final UnaryCallable - createInspectOperationCallable; - private final OperationCallable< - CreateInspectOperationRequest, InspectOperationResult, InspectOperationMetadata> - createInspectOperationOperationCallable; - private final UnaryCallable - listInspectFindingsCallable; - private final UnaryCallable listInfoTypesCallable; - private final UnaryCallable - listRootCategoriesCallable; - - private final GrpcStubCallableFactory callableFactory; - - public static final GrpcDlpServiceStub create(DlpServiceStubSettings settings) - throws IOException { - return new GrpcDlpServiceStub(settings, ClientContext.create(settings)); - } - - public static final GrpcDlpServiceStub create(ClientContext clientContext) throws IOException { - return new GrpcDlpServiceStub(DlpServiceStubSettings.newBuilder().build(), clientContext); - } - - public static final GrpcDlpServiceStub create( - ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { - return new GrpcDlpServiceStub( - DlpServiceStubSettings.newBuilder().build(), clientContext, callableFactory); - } - - /** - * Constructs an instance of GrpcDlpServiceStub, using the given settings. This is protected so - * that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected GrpcDlpServiceStub(DlpServiceStubSettings settings, ClientContext clientContext) - throws IOException { - this(settings, clientContext, new GrpcDlpServiceCallableFactory()); - } - - /** - * Constructs an instance of GrpcDlpServiceStub, using the given settings. This is protected so - * that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected GrpcDlpServiceStub( - DlpServiceStubSettings settings, - ClientContext clientContext, - GrpcStubCallableFactory callableFactory) - throws IOException { - this.callableFactory = callableFactory; - this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); - - GrpcCallSettings - inspectContentTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(inspectContentMethodDescriptor) - .build(); - GrpcCallSettings redactContentTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(redactContentMethodDescriptor) - .build(); - GrpcCallSettings - deidentifyContentTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(deidentifyContentMethodDescriptor) - .build(); - GrpcCallSettings - analyzeDataSourceRiskTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(analyzeDataSourceRiskMethodDescriptor) - .build(); - GrpcCallSettings - createInspectOperationTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(createInspectOperationMethodDescriptor) - .build(); - GrpcCallSettings - listInspectFindingsTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(listInspectFindingsMethodDescriptor) - .build(); - GrpcCallSettings listInfoTypesTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(listInfoTypesMethodDescriptor) - .build(); - GrpcCallSettings - listRootCategoriesTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(listRootCategoriesMethodDescriptor) - .build(); - - this.inspectContentCallable = - callableFactory.createUnaryCallable( - inspectContentTransportSettings, settings.inspectContentSettings(), clientContext); - this.redactContentCallable = - callableFactory.createUnaryCallable( - redactContentTransportSettings, settings.redactContentSettings(), clientContext); - this.deidentifyContentCallable = - callableFactory.createUnaryCallable( - deidentifyContentTransportSettings, - settings.deidentifyContentSettings(), - clientContext); - this.analyzeDataSourceRiskCallable = - callableFactory.createUnaryCallable( - analyzeDataSourceRiskTransportSettings, - settings.analyzeDataSourceRiskSettings(), - clientContext); - this.analyzeDataSourceRiskOperationCallable = - callableFactory.createOperationCallable( - analyzeDataSourceRiskTransportSettings, - settings.analyzeDataSourceRiskOperationSettings(), - clientContext, - this.operationsStub); - this.createInspectOperationCallable = - callableFactory.createUnaryCallable( - createInspectOperationTransportSettings, - settings.createInspectOperationSettings(), - clientContext); - this.createInspectOperationOperationCallable = - callableFactory.createOperationCallable( - createInspectOperationTransportSettings, - settings.createInspectOperationOperationSettings(), - clientContext, - this.operationsStub); - this.listInspectFindingsCallable = - callableFactory.createUnaryCallable( - listInspectFindingsTransportSettings, - settings.listInspectFindingsSettings(), - clientContext); - this.listInfoTypesCallable = - callableFactory.createUnaryCallable( - listInfoTypesTransportSettings, settings.listInfoTypesSettings(), clientContext); - this.listRootCategoriesCallable = - callableFactory.createUnaryCallable( - listRootCategoriesTransportSettings, - settings.listRootCategoriesSettings(), - clientContext); - - backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); - } - - public GrpcOperationsStub getOperationsStub() { - return operationsStub; - } - - public UnaryCallable inspectContentCallable() { - return inspectContentCallable; - } - - public UnaryCallable redactContentCallable() { - return redactContentCallable; - } - - public UnaryCallable - deidentifyContentCallable() { - return deidentifyContentCallable; - } - - public OperationCallable< - AnalyzeDataSourceRiskRequest, RiskAnalysisOperationResult, RiskAnalysisOperationMetadata> - analyzeDataSourceRiskOperationCallable() { - return analyzeDataSourceRiskOperationCallable; - } - - public UnaryCallable analyzeDataSourceRiskCallable() { - return analyzeDataSourceRiskCallable; - } - - public OperationCallable< - CreateInspectOperationRequest, InspectOperationResult, InspectOperationMetadata> - createInspectOperationOperationCallable() { - return createInspectOperationOperationCallable; - } - - public UnaryCallable createInspectOperationCallable() { - return createInspectOperationCallable; - } - - public UnaryCallable - listInspectFindingsCallable() { - return listInspectFindingsCallable; - } - - public UnaryCallable listInfoTypesCallable() { - return listInfoTypesCallable; - } - - public UnaryCallable - listRootCategoriesCallable() { - return listRootCategoriesCallable; - } - - @Override - public final void close() { - shutdown(); - } - - @Override - public void shutdown() { - backgroundResources.shutdown(); - } - - @Override - public boolean isShutdown() { - return backgroundResources.isShutdown(); - } - - @Override - public boolean isTerminated() { - return backgroundResources.isTerminated(); - } - - @Override - public void shutdownNow() { - backgroundResources.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return backgroundResources.awaitTermination(duration, unit); - } -} diff --git a/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/ColorTest.java b/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/ColorTest.java deleted file mode 100644 index dce909ca675d..000000000000 --- a/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/ColorTest.java +++ /dev/null @@ -1,26 +0,0 @@ -package com.google.cloud.dlp.v2beta1; - -import com.google.privacy.dlp.v2beta1.Color; -import org.junit.Assert; -import org.junit.Test; - -public class ColorTest { - - @Test - public void asDlpColorTest() { - Color got = Colors.asDlpColor(new java.awt.Color(1, 2, 3)); - Assert.assertEquals(got.getBlue(), 3, 0); - Assert.assertEquals(got.getGreen(), 2, 0); - Assert.assertEquals(got.getRed(), 1, 0); - } - - @Test - public void asAwtColorTest() { - java.awt.Color got = - Colors.asAwtColor(Color.newBuilder().setRed(1).setGreen(2).setBlue(3).build()); - - Assert.assertEquals(got.getBlue(), 3, 0); - Assert.assertEquals(got.getGreen(), 2, 0); - Assert.assertEquals(got.getRed(), 1, 0); - } -} diff --git a/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/DlpServiceClientTest.java b/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/DlpServiceClientTest.java deleted file mode 100644 index a086d7321caa..000000000000 --- a/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/DlpServiceClientTest.java +++ /dev/null @@ -1,446 +0,0 @@ -/* - * Copyright 2018 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.dlp.v2beta1; - -import com.google.api.gax.core.NoCredentialsProvider; -import com.google.api.gax.grpc.GaxGrpcProperties; -import com.google.api.gax.grpc.testing.LocalChannelProvider; -import com.google.api.gax.grpc.testing.MockGrpcService; -import com.google.api.gax.grpc.testing.MockServiceHelper; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.InvalidArgumentException; -import com.google.api.gax.rpc.StatusCode; -import com.google.longrunning.Operation; -import com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest; -import com.google.privacy.dlp.v2beta1.BigQueryTable; -import com.google.privacy.dlp.v2beta1.CloudStorageOptions; -import com.google.privacy.dlp.v2beta1.CloudStorageOptions.FileSet; -import com.google.privacy.dlp.v2beta1.ContentItem; -import com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyConfig; -import com.google.privacy.dlp.v2beta1.DeidentifyContentRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentResponse; -import com.google.privacy.dlp.v2beta1.InfoType; -import com.google.privacy.dlp.v2beta1.InspectConfig; -import com.google.privacy.dlp.v2beta1.InspectContentRequest; -import com.google.privacy.dlp.v2beta1.InspectContentResponse; -import com.google.privacy.dlp.v2beta1.InspectOperationResult; -import com.google.privacy.dlp.v2beta1.ListInfoTypesRequest; -import com.google.privacy.dlp.v2beta1.ListInfoTypesResponse; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse; -import com.google.privacy.dlp.v2beta1.OutputStorageConfig; -import com.google.privacy.dlp.v2beta1.PrivacyMetric; -import com.google.privacy.dlp.v2beta1.ResultName; -import com.google.privacy.dlp.v2beta1.RiskAnalysisOperationResult; -import com.google.privacy.dlp.v2beta1.StorageConfig; -import com.google.protobuf.Any; -import com.google.protobuf.GeneratedMessageV3; -import io.grpc.Status; -import io.grpc.StatusRuntimeException; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; -import java.util.concurrent.ExecutionException; -import org.junit.After; -import org.junit.AfterClass; -import org.junit.Assert; -import org.junit.Before; -import org.junit.BeforeClass; -import org.junit.Test; - -@javax.annotation.Generated("by GAPIC") -public class DlpServiceClientTest { - private static MockDlpService mockDlpService; - private static MockServiceHelper serviceHelper; - private DlpServiceClient client; - private LocalChannelProvider channelProvider; - - @BeforeClass - public static void startStaticServer() { - mockDlpService = new MockDlpService(); - serviceHelper = - new MockServiceHelper("in-process-1", Arrays.asList(mockDlpService)); - serviceHelper.start(); - } - - @AfterClass - public static void stopServer() { - serviceHelper.stop(); - } - - @Before - public void setUp() throws IOException { - serviceHelper.reset(); - channelProvider = serviceHelper.createChannelProvider(); - DlpServiceSettings settings = - DlpServiceSettings.newBuilder() - .setTransportChannelProvider(channelProvider) - .setCredentialsProvider(NoCredentialsProvider.create()) - .build(); - client = DlpServiceClient.create(settings); - } - - @After - public void tearDown() throws Exception { - client.close(); - } - - @Test - @SuppressWarnings("all") - public void inspectContentTest() { - InspectContentResponse expectedResponse = InspectContentResponse.newBuilder().build(); - mockDlpService.addResponse(expectedResponse); - - String name = "EMAIL_ADDRESS"; - InfoType infoTypesElement = InfoType.newBuilder().setName(name).build(); - List infoTypes = Arrays.asList(infoTypesElement); - InspectConfig inspectConfig = InspectConfig.newBuilder().addAllInfoTypes(infoTypes).build(); - String type = "text/plain"; - String value = "My email is example@example.com."; - ContentItem itemsElement = ContentItem.newBuilder().setType(type).setValue(value).build(); - List items = Arrays.asList(itemsElement); - - InspectContentResponse actualResponse = client.inspectContent(inspectConfig, items); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockDlpService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - InspectContentRequest actualRequest = (InspectContentRequest) actualRequests.get(0); - - Assert.assertEquals(inspectConfig, actualRequest.getInspectConfig()); - Assert.assertEquals(items, actualRequest.getItemsList()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void inspectContentExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockDlpService.addException(exception); - - try { - String name = "EMAIL_ADDRESS"; - InfoType infoTypesElement = InfoType.newBuilder().setName(name).build(); - List infoTypes = Arrays.asList(infoTypesElement); - InspectConfig inspectConfig = InspectConfig.newBuilder().addAllInfoTypes(infoTypes).build(); - String type = "text/plain"; - String value = "My email is example@example.com."; - ContentItem itemsElement = ContentItem.newBuilder().setType(type).setValue(value).build(); - List items = Arrays.asList(itemsElement); - - client.inspectContent(inspectConfig, items); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void deidentifyContentTest() { - DeidentifyContentResponse expectedResponse = DeidentifyContentResponse.newBuilder().build(); - mockDlpService.addResponse(expectedResponse); - - DeidentifyConfig deidentifyConfig = DeidentifyConfig.newBuilder().build(); - InspectConfig inspectConfig = InspectConfig.newBuilder().build(); - List items = new ArrayList<>(); - - DeidentifyContentResponse actualResponse = - client.deidentifyContent(deidentifyConfig, inspectConfig, items); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockDlpService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - DeidentifyContentRequest actualRequest = (DeidentifyContentRequest) actualRequests.get(0); - - Assert.assertEquals(deidentifyConfig, actualRequest.getDeidentifyConfig()); - Assert.assertEquals(inspectConfig, actualRequest.getInspectConfig()); - Assert.assertEquals(items, actualRequest.getItemsList()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void deidentifyContentExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockDlpService.addException(exception); - - try { - DeidentifyConfig deidentifyConfig = DeidentifyConfig.newBuilder().build(); - InspectConfig inspectConfig = InspectConfig.newBuilder().build(); - List items = new ArrayList<>(); - - client.deidentifyContent(deidentifyConfig, inspectConfig, items); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void analyzeDataSourceRiskTest() throws Exception { - RiskAnalysisOperationResult expectedResponse = RiskAnalysisOperationResult.newBuilder().build(); - Operation resultOperation = - Operation.newBuilder() - .setName("analyzeDataSourceRiskTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockDlpService.addResponse(resultOperation); - - PrivacyMetric privacyMetric = PrivacyMetric.newBuilder().build(); - BigQueryTable sourceTable = BigQueryTable.newBuilder().build(); - - RiskAnalysisOperationResult actualResponse = - client.analyzeDataSourceRiskAsync(privacyMetric, sourceTable).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockDlpService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - AnalyzeDataSourceRiskRequest actualRequest = - (AnalyzeDataSourceRiskRequest) actualRequests.get(0); - - Assert.assertEquals(privacyMetric, actualRequest.getPrivacyMetric()); - Assert.assertEquals(sourceTable, actualRequest.getSourceTable()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void analyzeDataSourceRiskExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockDlpService.addException(exception); - - try { - PrivacyMetric privacyMetric = PrivacyMetric.newBuilder().build(); - BigQueryTable sourceTable = BigQueryTable.newBuilder().build(); - - client.analyzeDataSourceRiskAsync(privacyMetric, sourceTable).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = (InvalidArgumentException) e.getCause(); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - @SuppressWarnings("all") - public void createInspectOperationTest() throws Exception { - ResultName name2 = ResultName.of("[RESULT]"); - InspectOperationResult expectedResponse = - InspectOperationResult.newBuilder().setName(name2.toString()).build(); - Operation resultOperation = - Operation.newBuilder() - .setName("createInspectOperationTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockDlpService.addResponse(resultOperation); - - String name = "EMAIL_ADDRESS"; - InfoType infoTypesElement = InfoType.newBuilder().setName(name).build(); - List infoTypes = Arrays.asList(infoTypesElement); - InspectConfig inspectConfig = InspectConfig.newBuilder().addAllInfoTypes(infoTypes).build(); - String url = "gs://example_bucket/example_file.png"; - CloudStorageOptions.FileSet fileSet = - CloudStorageOptions.FileSet.newBuilder().setUrl(url).build(); - CloudStorageOptions cloudStorageOptions = - CloudStorageOptions.newBuilder().setFileSet(fileSet).build(); - StorageConfig storageConfig = - StorageConfig.newBuilder().setCloudStorageOptions(cloudStorageOptions).build(); - OutputStorageConfig outputConfig = OutputStorageConfig.newBuilder().build(); - - InspectOperationResult actualResponse = - client.createInspectOperationAsync(inspectConfig, storageConfig, outputConfig).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockDlpService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - CreateInspectOperationRequest actualRequest = - (CreateInspectOperationRequest) actualRequests.get(0); - - Assert.assertEquals(inspectConfig, actualRequest.getInspectConfig()); - Assert.assertEquals(storageConfig, actualRequest.getStorageConfig()); - Assert.assertEquals(outputConfig, actualRequest.getOutputConfig()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void createInspectOperationExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockDlpService.addException(exception); - - try { - String name = "EMAIL_ADDRESS"; - InfoType infoTypesElement = InfoType.newBuilder().setName(name).build(); - List infoTypes = Arrays.asList(infoTypesElement); - InspectConfig inspectConfig = InspectConfig.newBuilder().addAllInfoTypes(infoTypes).build(); - String url = "gs://example_bucket/example_file.png"; - CloudStorageOptions.FileSet fileSet = - CloudStorageOptions.FileSet.newBuilder().setUrl(url).build(); - CloudStorageOptions cloudStorageOptions = - CloudStorageOptions.newBuilder().setFileSet(fileSet).build(); - StorageConfig storageConfig = - StorageConfig.newBuilder().setCloudStorageOptions(cloudStorageOptions).build(); - OutputStorageConfig outputConfig = OutputStorageConfig.newBuilder().build(); - - client.createInspectOperationAsync(inspectConfig, storageConfig, outputConfig).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = (InvalidArgumentException) e.getCause(); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - @SuppressWarnings("all") - public void listInspectFindingsTest() { - String nextPageToken = "nextPageToken-1530815211"; - ListInspectFindingsResponse expectedResponse = - ListInspectFindingsResponse.newBuilder().setNextPageToken(nextPageToken).build(); - mockDlpService.addResponse(expectedResponse); - - ResultName name = ResultName.of("[RESULT]"); - - ListInspectFindingsResponse actualResponse = client.listInspectFindings(name); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockDlpService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListInspectFindingsRequest actualRequest = (ListInspectFindingsRequest) actualRequests.get(0); - - Assert.assertEquals(name, ResultName.parse(actualRequest.getName())); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void listInspectFindingsExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockDlpService.addException(exception); - - try { - ResultName name = ResultName.of("[RESULT]"); - - client.listInspectFindings(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void listInfoTypesTest() { - ListInfoTypesResponse expectedResponse = ListInfoTypesResponse.newBuilder().build(); - mockDlpService.addResponse(expectedResponse); - - String category = "PII"; - String languageCode = "en"; - - ListInfoTypesResponse actualResponse = client.listInfoTypes(category, languageCode); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockDlpService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListInfoTypesRequest actualRequest = (ListInfoTypesRequest) actualRequests.get(0); - - Assert.assertEquals(category, actualRequest.getCategory()); - Assert.assertEquals(languageCode, actualRequest.getLanguageCode()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void listInfoTypesExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockDlpService.addException(exception); - - try { - String category = "PII"; - String languageCode = "en"; - - client.listInfoTypes(category, languageCode); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } - - @Test - @SuppressWarnings("all") - public void listRootCategoriesTest() { - ListRootCategoriesResponse expectedResponse = ListRootCategoriesResponse.newBuilder().build(); - mockDlpService.addResponse(expectedResponse); - - String languageCode = "en"; - - ListRootCategoriesResponse actualResponse = client.listRootCategories(languageCode); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockDlpService.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListRootCategoriesRequest actualRequest = (ListRootCategoriesRequest) actualRequests.get(0); - - Assert.assertEquals(languageCode, actualRequest.getLanguageCode()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - @SuppressWarnings("all") - public void listRootCategoriesExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); - mockDlpService.addException(exception); - - try { - String languageCode = "en"; - - client.listRootCategories(languageCode); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception - } - } -} diff --git a/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/MockDlpServiceImpl.java b/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/MockDlpServiceImpl.java deleted file mode 100644 index d9de978719da..000000000000 --- a/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/MockDlpServiceImpl.java +++ /dev/null @@ -1,196 +0,0 @@ -/* - * Copyright 2018 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloud.dlp.v2beta1; - -import com.google.api.core.BetaApi; -import com.google.longrunning.Operation; -import com.google.privacy.dlp.v2beta1.AnalyzeDataSourceRiskRequest; -import com.google.privacy.dlp.v2beta1.CreateInspectOperationRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentRequest; -import com.google.privacy.dlp.v2beta1.DeidentifyContentResponse; -import com.google.privacy.dlp.v2beta1.DlpServiceGrpc.DlpServiceImplBase; -import com.google.privacy.dlp.v2beta1.InspectContentRequest; -import com.google.privacy.dlp.v2beta1.InspectContentResponse; -import com.google.privacy.dlp.v2beta1.ListInfoTypesRequest; -import com.google.privacy.dlp.v2beta1.ListInfoTypesResponse; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsRequest; -import com.google.privacy.dlp.v2beta1.ListInspectFindingsResponse; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesRequest; -import com.google.privacy.dlp.v2beta1.ListRootCategoriesResponse; -import com.google.privacy.dlp.v2beta1.RedactContentRequest; -import com.google.privacy.dlp.v2beta1.RedactContentResponse; -import com.google.protobuf.GeneratedMessageV3; -import io.grpc.stub.StreamObserver; -import java.util.ArrayList; -import java.util.LinkedList; -import java.util.List; -import java.util.Queue; - -@javax.annotation.Generated("by GAPIC") -@BetaApi -public class MockDlpServiceImpl extends DlpServiceImplBase { - private ArrayList requests; - private Queue responses; - - public MockDlpServiceImpl() { - requests = new ArrayList<>(); - responses = new LinkedList<>(); - } - - public List getRequests() { - return requests; - } - - public void addResponse(GeneratedMessageV3 response) { - responses.add(response); - } - - public void setResponses(List responses) { - this.responses = new LinkedList(responses); - } - - public void addException(Exception exception) { - responses.add(exception); - } - - public void reset() { - requests = new ArrayList<>(); - responses = new LinkedList<>(); - } - - @Override - public void inspectContent( - InspectContentRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof InspectContentResponse) { - requests.add(request); - responseObserver.onNext((InspectContentResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void redactContent( - RedactContentRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof RedactContentResponse) { - requests.add(request); - responseObserver.onNext((RedactContentResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void deidentifyContent( - DeidentifyContentRequest request, - StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof DeidentifyContentResponse) { - requests.add(request); - responseObserver.onNext((DeidentifyContentResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void createInspectOperation( - CreateInspectOperationRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext((Operation) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void analyzeDataSourceRisk( - AnalyzeDataSourceRiskRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext((Operation) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void listInspectFindings( - ListInspectFindingsRequest request, - StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof ListInspectFindingsResponse) { - requests.add(request); - responseObserver.onNext((ListInspectFindingsResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void listInfoTypes( - ListInfoTypesRequest request, StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof ListInfoTypesResponse) { - requests.add(request); - responseObserver.onNext((ListInfoTypesResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } - - @Override - public void listRootCategories( - ListRootCategoriesRequest request, - StreamObserver responseObserver) { - Object response = responses.remove(); - if (response instanceof ListRootCategoriesResponse) { - requests.add(request); - responseObserver.onNext((ListRootCategoriesResponse) response); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError((Exception) response); - } else { - responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); - } - } -} diff --git a/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcErrorGroupServiceCallableFactory.java b/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcErrorGroupServiceCallableFactory.java index 6797c594c42f..6eddacea1f2e 100644 --- a/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcErrorGroupServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcErrorGroupServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcErrorStatsServiceCallableFactory.java b/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcErrorStatsServiceCallableFactory.java index 3bd051320c66..891fbad42b39 100644 --- a/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcErrorStatsServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcErrorStatsServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcReportErrorsServiceCallableFactory.java b/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcReportErrorsServiceCallableFactory.java index 9b2b32c0ccf2..db1c4b9c5497 100644 --- a/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcReportErrorsServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-errorreporting/src/main/java/com/google/cloud/errorreporting/v1beta1/stub/GrpcReportErrorsServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1beta1/stub/GrpcFirestoreCallableFactory.java b/google-cloud-clients/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1beta1/stub/GrpcFirestoreCallableFactory.java index cd6ce3f09efd..00816fb388db 100644 --- a/google-cloud-clients/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1beta1/stub/GrpcFirestoreCallableFactory.java +++ b/google-cloud-clients/google-cloud-firestore/src/main/java/com/google/cloud/firestore/v1beta1/stub/GrpcFirestoreCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-iot/README.md b/google-cloud-clients/google-cloud-iot/README.md new file mode 100644 index 000000000000..ebdf0adbaa5a --- /dev/null +++ b/google-cloud-clients/google-cloud-iot/README.md @@ -0,0 +1,102 @@ +Google Cloud Java Client for IoT Core +====================================== + +Java idiomatic client for [IoT Core][cloud-iot]. + +[![CircleCI](https://circleci.com/gh/GoogleCloudPlatform/google-cloud-java/tree/master.svg?style=shield)](https://circleci.com/gh/GoogleCloudPlatform/google-cloud-java/tree/master) +[![Coverage Status](https://coveralls.io/repos/GoogleCloudPlatform/google-cloud-java/badge.svg?branch=master)](https://coveralls.io/r/GoogleCloudPlatform/google-cloud-java?branch=master) +[![Maven](https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-iot.svg)](https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-iot.svg) +[![Codacy Badge](https://api.codacy.com/project/badge/grade/9da006ad7c3a4fe1abd142e77c003917)](https://www.codacy.com/app/mziccard/google-cloud-java) +[![Dependency Status](https://www.versioneye.com/user/projects/58fe4c8d6ac171426c414772/badge.svg?style=flat)](https://www.versioneye.com/user/projects/58fe4c8d6ac171426c414772) + +- [Product Documentation][iot-product-docs] +- [Client Library Documentation][iot-client-lib-docs] + +> Note: This client is a work-in-progress, and may occasionally +> make backwards-incompatible changes. + +Quickstart +---------- + +[//]: # ({x-version-update-start:google-cloud-iot:released}) +If you are using Maven, add this to your pom.xml file +```xml + + com.google.cloud + google-cloud-iot + 0.47.0-beta + +``` +If you are using Gradle, add this to your dependencies +```Groovy +compile 'com.google.cloud:google-cloud-iot:0.47.0-beta' +``` +If you are using SBT, add this to your dependencies +```Scala +libraryDependencies += "com.google.cloud" % "google-cloud-iot" % "0.47.0-beta" +``` +[//]: # ({x-version-update-end}) + +Authentication +-------------- + +See the [Authentication](https://github.com/GoogleCloudPlatform/google-cloud-java#authentication) section in the base directory's README. + +About Google Cloud IoT Core +---------------------------- + +Google Cloud [IoT Core][cloud-iot] is a fully managed service that allows you to easily and securely connect, manage, and ingest data from millions of globally dispersed devices. + +See the [IoT Core client library docs][iot-client-lib-docs] to learn how to use this IoT Core Client Library. + +Getting Started +--------------- +#### Prerequisites +You will need a [Google Developers Console](https://console.developers.google.com/) project with the IoT Core API enabled. [Follow these instructions](https://cloud.google.com/docs/authentication#preparation) to get your project set up. You will also need to set up the local development environment by [installing the Google Cloud SDK](https://cloud.google.com/sdk/) and running the following commands in command line: `gcloud auth login` and `gcloud config set project [YOUR PROJECT ID]`. + +#### Installation and setup +You'll need to obtain the `google-cloud-iot` library. See the [Quickstart](#quickstart) section to add `google-cloud-iot` as a dependency in your code. + +Troubleshooting +--------------- + +To get help, follow the instructions in the [shared Troubleshooting document](https://github.com/GoogleCloudPlatform/gcloud-common/blob/master/troubleshooting/readme.md#troubleshooting). + +Transport +--------- +IoT Core uses gRPC for the transport layer. + +Java Versions +------------- + +Java 7 or above is required for using this client. + +Versioning +---------- + +This library follows [Semantic Versioning](http://semver.org/). + +It is currently in major version zero (``0.y.z``), which means that anything may change at any time and the public API should not be considered stable. + +Contributing +------------ + +Contributions to this library are always welcome and highly encouraged. + +See `google-cloud`'s [CONTRIBUTING] documentation and the [shared documentation](https://github.com/GoogleCloudPlatform/gcloud-common/blob/master/contributing/readme.md#how-to-contribute-to-gcloud) for more information on how to get started. + +Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms. See [Code of Conduct][code-of-conduct] for more information. + +License +------- + +Apache 2.0 - See [LICENSE] for more information. + + +[CONTRIBUTING]:https://github.com/GoogleCloudPlatform/google-cloud-java/blob/master/CONTRIBUTING.md +[code-of-conduct]:https://github.com/GoogleCloudPlatform/google-cloud-java/blob/master/CODE_OF_CONDUCT.md#contributor-code-of-conduct +[LICENSE]: https://github.com/GoogleCloudPlatform/google-cloud-java/blob/master/LICENSE +[cloud-platform]: https://cloud.google.com/ +[cloud-iot]: https://cloud.google.com/iot-core +[iot-product-docs]: https://cloud.google.com/iot-core/docs +[iot-client-lib-docs]: https://googlecloudplatform.github.io/google-cloud-java/latest/apidocs/index.html?com/google/cloud/iot/v1/package-summary.html diff --git a/google-cloud-clients/google-cloud-iot/pom.xml b/google-cloud-clients/google-cloud-iot/pom.xml new file mode 100644 index 000000000000..b0dfc08ac7b7 --- /dev/null +++ b/google-cloud-clients/google-cloud-iot/pom.xml @@ -0,0 +1,68 @@ + + + 4.0.0 + google-cloud-iot + 0.47.1-beta-SNAPSHOT + jar + Google Cloud IoT + https://github.com/GoogleCloudPlatform/google-cloud-java/tree/master/google-cloud-iot + + Java idiomatic client for Google Cloud IoT Core + + + com.google.cloud + google-cloud-clients + 0.47.1-alpha-SNAPSHOT + + + google-cloud-iot + + + + ${project.groupId} + google-cloud-core + + + ${project.groupId} + google-cloud-core-grpc + + + com.google.api.grpc + proto-google-cloud-iot-v1 + + + io.grpc + grpc-netty-shaded + + + io.grpc + grpc-stub + + + io.grpc + grpc-auth + + + ${project.groupId} + google-cloud-core + test-jar + test + + + junit + junit + test + + + com.google.api.grpc + grpc-google-cloud-iot-v1 + test + + + com.google.api + gax-grpc + testlib + test + + + diff --git a/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/DeviceManagerClient.java b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/DeviceManagerClient.java new file mode 100644 index 000000000000..de0a3cd88c6c --- /dev/null +++ b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/DeviceManagerClient.java @@ -0,0 +1,2013 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.iot.v1; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.ApiFutures; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.paging.AbstractFixedSizeCollection; +import com.google.api.gax.paging.AbstractPage; +import com.google.api.gax.paging.AbstractPagedListResponse; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.iot.v1.stub.DeviceManagerStub; +import com.google.cloud.iot.v1.stub.DeviceManagerStubSettings; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.protobuf.ByteString; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import java.io.IOException; +import java.util.List; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND SERVICE +/** + * Service Description: Internet of things (IoT) service. Allows to manipulate device registry + * instances and the registration of devices (Things) to the cloud. + * + *

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

+ * 
+ * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+ *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+ *   DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build();
+ *   DeviceRegistry response = deviceManagerClient.createDeviceRegistry(parent, deviceRegistry);
+ * }
+ * 
+ * 
+ * + *

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

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

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

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

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

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

To customize credentials: + * + *

+ * 
+ * DeviceManagerSettings deviceManagerSettings =
+ *     DeviceManagerSettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * DeviceManagerClient deviceManagerClient =
+ *     DeviceManagerClient.create(deviceManagerSettings);
+ * 
+ * 
+ * + * To customize the endpoint: + * + *
+ * 
+ * DeviceManagerSettings deviceManagerSettings =
+ *     DeviceManagerSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * DeviceManagerClient deviceManagerClient =
+ *     DeviceManagerClient.create(deviceManagerSettings);
+ * 
+ * 
+ */ +@Generated("by gapic-generator") +@BetaApi +public class DeviceManagerClient implements BackgroundResource { + private final DeviceManagerSettings settings; + private final DeviceManagerStub stub; + + /** Constructs an instance of DeviceManagerClient with default settings. */ + public static final DeviceManagerClient create() throws IOException { + return create(DeviceManagerSettings.newBuilder().build()); + } + + /** + * Constructs an instance of DeviceManagerClient, using the given settings. The channels are + * created based on the settings passed in, or defaults for any settings that are not set. + */ + public static final DeviceManagerClient create(DeviceManagerSettings settings) + throws IOException { + return new DeviceManagerClient(settings); + } + + /** + * Constructs an instance of DeviceManagerClient, using the given stub for making calls. This is + * for advanced usage - prefer to use DeviceManagerSettings}. + */ + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public static final DeviceManagerClient create(DeviceManagerStub stub) { + return new DeviceManagerClient(stub); + } + + /** + * Constructs an instance of DeviceManagerClient, using the given settings. This is protected so + * that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected DeviceManagerClient(DeviceManagerSettings settings) throws IOException { + this.settings = settings; + this.stub = ((DeviceManagerStubSettings) settings.getStubSettings()).createStub(); + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + protected DeviceManagerClient(DeviceManagerStub stub) { + this.settings = null; + this.stub = stub; + } + + public final DeviceManagerSettings getSettings() { + return settings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public DeviceManagerStub getStub() { + return stub; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a device registry that contains devices. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build();
+   *   DeviceRegistry response = deviceManagerClient.createDeviceRegistry(parent, deviceRegistry);
+   * }
+   * 
+ * + * @param parent The project and cloud region where this device registry must be created. For + * example, `projects/example-project/locations/us-central1`. + * @param deviceRegistry The device registry. The field `name` must be empty. The server will + * generate that field from the device registry `id` provided and the `parent` field. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final DeviceRegistry createDeviceRegistry( + LocationName parent, DeviceRegistry deviceRegistry) { + + CreateDeviceRegistryRequest request = + CreateDeviceRegistryRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setDeviceRegistry(deviceRegistry) + .build(); + return createDeviceRegistry(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a device registry that contains devices. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build();
+   *   DeviceRegistry response = deviceManagerClient.createDeviceRegistry(parent.toString(), deviceRegistry);
+   * }
+   * 
+ * + * @param parent The project and cloud region where this device registry must be created. For + * example, `projects/example-project/locations/us-central1`. + * @param deviceRegistry The device registry. The field `name` must be empty. The server will + * generate that field from the device registry `id` provided and the `parent` field. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final DeviceRegistry createDeviceRegistry(String parent, DeviceRegistry deviceRegistry) { + + CreateDeviceRegistryRequest request = + CreateDeviceRegistryRequest.newBuilder() + .setParent(parent) + .setDeviceRegistry(deviceRegistry) + .build(); + return createDeviceRegistry(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a device registry that contains devices. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build();
+   *   CreateDeviceRegistryRequest request = CreateDeviceRegistryRequest.newBuilder()
+   *     .setParent(parent.toString())
+   *     .setDeviceRegistry(deviceRegistry)
+   *     .build();
+   *   DeviceRegistry response = deviceManagerClient.createDeviceRegistry(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final DeviceRegistry createDeviceRegistry(CreateDeviceRegistryRequest request) { + return createDeviceRegistryCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a device registry that contains devices. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build();
+   *   CreateDeviceRegistryRequest request = CreateDeviceRegistryRequest.newBuilder()
+   *     .setParent(parent.toString())
+   *     .setDeviceRegistry(deviceRegistry)
+   *     .build();
+   *   ApiFuture<DeviceRegistry> future = deviceManagerClient.createDeviceRegistryCallable().futureCall(request);
+   *   // Do something
+   *   DeviceRegistry response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable + createDeviceRegistryCallable() { + return stub.createDeviceRegistryCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   DeviceRegistry response = deviceManagerClient.getDeviceRegistry(name);
+   * }
+   * 
+ * + * @param name The name of the device registry. For example, + * `projects/example-project/locations/us-central1/registries/my-registry`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final DeviceRegistry getDeviceRegistry(RegistryName name) { + + GetDeviceRegistryRequest request = + GetDeviceRegistryRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getDeviceRegistry(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   DeviceRegistry response = deviceManagerClient.getDeviceRegistry(name.toString());
+   * }
+   * 
+ * + * @param name The name of the device registry. For example, + * `projects/example-project/locations/us-central1/registries/my-registry`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final DeviceRegistry getDeviceRegistry(String name) { + + GetDeviceRegistryRequest request = GetDeviceRegistryRequest.newBuilder().setName(name).build(); + return getDeviceRegistry(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   GetDeviceRegistryRequest request = GetDeviceRegistryRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   DeviceRegistry response = deviceManagerClient.getDeviceRegistry(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final DeviceRegistry getDeviceRegistry(GetDeviceRegistryRequest request) { + return getDeviceRegistryCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   GetDeviceRegistryRequest request = GetDeviceRegistryRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   ApiFuture<DeviceRegistry> future = deviceManagerClient.getDeviceRegistryCallable().futureCall(request);
+   *   // Do something
+   *   DeviceRegistry response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable getDeviceRegistryCallable() { + return stub.getDeviceRegistryCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Updates a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   DeviceRegistry response = deviceManagerClient.updateDeviceRegistry(deviceRegistry, updateMask);
+   * }
+   * 
+ * + * @param deviceRegistry The new values for the device registry. The `id` field must be empty, and + * the `name` field must indicate the path of the resource. For example, + * `projects/example-project/locations/us-central1/registries/my-registry`. + * @param updateMask Only updates the `device_registry` fields indicated by this mask. The field + * mask must not be empty, and it must not contain fields that are immutable or only set by + * the server. Mutable top-level fields: `event_notification_config`, `http_config`, + * `mqtt_config`, and `state_notification_config`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final DeviceRegistry updateDeviceRegistry( + DeviceRegistry deviceRegistry, FieldMask updateMask) { + + UpdateDeviceRegistryRequest request = + UpdateDeviceRegistryRequest.newBuilder() + .setDeviceRegistry(deviceRegistry) + .setUpdateMask(updateMask) + .build(); + return updateDeviceRegistry(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Updates a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   UpdateDeviceRegistryRequest request = UpdateDeviceRegistryRequest.newBuilder()
+   *     .setDeviceRegistry(deviceRegistry)
+   *     .setUpdateMask(updateMask)
+   *     .build();
+   *   DeviceRegistry response = deviceManagerClient.updateDeviceRegistry(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final DeviceRegistry updateDeviceRegistry(UpdateDeviceRegistryRequest request) { + return updateDeviceRegistryCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Updates a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   UpdateDeviceRegistryRequest request = UpdateDeviceRegistryRequest.newBuilder()
+   *     .setDeviceRegistry(deviceRegistry)
+   *     .setUpdateMask(updateMask)
+   *     .build();
+   *   ApiFuture<DeviceRegistry> future = deviceManagerClient.updateDeviceRegistryCallable().futureCall(request);
+   *   // Do something
+   *   DeviceRegistry response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable + updateDeviceRegistryCallable() { + return stub.updateDeviceRegistryCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   deviceManagerClient.deleteDeviceRegistry(name);
+   * }
+   * 
+ * + * @param name The name of the device registry. For example, + * `projects/example-project/locations/us-central1/registries/my-registry`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteDeviceRegistry(RegistryName name) { + + DeleteDeviceRegistryRequest request = + DeleteDeviceRegistryRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + deleteDeviceRegistry(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   deviceManagerClient.deleteDeviceRegistry(name.toString());
+   * }
+   * 
+ * + * @param name The name of the device registry. For example, + * `projects/example-project/locations/us-central1/registries/my-registry`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteDeviceRegistry(String name) { + + DeleteDeviceRegistryRequest request = + DeleteDeviceRegistryRequest.newBuilder().setName(name).build(); + deleteDeviceRegistry(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   DeleteDeviceRegistryRequest request = DeleteDeviceRegistryRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   deviceManagerClient.deleteDeviceRegistry(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final void deleteDeviceRegistry(DeleteDeviceRegistryRequest request) { + deleteDeviceRegistryCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes a device registry configuration. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   DeleteDeviceRegistryRequest request = DeleteDeviceRegistryRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   ApiFuture<Void> future = deviceManagerClient.deleteDeviceRegistryCallable().futureCall(request);
+   *   // Do something
+   *   future.get();
+   * }
+   * 
+ */ + public final UnaryCallable deleteDeviceRegistryCallable() { + return stub.deleteDeviceRegistryCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists device registries. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (DeviceRegistry element : deviceManagerClient.listDeviceRegistries(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param parent The project and cloud region path. For example, + * `projects/example-project/locations/us-central1`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDeviceRegistriesPagedResponse listDeviceRegistries(LocationName parent) { + ListDeviceRegistriesRequest request = + ListDeviceRegistriesRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listDeviceRegistries(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists device registries. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (DeviceRegistry element : deviceManagerClient.listDeviceRegistries(parent.toString()).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param parent The project and cloud region path. For example, + * `projects/example-project/locations/us-central1`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDeviceRegistriesPagedResponse listDeviceRegistries(String parent) { + ListDeviceRegistriesRequest request = + ListDeviceRegistriesRequest.newBuilder().setParent(parent).build(); + return listDeviceRegistries(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists device registries. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   ListDeviceRegistriesRequest request = ListDeviceRegistriesRequest.newBuilder()
+   *     .setParent(parent.toString())
+   *     .build();
+   *   for (DeviceRegistry element : deviceManagerClient.listDeviceRegistries(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDeviceRegistriesPagedResponse listDeviceRegistries( + ListDeviceRegistriesRequest request) { + return listDeviceRegistriesPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists device registries. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   ListDeviceRegistriesRequest request = ListDeviceRegistriesRequest.newBuilder()
+   *     .setParent(parent.toString())
+   *     .build();
+   *   ApiFuture<ListDeviceRegistriesPagedResponse> future = deviceManagerClient.listDeviceRegistriesPagedCallable().futureCall(request);
+   *   // Do something
+   *   for (DeviceRegistry element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + listDeviceRegistriesPagedCallable() { + return stub.listDeviceRegistriesPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists device registries. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   ListDeviceRegistriesRequest request = ListDeviceRegistriesRequest.newBuilder()
+   *     .setParent(parent.toString())
+   *     .build();
+   *   while (true) {
+   *     ListDeviceRegistriesResponse response = deviceManagerClient.listDeviceRegistriesCallable().call(request);
+   *     for (DeviceRegistry element : response.getDeviceRegistriesList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + listDeviceRegistriesCallable() { + return stub.listDeviceRegistriesCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a device in a device registry. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   Device device = Device.newBuilder().build();
+   *   Device response = deviceManagerClient.createDevice(parent, device);
+   * }
+   * 
+ * + * @param parent The name of the device registry where this device should be created. For example, + * `projects/example-project/locations/us-central1/registries/my-registry`. + * @param device The device registration details. The field `name` must be empty. The server will + * generate that field from the device registry `id` provided and the `parent` field. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Device createDevice(RegistryName parent, Device device) { + + CreateDeviceRequest request = + CreateDeviceRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setDevice(device) + .build(); + return createDevice(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a device in a device registry. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   Device device = Device.newBuilder().build();
+   *   Device response = deviceManagerClient.createDevice(parent.toString(), device);
+   * }
+   * 
+ * + * @param parent The name of the device registry where this device should be created. For example, + * `projects/example-project/locations/us-central1/registries/my-registry`. + * @param device The device registration details. The field `name` must be empty. The server will + * generate that field from the device registry `id` provided and the `parent` field. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Device createDevice(String parent, Device device) { + + CreateDeviceRequest request = + CreateDeviceRequest.newBuilder().setParent(parent).setDevice(device).build(); + return createDevice(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a device in a device registry. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   Device device = Device.newBuilder().build();
+   *   CreateDeviceRequest request = CreateDeviceRequest.newBuilder()
+   *     .setParent(parent.toString())
+   *     .setDevice(device)
+   *     .build();
+   *   Device response = deviceManagerClient.createDevice(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Device createDevice(CreateDeviceRequest request) { + return createDeviceCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a device in a device registry. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   Device device = Device.newBuilder().build();
+   *   CreateDeviceRequest request = CreateDeviceRequest.newBuilder()
+   *     .setParent(parent.toString())
+   *     .setDevice(device)
+   *     .build();
+   *   ApiFuture<Device> future = deviceManagerClient.createDeviceCallable().futureCall(request);
+   *   // Do something
+   *   Device response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable createDeviceCallable() { + return stub.createDeviceCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets details about a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   Device response = deviceManagerClient.getDevice(name);
+   * }
+   * 
+ * + * @param name The name of the device. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0` or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Device getDevice(DeviceName name) { + + GetDeviceRequest request = + GetDeviceRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getDevice(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets details about a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   Device response = deviceManagerClient.getDevice(name.toString());
+   * }
+   * 
+ * + * @param name The name of the device. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0` or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Device getDevice(String name) { + + GetDeviceRequest request = GetDeviceRequest.newBuilder().setName(name).build(); + return getDevice(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets details about a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   GetDeviceRequest request = GetDeviceRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   Device response = deviceManagerClient.getDevice(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Device getDevice(GetDeviceRequest request) { + return getDeviceCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets details about a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   GetDeviceRequest request = GetDeviceRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   ApiFuture<Device> future = deviceManagerClient.getDeviceCallable().futureCall(request);
+   *   // Do something
+   *   Device response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable getDeviceCallable() { + return stub.getDeviceCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Updates a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   Device device = Device.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   Device response = deviceManagerClient.updateDevice(device, updateMask);
+   * }
+   * 
+ * + * @param device The new values for the device registry. The `id` and `num_id` fields must be + * empty, and the field `name` must specify the name path. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0`or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @param updateMask Only updates the `device` fields indicated by this mask. The field mask must + * not be empty, and it must not contain fields that are immutable or only set by the server. + * Mutable top-level fields: `credentials`, `blocked`, and `metadata` + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Device updateDevice(Device device, FieldMask updateMask) { + + UpdateDeviceRequest request = + UpdateDeviceRequest.newBuilder().setDevice(device).setUpdateMask(updateMask).build(); + return updateDevice(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Updates a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   Device device = Device.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   UpdateDeviceRequest request = UpdateDeviceRequest.newBuilder()
+   *     .setDevice(device)
+   *     .setUpdateMask(updateMask)
+   *     .build();
+   *   Device response = deviceManagerClient.updateDevice(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Device updateDevice(UpdateDeviceRequest request) { + return updateDeviceCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Updates a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   Device device = Device.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   UpdateDeviceRequest request = UpdateDeviceRequest.newBuilder()
+   *     .setDevice(device)
+   *     .setUpdateMask(updateMask)
+   *     .build();
+   *   ApiFuture<Device> future = deviceManagerClient.updateDeviceCallable().futureCall(request);
+   *   // Do something
+   *   Device response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable updateDeviceCallable() { + return stub.updateDeviceCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   deviceManagerClient.deleteDevice(name);
+   * }
+   * 
+ * + * @param name The name of the device. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0` or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteDevice(DeviceName name) { + + DeleteDeviceRequest request = + DeleteDeviceRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + deleteDevice(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   deviceManagerClient.deleteDevice(name.toString());
+   * }
+   * 
+ * + * @param name The name of the device. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0` or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteDevice(String name) { + + DeleteDeviceRequest request = DeleteDeviceRequest.newBuilder().setName(name).build(); + deleteDevice(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   DeleteDeviceRequest request = DeleteDeviceRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   deviceManagerClient.deleteDevice(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final void deleteDevice(DeleteDeviceRequest request) { + deleteDeviceCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes a device. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   DeleteDeviceRequest request = DeleteDeviceRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   ApiFuture<Void> future = deviceManagerClient.deleteDeviceCallable().futureCall(request);
+   *   // Do something
+   *   future.get();
+   * }
+   * 
+ */ + public final UnaryCallable deleteDeviceCallable() { + return stub.deleteDeviceCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List devices in a device registry. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   for (Device element : deviceManagerClient.listDevices(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param parent The device registry path. Required. For example, + * `projects/my-project/locations/us-central1/registries/my-registry`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDevicesPagedResponse listDevices(RegistryName parent) { + ListDevicesRequest request = + ListDevicesRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listDevices(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List devices in a device registry. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   for (Device element : deviceManagerClient.listDevices(parent.toString()).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param parent The device registry path. Required. For example, + * `projects/my-project/locations/us-central1/registries/my-registry`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDevicesPagedResponse listDevices(String parent) { + ListDevicesRequest request = ListDevicesRequest.newBuilder().setParent(parent).build(); + return listDevices(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List devices in a device registry. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   ListDevicesRequest request = ListDevicesRequest.newBuilder()
+   *     .setParent(parent.toString())
+   *     .build();
+   *   for (Device element : deviceManagerClient.listDevices(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDevicesPagedResponse listDevices(ListDevicesRequest request) { + return listDevicesPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List devices in a device registry. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   ListDevicesRequest request = ListDevicesRequest.newBuilder()
+   *     .setParent(parent.toString())
+   *     .build();
+   *   ApiFuture<ListDevicesPagedResponse> future = deviceManagerClient.listDevicesPagedCallable().futureCall(request);
+   *   // Do something
+   *   for (Device element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + listDevicesPagedCallable() { + return stub.listDevicesPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List devices in a device registry. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   ListDevicesRequest request = ListDevicesRequest.newBuilder()
+   *     .setParent(parent.toString())
+   *     .build();
+   *   while (true) {
+   *     ListDevicesResponse response = deviceManagerClient.listDevicesCallable().call(request);
+   *     for (Device element : response.getDevicesList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable listDevicesCallable() { + return stub.listDevicesCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Modifies the configuration for the device, which is eventually sent from the Cloud IoT Core + * servers. Returns the modified configuration version and its metadata. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ByteString binaryData = ByteString.copyFromUtf8("");
+   *   DeviceConfig response = deviceManagerClient.modifyCloudToDeviceConfig(name, binaryData);
+   * }
+   * 
+ * + * @param name The name of the device. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0` or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @param binaryData The configuration data for the device. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final DeviceConfig modifyCloudToDeviceConfig(DeviceName name, ByteString binaryData) { + + ModifyCloudToDeviceConfigRequest request = + ModifyCloudToDeviceConfigRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .setBinaryData(binaryData) + .build(); + return modifyCloudToDeviceConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Modifies the configuration for the device, which is eventually sent from the Cloud IoT Core + * servers. Returns the modified configuration version and its metadata. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ByteString binaryData = ByteString.copyFromUtf8("");
+   *   DeviceConfig response = deviceManagerClient.modifyCloudToDeviceConfig(name.toString(), binaryData);
+   * }
+   * 
+ * + * @param name The name of the device. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0` or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @param binaryData The configuration data for the device. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final DeviceConfig modifyCloudToDeviceConfig(String name, ByteString binaryData) { + + ModifyCloudToDeviceConfigRequest request = + ModifyCloudToDeviceConfigRequest.newBuilder() + .setName(name) + .setBinaryData(binaryData) + .build(); + return modifyCloudToDeviceConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Modifies the configuration for the device, which is eventually sent from the Cloud IoT Core + * servers. Returns the modified configuration version and its metadata. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ByteString binaryData = ByteString.copyFromUtf8("");
+   *   ModifyCloudToDeviceConfigRequest request = ModifyCloudToDeviceConfigRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .setBinaryData(binaryData)
+   *     .build();
+   *   DeviceConfig response = deviceManagerClient.modifyCloudToDeviceConfig(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final DeviceConfig modifyCloudToDeviceConfig(ModifyCloudToDeviceConfigRequest request) { + return modifyCloudToDeviceConfigCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Modifies the configuration for the device, which is eventually sent from the Cloud IoT Core + * servers. Returns the modified configuration version and its metadata. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ByteString binaryData = ByteString.copyFromUtf8("");
+   *   ModifyCloudToDeviceConfigRequest request = ModifyCloudToDeviceConfigRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .setBinaryData(binaryData)
+   *     .build();
+   *   ApiFuture<DeviceConfig> future = deviceManagerClient.modifyCloudToDeviceConfigCallable().futureCall(request);
+   *   // Do something
+   *   DeviceConfig response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable + modifyCloudToDeviceConfigCallable() { + return stub.modifyCloudToDeviceConfigCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists the last few versions of the device configuration in descending order (i.e.: newest + * first). + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ListDeviceConfigVersionsResponse response = deviceManagerClient.listDeviceConfigVersions(name);
+   * }
+   * 
+ * + * @param name The name of the device. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0` or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDeviceConfigVersionsResponse listDeviceConfigVersions(DeviceName name) { + + ListDeviceConfigVersionsRequest request = + ListDeviceConfigVersionsRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return listDeviceConfigVersions(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists the last few versions of the device configuration in descending order (i.e.: newest + * first). + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ListDeviceConfigVersionsResponse response = deviceManagerClient.listDeviceConfigVersions(name.toString());
+   * }
+   * 
+ * + * @param name The name of the device. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0` or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDeviceConfigVersionsResponse listDeviceConfigVersions(String name) { + + ListDeviceConfigVersionsRequest request = + ListDeviceConfigVersionsRequest.newBuilder().setName(name).build(); + return listDeviceConfigVersions(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists the last few versions of the device configuration in descending order (i.e.: newest + * first). + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ListDeviceConfigVersionsRequest request = ListDeviceConfigVersionsRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   ListDeviceConfigVersionsResponse response = deviceManagerClient.listDeviceConfigVersions(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDeviceConfigVersionsResponse listDeviceConfigVersions( + ListDeviceConfigVersionsRequest request) { + return listDeviceConfigVersionsCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists the last few versions of the device configuration in descending order (i.e.: newest + * first). + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ListDeviceConfigVersionsRequest request = ListDeviceConfigVersionsRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   ApiFuture<ListDeviceConfigVersionsResponse> future = deviceManagerClient.listDeviceConfigVersionsCallable().futureCall(request);
+   *   // Do something
+   *   ListDeviceConfigVersionsResponse response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable + listDeviceConfigVersionsCallable() { + return stub.listDeviceConfigVersionsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists the last few versions of the device state in descending order (i.e.: newest first). + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ListDeviceStatesResponse response = deviceManagerClient.listDeviceStates(name);
+   * }
+   * 
+ * + * @param name The name of the device. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0` or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDeviceStatesResponse listDeviceStates(DeviceName name) { + + ListDeviceStatesRequest request = + ListDeviceStatesRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return listDeviceStates(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists the last few versions of the device state in descending order (i.e.: newest first). + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ListDeviceStatesResponse response = deviceManagerClient.listDeviceStates(name.toString());
+   * }
+   * 
+ * + * @param name The name of the device. For example, + * `projects/p0/locations/us-central1/registries/registry0/devices/device0` or + * `projects/p0/locations/us-central1/registries/registry0/devices/{num_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDeviceStatesResponse listDeviceStates(String name) { + + ListDeviceStatesRequest request = ListDeviceStatesRequest.newBuilder().setName(name).build(); + return listDeviceStates(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists the last few versions of the device state in descending order (i.e.: newest first). + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ListDeviceStatesRequest request = ListDeviceStatesRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   ListDeviceStatesResponse response = deviceManagerClient.listDeviceStates(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListDeviceStatesResponse listDeviceStates(ListDeviceStatesRequest request) { + return listDeviceStatesCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists the last few versions of the device state in descending order (i.e.: newest first). + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]");
+   *   ListDeviceStatesRequest request = ListDeviceStatesRequest.newBuilder()
+   *     .setName(name.toString())
+   *     .build();
+   *   ApiFuture<ListDeviceStatesResponse> future = deviceManagerClient.listDeviceStatesCallable().futureCall(request);
+   *   // Do something
+   *   ListDeviceStatesResponse response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable + listDeviceStatesCallable() { + return stub.listDeviceStatesCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Sets the access control policy on the specified resource. Replaces any existing policy. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   Policy policy = Policy.newBuilder().build();
+   *   Policy response = deviceManagerClient.setIamPolicy(resource, policy);
+   * }
+   * 
+ * + * @param resource REQUIRED: The resource for which the policy is being specified. `resource` is + * usually specified as a path. For example, a Project resource is specified as + * `projects/{project}`. + * @param policy REQUIRED: The complete policy to be applied to the `resource`. The size of the + * policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud + * Platform services (such as Projects) might reject them. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy setIamPolicy(RegistryName resource, Policy policy) { + + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource(resource == null ? null : resource.toString()) + .setPolicy(policy) + .build(); + return setIamPolicy(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Sets the access control policy on the specified resource. Replaces any existing policy. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   Policy policy = Policy.newBuilder().build();
+   *   Policy response = deviceManagerClient.setIamPolicy(resource.toString(), policy);
+   * }
+   * 
+ * + * @param resource REQUIRED: The resource for which the policy is being specified. `resource` is + * usually specified as a path. For example, a Project resource is specified as + * `projects/{project}`. + * @param policy REQUIRED: The complete policy to be applied to the `resource`. The size of the + * policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud + * Platform services (such as Projects) might reject them. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy setIamPolicy(String resource, Policy policy) { + + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder().setResource(resource).setPolicy(policy).build(); + return setIamPolicy(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Sets the access control policy on the specified resource. Replaces any existing policy. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   ResourceName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   Policy policy = Policy.newBuilder().build();
+   *   SetIamPolicyRequest request = SetIamPolicyRequest.newBuilder()
+   *     .setResource(resource.toString())
+   *     .setPolicy(policy)
+   *     .build();
+   *   Policy response = deviceManagerClient.setIamPolicy(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy setIamPolicy(SetIamPolicyRequest request) { + return setIamPolicyCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Sets the access control policy on the specified resource. Replaces any existing policy. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   ResourceName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   Policy policy = Policy.newBuilder().build();
+   *   SetIamPolicyRequest request = SetIamPolicyRequest.newBuilder()
+   *     .setResource(resource.toString())
+   *     .setPolicy(policy)
+   *     .build();
+   *   ApiFuture<Policy> future = deviceManagerClient.setIamPolicyCallable().futureCall(request);
+   *   // Do something
+   *   Policy response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable setIamPolicyCallable() { + return stub.setIamPolicyCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets the access control policy for a resource. Returns an empty policy if the resource exists + * and does not have a policy set. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   Policy response = deviceManagerClient.getIamPolicy(resource);
+   * }
+   * 
+ * + * @param resource REQUIRED: The resource for which the policy is being requested. `resource` is + * usually specified as a path. For example, a Project resource is specified as + * `projects/{project}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy getIamPolicy(RegistryName resource) { + + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource(resource == null ? null : resource.toString()) + .build(); + return getIamPolicy(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets the access control policy for a resource. Returns an empty policy if the resource exists + * and does not have a policy set. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   Policy response = deviceManagerClient.getIamPolicy(resource.toString());
+   * }
+   * 
+ * + * @param resource REQUIRED: The resource for which the policy is being requested. `resource` is + * usually specified as a path. For example, a Project resource is specified as + * `projects/{project}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy getIamPolicy(String resource) { + + GetIamPolicyRequest request = GetIamPolicyRequest.newBuilder().setResource(resource).build(); + return getIamPolicy(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets the access control policy for a resource. Returns an empty policy if the resource exists + * and does not have a policy set. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   ResourceName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   GetIamPolicyRequest request = GetIamPolicyRequest.newBuilder()
+   *     .setResource(resource.toString())
+   *     .build();
+   *   Policy response = deviceManagerClient.getIamPolicy(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final Policy getIamPolicy(GetIamPolicyRequest request) { + return getIamPolicyCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets the access control policy for a resource. Returns an empty policy if the resource exists + * and does not have a policy set. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   ResourceName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   GetIamPolicyRequest request = GetIamPolicyRequest.newBuilder()
+   *     .setResource(resource.toString())
+   *     .build();
+   *   ApiFuture<Policy> future = deviceManagerClient.getIamPolicyCallable().futureCall(request);
+   *   // Do something
+   *   Policy response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable getIamPolicyCallable() { + return stub.getIamPolicyCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Returns permissions that a caller has on the specified resource. If the resource does not + * exist, this will return an empty set of permissions, not a NOT_FOUND error. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   List<String> permissions = new ArrayList<>();
+   *   TestIamPermissionsResponse response = deviceManagerClient.testIamPermissions(resource, permissions);
+   * }
+   * 
+ * + * @param resource REQUIRED: The resource for which the policy detail is being requested. + * `resource` is usually specified as a path. For example, a Project resource is specified as + * `projects/{project}`. + * @param permissions The set of permissions to check for the `resource`. Permissions with + * wildcards (such as '*' or 'storage.*') are not allowed. For more information see + * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final TestIamPermissionsResponse testIamPermissions( + RegistryName resource, List permissions) { + + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource(resource == null ? null : resource.toString()) + .addAllPermissions(permissions) + .build(); + return testIamPermissions(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Returns permissions that a caller has on the specified resource. If the resource does not + * exist, this will return an empty set of permissions, not a NOT_FOUND error. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   List<String> permissions = new ArrayList<>();
+   *   TestIamPermissionsResponse response = deviceManagerClient.testIamPermissions(resource.toString(), permissions);
+   * }
+   * 
+ * + * @param resource REQUIRED: The resource for which the policy detail is being requested. + * `resource` is usually specified as a path. For example, a Project resource is specified as + * `projects/{project}`. + * @param permissions The set of permissions to check for the `resource`. Permissions with + * wildcards (such as '*' or 'storage.*') are not allowed. For more information see + * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final TestIamPermissionsResponse testIamPermissions( + String resource, List permissions) { + + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource(resource) + .addAllPermissions(permissions) + .build(); + return testIamPermissions(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Returns permissions that a caller has on the specified resource. If the resource does not + * exist, this will return an empty set of permissions, not a NOT_FOUND error. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   ResourceName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   List<String> permissions = new ArrayList<>();
+   *   TestIamPermissionsRequest request = TestIamPermissionsRequest.newBuilder()
+   *     .setResource(resource.toString())
+   *     .addAllPermissions(permissions)
+   *     .build();
+   *   TestIamPermissionsResponse response = deviceManagerClient.testIamPermissions(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsRequest request) { + return testIamPermissionsCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Returns permissions that a caller has on the specified resource. If the resource does not + * exist, this will return an empty set of permissions, not a NOT_FOUND error. + * + *

Sample code: + * + *


+   * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+   *   ResourceName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]");
+   *   List<String> permissions = new ArrayList<>();
+   *   TestIamPermissionsRequest request = TestIamPermissionsRequest.newBuilder()
+   *     .setResource(resource.toString())
+   *     .addAllPermissions(permissions)
+   *     .build();
+   *   ApiFuture<TestIamPermissionsResponse> future = deviceManagerClient.testIamPermissionsCallable().futureCall(request);
+   *   // Do something
+   *   TestIamPermissionsResponse response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable + testIamPermissionsCallable() { + return stub.testIamPermissionsCallable(); + } + + @Override + public final void close() { + stub.close(); + } + + @Override + public void shutdown() { + stub.shutdown(); + } + + @Override + public boolean isShutdown() { + return stub.isShutdown(); + } + + @Override + public boolean isTerminated() { + return stub.isTerminated(); + } + + @Override + public void shutdownNow() { + stub.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return stub.awaitTermination(duration, unit); + } + + public static class ListDeviceRegistriesPagedResponse + extends AbstractPagedListResponse< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, DeviceRegistry, + ListDeviceRegistriesPage, ListDeviceRegistriesFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListDeviceRegistriesPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + new ApiFunction() { + @Override + public ListDeviceRegistriesPagedResponse apply(ListDeviceRegistriesPage input) { + return new ListDeviceRegistriesPagedResponse(input); + } + }); + } + + private ListDeviceRegistriesPagedResponse(ListDeviceRegistriesPage page) { + super(page, ListDeviceRegistriesFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListDeviceRegistriesPage + extends AbstractPage< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, DeviceRegistry, + ListDeviceRegistriesPage> { + + private ListDeviceRegistriesPage( + PageContext + context, + ListDeviceRegistriesResponse response) { + super(context, response); + } + + private static ListDeviceRegistriesPage createEmptyPage() { + return new ListDeviceRegistriesPage(null, null); + } + + @Override + protected ListDeviceRegistriesPage createPage( + PageContext + context, + ListDeviceRegistriesResponse response) { + return new ListDeviceRegistriesPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListDeviceRegistriesFixedSizeCollection + extends AbstractFixedSizeCollection< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, DeviceRegistry, + ListDeviceRegistriesPage, ListDeviceRegistriesFixedSizeCollection> { + + private ListDeviceRegistriesFixedSizeCollection( + List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListDeviceRegistriesFixedSizeCollection createEmptyCollection() { + return new ListDeviceRegistriesFixedSizeCollection(null, 0); + } + + @Override + protected ListDeviceRegistriesFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListDeviceRegistriesFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListDevicesPagedResponse + extends AbstractPagedListResponse< + ListDevicesRequest, ListDevicesResponse, Device, ListDevicesPage, + ListDevicesFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListDevicesPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + new ApiFunction() { + @Override + public ListDevicesPagedResponse apply(ListDevicesPage input) { + return new ListDevicesPagedResponse(input); + } + }); + } + + private ListDevicesPagedResponse(ListDevicesPage page) { + super(page, ListDevicesFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListDevicesPage + extends AbstractPage { + + private ListDevicesPage( + PageContext context, + ListDevicesResponse response) { + super(context, response); + } + + private static ListDevicesPage createEmptyPage() { + return new ListDevicesPage(null, null); + } + + @Override + protected ListDevicesPage createPage( + PageContext context, + ListDevicesResponse response) { + return new ListDevicesPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListDevicesFixedSizeCollection + extends AbstractFixedSizeCollection< + ListDevicesRequest, ListDevicesResponse, Device, ListDevicesPage, + ListDevicesFixedSizeCollection> { + + private ListDevicesFixedSizeCollection(List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListDevicesFixedSizeCollection createEmptyCollection() { + return new ListDevicesFixedSizeCollection(null, 0); + } + + @Override + protected ListDevicesFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListDevicesFixedSizeCollection(pages, collectionSize); + } + } +} diff --git a/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/DeviceManagerSettings.java b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/DeviceManagerSettings.java new file mode 100644 index 000000000000..889b4419b819 --- /dev/null +++ b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/DeviceManagerSettings.java @@ -0,0 +1,358 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.iot.v1; + +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDeviceRegistriesPagedResponse; +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDevicesPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientSettings; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.cloud.iot.v1.stub.DeviceManagerStubSettings; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS +/** + * Settings class to configure an instance of {@link DeviceManagerClient}. + * + *

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

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

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. For + * example, to set the total timeout of createDeviceRegistry to 30 seconds: + * + *

+ * 
+ * DeviceManagerSettings.Builder deviceManagerSettingsBuilder =
+ *     DeviceManagerSettings.newBuilder();
+ * deviceManagerSettingsBuilder.createDeviceRegistrySettings().getRetrySettings().toBuilder()
+ *     .setTotalTimeout(Duration.ofSeconds(30));
+ * DeviceManagerSettings deviceManagerSettings = deviceManagerSettingsBuilder.build();
+ * 
+ * 
+ */ +@Generated("by gapic-generator") +@BetaApi +public class DeviceManagerSettings extends ClientSettings { + /** Returns the object with the settings used for calls to createDeviceRegistry. */ + public UnaryCallSettings + createDeviceRegistrySettings() { + return ((DeviceManagerStubSettings) getStubSettings()).createDeviceRegistrySettings(); + } + + /** Returns the object with the settings used for calls to getDeviceRegistry. */ + public UnaryCallSettings getDeviceRegistrySettings() { + return ((DeviceManagerStubSettings) getStubSettings()).getDeviceRegistrySettings(); + } + + /** Returns the object with the settings used for calls to updateDeviceRegistry. */ + public UnaryCallSettings + updateDeviceRegistrySettings() { + return ((DeviceManagerStubSettings) getStubSettings()).updateDeviceRegistrySettings(); + } + + /** Returns the object with the settings used for calls to deleteDeviceRegistry. */ + public UnaryCallSettings deleteDeviceRegistrySettings() { + return ((DeviceManagerStubSettings) getStubSettings()).deleteDeviceRegistrySettings(); + } + + /** Returns the object with the settings used for calls to listDeviceRegistries. */ + public PagedCallSettings< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, + ListDeviceRegistriesPagedResponse> + listDeviceRegistriesSettings() { + return ((DeviceManagerStubSettings) getStubSettings()).listDeviceRegistriesSettings(); + } + + /** Returns the object with the settings used for calls to createDevice. */ + public UnaryCallSettings createDeviceSettings() { + return ((DeviceManagerStubSettings) getStubSettings()).createDeviceSettings(); + } + + /** Returns the object with the settings used for calls to getDevice. */ + public UnaryCallSettings getDeviceSettings() { + return ((DeviceManagerStubSettings) getStubSettings()).getDeviceSettings(); + } + + /** Returns the object with the settings used for calls to updateDevice. */ + public UnaryCallSettings updateDeviceSettings() { + return ((DeviceManagerStubSettings) getStubSettings()).updateDeviceSettings(); + } + + /** Returns the object with the settings used for calls to deleteDevice. */ + public UnaryCallSettings deleteDeviceSettings() { + return ((DeviceManagerStubSettings) getStubSettings()).deleteDeviceSettings(); + } + + /** Returns the object with the settings used for calls to listDevices. */ + public PagedCallSettings + listDevicesSettings() { + return ((DeviceManagerStubSettings) getStubSettings()).listDevicesSettings(); + } + + /** Returns the object with the settings used for calls to modifyCloudToDeviceConfig. */ + public UnaryCallSettings + modifyCloudToDeviceConfigSettings() { + return ((DeviceManagerStubSettings) getStubSettings()).modifyCloudToDeviceConfigSettings(); + } + + /** Returns the object with the settings used for calls to listDeviceConfigVersions. */ + public UnaryCallSettings + listDeviceConfigVersionsSettings() { + return ((DeviceManagerStubSettings) getStubSettings()).listDeviceConfigVersionsSettings(); + } + + /** Returns the object with the settings used for calls to listDeviceStates. */ + public UnaryCallSettings + listDeviceStatesSettings() { + return ((DeviceManagerStubSettings) getStubSettings()).listDeviceStatesSettings(); + } + + /** Returns the object with the settings used for calls to setIamPolicy. */ + public UnaryCallSettings setIamPolicySettings() { + return ((DeviceManagerStubSettings) getStubSettings()).setIamPolicySettings(); + } + + /** Returns the object with the settings used for calls to getIamPolicy. */ + public UnaryCallSettings getIamPolicySettings() { + return ((DeviceManagerStubSettings) getStubSettings()).getIamPolicySettings(); + } + + /** Returns the object with the settings used for calls to testIamPermissions. */ + public UnaryCallSettings + testIamPermissionsSettings() { + return ((DeviceManagerStubSettings) getStubSettings()).testIamPermissionsSettings(); + } + + public static final DeviceManagerSettings create(DeviceManagerStubSettings stub) + throws IOException { + return new DeviceManagerSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return DeviceManagerStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return DeviceManagerStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return DeviceManagerStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return DeviceManagerStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return DeviceManagerStubSettings.defaultGrpcTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return DeviceManagerStubSettings.defaultTransportChannelProvider(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return DeviceManagerStubSettings.defaultApiClientHeaderProviderBuilder(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected DeviceManagerSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for DeviceManagerSettings. */ + public static class Builder extends ClientSettings.Builder { + protected Builder() throws IOException { + this((ClientContext) null); + } + + protected Builder(ClientContext clientContext) { + super(DeviceManagerStubSettings.newBuilder(clientContext)); + } + + private static Builder createDefault() { + return new Builder(DeviceManagerStubSettings.newBuilder()); + } + + protected Builder(DeviceManagerSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(DeviceManagerStubSettings.Builder stubSettings) { + super(stubSettings); + } + + public DeviceManagerStubSettings.Builder getStubSettingsBuilder() { + return ((DeviceManagerStubSettings.Builder) getStubSettings()); + } + + // NEXT_MAJOR_VER: remove 'throws Exception' + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) throws Exception { + super.applyToAllUnaryMethods( + getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); + return this; + } + + /** Returns the builder for the settings used for calls to createDeviceRegistry. */ + public UnaryCallSettings.Builder + createDeviceRegistrySettings() { + return getStubSettingsBuilder().createDeviceRegistrySettings(); + } + + /** Returns the builder for the settings used for calls to getDeviceRegistry. */ + public UnaryCallSettings.Builder + getDeviceRegistrySettings() { + return getStubSettingsBuilder().getDeviceRegistrySettings(); + } + + /** Returns the builder for the settings used for calls to updateDeviceRegistry. */ + public UnaryCallSettings.Builder + updateDeviceRegistrySettings() { + return getStubSettingsBuilder().updateDeviceRegistrySettings(); + } + + /** Returns the builder for the settings used for calls to deleteDeviceRegistry. */ + public UnaryCallSettings.Builder + deleteDeviceRegistrySettings() { + return getStubSettingsBuilder().deleteDeviceRegistrySettings(); + } + + /** Returns the builder for the settings used for calls to listDeviceRegistries. */ + public PagedCallSettings.Builder< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, + ListDeviceRegistriesPagedResponse> + listDeviceRegistriesSettings() { + return getStubSettingsBuilder().listDeviceRegistriesSettings(); + } + + /** Returns the builder for the settings used for calls to createDevice. */ + public UnaryCallSettings.Builder createDeviceSettings() { + return getStubSettingsBuilder().createDeviceSettings(); + } + + /** Returns the builder for the settings used for calls to getDevice. */ + public UnaryCallSettings.Builder getDeviceSettings() { + return getStubSettingsBuilder().getDeviceSettings(); + } + + /** Returns the builder for the settings used for calls to updateDevice. */ + public UnaryCallSettings.Builder updateDeviceSettings() { + return getStubSettingsBuilder().updateDeviceSettings(); + } + + /** Returns the builder for the settings used for calls to deleteDevice. */ + public UnaryCallSettings.Builder deleteDeviceSettings() { + return getStubSettingsBuilder().deleteDeviceSettings(); + } + + /** Returns the builder for the settings used for calls to listDevices. */ + public PagedCallSettings.Builder< + ListDevicesRequest, ListDevicesResponse, ListDevicesPagedResponse> + listDevicesSettings() { + return getStubSettingsBuilder().listDevicesSettings(); + } + + /** Returns the builder for the settings used for calls to modifyCloudToDeviceConfig. */ + public UnaryCallSettings.Builder + modifyCloudToDeviceConfigSettings() { + return getStubSettingsBuilder().modifyCloudToDeviceConfigSettings(); + } + + /** Returns the builder for the settings used for calls to listDeviceConfigVersions. */ + public UnaryCallSettings.Builder< + ListDeviceConfigVersionsRequest, ListDeviceConfigVersionsResponse> + listDeviceConfigVersionsSettings() { + return getStubSettingsBuilder().listDeviceConfigVersionsSettings(); + } + + /** Returns the builder for the settings used for calls to listDeviceStates. */ + public UnaryCallSettings.Builder + listDeviceStatesSettings() { + return getStubSettingsBuilder().listDeviceStatesSettings(); + } + + /** Returns the builder for the settings used for calls to setIamPolicy. */ + public UnaryCallSettings.Builder setIamPolicySettings() { + return getStubSettingsBuilder().setIamPolicySettings(); + } + + /** Returns the builder for the settings used for calls to getIamPolicy. */ + public UnaryCallSettings.Builder getIamPolicySettings() { + return getStubSettingsBuilder().getIamPolicySettings(); + } + + /** Returns the builder for the settings used for calls to testIamPermissions. */ + public UnaryCallSettings.Builder + testIamPermissionsSettings() { + return getStubSettingsBuilder().testIamPermissionsSettings(); + } + + @Override + public DeviceManagerSettings build() throws IOException { + return new DeviceManagerSettings(this); + } + } +} diff --git a/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/package-info.java b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/package-info.java new file mode 100644 index 000000000000..9534a559c886 --- /dev/null +++ b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/package-info.java @@ -0,0 +1,39 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * 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. + */ + +/** + * A client to Cloud IoT API. + * + *

The interfaces provided are listed below, along with usage samples. + * + *

=================== DeviceManagerClient =================== + * + *

Service Description: Internet of things (IoT) service. Allows to manipulate device registry + * instances and the registration of devices (Things) to the cloud. + * + *

Sample for DeviceManagerClient: + * + *

+ * 
+ * try (DeviceManagerClient deviceManagerClient = DeviceManagerClient.create()) {
+ *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+ *   DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build();
+ *   DeviceRegistry response = deviceManagerClient.createDeviceRegistry(parent, deviceRegistry);
+ * }
+ * 
+ * 
+ */ +package com.google.cloud.iot.v1; diff --git a/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/DeviceManagerStub.java b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/DeviceManagerStub.java new file mode 100644 index 000000000000..7ac5ab4de6f5 --- /dev/null +++ b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/DeviceManagerStub.java @@ -0,0 +1,142 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.iot.v1.stub; + +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDeviceRegistriesPagedResponse; +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDevicesPagedResponse; + +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.iot.v1.CreateDeviceRegistryRequest; +import com.google.cloud.iot.v1.CreateDeviceRequest; +import com.google.cloud.iot.v1.DeleteDeviceRegistryRequest; +import com.google.cloud.iot.v1.DeleteDeviceRequest; +import com.google.cloud.iot.v1.Device; +import com.google.cloud.iot.v1.DeviceConfig; +import com.google.cloud.iot.v1.DeviceRegistry; +import com.google.cloud.iot.v1.GetDeviceRegistryRequest; +import com.google.cloud.iot.v1.GetDeviceRequest; +import com.google.cloud.iot.v1.ListDeviceConfigVersionsRequest; +import com.google.cloud.iot.v1.ListDeviceConfigVersionsResponse; +import com.google.cloud.iot.v1.ListDeviceRegistriesRequest; +import com.google.cloud.iot.v1.ListDeviceRegistriesResponse; +import com.google.cloud.iot.v1.ListDeviceStatesRequest; +import com.google.cloud.iot.v1.ListDeviceStatesResponse; +import com.google.cloud.iot.v1.ListDevicesRequest; +import com.google.cloud.iot.v1.ListDevicesResponse; +import com.google.cloud.iot.v1.ModifyCloudToDeviceConfigRequest; +import com.google.cloud.iot.v1.UpdateDeviceRegistryRequest; +import com.google.cloud.iot.v1.UpdateDeviceRequest; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.protobuf.Empty; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS +/** + * Base stub class for Cloud IoT API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator") +@BetaApi("A restructuring of stub classes is planned, so this may break in the future") +public abstract class DeviceManagerStub implements BackgroundResource { + + public UnaryCallable createDeviceRegistryCallable() { + throw new UnsupportedOperationException("Not implemented: createDeviceRegistryCallable()"); + } + + public UnaryCallable getDeviceRegistryCallable() { + throw new UnsupportedOperationException("Not implemented: getDeviceRegistryCallable()"); + } + + public UnaryCallable updateDeviceRegistryCallable() { + throw new UnsupportedOperationException("Not implemented: updateDeviceRegistryCallable()"); + } + + public UnaryCallable deleteDeviceRegistryCallable() { + throw new UnsupportedOperationException("Not implemented: deleteDeviceRegistryCallable()"); + } + + public UnaryCallable + listDeviceRegistriesPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listDeviceRegistriesPagedCallable()"); + } + + public UnaryCallable + listDeviceRegistriesCallable() { + throw new UnsupportedOperationException("Not implemented: listDeviceRegistriesCallable()"); + } + + public UnaryCallable createDeviceCallable() { + throw new UnsupportedOperationException("Not implemented: createDeviceCallable()"); + } + + public UnaryCallable getDeviceCallable() { + throw new UnsupportedOperationException("Not implemented: getDeviceCallable()"); + } + + public UnaryCallable updateDeviceCallable() { + throw new UnsupportedOperationException("Not implemented: updateDeviceCallable()"); + } + + public UnaryCallable deleteDeviceCallable() { + throw new UnsupportedOperationException("Not implemented: deleteDeviceCallable()"); + } + + public UnaryCallable listDevicesPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listDevicesPagedCallable()"); + } + + public UnaryCallable listDevicesCallable() { + throw new UnsupportedOperationException("Not implemented: listDevicesCallable()"); + } + + public UnaryCallable + modifyCloudToDeviceConfigCallable() { + throw new UnsupportedOperationException("Not implemented: modifyCloudToDeviceConfigCallable()"); + } + + public UnaryCallable + listDeviceConfigVersionsCallable() { + throw new UnsupportedOperationException("Not implemented: listDeviceConfigVersionsCallable()"); + } + + public UnaryCallable + listDeviceStatesCallable() { + throw new UnsupportedOperationException("Not implemented: listDeviceStatesCallable()"); + } + + public UnaryCallable setIamPolicyCallable() { + throw new UnsupportedOperationException("Not implemented: setIamPolicyCallable()"); + } + + public UnaryCallable getIamPolicyCallable() { + throw new UnsupportedOperationException("Not implemented: getIamPolicyCallable()"); + } + + public UnaryCallable + testIamPermissionsCallable() { + throw new UnsupportedOperationException("Not implemented: testIamPermissionsCallable()"); + } + + @Override + public abstract void close(); +} diff --git a/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/DeviceManagerStubSettings.java b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/DeviceManagerStubSettings.java new file mode 100644 index 000000000000..0e93c14c2a09 --- /dev/null +++ b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/DeviceManagerStubSettings.java @@ -0,0 +1,826 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.iot.v1.stub; + +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDeviceRegistriesPagedResponse; +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDevicesPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.GaxProperties; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.GrpcTransportChannel; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.rpc.ApiCallContext; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.PagedListDescriptor; +import com.google.api.gax.rpc.PagedListResponseFactory; +import com.google.api.gax.rpc.StatusCode; +import com.google.api.gax.rpc.StubSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.iot.v1.CreateDeviceRegistryRequest; +import com.google.cloud.iot.v1.CreateDeviceRequest; +import com.google.cloud.iot.v1.DeleteDeviceRegistryRequest; +import com.google.cloud.iot.v1.DeleteDeviceRequest; +import com.google.cloud.iot.v1.Device; +import com.google.cloud.iot.v1.DeviceConfig; +import com.google.cloud.iot.v1.DeviceRegistry; +import com.google.cloud.iot.v1.GetDeviceRegistryRequest; +import com.google.cloud.iot.v1.GetDeviceRequest; +import com.google.cloud.iot.v1.ListDeviceConfigVersionsRequest; +import com.google.cloud.iot.v1.ListDeviceConfigVersionsResponse; +import com.google.cloud.iot.v1.ListDeviceRegistriesRequest; +import com.google.cloud.iot.v1.ListDeviceRegistriesResponse; +import com.google.cloud.iot.v1.ListDeviceStatesRequest; +import com.google.cloud.iot.v1.ListDeviceStatesResponse; +import com.google.cloud.iot.v1.ListDevicesRequest; +import com.google.cloud.iot.v1.ListDevicesResponse; +import com.google.cloud.iot.v1.ModifyCloudToDeviceConfigRequest; +import com.google.cloud.iot.v1.UpdateDeviceRegistryRequest; +import com.google.cloud.iot.v1.UpdateDeviceRequest; +import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableSet; +import com.google.common.collect.Lists; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; +import org.threeten.bp.Duration; + +// AUTO-GENERATED DOCUMENTATION AND CLASS +/** + * Settings class to configure an instance of {@link DeviceManagerStub}. + * + *

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

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

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. For + * example, to set the total timeout of createDeviceRegistry to 30 seconds: + * + *

+ * 
+ * DeviceManagerStubSettings.Builder deviceManagerSettingsBuilder =
+ *     DeviceManagerStubSettings.newBuilder();
+ * deviceManagerSettingsBuilder.createDeviceRegistrySettings().getRetrySettings().toBuilder()
+ *     .setTotalTimeout(Duration.ofSeconds(30));
+ * DeviceManagerStubSettings deviceManagerSettings = deviceManagerSettingsBuilder.build();
+ * 
+ * 
+ */ +@Generated("by gapic-generator") +@BetaApi +public class DeviceManagerStubSettings extends StubSettings { + /** The default scopes of the service. */ + private static final ImmutableList DEFAULT_SERVICE_SCOPES = + ImmutableList.builder() + .add("https://www.googleapis.com/auth/cloud-platform") + .add("https://www.googleapis.com/auth/cloudiot") + .build(); + + private final UnaryCallSettings + createDeviceRegistrySettings; + private final UnaryCallSettings + getDeviceRegistrySettings; + private final UnaryCallSettings + updateDeviceRegistrySettings; + private final UnaryCallSettings deleteDeviceRegistrySettings; + private final PagedCallSettings< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, + ListDeviceRegistriesPagedResponse> + listDeviceRegistriesSettings; + private final UnaryCallSettings createDeviceSettings; + private final UnaryCallSettings getDeviceSettings; + private final UnaryCallSettings updateDeviceSettings; + private final UnaryCallSettings deleteDeviceSettings; + private final PagedCallSettings + listDevicesSettings; + private final UnaryCallSettings + modifyCloudToDeviceConfigSettings; + private final UnaryCallSettings + listDeviceConfigVersionsSettings; + private final UnaryCallSettings + listDeviceStatesSettings; + private final UnaryCallSettings setIamPolicySettings; + private final UnaryCallSettings getIamPolicySettings; + private final UnaryCallSettings + testIamPermissionsSettings; + + /** Returns the object with the settings used for calls to createDeviceRegistry. */ + public UnaryCallSettings + createDeviceRegistrySettings() { + return createDeviceRegistrySettings; + } + + /** Returns the object with the settings used for calls to getDeviceRegistry. */ + public UnaryCallSettings getDeviceRegistrySettings() { + return getDeviceRegistrySettings; + } + + /** Returns the object with the settings used for calls to updateDeviceRegistry. */ + public UnaryCallSettings + updateDeviceRegistrySettings() { + return updateDeviceRegistrySettings; + } + + /** Returns the object with the settings used for calls to deleteDeviceRegistry. */ + public UnaryCallSettings deleteDeviceRegistrySettings() { + return deleteDeviceRegistrySettings; + } + + /** Returns the object with the settings used for calls to listDeviceRegistries. */ + public PagedCallSettings< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, + ListDeviceRegistriesPagedResponse> + listDeviceRegistriesSettings() { + return listDeviceRegistriesSettings; + } + + /** Returns the object with the settings used for calls to createDevice. */ + public UnaryCallSettings createDeviceSettings() { + return createDeviceSettings; + } + + /** Returns the object with the settings used for calls to getDevice. */ + public UnaryCallSettings getDeviceSettings() { + return getDeviceSettings; + } + + /** Returns the object with the settings used for calls to updateDevice. */ + public UnaryCallSettings updateDeviceSettings() { + return updateDeviceSettings; + } + + /** Returns the object with the settings used for calls to deleteDevice. */ + public UnaryCallSettings deleteDeviceSettings() { + return deleteDeviceSettings; + } + + /** Returns the object with the settings used for calls to listDevices. */ + public PagedCallSettings + listDevicesSettings() { + return listDevicesSettings; + } + + /** Returns the object with the settings used for calls to modifyCloudToDeviceConfig. */ + public UnaryCallSettings + modifyCloudToDeviceConfigSettings() { + return modifyCloudToDeviceConfigSettings; + } + + /** Returns the object with the settings used for calls to listDeviceConfigVersions. */ + public UnaryCallSettings + listDeviceConfigVersionsSettings() { + return listDeviceConfigVersionsSettings; + } + + /** Returns the object with the settings used for calls to listDeviceStates. */ + public UnaryCallSettings + listDeviceStatesSettings() { + return listDeviceStatesSettings; + } + + /** Returns the object with the settings used for calls to setIamPolicy. */ + public UnaryCallSettings setIamPolicySettings() { + return setIamPolicySettings; + } + + /** Returns the object with the settings used for calls to getIamPolicy. */ + public UnaryCallSettings getIamPolicySettings() { + return getIamPolicySettings; + } + + /** Returns the object with the settings used for calls to testIamPermissions. */ + public UnaryCallSettings + testIamPermissionsSettings() { + return testIamPermissionsSettings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public DeviceManagerStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(GrpcTransportChannel.getGrpcTransportName())) { + return GrpcDeviceManagerStub.create(this); + } else { + throw new UnsupportedOperationException( + "Transport not supported: " + getTransportChannelProvider().getTransportName()); + } + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return InstantiatingExecutorProvider.newBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return "cloudiot.googleapis.com:443"; + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return DEFAULT_SERVICE_SCOPES; + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return GoogleCredentialsProvider.newBuilder().setScopesToApply(DEFAULT_SERVICE_SCOPES); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return InstantiatingGrpcChannelProvider.newBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return defaultGrpcTransportProviderBuilder().build(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", GaxProperties.getLibraryVersion(DeviceManagerStubSettings.class)) + .setTransportToken( + GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected DeviceManagerStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + createDeviceRegistrySettings = settingsBuilder.createDeviceRegistrySettings().build(); + getDeviceRegistrySettings = settingsBuilder.getDeviceRegistrySettings().build(); + updateDeviceRegistrySettings = settingsBuilder.updateDeviceRegistrySettings().build(); + deleteDeviceRegistrySettings = settingsBuilder.deleteDeviceRegistrySettings().build(); + listDeviceRegistriesSettings = settingsBuilder.listDeviceRegistriesSettings().build(); + createDeviceSettings = settingsBuilder.createDeviceSettings().build(); + getDeviceSettings = settingsBuilder.getDeviceSettings().build(); + updateDeviceSettings = settingsBuilder.updateDeviceSettings().build(); + deleteDeviceSettings = settingsBuilder.deleteDeviceSettings().build(); + listDevicesSettings = settingsBuilder.listDevicesSettings().build(); + modifyCloudToDeviceConfigSettings = settingsBuilder.modifyCloudToDeviceConfigSettings().build(); + listDeviceConfigVersionsSettings = settingsBuilder.listDeviceConfigVersionsSettings().build(); + listDeviceStatesSettings = settingsBuilder.listDeviceStatesSettings().build(); + setIamPolicySettings = settingsBuilder.setIamPolicySettings().build(); + getIamPolicySettings = settingsBuilder.getIamPolicySettings().build(); + testIamPermissionsSettings = settingsBuilder.testIamPermissionsSettings().build(); + } + + private static final PagedListDescriptor< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, DeviceRegistry> + LIST_DEVICE_REGISTRIES_PAGE_STR_DESC = + new PagedListDescriptor< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, DeviceRegistry>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListDeviceRegistriesRequest injectToken( + ListDeviceRegistriesRequest payload, String token) { + return ListDeviceRegistriesRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListDeviceRegistriesRequest injectPageSize( + ListDeviceRegistriesRequest payload, int pageSize) { + return ListDeviceRegistriesRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListDeviceRegistriesRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListDeviceRegistriesResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListDeviceRegistriesResponse payload) { + return payload.getDeviceRegistriesList(); + } + }; + + private static final PagedListDescriptor + LIST_DEVICES_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListDevicesRequest injectToken(ListDevicesRequest payload, String token) { + return ListDevicesRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListDevicesRequest injectPageSize(ListDevicesRequest payload, int pageSize) { + return ListDevicesRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListDevicesRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListDevicesResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListDevicesResponse payload) { + return payload.getDevicesList(); + } + }; + + private static final PagedListResponseFactory< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, + ListDeviceRegistriesPagedResponse> + LIST_DEVICE_REGISTRIES_PAGE_STR_FACT = + new PagedListResponseFactory< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, + ListDeviceRegistriesPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListDeviceRegistriesRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext + pageContext = + PageContext.create( + callable, LIST_DEVICE_REGISTRIES_PAGE_STR_DESC, request, context); + return ListDeviceRegistriesPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListDevicesRequest, ListDevicesResponse, ListDevicesPagedResponse> + LIST_DEVICES_PAGE_STR_FACT = + new PagedListResponseFactory< + ListDevicesRequest, ListDevicesResponse, ListDevicesPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListDevicesRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_DEVICES_PAGE_STR_DESC, request, context); + return ListDevicesPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + /** Builder for DeviceManagerStubSettings. */ + public static class Builder extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + + private final UnaryCallSettings.Builder + createDeviceRegistrySettings; + private final UnaryCallSettings.Builder + getDeviceRegistrySettings; + private final UnaryCallSettings.Builder + updateDeviceRegistrySettings; + private final UnaryCallSettings.Builder + deleteDeviceRegistrySettings; + private final PagedCallSettings.Builder< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, + ListDeviceRegistriesPagedResponse> + listDeviceRegistriesSettings; + private final UnaryCallSettings.Builder createDeviceSettings; + private final UnaryCallSettings.Builder getDeviceSettings; + private final UnaryCallSettings.Builder updateDeviceSettings; + private final UnaryCallSettings.Builder deleteDeviceSettings; + private final PagedCallSettings.Builder< + ListDevicesRequest, ListDevicesResponse, ListDevicesPagedResponse> + listDevicesSettings; + private final UnaryCallSettings.Builder + modifyCloudToDeviceConfigSettings; + private final UnaryCallSettings.Builder< + ListDeviceConfigVersionsRequest, ListDeviceConfigVersionsResponse> + listDeviceConfigVersionsSettings; + private final UnaryCallSettings.Builder + listDeviceStatesSettings; + private final UnaryCallSettings.Builder setIamPolicySettings; + private final UnaryCallSettings.Builder getIamPolicySettings; + private final UnaryCallSettings.Builder + testIamPermissionsSettings; + + private static final ImmutableMap> + RETRYABLE_CODE_DEFINITIONS; + + static { + ImmutableMap.Builder> definitions = + ImmutableMap.builder(); + definitions.put( + "idempotent", + ImmutableSet.copyOf( + Lists.newArrayList( + StatusCode.Code.DEADLINE_EXCEEDED, StatusCode.Code.UNAVAILABLE))); + definitions.put("non_idempotent", ImmutableSet.copyOf(Lists.newArrayList())); + definitions.put( + "rate_limited_aware", + ImmutableSet.copyOf( + Lists.newArrayList( + StatusCode.Code.DEADLINE_EXCEEDED, + StatusCode.Code.RESOURCE_EXHAUSTED, + StatusCode.Code.UNAVAILABLE))); + RETRYABLE_CODE_DEFINITIONS = definitions.build(); + } + + private static final ImmutableMap RETRY_PARAM_DEFINITIONS; + + static { + ImmutableMap.Builder definitions = ImmutableMap.builder(); + RetrySettings settings = null; + settings = + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(100L)) + .setRetryDelayMultiplier(1.3) + .setMaxRetryDelay(Duration.ofMillis(60000L)) + .setInitialRpcTimeout(Duration.ofMillis(20000L)) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ofMillis(20000L)) + .setTotalTimeout(Duration.ofMillis(120000L)) + .build(); + definitions.put("default", settings); + settings = + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(1000L)) + .setRetryDelayMultiplier(1.3) + .setMaxRetryDelay(Duration.ofMillis(60000L)) + .setInitialRpcTimeout(Duration.ofMillis(20000L)) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ofMillis(20000L)) + .setTotalTimeout(Duration.ofMillis(120000L)) + .build(); + definitions.put("rate_limited_aware", settings); + RETRY_PARAM_DEFINITIONS = definitions.build(); + } + + protected Builder() { + this((ClientContext) null); + } + + protected Builder(ClientContext clientContext) { + super(clientContext); + + createDeviceRegistrySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + getDeviceRegistrySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + updateDeviceRegistrySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + deleteDeviceRegistrySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + listDeviceRegistriesSettings = + PagedCallSettings.newBuilder(LIST_DEVICE_REGISTRIES_PAGE_STR_FACT); + + createDeviceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + getDeviceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + updateDeviceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + deleteDeviceSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + listDevicesSettings = PagedCallSettings.newBuilder(LIST_DEVICES_PAGE_STR_FACT); + + modifyCloudToDeviceConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + listDeviceConfigVersionsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + listDeviceStatesSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + setIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + getIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + testIamPermissionsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + createDeviceRegistrySettings, + getDeviceRegistrySettings, + updateDeviceRegistrySettings, + deleteDeviceRegistrySettings, + listDeviceRegistriesSettings, + createDeviceSettings, + getDeviceSettings, + updateDeviceSettings, + deleteDeviceSettings, + listDevicesSettings, + modifyCloudToDeviceConfigSettings, + listDeviceConfigVersionsSettings, + listDeviceStatesSettings, + setIamPolicySettings, + getIamPolicySettings, + testIamPermissionsSettings); + + initDefaults(this); + } + + private static Builder createDefault() { + Builder builder = new Builder((ClientContext) null); + builder.setTransportChannelProvider(defaultTransportChannelProvider()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); + builder.setEndpoint(getDefaultEndpoint()); + return initDefaults(builder); + } + + private static Builder initDefaults(Builder builder) { + + builder + .createDeviceRegistrySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .getDeviceRegistrySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .updateDeviceRegistrySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .deleteDeviceRegistrySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .listDeviceRegistriesSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .createDeviceSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .getDeviceSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .updateDeviceSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .deleteDeviceSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .listDevicesSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .modifyCloudToDeviceConfigSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("rate_limited_aware")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("rate_limited_aware")); + + builder + .listDeviceConfigVersionsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .listDeviceStatesSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .setIamPolicySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .getIamPolicySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .testIamPermissionsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + return builder; + } + + protected Builder(DeviceManagerStubSettings settings) { + super(settings); + + createDeviceRegistrySettings = settings.createDeviceRegistrySettings.toBuilder(); + getDeviceRegistrySettings = settings.getDeviceRegistrySettings.toBuilder(); + updateDeviceRegistrySettings = settings.updateDeviceRegistrySettings.toBuilder(); + deleteDeviceRegistrySettings = settings.deleteDeviceRegistrySettings.toBuilder(); + listDeviceRegistriesSettings = settings.listDeviceRegistriesSettings.toBuilder(); + createDeviceSettings = settings.createDeviceSettings.toBuilder(); + getDeviceSettings = settings.getDeviceSettings.toBuilder(); + updateDeviceSettings = settings.updateDeviceSettings.toBuilder(); + deleteDeviceSettings = settings.deleteDeviceSettings.toBuilder(); + listDevicesSettings = settings.listDevicesSettings.toBuilder(); + modifyCloudToDeviceConfigSettings = settings.modifyCloudToDeviceConfigSettings.toBuilder(); + listDeviceConfigVersionsSettings = settings.listDeviceConfigVersionsSettings.toBuilder(); + listDeviceStatesSettings = settings.listDeviceStatesSettings.toBuilder(); + setIamPolicySettings = settings.setIamPolicySettings.toBuilder(); + getIamPolicySettings = settings.getIamPolicySettings.toBuilder(); + testIamPermissionsSettings = settings.testIamPermissionsSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + createDeviceRegistrySettings, + getDeviceRegistrySettings, + updateDeviceRegistrySettings, + deleteDeviceRegistrySettings, + listDeviceRegistriesSettings, + createDeviceSettings, + getDeviceSettings, + updateDeviceSettings, + deleteDeviceSettings, + listDevicesSettings, + modifyCloudToDeviceConfigSettings, + listDeviceConfigVersionsSettings, + listDeviceStatesSettings, + setIamPolicySettings, + getIamPolicySettings, + testIamPermissionsSettings); + } + + // NEXT_MAJOR_VER: remove 'throws Exception' + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) throws Exception { + super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); + return this; + } + + public ImmutableList> unaryMethodSettingsBuilders() { + return unaryMethodSettingsBuilders; + } + + /** Returns the builder for the settings used for calls to createDeviceRegistry. */ + public UnaryCallSettings.Builder + createDeviceRegistrySettings() { + return createDeviceRegistrySettings; + } + + /** Returns the builder for the settings used for calls to getDeviceRegistry. */ + public UnaryCallSettings.Builder + getDeviceRegistrySettings() { + return getDeviceRegistrySettings; + } + + /** Returns the builder for the settings used for calls to updateDeviceRegistry. */ + public UnaryCallSettings.Builder + updateDeviceRegistrySettings() { + return updateDeviceRegistrySettings; + } + + /** Returns the builder for the settings used for calls to deleteDeviceRegistry. */ + public UnaryCallSettings.Builder + deleteDeviceRegistrySettings() { + return deleteDeviceRegistrySettings; + } + + /** Returns the builder for the settings used for calls to listDeviceRegistries. */ + public PagedCallSettings.Builder< + ListDeviceRegistriesRequest, ListDeviceRegistriesResponse, + ListDeviceRegistriesPagedResponse> + listDeviceRegistriesSettings() { + return listDeviceRegistriesSettings; + } + + /** Returns the builder for the settings used for calls to createDevice. */ + public UnaryCallSettings.Builder createDeviceSettings() { + return createDeviceSettings; + } + + /** Returns the builder for the settings used for calls to getDevice. */ + public UnaryCallSettings.Builder getDeviceSettings() { + return getDeviceSettings; + } + + /** Returns the builder for the settings used for calls to updateDevice. */ + public UnaryCallSettings.Builder updateDeviceSettings() { + return updateDeviceSettings; + } + + /** Returns the builder for the settings used for calls to deleteDevice. */ + public UnaryCallSettings.Builder deleteDeviceSettings() { + return deleteDeviceSettings; + } + + /** Returns the builder for the settings used for calls to listDevices. */ + public PagedCallSettings.Builder< + ListDevicesRequest, ListDevicesResponse, ListDevicesPagedResponse> + listDevicesSettings() { + return listDevicesSettings; + } + + /** Returns the builder for the settings used for calls to modifyCloudToDeviceConfig. */ + public UnaryCallSettings.Builder + modifyCloudToDeviceConfigSettings() { + return modifyCloudToDeviceConfigSettings; + } + + /** Returns the builder for the settings used for calls to listDeviceConfigVersions. */ + public UnaryCallSettings.Builder< + ListDeviceConfigVersionsRequest, ListDeviceConfigVersionsResponse> + listDeviceConfigVersionsSettings() { + return listDeviceConfigVersionsSettings; + } + + /** Returns the builder for the settings used for calls to listDeviceStates. */ + public UnaryCallSettings.Builder + listDeviceStatesSettings() { + return listDeviceStatesSettings; + } + + /** Returns the builder for the settings used for calls to setIamPolicy. */ + public UnaryCallSettings.Builder setIamPolicySettings() { + return setIamPolicySettings; + } + + /** Returns the builder for the settings used for calls to getIamPolicy. */ + public UnaryCallSettings.Builder getIamPolicySettings() { + return getIamPolicySettings; + } + + /** Returns the builder for the settings used for calls to testIamPermissions. */ + public UnaryCallSettings.Builder + testIamPermissionsSettings() { + return testIamPermissionsSettings; + } + + @Override + public DeviceManagerStubSettings build() throws IOException { + return new DeviceManagerStubSettings(this); + } + } +} diff --git a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/GrpcDlpServiceCallableFactory.java b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/GrpcDeviceManagerCallableFactory.java similarity index 94% rename from google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/GrpcDlpServiceCallableFactory.java rename to google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/GrpcDeviceManagerCallableFactory.java index cc4a21dfe501..85481f99f7ea 100644 --- a/google-cloud-clients/google-cloud-dlp/src/main/java/com/google/cloud/dlp/v2beta1/stub/GrpcDlpServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/GrpcDeviceManagerCallableFactory.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.google.cloud.dlp.v2beta1.stub; +package com.google.cloud.iot.v1.stub; import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; @@ -37,13 +37,13 @@ // AUTO-GENERATED DOCUMENTATION AND CLASS /** - * gRPC callable factory implementation for DLP API. + * gRPC callable factory implementation for Cloud IoT API. * *

This class is for advanced usage. */ @Generated("by gapic-generator") @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") -public class GrpcDlpServiceCallableFactory implements GrpcStubCallableFactory { +public class GrpcDeviceManagerCallableFactory implements GrpcStubCallableFactory { @Override public UnaryCallable createUnaryCallable( GrpcCallSettings grpcCallSettings, @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/GrpcDeviceManagerStub.java b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/GrpcDeviceManagerStub.java new file mode 100644 index 000000000000..4bedbca02ef5 --- /dev/null +++ b/google-cloud-clients/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/GrpcDeviceManagerStub.java @@ -0,0 +1,683 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.iot.v1.stub; + +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDeviceRegistriesPagedResponse; +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDevicesPagedResponse; + +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.core.BackgroundResourceAggregation; +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.RequestParamsExtractor; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.iot.v1.CreateDeviceRegistryRequest; +import com.google.cloud.iot.v1.CreateDeviceRequest; +import com.google.cloud.iot.v1.DeleteDeviceRegistryRequest; +import com.google.cloud.iot.v1.DeleteDeviceRequest; +import com.google.cloud.iot.v1.Device; +import com.google.cloud.iot.v1.DeviceConfig; +import com.google.cloud.iot.v1.DeviceRegistry; +import com.google.cloud.iot.v1.GetDeviceRegistryRequest; +import com.google.cloud.iot.v1.GetDeviceRequest; +import com.google.cloud.iot.v1.ListDeviceConfigVersionsRequest; +import com.google.cloud.iot.v1.ListDeviceConfigVersionsResponse; +import com.google.cloud.iot.v1.ListDeviceRegistriesRequest; +import com.google.cloud.iot.v1.ListDeviceRegistriesResponse; +import com.google.cloud.iot.v1.ListDeviceStatesRequest; +import com.google.cloud.iot.v1.ListDeviceStatesResponse; +import com.google.cloud.iot.v1.ListDevicesRequest; +import com.google.cloud.iot.v1.ListDevicesResponse; +import com.google.cloud.iot.v1.ModifyCloudToDeviceConfigRequest; +import com.google.cloud.iot.v1.UpdateDeviceRegistryRequest; +import com.google.cloud.iot.v1.UpdateDeviceRequest; +import com.google.common.collect.ImmutableMap; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.protobuf.Empty; +import io.grpc.MethodDescriptor; +import io.grpc.protobuf.ProtoUtils; +import java.io.IOException; +import java.util.Map; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS +/** + * gRPC stub implementation for Cloud IoT API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator") +@BetaApi("A restructuring of stub classes is planned, so this may break in the future") +public class GrpcDeviceManagerStub extends DeviceManagerStub { + + private static final MethodDescriptor + createDeviceRegistryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/CreateDeviceRegistry") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateDeviceRegistryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(DeviceRegistry.getDefaultInstance())) + .build(); + private static final MethodDescriptor + getDeviceRegistryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/GetDeviceRegistry") + .setRequestMarshaller( + ProtoUtils.marshaller(GetDeviceRegistryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(DeviceRegistry.getDefaultInstance())) + .build(); + private static final MethodDescriptor + updateDeviceRegistryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/UpdateDeviceRegistry") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateDeviceRegistryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(DeviceRegistry.getDefaultInstance())) + .build(); + private static final MethodDescriptor + deleteDeviceRegistryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/DeleteDeviceRegistry") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteDeviceRegistryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) + .build(); + private static final MethodDescriptor + listDeviceRegistriesMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/ListDeviceRegistries") + .setRequestMarshaller( + ProtoUtils.marshaller(ListDeviceRegistriesRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListDeviceRegistriesResponse.getDefaultInstance())) + .build(); + private static final MethodDescriptor createDeviceMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/CreateDevice") + .setRequestMarshaller(ProtoUtils.marshaller(CreateDeviceRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Device.getDefaultInstance())) + .build(); + private static final MethodDescriptor getDeviceMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/GetDevice") + .setRequestMarshaller(ProtoUtils.marshaller(GetDeviceRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Device.getDefaultInstance())) + .build(); + private static final MethodDescriptor updateDeviceMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/UpdateDevice") + .setRequestMarshaller(ProtoUtils.marshaller(UpdateDeviceRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Device.getDefaultInstance())) + .build(); + private static final MethodDescriptor deleteDeviceMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/DeleteDevice") + .setRequestMarshaller(ProtoUtils.marshaller(DeleteDeviceRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) + .build(); + private static final MethodDescriptor + listDevicesMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/ListDevices") + .setRequestMarshaller(ProtoUtils.marshaller(ListDevicesRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListDevicesResponse.getDefaultInstance())) + .build(); + private static final MethodDescriptor + modifyCloudToDeviceConfigMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/ModifyCloudToDeviceConfig") + .setRequestMarshaller( + ProtoUtils.marshaller(ModifyCloudToDeviceConfigRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(DeviceConfig.getDefaultInstance())) + .build(); + private static final MethodDescriptor< + ListDeviceConfigVersionsRequest, ListDeviceConfigVersionsResponse> + listDeviceConfigVersionsMethodDescriptor = + MethodDescriptor + .newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/ListDeviceConfigVersions") + .setRequestMarshaller( + ProtoUtils.marshaller(ListDeviceConfigVersionsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListDeviceConfigVersionsResponse.getDefaultInstance())) + .build(); + private static final MethodDescriptor + listDeviceStatesMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/ListDeviceStates") + .setRequestMarshaller( + ProtoUtils.marshaller(ListDeviceStatesRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListDeviceStatesResponse.getDefaultInstance())) + .build(); + private static final MethodDescriptor setIamPolicyMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/SetIamPolicy") + .setRequestMarshaller(ProtoUtils.marshaller(SetIamPolicyRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Policy.getDefaultInstance())) + .build(); + private static final MethodDescriptor getIamPolicyMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/GetIamPolicy") + .setRequestMarshaller(ProtoUtils.marshaller(GetIamPolicyRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Policy.getDefaultInstance())) + .build(); + private static final MethodDescriptor + testIamPermissionsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.iot.v1.DeviceManager/TestIamPermissions") + .setRequestMarshaller( + ProtoUtils.marshaller(TestIamPermissionsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(TestIamPermissionsResponse.getDefaultInstance())) + .build(); + + private final BackgroundResource backgroundResources; + + private final UnaryCallable + createDeviceRegistryCallable; + private final UnaryCallable getDeviceRegistryCallable; + private final UnaryCallable + updateDeviceRegistryCallable; + private final UnaryCallable deleteDeviceRegistryCallable; + private final UnaryCallable + listDeviceRegistriesCallable; + private final UnaryCallable + listDeviceRegistriesPagedCallable; + private final UnaryCallable createDeviceCallable; + private final UnaryCallable getDeviceCallable; + private final UnaryCallable updateDeviceCallable; + private final UnaryCallable deleteDeviceCallable; + private final UnaryCallable listDevicesCallable; + private final UnaryCallable + listDevicesPagedCallable; + private final UnaryCallable + modifyCloudToDeviceConfigCallable; + private final UnaryCallable + listDeviceConfigVersionsCallable; + private final UnaryCallable + listDeviceStatesCallable; + private final UnaryCallable setIamPolicyCallable; + private final UnaryCallable getIamPolicyCallable; + private final UnaryCallable + testIamPermissionsCallable; + + private final GrpcStubCallableFactory callableFactory; + + public static final GrpcDeviceManagerStub create(DeviceManagerStubSettings settings) + throws IOException { + return new GrpcDeviceManagerStub(settings, ClientContext.create(settings)); + } + + public static final GrpcDeviceManagerStub create(ClientContext clientContext) throws IOException { + return new GrpcDeviceManagerStub(DeviceManagerStubSettings.newBuilder().build(), clientContext); + } + + public static final GrpcDeviceManagerStub create( + ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { + return new GrpcDeviceManagerStub( + DeviceManagerStubSettings.newBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of GrpcDeviceManagerStub, using the given settings. This is protected so + * that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected GrpcDeviceManagerStub(DeviceManagerStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new GrpcDeviceManagerCallableFactory()); + } + + /** + * Constructs an instance of GrpcDeviceManagerStub, using the given settings. This is protected so + * that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected GrpcDeviceManagerStub( + DeviceManagerStubSettings settings, + ClientContext clientContext, + GrpcStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + + GrpcCallSettings + createDeviceRegistryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createDeviceRegistryMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(CreateDeviceRegistryRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); + GrpcCallSettings getDeviceRegistryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getDeviceRegistryMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(GetDeviceRegistryRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings + updateDeviceRegistryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateDeviceRegistryMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(UpdateDeviceRegistryRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put( + "device_registry.name", + String.valueOf(request.getDeviceRegistry().getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings deleteDeviceRegistryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteDeviceRegistryMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(DeleteDeviceRegistryRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings + listDeviceRegistriesTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listDeviceRegistriesMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(ListDeviceRegistriesRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); + GrpcCallSettings createDeviceTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createDeviceMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(CreateDeviceRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); + GrpcCallSettings getDeviceTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getDeviceMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(GetDeviceRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings updateDeviceTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateDeviceMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(UpdateDeviceRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("device.name", String.valueOf(request.getDevice().getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings deleteDeviceTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteDeviceMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(DeleteDeviceRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings listDevicesTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listDevicesMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(ListDevicesRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); + GrpcCallSettings + modifyCloudToDeviceConfigTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(modifyCloudToDeviceConfigMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(ModifyCloudToDeviceConfigRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings + listDeviceConfigVersionsTransportSettings = + GrpcCallSettings + .newBuilder() + .setMethodDescriptor(listDeviceConfigVersionsMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(ListDeviceConfigVersionsRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings + listDeviceStatesTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listDeviceStatesMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(ListDeviceStatesRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings setIamPolicyTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(setIamPolicyMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(SetIamPolicyRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("resource", String.valueOf(request.getResource())); + return params.build(); + } + }) + .build(); + GrpcCallSettings getIamPolicyTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getIamPolicyMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(GetIamPolicyRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("resource", String.valueOf(request.getResource())); + return params.build(); + } + }) + .build(); + GrpcCallSettings + testIamPermissionsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(testIamPermissionsMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(TestIamPermissionsRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("resource", String.valueOf(request.getResource())); + return params.build(); + } + }) + .build(); + + this.createDeviceRegistryCallable = + callableFactory.createUnaryCallable( + createDeviceRegistryTransportSettings, + settings.createDeviceRegistrySettings(), + clientContext); + this.getDeviceRegistryCallable = + callableFactory.createUnaryCallable( + getDeviceRegistryTransportSettings, + settings.getDeviceRegistrySettings(), + clientContext); + this.updateDeviceRegistryCallable = + callableFactory.createUnaryCallable( + updateDeviceRegistryTransportSettings, + settings.updateDeviceRegistrySettings(), + clientContext); + this.deleteDeviceRegistryCallable = + callableFactory.createUnaryCallable( + deleteDeviceRegistryTransportSettings, + settings.deleteDeviceRegistrySettings(), + clientContext); + this.listDeviceRegistriesCallable = + callableFactory.createUnaryCallable( + listDeviceRegistriesTransportSettings, + settings.listDeviceRegistriesSettings(), + clientContext); + this.listDeviceRegistriesPagedCallable = + callableFactory.createPagedCallable( + listDeviceRegistriesTransportSettings, + settings.listDeviceRegistriesSettings(), + clientContext); + this.createDeviceCallable = + callableFactory.createUnaryCallable( + createDeviceTransportSettings, settings.createDeviceSettings(), clientContext); + this.getDeviceCallable = + callableFactory.createUnaryCallable( + getDeviceTransportSettings, settings.getDeviceSettings(), clientContext); + this.updateDeviceCallable = + callableFactory.createUnaryCallable( + updateDeviceTransportSettings, settings.updateDeviceSettings(), clientContext); + this.deleteDeviceCallable = + callableFactory.createUnaryCallable( + deleteDeviceTransportSettings, settings.deleteDeviceSettings(), clientContext); + this.listDevicesCallable = + callableFactory.createUnaryCallable( + listDevicesTransportSettings, settings.listDevicesSettings(), clientContext); + this.listDevicesPagedCallable = + callableFactory.createPagedCallable( + listDevicesTransportSettings, settings.listDevicesSettings(), clientContext); + this.modifyCloudToDeviceConfigCallable = + callableFactory.createUnaryCallable( + modifyCloudToDeviceConfigTransportSettings, + settings.modifyCloudToDeviceConfigSettings(), + clientContext); + this.listDeviceConfigVersionsCallable = + callableFactory.createUnaryCallable( + listDeviceConfigVersionsTransportSettings, + settings.listDeviceConfigVersionsSettings(), + clientContext); + this.listDeviceStatesCallable = + callableFactory.createUnaryCallable( + listDeviceStatesTransportSettings, settings.listDeviceStatesSettings(), clientContext); + this.setIamPolicyCallable = + callableFactory.createUnaryCallable( + setIamPolicyTransportSettings, settings.setIamPolicySettings(), clientContext); + this.getIamPolicyCallable = + callableFactory.createUnaryCallable( + getIamPolicyTransportSettings, settings.getIamPolicySettings(), clientContext); + this.testIamPermissionsCallable = + callableFactory.createUnaryCallable( + testIamPermissionsTransportSettings, + settings.testIamPermissionsSettings(), + clientContext); + + backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + public UnaryCallable createDeviceRegistryCallable() { + return createDeviceRegistryCallable; + } + + public UnaryCallable getDeviceRegistryCallable() { + return getDeviceRegistryCallable; + } + + public UnaryCallable updateDeviceRegistryCallable() { + return updateDeviceRegistryCallable; + } + + public UnaryCallable deleteDeviceRegistryCallable() { + return deleteDeviceRegistryCallable; + } + + public UnaryCallable + listDeviceRegistriesPagedCallable() { + return listDeviceRegistriesPagedCallable; + } + + public UnaryCallable + listDeviceRegistriesCallable() { + return listDeviceRegistriesCallable; + } + + public UnaryCallable createDeviceCallable() { + return createDeviceCallable; + } + + public UnaryCallable getDeviceCallable() { + return getDeviceCallable; + } + + public UnaryCallable updateDeviceCallable() { + return updateDeviceCallable; + } + + public UnaryCallable deleteDeviceCallable() { + return deleteDeviceCallable; + } + + public UnaryCallable listDevicesPagedCallable() { + return listDevicesPagedCallable; + } + + public UnaryCallable listDevicesCallable() { + return listDevicesCallable; + } + + public UnaryCallable + modifyCloudToDeviceConfigCallable() { + return modifyCloudToDeviceConfigCallable; + } + + public UnaryCallable + listDeviceConfigVersionsCallable() { + return listDeviceConfigVersionsCallable; + } + + public UnaryCallable + listDeviceStatesCallable() { + return listDeviceStatesCallable; + } + + public UnaryCallable setIamPolicyCallable() { + return setIamPolicyCallable; + } + + public UnaryCallable getIamPolicyCallable() { + return getIamPolicyCallable; + } + + public UnaryCallable + testIamPermissionsCallable() { + return testIamPermissionsCallable; + } + + @Override + public final void close() { + shutdown(); + } + + @Override + public void shutdown() { + backgroundResources.shutdown(); + } + + @Override + public boolean isShutdown() { + return backgroundResources.isShutdown(); + } + + @Override + public boolean isTerminated() { + return backgroundResources.isTerminated(); + } + + @Override + public void shutdownNow() { + backgroundResources.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return backgroundResources.awaitTermination(duration, unit); + } +} diff --git a/google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/DeviceManagerClientTest.java b/google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/DeviceManagerClientTest.java new file mode 100644 index 000000000000..2e29a774afa9 --- /dev/null +++ b/google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/DeviceManagerClientTest.java @@ -0,0 +1,784 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.iot.v1; + +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDeviceRegistriesPagedResponse; +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDevicesPagedResponse; + +import com.google.api.gax.core.NoCredentialsProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.testing.LocalChannelProvider; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.api.gax.grpc.testing.MockServiceHelper; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.InvalidArgumentException; +import com.google.common.collect.Lists; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.protobuf.ByteString; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import com.google.protobuf.GeneratedMessageV3; +import io.grpc.Status; +import io.grpc.StatusRuntimeException; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.Objects; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; + +@javax.annotation.Generated("by GAPIC") +public class DeviceManagerClientTest { + private static MockDeviceManager mockDeviceManager; + private static MockServiceHelper serviceHelper; + private DeviceManagerClient client; + private LocalChannelProvider channelProvider; + + @BeforeClass + public static void startStaticServer() { + mockDeviceManager = new MockDeviceManager(); + serviceHelper = + new MockServiceHelper("in-process-1", Arrays.asList(mockDeviceManager)); + serviceHelper.start(); + } + + @AfterClass + public static void stopServer() { + serviceHelper.stop(); + } + + @Before + public void setUp() throws IOException { + serviceHelper.reset(); + channelProvider = serviceHelper.createChannelProvider(); + DeviceManagerSettings settings = + DeviceManagerSettings.newBuilder() + .setTransportChannelProvider(channelProvider) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = DeviceManagerClient.create(settings); + } + + @After + public void tearDown() throws Exception { + client.close(); + } + + @Test + @SuppressWarnings("all") + public void createDeviceRegistryTest() { + String id = "id3355"; + RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + DeviceRegistry expectedResponse = + DeviceRegistry.newBuilder().setId(id).setName(name.toString()).build(); + mockDeviceManager.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build(); + + DeviceRegistry actualResponse = client.createDeviceRegistry(parent, deviceRegistry); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateDeviceRegistryRequest actualRequest = (CreateDeviceRegistryRequest) actualRequests.get(0); + + Assert.assertEquals(parent, LocationName.parse(actualRequest.getParent())); + Assert.assertEquals(deviceRegistry, actualRequest.getDeviceRegistry()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void createDeviceRegistryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build(); + + client.createDeviceRegistry(parent, deviceRegistry); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void getDeviceRegistryTest() { + String id = "id3355"; + RegistryName name2 = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + DeviceRegistry expectedResponse = + DeviceRegistry.newBuilder().setId(id).setName(name2.toString()).build(); + mockDeviceManager.addResponse(expectedResponse); + + RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + + DeviceRegistry actualResponse = client.getDeviceRegistry(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetDeviceRegistryRequest actualRequest = (GetDeviceRegistryRequest) actualRequests.get(0); + + Assert.assertEquals(name, RegistryName.parse(actualRequest.getName())); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void getDeviceRegistryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + + client.getDeviceRegistry(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void updateDeviceRegistryTest() { + String id = "id3355"; + RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + DeviceRegistry expectedResponse = + DeviceRegistry.newBuilder().setId(id).setName(name.toString()).build(); + mockDeviceManager.addResponse(expectedResponse); + + DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + DeviceRegistry actualResponse = client.updateDeviceRegistry(deviceRegistry, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateDeviceRegistryRequest actualRequest = (UpdateDeviceRegistryRequest) actualRequests.get(0); + + Assert.assertEquals(deviceRegistry, actualRequest.getDeviceRegistry()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void updateDeviceRegistryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + DeviceRegistry deviceRegistry = DeviceRegistry.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + client.updateDeviceRegistry(deviceRegistry, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void deleteDeviceRegistryTest() { + Empty expectedResponse = Empty.newBuilder().build(); + mockDeviceManager.addResponse(expectedResponse); + + RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + + client.deleteDeviceRegistry(name); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteDeviceRegistryRequest actualRequest = (DeleteDeviceRegistryRequest) actualRequests.get(0); + + Assert.assertEquals(name, RegistryName.parse(actualRequest.getName())); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void deleteDeviceRegistryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + RegistryName name = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + + client.deleteDeviceRegistry(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void listDeviceRegistriesTest() { + String nextPageToken = ""; + DeviceRegistry deviceRegistriesElement = DeviceRegistry.newBuilder().build(); + List deviceRegistries = Arrays.asList(deviceRegistriesElement); + ListDeviceRegistriesResponse expectedResponse = + ListDeviceRegistriesResponse.newBuilder() + .setNextPageToken(nextPageToken) + .addAllDeviceRegistries(deviceRegistries) + .build(); + mockDeviceManager.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListDeviceRegistriesPagedResponse pagedListResponse = client.listDeviceRegistries(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getDeviceRegistriesList().get(0), resources.get(0)); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListDeviceRegistriesRequest actualRequest = (ListDeviceRegistriesRequest) actualRequests.get(0); + + Assert.assertEquals(parent, LocationName.parse(actualRequest.getParent())); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void listDeviceRegistriesExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + client.listDeviceRegistries(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void createDeviceTest() { + String id = "id3355"; + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + long numId = 1034366860L; + boolean blocked = true; + Device expectedResponse = + Device.newBuilder() + .setId(id) + .setName(name.toString()) + .setNumId(numId) + .setBlocked(blocked) + .build(); + mockDeviceManager.addResponse(expectedResponse); + + RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + Device device = Device.newBuilder().build(); + + Device actualResponse = client.createDevice(parent, device); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateDeviceRequest actualRequest = (CreateDeviceRequest) actualRequests.get(0); + + Assert.assertEquals(parent, RegistryName.parse(actualRequest.getParent())); + Assert.assertEquals(device, actualRequest.getDevice()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void createDeviceExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + Device device = Device.newBuilder().build(); + + client.createDevice(parent, device); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void getDeviceTest() { + String id = "id3355"; + DeviceName name2 = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + long numId = 1034366860L; + boolean blocked = true; + Device expectedResponse = + Device.newBuilder() + .setId(id) + .setName(name2.toString()) + .setNumId(numId) + .setBlocked(blocked) + .build(); + mockDeviceManager.addResponse(expectedResponse); + + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + + Device actualResponse = client.getDevice(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetDeviceRequest actualRequest = (GetDeviceRequest) actualRequests.get(0); + + Assert.assertEquals(name, DeviceName.parse(actualRequest.getName())); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void getDeviceExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + + client.getDevice(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void updateDeviceTest() { + String id = "id3355"; + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + long numId = 1034366860L; + boolean blocked = true; + Device expectedResponse = + Device.newBuilder() + .setId(id) + .setName(name.toString()) + .setNumId(numId) + .setBlocked(blocked) + .build(); + mockDeviceManager.addResponse(expectedResponse); + + Device device = Device.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Device actualResponse = client.updateDevice(device, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateDeviceRequest actualRequest = (UpdateDeviceRequest) actualRequests.get(0); + + Assert.assertEquals(device, actualRequest.getDevice()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void updateDeviceExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + Device device = Device.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + client.updateDevice(device, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void deleteDeviceTest() { + Empty expectedResponse = Empty.newBuilder().build(); + mockDeviceManager.addResponse(expectedResponse); + + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + + client.deleteDevice(name); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteDeviceRequest actualRequest = (DeleteDeviceRequest) actualRequests.get(0); + + Assert.assertEquals(name, DeviceName.parse(actualRequest.getName())); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void deleteDeviceExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + + client.deleteDevice(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void listDevicesTest() { + String nextPageToken = ""; + Device devicesElement = Device.newBuilder().build(); + List devices = Arrays.asList(devicesElement); + ListDevicesResponse expectedResponse = + ListDevicesResponse.newBuilder() + .setNextPageToken(nextPageToken) + .addAllDevices(devices) + .build(); + mockDeviceManager.addResponse(expectedResponse); + + RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + + ListDevicesPagedResponse pagedListResponse = client.listDevices(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getDevicesList().get(0), resources.get(0)); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListDevicesRequest actualRequest = (ListDevicesRequest) actualRequests.get(0); + + Assert.assertEquals(parent, RegistryName.parse(actualRequest.getParent())); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void listDevicesExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + RegistryName parent = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + + client.listDevices(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void modifyCloudToDeviceConfigTest() { + long version = 351608024L; + ByteString binaryData2 = ByteString.copyFromUtf8("-37"); + DeviceConfig expectedResponse = + DeviceConfig.newBuilder().setVersion(version).setBinaryData(binaryData2).build(); + mockDeviceManager.addResponse(expectedResponse); + + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + ByteString binaryData = ByteString.copyFromUtf8("40"); + + DeviceConfig actualResponse = client.modifyCloudToDeviceConfig(name, binaryData); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ModifyCloudToDeviceConfigRequest actualRequest = + (ModifyCloudToDeviceConfigRequest) actualRequests.get(0); + + Assert.assertEquals(name, DeviceName.parse(actualRequest.getName())); + Assert.assertEquals(binaryData, actualRequest.getBinaryData()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void modifyCloudToDeviceConfigExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + ByteString binaryData = ByteString.copyFromUtf8("40"); + + client.modifyCloudToDeviceConfig(name, binaryData); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void listDeviceConfigVersionsTest() { + ListDeviceConfigVersionsResponse expectedResponse = + ListDeviceConfigVersionsResponse.newBuilder().build(); + mockDeviceManager.addResponse(expectedResponse); + + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + + ListDeviceConfigVersionsResponse actualResponse = client.listDeviceConfigVersions(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListDeviceConfigVersionsRequest actualRequest = + (ListDeviceConfigVersionsRequest) actualRequests.get(0); + + Assert.assertEquals(name, DeviceName.parse(actualRequest.getName())); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void listDeviceConfigVersionsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + + client.listDeviceConfigVersions(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void listDeviceStatesTest() { + ListDeviceStatesResponse expectedResponse = ListDeviceStatesResponse.newBuilder().build(); + mockDeviceManager.addResponse(expectedResponse); + + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + + ListDeviceStatesResponse actualResponse = client.listDeviceStates(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListDeviceStatesRequest actualRequest = (ListDeviceStatesRequest) actualRequests.get(0); + + Assert.assertEquals(name, DeviceName.parse(actualRequest.getName())); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void listDeviceStatesExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + DeviceName name = DeviceName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]", "[DEVICE]"); + + client.listDeviceStates(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void setIamPolicyTest() { + int version = 351608024; + ByteString etag = ByteString.copyFromUtf8("21"); + Policy expectedResponse = Policy.newBuilder().setVersion(version).setEtag(etag).build(); + mockDeviceManager.addResponse(expectedResponse); + + RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + Policy policy = Policy.newBuilder().build(); + + Policy actualResponse = client.setIamPolicy(resource, policy); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + SetIamPolicyRequest actualRequest = (SetIamPolicyRequest) actualRequests.get(0); + + Assert.assertEquals(Objects.toString(resource), Objects.toString(actualRequest.getResource())); + Assert.assertEquals(policy, actualRequest.getPolicy()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void setIamPolicyExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + Policy policy = Policy.newBuilder().build(); + + client.setIamPolicy(resource, policy); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void getIamPolicyTest() { + int version = 351608024; + ByteString etag = ByteString.copyFromUtf8("21"); + Policy expectedResponse = Policy.newBuilder().setVersion(version).setEtag(etag).build(); + mockDeviceManager.addResponse(expectedResponse); + + RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + + Policy actualResponse = client.getIamPolicy(resource); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetIamPolicyRequest actualRequest = (GetIamPolicyRequest) actualRequests.get(0); + + Assert.assertEquals(Objects.toString(resource), Objects.toString(actualRequest.getResource())); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void getIamPolicyExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + + client.getIamPolicy(resource); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void testIamPermissionsTest() { + TestIamPermissionsResponse expectedResponse = TestIamPermissionsResponse.newBuilder().build(); + mockDeviceManager.addResponse(expectedResponse); + + RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + List permissions = new ArrayList<>(); + + TestIamPermissionsResponse actualResponse = client.testIamPermissions(resource, permissions); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockDeviceManager.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + TestIamPermissionsRequest actualRequest = (TestIamPermissionsRequest) actualRequests.get(0); + + Assert.assertEquals(Objects.toString(resource), Objects.toString(actualRequest.getResource())); + Assert.assertEquals(permissions, actualRequest.getPermissionsList()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void testIamPermissionsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockDeviceManager.addException(exception); + + try { + RegistryName resource = RegistryName.of("[PROJECT]", "[LOCATION]", "[REGISTRY]"); + List permissions = new ArrayList<>(); + + client.testIamPermissions(resource, permissions); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } +} diff --git a/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/DlpServiceSmokeTest.java b/google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/DeviceManagerSmokeTest.java similarity index 62% rename from google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/DlpServiceSmokeTest.java rename to google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/DeviceManagerSmokeTest.java index 69d078aeac26..507896c73c3c 100644 --- a/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/DlpServiceSmokeTest.java +++ b/google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/DeviceManagerSmokeTest.java @@ -13,21 +13,17 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.google.cloud.dlp.v2beta1; +package com.google.cloud.iot.v1; + +import static com.google.cloud.iot.v1.DeviceManagerClient.ListDeviceRegistriesPagedResponse; import com.google.common.base.Preconditions; -import com.google.privacy.dlp.v2beta1.ContentItem; -import com.google.privacy.dlp.v2beta1.InspectConfig; -import com.google.privacy.dlp.v2beta1.InspectContentResponse; -import com.google.privacy.dlp.v2beta1.Likelihood; -import java.util.Arrays; -import java.util.List; import java.util.logging.Level; import java.util.logging.Logger; import org.junit.Test; @javax.annotation.Generated("by GAPIC") -public class DlpServiceSmokeTest { +public class DeviceManagerSmokeTest { private static final String PROJECT_ENV_NAME = "GOOGLE_CLOUD_PROJECT"; private static final String LEGACY_PROJECT_ENV_NAME = "GCLOUD_PROJECT"; @@ -39,7 +35,7 @@ public void run() { public static void main(String args[]) { Logger.getLogger("").setLevel(Level.WARNING); try { - executeNoCatch(); + executeNoCatch(getProjectId()); System.out.println("OK"); } catch (Exception e) { System.err.println("Failed with exception:"); @@ -48,17 +44,11 @@ public static void main(String args[]) { } } - public static void executeNoCatch() throws Exception { - try (DlpServiceClient client = DlpServiceClient.create()) { - Likelihood minLikelihood = Likelihood.POSSIBLE; - InspectConfig inspectConfig = - InspectConfig.newBuilder().setMinLikelihood(minLikelihood).build(); - String type = "text/plain"; - String value = "my phone number is 215-512-1212"; - ContentItem itemsElement = ContentItem.newBuilder().setType(type).setValue(value).build(); - List items = Arrays.asList(itemsElement); + public static void executeNoCatch(String projectId) throws Exception { + try (DeviceManagerClient client = DeviceManagerClient.create()) { + LocationName parent = LocationName.of(projectId, "us-central1"); - InspectContentResponse response = client.inspectContent(inspectConfig, items); + ListDeviceRegistriesPagedResponse pagedResponse = client.listDeviceRegistries(parent); } } diff --git a/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/MockDlpService.java b/google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/MockDeviceManager.java similarity index 85% rename from google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/MockDlpService.java rename to google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/MockDeviceManager.java index 94c7ae6eca87..aaa8f7a936bb 100644 --- a/google-cloud-clients/google-cloud-dlp/src/test/java/com/google/cloud/dlp/v2beta1/MockDlpService.java +++ b/google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/MockDeviceManager.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.google.cloud.dlp.v2beta1; +package com.google.cloud.iot.v1; import com.google.api.core.BetaApi; import com.google.api.gax.grpc.testing.MockGrpcService; @@ -23,11 +23,11 @@ @javax.annotation.Generated("by GAPIC") @BetaApi -public class MockDlpService implements MockGrpcService { - private final MockDlpServiceImpl serviceImpl; +public class MockDeviceManager implements MockGrpcService { + private final MockDeviceManagerImpl serviceImpl; - public MockDlpService() { - serviceImpl = new MockDlpServiceImpl(); + public MockDeviceManager() { + serviceImpl = new MockDeviceManagerImpl(); } @Override diff --git a/google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/MockDeviceManagerImpl.java b/google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/MockDeviceManagerImpl.java new file mode 100644 index 000000000000..0fc8486ddf96 --- /dev/null +++ b/google-cloud-clients/google-cloud-iot/src/test/java/com/google/cloud/iot/v1/MockDeviceManagerImpl.java @@ -0,0 +1,301 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.iot.v1; + +import com.google.api.core.BetaApi; +import com.google.cloud.iot.v1.DeviceManagerGrpc.DeviceManagerImplBase; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.protobuf.Empty; +import com.google.protobuf.GeneratedMessageV3; +import io.grpc.stub.StreamObserver; +import java.util.ArrayList; +import java.util.LinkedList; +import java.util.List; +import java.util.Queue; + +@javax.annotation.Generated("by GAPIC") +@BetaApi +public class MockDeviceManagerImpl extends DeviceManagerImplBase { + private ArrayList requests; + private Queue responses; + + public MockDeviceManagerImpl() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + public List getRequests() { + return requests; + } + + public void addResponse(GeneratedMessageV3 response) { + responses.add(response); + } + + public void setResponses(List responses) { + this.responses = new LinkedList(responses); + } + + public void addException(Exception exception) { + responses.add(exception); + } + + public void reset() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + @Override + public void createDeviceRegistry( + CreateDeviceRegistryRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof DeviceRegistry) { + requests.add(request); + responseObserver.onNext((DeviceRegistry) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void getDeviceRegistry( + GetDeviceRegistryRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof DeviceRegistry) { + requests.add(request); + responseObserver.onNext((DeviceRegistry) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void updateDeviceRegistry( + UpdateDeviceRegistryRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof DeviceRegistry) { + requests.add(request); + responseObserver.onNext((DeviceRegistry) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void deleteDeviceRegistry( + DeleteDeviceRegistryRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Empty) { + requests.add(request); + responseObserver.onNext((Empty) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void listDeviceRegistries( + ListDeviceRegistriesRequest request, + StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListDeviceRegistriesResponse) { + requests.add(request); + responseObserver.onNext((ListDeviceRegistriesResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void createDevice(CreateDeviceRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Device) { + requests.add(request); + responseObserver.onNext((Device) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void getDevice(GetDeviceRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Device) { + requests.add(request); + responseObserver.onNext((Device) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void updateDevice(UpdateDeviceRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Device) { + requests.add(request); + responseObserver.onNext((Device) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void deleteDevice(DeleteDeviceRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Empty) { + requests.add(request); + responseObserver.onNext((Empty) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void listDevices( + ListDevicesRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListDevicesResponse) { + requests.add(request); + responseObserver.onNext((ListDevicesResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void modifyCloudToDeviceConfig( + ModifyCloudToDeviceConfigRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof DeviceConfig) { + requests.add(request); + responseObserver.onNext((DeviceConfig) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void listDeviceConfigVersions( + ListDeviceConfigVersionsRequest request, + StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListDeviceConfigVersionsResponse) { + requests.add(request); + responseObserver.onNext((ListDeviceConfigVersionsResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void listDeviceStates( + ListDeviceStatesRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListDeviceStatesResponse) { + requests.add(request); + responseObserver.onNext((ListDeviceStatesResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void setIamPolicy(SetIamPolicyRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Policy) { + requests.add(request); + responseObserver.onNext((Policy) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void getIamPolicy(GetIamPolicyRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Policy) { + requests.add(request); + responseObserver.onNext((Policy) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void testIamPermissions( + TestIamPermissionsRequest request, + StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof TestIamPermissionsResponse) { + requests.add(request); + responseObserver.onNext((TestIamPermissionsResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } +} diff --git a/google-cloud-clients/google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/GrpcLanguageServiceCallableFactory.java b/google-cloud-clients/google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/GrpcLanguageServiceCallableFactory.java index ff709f485c8d..bf7bac9c0e5a 100644 --- a/google-cloud-clients/google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/GrpcLanguageServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-language/src/main/java/com/google/cloud/language/v1/stub/GrpcLanguageServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/stub/GrpcLanguageServiceCallableFactory.java b/google-cloud-clients/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/stub/GrpcLanguageServiceCallableFactory.java index 90cc45033308..509df86e672e 100644 --- a/google-cloud-clients/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/stub/GrpcLanguageServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-language/src/main/java/com/google/cloud/language/v1beta2/stub/GrpcLanguageServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcConfigServiceV2CallableFactory.java b/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcConfigServiceV2CallableFactory.java index 1ce15a039d11..74133c4bac91 100644 --- a/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcConfigServiceV2CallableFactory.java +++ b/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcConfigServiceV2CallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcLoggingServiceV2CallableFactory.java b/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcLoggingServiceV2CallableFactory.java index 48e637617be2..b0fc3c91a1dd 100644 --- a/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcLoggingServiceV2CallableFactory.java +++ b/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcLoggingServiceV2CallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcMetricsServiceV2CallableFactory.java b/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcMetricsServiceV2CallableFactory.java index fb0addfff429..4d39270c8923 100644 --- a/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcMetricsServiceV2CallableFactory.java +++ b/google-cloud-clients/google-cloud-logging/src/main/java/com/google/cloud/logging/v2/stub/GrpcMetricsServiceV2CallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcAlertPolicyServiceCallableFactory.java b/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcAlertPolicyServiceCallableFactory.java index 1b1bff7eba03..62a328dee3f2 100644 --- a/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcAlertPolicyServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcAlertPolicyServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcGroupServiceCallableFactory.java b/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcGroupServiceCallableFactory.java index 6dc5f768ab42..ab7a40b4fe25 100644 --- a/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcGroupServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcGroupServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcMetricServiceCallableFactory.java b/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcMetricServiceCallableFactory.java index 90a93c0157ee..4cd40409b8f9 100644 --- a/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcMetricServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcMetricServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcNotificationChannelServiceCallableFactory.java b/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcNotificationChannelServiceCallableFactory.java index d6e86817bb02..be47e609a463 100644 --- a/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcNotificationChannelServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcNotificationChannelServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcUptimeCheckServiceCallableFactory.java b/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcUptimeCheckServiceCallableFactory.java index bfa3975e0f61..a1a9ad827144 100644 --- a/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcUptimeCheckServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-monitoring/src/main/java/com/google/cloud/monitoring/v3/stub/GrpcUptimeCheckServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/stub/GrpcOsLoginServiceCallableFactory.java b/google-cloud-clients/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/stub/GrpcOsLoginServiceCallableFactory.java index 7a1603168665..c0f7fec11648 100644 --- a/google-cloud-clients/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/stub/GrpcOsLoginServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/stub/GrpcOsLoginServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/stub/GrpcPublisherCallableFactory.java b/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/stub/GrpcPublisherCallableFactory.java index d5782487f5cd..12e3350069cd 100644 --- a/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/stub/GrpcPublisherCallableFactory.java +++ b/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/stub/GrpcPublisherCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/stub/GrpcSubscriberCallableFactory.java b/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/stub/GrpcSubscriberCallableFactory.java index 34a596101833..22f77732138d 100644 --- a/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/stub/GrpcSubscriberCallableFactory.java +++ b/google-cloud-clients/google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1/stub/GrpcSubscriberCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/CloudRedisClient.java b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/CloudRedisClient.java index c12db4788193..3a6a581520cb 100644 --- a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/CloudRedisClient.java +++ b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/CloudRedisClient.java @@ -176,6 +176,8 @@ public CloudRedisStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -482,6 +484,8 @@ public final UnaryCallable getInstanceCallable() { * @param instance Required. A Redis [Instance] resource * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createInstanceAsync( LocationName parent, String instanceId, Instance instance) { @@ -535,6 +539,8 @@ public final OperationFuture createInstanceAsync( * @param instance Required. A Redis [Instance] resource * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createInstanceAsync( String parent, String instanceId, Instance instance) { @@ -586,6 +592,8 @@ public final OperationFuture createInstanceAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createInstanceAsync(CreateInstanceRequest request) { return createInstanceOperationCallable().futureCall(request); } @@ -628,6 +636,7 @@ public final OperationFuture createInstanceAsync(CreateInstanceRe * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable createInstanceOperationCallable() { return stub.createInstanceOperationCallable(); @@ -710,6 +719,8 @@ public final UnaryCallable createInstanceCalla * @param instance Required. Update description. Only fields specified in update_mask are updated. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateInstanceAsync( FieldMask updateMask, Instance instance) { @@ -753,6 +764,8 @@ public final OperationFuture updateInstanceAsync( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateInstanceAsync(UpdateInstanceRequest request) { return updateInstanceOperationCallable().futureCall(request); } @@ -791,6 +804,7 @@ public final OperationFuture updateInstanceAsync(UpdateInstanceRe * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable updateInstanceOperationCallable() { return stub.updateInstanceOperationCallable(); @@ -852,6 +866,8 @@ public final UnaryCallable updateInstanceCalla * refers to a GCP region * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture deleteInstanceAsync(InstanceName name) { DeleteInstanceRequest request = @@ -877,6 +893,8 @@ public final OperationFuture deleteInstanceAsync(InstanceName name) * refers to a GCP region * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture deleteInstanceAsync(String name) { DeleteInstanceRequest request = DeleteInstanceRequest.newBuilder().setName(name).build(); @@ -902,6 +920,8 @@ public final OperationFuture deleteInstanceAsync(String name) { * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") private final OperationFuture deleteInstanceAsync(DeleteInstanceRequest request) { return deleteInstanceOperationCallable().futureCall(request); } @@ -924,6 +944,7 @@ private final OperationFuture deleteInstanceAsync(DeleteInstanceRequ * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable deleteInstanceOperationCallable() { return stub.deleteInstanceOperationCallable(); diff --git a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/CloudRedisSettings.java b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/CloudRedisSettings.java index 1d853addbaa8..fe99bd458794 100644 --- a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/CloudRedisSettings.java +++ b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/CloudRedisSettings.java @@ -83,6 +83,8 @@ public UnaryCallSettings createInstanceSetting } /** Returns the object with the settings used for calls to createInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings createInstanceOperationSettings() { return ((CloudRedisStubSettings) getStubSettings()).createInstanceOperationSettings(); @@ -94,6 +96,8 @@ public UnaryCallSettings updateInstanceSetting } /** Returns the object with the settings used for calls to updateInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings updateInstanceOperationSettings() { return ((CloudRedisStubSettings) getStubSettings()).updateInstanceOperationSettings(); @@ -105,6 +109,8 @@ public UnaryCallSettings deleteInstanceSetting } /** Returns the object with the settings used for calls to deleteInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings deleteInstanceOperationSettings() { return ((CloudRedisStubSettings) getStubSettings()).deleteInstanceOperationSettings(); @@ -224,6 +230,8 @@ public UnaryCallSettings.Builder createInstanc } /** Returns the builder for the settings used for calls to createInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder createInstanceOperationSettings() { return getStubSettingsBuilder().createInstanceOperationSettings(); @@ -235,6 +243,8 @@ public UnaryCallSettings.Builder updateInstanc } /** Returns the builder for the settings used for calls to updateInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder updateInstanceOperationSettings() { return getStubSettingsBuilder().updateInstanceOperationSettings(); @@ -246,6 +256,8 @@ public UnaryCallSettings.Builder deleteInstanc } /** Returns the builder for the settings used for calls to deleteInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder deleteInstanceOperationSettings() { return getStubSettingsBuilder().deleteInstanceOperationSettings(); diff --git a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/CloudRedisStub.java b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/CloudRedisStub.java index 4043840bf60c..174cc7370cc0 100644 --- a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/CloudRedisStub.java +++ b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/CloudRedisStub.java @@ -44,6 +44,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class CloudRedisStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -61,6 +62,7 @@ public UnaryCallable getInstanceCallable() { throw new UnsupportedOperationException("Not implemented: getInstanceCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createInstanceOperationCallable() { throw new UnsupportedOperationException("Not implemented: createInstanceOperationCallable()"); } @@ -69,6 +71,7 @@ public UnaryCallable createInstanceCallable() throw new UnsupportedOperationException("Not implemented: createInstanceCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateInstanceOperationCallable() { throw new UnsupportedOperationException("Not implemented: updateInstanceOperationCallable()"); } @@ -77,6 +80,7 @@ public UnaryCallable updateInstanceCallable() throw new UnsupportedOperationException("Not implemented: updateInstanceCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable deleteInstanceOperationCallable() { throw new UnsupportedOperationException("Not implemented: deleteInstanceOperationCallable()"); } diff --git a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/CloudRedisStubSettings.java b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/CloudRedisStubSettings.java index 3b9b51a26deb..9b7dffae786d 100644 --- a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/CloudRedisStubSettings.java +++ b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/CloudRedisStubSettings.java @@ -126,6 +126,7 @@ public UnaryCallSettings createInstanceSetting } /** Returns the object with the settings used for calls to createInstance. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings createInstanceOperationSettings() { return createInstanceOperationSettings; @@ -137,6 +138,7 @@ public UnaryCallSettings updateInstanceSetting } /** Returns the object with the settings used for calls to updateInstance. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings updateInstanceOperationSettings() { return updateInstanceOperationSettings; @@ -148,6 +150,7 @@ public UnaryCallSettings deleteInstanceSetting } /** Returns the object with the settings used for calls to deleteInstance. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings deleteInstanceOperationSettings() { return deleteInstanceOperationSettings; @@ -531,6 +534,8 @@ public UnaryCallSettings.Builder createInstanc } /** Returns the builder for the settings used for calls to createInstance. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder createInstanceOperationSettings() { return createInstanceOperationSettings; @@ -542,6 +547,8 @@ public UnaryCallSettings.Builder updateInstanc } /** Returns the builder for the settings used for calls to updateInstance. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder updateInstanceOperationSettings() { return updateInstanceOperationSettings; @@ -553,6 +560,8 @@ public UnaryCallSettings.Builder deleteInstanc } /** Returns the builder for the settings used for calls to deleteInstance. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder deleteInstanceOperationSettings() { return deleteInstanceOperationSettings; diff --git a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/GrpcCloudRedisCallableFactory.java b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/GrpcCloudRedisCallableFactory.java index 0e35704c894a..c6859a8dedbf 100644 --- a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/GrpcCloudRedisCallableFactory.java +++ b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/GrpcCloudRedisCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/GrpcCloudRedisStub.java b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/GrpcCloudRedisStub.java index 37e23a4e5990..e30fb6d02de9 100644 --- a/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/GrpcCloudRedisStub.java +++ b/google-cloud-clients/google-cloud-redis/src/main/java/com/google/cloud/redis/v1beta1/stub/GrpcCloudRedisStub.java @@ -215,6 +215,7 @@ protected GrpcCloudRedisStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -232,6 +233,7 @@ public UnaryCallable getInstanceCallable() { return getInstanceCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createInstanceOperationCallable() { return createInstanceOperationCallable; } @@ -240,6 +242,7 @@ public UnaryCallable createInstanceCallable() return createInstanceCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateInstanceOperationCallable() { return updateInstanceOperationCallable; } @@ -248,6 +251,7 @@ public UnaryCallable updateInstanceCallable() return updateInstanceCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable deleteInstanceOperationCallable() { return deleteInstanceOperationCallable; } diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminClient.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminClient.java index 5bfeadaffa97..d91b43e7dedd 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminClient.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminClient.java @@ -185,6 +185,8 @@ public DatabaseAdminStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -350,6 +352,8 @@ public final UnaryCallable listData * in backticks (`` ` ``). * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createDatabaseAsync( InstanceName parent, String createStatement) { @@ -390,6 +394,8 @@ public final OperationFuture createDatabaseAsy * in backticks (`` ` ``). * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createDatabaseAsync( String parent, String createStatement) { @@ -428,6 +434,8 @@ public final OperationFuture createDatabaseAsy * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createDatabaseAsync( CreateDatabaseRequest request) { return createDatabaseOperationCallable().futureCall(request); @@ -459,6 +467,7 @@ public final OperationFuture createDatabaseAsy * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable createDatabaseOperationCallable() { return stub.createDatabaseOperationCallable(); @@ -610,6 +619,8 @@ public final UnaryCallable getDatabaseCallable() { * @param statements DDL statements to be applied to the database. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateDatabaseDdlAsync( DatabaseName database, List statements) { @@ -645,6 +656,8 @@ public final OperationFuture updateDatabaseDdl * @param statements DDL statements to be applied to the database. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateDatabaseDdlAsync( String database, List statements) { @@ -683,6 +696,8 @@ public final OperationFuture updateDatabaseDdl * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateDatabaseDdlAsync( UpdateDatabaseDdlRequest request) { return updateDatabaseDdlOperationCallable().futureCall(request); @@ -714,6 +729,7 @@ public final OperationFuture updateDatabaseDdl * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable updateDatabaseDdlOperationCallable() { return stub.updateDatabaseDdlOperationCallable(); diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminSettings.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminSettings.java index c24e93757ef8..61d4c18ca854 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminSettings.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/DatabaseAdminSettings.java @@ -93,6 +93,8 @@ public UnaryCallSettings createDatabaseSetting } /** Returns the object with the settings used for calls to createDatabase. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings createDatabaseOperationSettings() { return ((DatabaseAdminStubSettings) getStubSettings()).createDatabaseOperationSettings(); @@ -109,6 +111,8 @@ public UnaryCallSettings updateDatabaseDdlS } /** Returns the object with the settings used for calls to updateDatabaseDdl. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings updateDatabaseDdlOperationSettings() { return ((DatabaseAdminStubSettings) getStubSettings()).updateDatabaseDdlOperationSettings(); @@ -250,6 +254,8 @@ public UnaryCallSettings.Builder createDatabas } /** Returns the builder for the settings used for calls to createDatabase. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder createDatabaseOperationSettings() { return getStubSettingsBuilder().createDatabaseOperationSettings(); @@ -267,6 +273,8 @@ public UnaryCallSettings.Builder getDatabaseSettin } /** Returns the builder for the settings used for calls to updateDatabaseDdl. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder updateDatabaseDdlOperationSettings() { return getStubSettingsBuilder().updateDatabaseDdlOperationSettings(); diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/DatabaseAdminStub.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/DatabaseAdminStub.java index a00d3d2729eb..27c9a863812c 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/DatabaseAdminStub.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/DatabaseAdminStub.java @@ -52,6 +52,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class DatabaseAdminStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -65,6 +66,7 @@ public UnaryCallable listDatabasesC throw new UnsupportedOperationException("Not implemented: listDatabasesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createDatabaseOperationCallable() { throw new UnsupportedOperationException("Not implemented: createDatabaseOperationCallable()"); @@ -78,6 +80,7 @@ public UnaryCallable getDatabaseCallable() { throw new UnsupportedOperationException("Not implemented: getDatabaseCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateDatabaseDdlOperationCallable() { throw new UnsupportedOperationException( diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/DatabaseAdminStubSettings.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/DatabaseAdminStubSettings.java index e3a456885565..b0bac76fc0a1 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/DatabaseAdminStubSettings.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/DatabaseAdminStubSettings.java @@ -136,6 +136,7 @@ public UnaryCallSettings createDatabaseSetting } /** Returns the object with the settings used for calls to createDatabase. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings createDatabaseOperationSettings() { return createDatabaseOperationSettings; @@ -152,6 +153,7 @@ public UnaryCallSettings updateDatabaseDdlS } /** Returns the object with the settings used for calls to updateDatabaseDdl. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings updateDatabaseDdlOperationSettings() { return updateDatabaseDdlOperationSettings; @@ -583,6 +585,8 @@ public UnaryCallSettings.Builder createDatabas } /** Returns the builder for the settings used for calls to createDatabase. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder createDatabaseOperationSettings() { return createDatabaseOperationSettings; @@ -600,6 +604,8 @@ public UnaryCallSettings.Builder getDatabaseSettin } /** Returns the builder for the settings used for calls to updateDatabaseDdl. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder updateDatabaseDdlOperationSettings() { return updateDatabaseDdlOperationSettings; diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/GrpcDatabaseAdminCallableFactory.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/GrpcDatabaseAdminCallableFactory.java index ccdf90a50320..2a89fd6e32c5 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/GrpcDatabaseAdminCallableFactory.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/GrpcDatabaseAdminCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/GrpcDatabaseAdminStub.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/GrpcDatabaseAdminStub.java index 62413877570e..164a2c57e34b 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/GrpcDatabaseAdminStub.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/database/v1/stub/GrpcDatabaseAdminStub.java @@ -287,6 +287,7 @@ protected GrpcDatabaseAdminStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -300,6 +301,7 @@ public UnaryCallable listDatabasesC return listDatabasesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createDatabaseOperationCallable() { return createDatabaseOperationCallable; @@ -313,6 +315,7 @@ public UnaryCallable getDatabaseCallable() { return getDatabaseCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateDatabaseDdlOperationCallable() { return updateDatabaseDdlOperationCallable; diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/InstanceAdminClient.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/InstanceAdminClient.java index 8c03e371b1d6..baa270709c1e 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/InstanceAdminClient.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/InstanceAdminClient.java @@ -202,6 +202,8 @@ public InstanceAdminStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -710,6 +712,8 @@ public final UnaryCallable getInstanceCallable() { * must be `<parent>/instances/<instance_id>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createInstanceAsync( ProjectName parent, InstanceName instanceId, Instance instance) { @@ -773,6 +777,8 @@ public final OperationFuture createInstanceAsy * must be `<parent>/instances/<instance_id>`. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createInstanceAsync( String parent, String instanceId, Instance instance) { @@ -836,6 +842,8 @@ public final OperationFuture createInstanceAsy * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture createInstanceAsync( CreateInstanceRequest request) { return createInstanceOperationCallable().futureCall(request); @@ -891,6 +899,7 @@ public final OperationFuture createInstanceAsy * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable createInstanceOperationCallable() { return stub.createInstanceOperationCallable(); @@ -1006,6 +1015,8 @@ public final UnaryCallable createInstanceCalla * that do not know about them. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateInstanceAsync( Instance instance, FieldMask fieldMask) { @@ -1067,6 +1078,8 @@ public final OperationFuture updateInstanceAsy * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture updateInstanceAsync( UpdateInstanceRequest request) { return updateInstanceOperationCallable().futureCall(request); @@ -1124,6 +1137,7 @@ public final OperationFuture updateInstanceAsy * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable updateInstanceOperationCallable() { return stub.updateInstanceOperationCallable(); diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/InstanceAdminSettings.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/InstanceAdminSettings.java index 151e8b7f0c89..989cd6f4ef97 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/InstanceAdminSettings.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/InstanceAdminSettings.java @@ -113,6 +113,8 @@ public UnaryCallSettings createInstanceSetting } /** Returns the object with the settings used for calls to createInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings createInstanceOperationSettings() { return ((InstanceAdminStubSettings) getStubSettings()).createInstanceOperationSettings(); @@ -124,6 +126,8 @@ public UnaryCallSettings updateInstanceSetting } /** Returns the object with the settings used for calls to updateInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings updateInstanceOperationSettings() { return ((InstanceAdminStubSettings) getStubSettings()).updateInstanceOperationSettings(); @@ -279,6 +283,8 @@ public UnaryCallSettings.Builder createInstanc } /** Returns the builder for the settings used for calls to createInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder createInstanceOperationSettings() { return getStubSettingsBuilder().createInstanceOperationSettings(); @@ -290,6 +296,8 @@ public UnaryCallSettings.Builder updateInstanc } /** Returns the builder for the settings used for calls to updateInstance. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder updateInstanceOperationSettings() { return getStubSettingsBuilder().updateInstanceOperationSettings(); diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/GrpcInstanceAdminCallableFactory.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/GrpcInstanceAdminCallableFactory.java index a6693d0ded58..46442b4febc5 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/GrpcInstanceAdminCallableFactory.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/GrpcInstanceAdminCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/GrpcInstanceAdminStub.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/GrpcInstanceAdminStub.java index 0efe8ed7b28b..57c49ecc740f 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/GrpcInstanceAdminStub.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/GrpcInstanceAdminStub.java @@ -320,6 +320,7 @@ protected GrpcInstanceAdminStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -351,6 +352,7 @@ public UnaryCallable getInstanceCallable() { return getInstanceCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createInstanceOperationCallable() { return createInstanceOperationCallable; @@ -360,6 +362,7 @@ public UnaryCallable createInstanceCallable() return createInstanceCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateInstanceOperationCallable() { return updateInstanceOperationCallable; diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/InstanceAdminStub.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/InstanceAdminStub.java index 67a135315f0b..b3b37d4835c2 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/InstanceAdminStub.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/InstanceAdminStub.java @@ -55,6 +55,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class InstanceAdminStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -86,6 +87,7 @@ public UnaryCallable getInstanceCallable() { throw new UnsupportedOperationException("Not implemented: getInstanceCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable createInstanceOperationCallable() { throw new UnsupportedOperationException("Not implemented: createInstanceOperationCallable()"); @@ -95,6 +97,7 @@ public UnaryCallable createInstanceCallable() throw new UnsupportedOperationException("Not implemented: createInstanceCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable updateInstanceOperationCallable() { throw new UnsupportedOperationException("Not implemented: updateInstanceOperationCallable()"); diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/InstanceAdminStubSettings.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/InstanceAdminStubSettings.java index 6f6406d028ba..7a33417a3bdb 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/InstanceAdminStubSettings.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/admin/instance/v1/stub/InstanceAdminStubSettings.java @@ -159,6 +159,7 @@ public UnaryCallSettings createInstanceSetting } /** Returns the object with the settings used for calls to createInstance. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings createInstanceOperationSettings() { return createInstanceOperationSettings; @@ -170,6 +171,7 @@ public UnaryCallSettings updateInstanceSetting } /** Returns the object with the settings used for calls to updateInstance. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings updateInstanceOperationSettings() { return updateInstanceOperationSettings; @@ -687,6 +689,8 @@ public UnaryCallSettings.Builder createInstanc } /** Returns the builder for the settings used for calls to createInstance. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder createInstanceOperationSettings() { return createInstanceOperationSettings; @@ -698,6 +702,8 @@ public UnaryCallSettings.Builder updateInstanc } /** Returns the builder for the settings used for calls to updateInstance. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder updateInstanceOperationSettings() { return updateInstanceOperationSettings; diff --git a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/v1/stub/GrpcSpannerCallableFactory.java b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/v1/stub/GrpcSpannerCallableFactory.java index 2a990f88338d..01f1c6f8b767 100644 --- a/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/v1/stub/GrpcSpannerCallableFactory.java +++ b/google-cloud-clients/google-cloud-spanner/src/main/java/com/google/cloud/spanner/v1/stub/GrpcSpannerCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/SpeechClient.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/SpeechClient.java index 3f6f9965f186..1949d8c01164 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/SpeechClient.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/SpeechClient.java @@ -165,6 +165,8 @@ public SpeechStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -308,6 +310,8 @@ public final UnaryCallable recognizeCallabl * @param audio *Required* The audio data to be recognized. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture longRunningRecognizeAsync(RecognitionConfig config, RecognitionAudio audio) { @@ -349,6 +353,8 @@ public final UnaryCallable recognizeCallabl * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture longRunningRecognizeAsync(LongRunningRecognizeRequest request) { return longRunningRecognizeOperationCallable().futureCall(request); @@ -386,6 +392,7 @@ public final UnaryCallable recognizeCallabl * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationCallable() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/SpeechSettings.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/SpeechSettings.java index 170efa9f729d..d06cb6d23bd4 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/SpeechSettings.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/SpeechSettings.java @@ -73,6 +73,8 @@ public UnaryCallSettings longRunningReco } /** Returns the object with the settings used for calls to longRunningRecognize. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationSettings() { @@ -193,6 +195,8 @@ public UnaryCallSettings.Builder recognizeS } /** Returns the builder for the settings used for calls to longRunningRecognize. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationSettings() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/GrpcSpeechCallableFactory.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/GrpcSpeechCallableFactory.java index 4c5d88081577..d3fdff0d4232 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/GrpcSpeechCallableFactory.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/GrpcSpeechCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/GrpcSpeechStub.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/GrpcSpeechStub.java index ae5ac1fa90c5..a64a11308004 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/GrpcSpeechStub.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/GrpcSpeechStub.java @@ -162,6 +162,7 @@ protected GrpcSpeechStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -170,6 +171,7 @@ public UnaryCallable recognizeCallable() { return recognizeCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationCallable() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/SpeechStub.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/SpeechStub.java index 295357b0f9f1..93969d0dd311 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/SpeechStub.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/SpeechStub.java @@ -41,6 +41,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class SpeechStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -49,6 +50,7 @@ public UnaryCallable recognizeCallable() { throw new UnsupportedOperationException("Not implemented: recognizeCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationCallable() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/SpeechStubSettings.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/SpeechStubSettings.java index bcc5574b13e9..f65b6052dbd3 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/SpeechStubSettings.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1/stub/SpeechStubSettings.java @@ -105,6 +105,7 @@ public UnaryCallSettings longRunningReco } /** Returns the object with the settings used for calls to longRunningRecognize. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationSettings() { @@ -352,6 +353,8 @@ public UnaryCallSettings.Builder recognizeS } /** Returns the builder for the settings used for calls to longRunningRecognize. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationSettings() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/SpeechClient.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/SpeechClient.java index 006d9db62376..2d247831316b 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/SpeechClient.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/SpeechClient.java @@ -163,6 +163,8 @@ public SpeechStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -300,6 +302,8 @@ public final UnaryCallable syncReco * @param audio *Required* The audio data to be recognized. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture asyncRecognizeAsync( RecognitionConfig config, RecognitionAudio audio) { @@ -340,6 +344,8 @@ public final OperationFuture asy * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture asyncRecognizeAsync( AsyncRecognizeRequest request) { return asyncRecognizeOperationCallable().futureCall(request); @@ -376,6 +382,7 @@ public final OperationFuture asy * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable< AsyncRecognizeRequest, AsyncRecognizeResponse, AsyncRecognizeMetadata> asyncRecognizeOperationCallable() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/SpeechSettings.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/SpeechSettings.java index 9d8666ece557..a28c15ada807 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/SpeechSettings.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/SpeechSettings.java @@ -73,6 +73,8 @@ public UnaryCallSettings asyncRecognizeSetting } /** Returns the object with the settings used for calls to asyncRecognize. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings< AsyncRecognizeRequest, AsyncRecognizeResponse, AsyncRecognizeMetadata> asyncRecognizeOperationSettings() { @@ -193,6 +195,8 @@ public UnaryCallSettings.Builder asyncRecogniz } /** Returns the builder for the settings used for calls to asyncRecognize. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< AsyncRecognizeRequest, AsyncRecognizeResponse, AsyncRecognizeMetadata> asyncRecognizeOperationSettings() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/GrpcSpeechCallableFactory.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/GrpcSpeechCallableFactory.java index f200b3dd2c71..cde6000ebc94 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/GrpcSpeechCallableFactory.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/GrpcSpeechCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/GrpcSpeechStub.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/GrpcSpeechStub.java index f91b4663578c..d74143bb632d 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/GrpcSpeechStub.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/GrpcSpeechStub.java @@ -162,6 +162,7 @@ protected GrpcSpeechStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -170,6 +171,7 @@ public UnaryCallable syncRecognizeC return syncRecognizeCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable asyncRecognizeOperationCallable() { return asyncRecognizeOperationCallable; diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/SpeechStub.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/SpeechStub.java index 684aa906d91b..d1265fc0a7d4 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/SpeechStub.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/SpeechStub.java @@ -41,6 +41,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class SpeechStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -49,6 +50,7 @@ public UnaryCallable syncRecognizeC throw new UnsupportedOperationException("Not implemented: syncRecognizeCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable asyncRecognizeOperationCallable() { throw new UnsupportedOperationException("Not implemented: asyncRecognizeOperationCallable()"); diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/SpeechStubSettings.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/SpeechStubSettings.java index c495a0f1d5d9..0bcce9f98c67 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/SpeechStubSettings.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1beta1/stub/SpeechStubSettings.java @@ -105,6 +105,7 @@ public UnaryCallSettings asyncRecognizeSetting } /** Returns the object with the settings used for calls to asyncRecognize. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings< AsyncRecognizeRequest, AsyncRecognizeResponse, AsyncRecognizeMetadata> asyncRecognizeOperationSettings() { @@ -349,6 +350,8 @@ public UnaryCallSettings.Builder asyncRecogniz } /** Returns the builder for the settings used for calls to asyncRecognize. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< AsyncRecognizeRequest, AsyncRecognizeResponse, AsyncRecognizeMetadata> asyncRecognizeOperationSettings() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/SpeechClient.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/SpeechClient.java index 68bad96b995b..57986e52395e 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/SpeechClient.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/SpeechClient.java @@ -165,6 +165,8 @@ public SpeechStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -308,6 +310,8 @@ public final UnaryCallable recognizeCallabl * @param audio *Required* The audio data to be recognized. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture longRunningRecognizeAsync(RecognitionConfig config, RecognitionAudio audio) { @@ -349,6 +353,8 @@ public final UnaryCallable recognizeCallabl * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture longRunningRecognizeAsync(LongRunningRecognizeRequest request) { return longRunningRecognizeOperationCallable().futureCall(request); @@ -386,6 +392,7 @@ public final UnaryCallable recognizeCallabl * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationCallable() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/SpeechSettings.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/SpeechSettings.java index 79d0fc282efa..8fec2526d25b 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/SpeechSettings.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/SpeechSettings.java @@ -73,6 +73,8 @@ public UnaryCallSettings longRunningReco } /** Returns the object with the settings used for calls to longRunningRecognize. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationSettings() { @@ -193,6 +195,8 @@ public UnaryCallSettings.Builder recognizeS } /** Returns the builder for the settings used for calls to longRunningRecognize. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationSettings() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/GrpcSpeechCallableFactory.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/GrpcSpeechCallableFactory.java index abb7b7f32a3e..9bc04f1a7267 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/GrpcSpeechCallableFactory.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/GrpcSpeechCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/GrpcSpeechStub.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/GrpcSpeechStub.java index 90caae563b17..bc85f501e1cd 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/GrpcSpeechStub.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/GrpcSpeechStub.java @@ -162,6 +162,7 @@ protected GrpcSpeechStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -170,6 +171,7 @@ public UnaryCallable recognizeCallable() { return recognizeCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationCallable() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/SpeechStub.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/SpeechStub.java index 39db17e3da2c..53ee455cd5b4 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/SpeechStub.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/SpeechStub.java @@ -41,6 +41,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class SpeechStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -49,6 +50,7 @@ public UnaryCallable recognizeCallable() { throw new UnsupportedOperationException("Not implemented: recognizeCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationCallable() { diff --git a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/SpeechStubSettings.java b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/SpeechStubSettings.java index caa10897f4a9..53aef143fdc5 100644 --- a/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/SpeechStubSettings.java +++ b/google-cloud-clients/google-cloud-speech/src/main/java/com/google/cloud/speech/v1p1beta1/stub/SpeechStubSettings.java @@ -105,6 +105,7 @@ public UnaryCallSettings longRunningReco } /** Returns the object with the settings used for calls to longRunningRecognize. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationSettings() { @@ -352,6 +353,8 @@ public UnaryCallSettings.Builder recognizeS } /** Returns the builder for the settings used for calls to longRunningRecognize. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< LongRunningRecognizeRequest, LongRunningRecognizeResponse, LongRunningRecognizeMetadata> longRunningRecognizeOperationSettings() { diff --git a/google-cloud-clients/google-cloud-texttospeech/src/main/java/com/google/cloud/texttospeech/v1beta1/stub/GrpcTextToSpeechCallableFactory.java b/google-cloud-clients/google-cloud-texttospeech/src/main/java/com/google/cloud/texttospeech/v1beta1/stub/GrpcTextToSpeechCallableFactory.java index 3ff2d74637af..9b7ece53433a 100644 --- a/google-cloud-clients/google-cloud-texttospeech/src/main/java/com/google/cloud/texttospeech/v1beta1/stub/GrpcTextToSpeechCallableFactory.java +++ b/google-cloud-clients/google-cloud-texttospeech/src/main/java/com/google/cloud/texttospeech/v1beta1/stub/GrpcTextToSpeechCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v1/stub/GrpcTraceServiceCallableFactory.java b/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v1/stub/GrpcTraceServiceCallableFactory.java index 675ccaaf5082..57aa0b461152 100644 --- a/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v1/stub/GrpcTraceServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v1/stub/GrpcTraceServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v2/stub/GrpcTraceServiceCallableFactory.java b/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v2/stub/GrpcTraceServiceCallableFactory.java index 9faa25426d90..537f72e9817d 100644 --- a/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v2/stub/GrpcTraceServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v2/stub/GrpcTraceServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/VideoIntelligenceServiceClient.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/VideoIntelligenceServiceClient.java index 705b7b640d2d..9ec1403a7ab2 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/VideoIntelligenceServiceClient.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/VideoIntelligenceServiceClient.java @@ -161,6 +161,8 @@ public VideoIntelligenceServiceStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -194,6 +196,8 @@ public final OperationsClient getOperationsClient() { * @param features Requested video annotation features. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture annotateVideoAsync( String inputUri, List features) { @@ -227,6 +231,8 @@ public final OperationFuture annot * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture annotateVideoAsync( AnnotateVideoRequest request) { return annotateVideoOperationCallable().futureCall(request); @@ -256,6 +262,7 @@ public final OperationFuture annot * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable annotateVideoOperationCallable() { return stub.annotateVideoOperationCallable(); diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/VideoIntelligenceServiceSettings.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/VideoIntelligenceServiceSettings.java index 15d2a94c1c13..ebc1c0bed5fc 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/VideoIntelligenceServiceSettings.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/VideoIntelligenceServiceSettings.java @@ -69,6 +69,8 @@ public UnaryCallSettings annotateVideoSettings( } /** Returns the object with the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings annotateVideoOperationSettings() { return ((VideoIntelligenceServiceStubSettings) getStubSettings()) @@ -179,6 +181,8 @@ public UnaryCallSettings.Builder annotateVideoS } /** Returns the builder for the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< AnnotateVideoRequest, AnnotateVideoResponse, AnnotateVideoProgress> annotateVideoOperationSettings() { diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/GrpcVideoIntelligenceServiceCallableFactory.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/GrpcVideoIntelligenceServiceCallableFactory.java index bcba3c74d8ae..7031984d43ee 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/GrpcVideoIntelligenceServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/GrpcVideoIntelligenceServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/GrpcVideoIntelligenceServiceStub.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/GrpcVideoIntelligenceServiceStub.java index 83025e2bf4ab..b38e5e30c4cd 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/GrpcVideoIntelligenceServiceStub.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/GrpcVideoIntelligenceServiceStub.java @@ -124,10 +124,12 @@ protected GrpcVideoIntelligenceServiceStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable annotateVideoOperationCallable() { return annotateVideoOperationCallable; diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/VideoIntelligenceServiceStub.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/VideoIntelligenceServiceStub.java index 994ccf5070ec..1ac51d0d92a3 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/VideoIntelligenceServiceStub.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/VideoIntelligenceServiceStub.java @@ -36,10 +36,12 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class VideoIntelligenceServiceStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable annotateVideoOperationCallable() { throw new UnsupportedOperationException("Not implemented: annotateVideoOperationCallable()"); diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/VideoIntelligenceServiceStubSettings.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/VideoIntelligenceServiceStubSettings.java index d45acd297d22..965703c13061 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/VideoIntelligenceServiceStubSettings.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1/stub/VideoIntelligenceServiceStubSettings.java @@ -93,6 +93,7 @@ public UnaryCallSettings annotateVideoSettings( } /** Returns the object with the settings used for calls to annotateVideo. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings annotateVideoOperationSettings() { return annotateVideoOperationSettings; @@ -305,6 +306,8 @@ public UnaryCallSettings.Builder annotateVideoS } /** Returns the builder for the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< AnnotateVideoRequest, AnnotateVideoResponse, AnnotateVideoProgress> annotateVideoOperationSettings() { diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/VideoIntelligenceServiceClient.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/VideoIntelligenceServiceClient.java index 2d9ace74611d..94f41871c956 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/VideoIntelligenceServiceClient.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/VideoIntelligenceServiceClient.java @@ -161,6 +161,8 @@ public VideoIntelligenceServiceStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -194,6 +196,8 @@ public final OperationsClient getOperationsClient() { * @param features Requested video annotation features. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture annotateVideoAsync( String inputUri, List features) { @@ -227,6 +231,8 @@ public final OperationFuture annot * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture annotateVideoAsync( AnnotateVideoRequest request) { return annotateVideoOperationCallable().futureCall(request); @@ -256,6 +262,7 @@ public final OperationFuture annot * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable annotateVideoOperationCallable() { return stub.annotateVideoOperationCallable(); diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/VideoIntelligenceServiceSettings.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/VideoIntelligenceServiceSettings.java index 67c21431e690..51a6780e006b 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/VideoIntelligenceServiceSettings.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/VideoIntelligenceServiceSettings.java @@ -69,6 +69,8 @@ public UnaryCallSettings annotateVideoSettings( } /** Returns the object with the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings annotateVideoOperationSettings() { return ((VideoIntelligenceServiceStubSettings) getStubSettings()) @@ -179,6 +181,8 @@ public UnaryCallSettings.Builder annotateVideoS } /** Returns the builder for the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< AnnotateVideoRequest, AnnotateVideoResponse, AnnotateVideoProgress> annotateVideoOperationSettings() { diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/GrpcVideoIntelligenceServiceCallableFactory.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/GrpcVideoIntelligenceServiceCallableFactory.java index 06d5a3d1f4b9..aa52195d6493 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/GrpcVideoIntelligenceServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/GrpcVideoIntelligenceServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/GrpcVideoIntelligenceServiceStub.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/GrpcVideoIntelligenceServiceStub.java index e2963585ffce..8acff716734b 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/GrpcVideoIntelligenceServiceStub.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/GrpcVideoIntelligenceServiceStub.java @@ -124,10 +124,12 @@ protected GrpcVideoIntelligenceServiceStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable annotateVideoOperationCallable() { return annotateVideoOperationCallable; diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/VideoIntelligenceServiceStub.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/VideoIntelligenceServiceStub.java index 2c7387e4ec3e..eae1c558a752 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/VideoIntelligenceServiceStub.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/VideoIntelligenceServiceStub.java @@ -36,10 +36,12 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class VideoIntelligenceServiceStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable annotateVideoOperationCallable() { throw new UnsupportedOperationException("Not implemented: annotateVideoOperationCallable()"); diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/VideoIntelligenceServiceStubSettings.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/VideoIntelligenceServiceStubSettings.java index 2365ec31d782..ddcf849d83c3 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/VideoIntelligenceServiceStubSettings.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta1/stub/VideoIntelligenceServiceStubSettings.java @@ -93,6 +93,7 @@ public UnaryCallSettings annotateVideoSettings( } /** Returns the object with the settings used for calls to annotateVideo. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings annotateVideoOperationSettings() { return annotateVideoOperationSettings; @@ -305,6 +306,8 @@ public UnaryCallSettings.Builder annotateVideoS } /** Returns the builder for the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< AnnotateVideoRequest, AnnotateVideoResponse, AnnotateVideoProgress> annotateVideoOperationSettings() { diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/VideoIntelligenceServiceClient.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/VideoIntelligenceServiceClient.java index b701926d1b64..48f3c349f192 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/VideoIntelligenceServiceClient.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/VideoIntelligenceServiceClient.java @@ -161,6 +161,8 @@ public VideoIntelligenceServiceStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -194,6 +196,8 @@ public final OperationsClient getOperationsClient() { * @param features Requested video annotation features. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture annotateVideoAsync( String inputUri, List features) { @@ -227,6 +231,8 @@ public final OperationFuture annot * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture annotateVideoAsync( AnnotateVideoRequest request) { return annotateVideoOperationCallable().futureCall(request); @@ -256,6 +262,7 @@ public final OperationFuture annot * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable annotateVideoOperationCallable() { return stub.annotateVideoOperationCallable(); diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/VideoIntelligenceServiceSettings.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/VideoIntelligenceServiceSettings.java index e786c7d42d45..4e9425bf7790 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/VideoIntelligenceServiceSettings.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/VideoIntelligenceServiceSettings.java @@ -69,6 +69,8 @@ public UnaryCallSettings annotateVideoSettings( } /** Returns the object with the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings annotateVideoOperationSettings() { return ((VideoIntelligenceServiceStubSettings) getStubSettings()) @@ -179,6 +181,8 @@ public UnaryCallSettings.Builder annotateVideoS } /** Returns the builder for the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< AnnotateVideoRequest, AnnotateVideoResponse, AnnotateVideoProgress> annotateVideoOperationSettings() { diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/GrpcVideoIntelligenceServiceCallableFactory.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/GrpcVideoIntelligenceServiceCallableFactory.java index 7706572943eb..c4ac7183edbe 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/GrpcVideoIntelligenceServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/GrpcVideoIntelligenceServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/GrpcVideoIntelligenceServiceStub.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/GrpcVideoIntelligenceServiceStub.java index 8fd0d6a66213..1bc30620fcaa 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/GrpcVideoIntelligenceServiceStub.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/GrpcVideoIntelligenceServiceStub.java @@ -124,10 +124,12 @@ protected GrpcVideoIntelligenceServiceStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable annotateVideoOperationCallable() { return annotateVideoOperationCallable; diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/VideoIntelligenceServiceStub.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/VideoIntelligenceServiceStub.java index 276d8e7b5525..a6b782c35a50 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/VideoIntelligenceServiceStub.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/VideoIntelligenceServiceStub.java @@ -36,10 +36,12 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class VideoIntelligenceServiceStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable annotateVideoOperationCallable() { throw new UnsupportedOperationException("Not implemented: annotateVideoOperationCallable()"); diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/VideoIntelligenceServiceStubSettings.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/VideoIntelligenceServiceStubSettings.java index 63278e78c9cc..e129032e2ee5 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/VideoIntelligenceServiceStubSettings.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1beta2/stub/VideoIntelligenceServiceStubSettings.java @@ -93,6 +93,7 @@ public UnaryCallSettings annotateVideoSettings( } /** Returns the object with the settings used for calls to annotateVideo. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings annotateVideoOperationSettings() { return annotateVideoOperationSettings; @@ -305,6 +306,8 @@ public UnaryCallSettings.Builder annotateVideoS } /** Returns the builder for the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< AnnotateVideoRequest, AnnotateVideoResponse, AnnotateVideoProgress> annotateVideoOperationSettings() { diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/VideoIntelligenceServiceClient.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/VideoIntelligenceServiceClient.java index f51fe5aa05af..e158e3a28f76 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/VideoIntelligenceServiceClient.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/VideoIntelligenceServiceClient.java @@ -161,6 +161,8 @@ public VideoIntelligenceServiceStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -194,6 +196,8 @@ public final OperationsClient getOperationsClient() { * @param features Requested video annotation features. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture annotateVideoAsync( String inputUri, List features) { @@ -227,6 +231,8 @@ public final OperationFuture annot * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture annotateVideoAsync( AnnotateVideoRequest request) { return annotateVideoOperationCallable().futureCall(request); @@ -256,6 +262,7 @@ public final OperationFuture annot * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable annotateVideoOperationCallable() { return stub.annotateVideoOperationCallable(); diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/VideoIntelligenceServiceSettings.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/VideoIntelligenceServiceSettings.java index bb017ebf3b2a..8ca0eb34de7e 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/VideoIntelligenceServiceSettings.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/VideoIntelligenceServiceSettings.java @@ -69,6 +69,8 @@ public UnaryCallSettings annotateVideoSettings( } /** Returns the object with the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings annotateVideoOperationSettings() { return ((VideoIntelligenceServiceStubSettings) getStubSettings()) @@ -179,6 +181,8 @@ public UnaryCallSettings.Builder annotateVideoS } /** Returns the builder for the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< AnnotateVideoRequest, AnnotateVideoResponse, AnnotateVideoProgress> annotateVideoOperationSettings() { diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/GrpcVideoIntelligenceServiceCallableFactory.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/GrpcVideoIntelligenceServiceCallableFactory.java index 86fc145e9b4b..28aa4bc618e7 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/GrpcVideoIntelligenceServiceCallableFactory.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/GrpcVideoIntelligenceServiceCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/GrpcVideoIntelligenceServiceStub.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/GrpcVideoIntelligenceServiceStub.java index a6d705d1a7de..41b814ad68b8 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/GrpcVideoIntelligenceServiceStub.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/GrpcVideoIntelligenceServiceStub.java @@ -124,10 +124,12 @@ protected GrpcVideoIntelligenceServiceStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable annotateVideoOperationCallable() { return annotateVideoOperationCallable; diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/VideoIntelligenceServiceStub.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/VideoIntelligenceServiceStub.java index 3d0f9a6d5856..0555e4b09a99 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/VideoIntelligenceServiceStub.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/VideoIntelligenceServiceStub.java @@ -36,10 +36,12 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class VideoIntelligenceServiceStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable annotateVideoOperationCallable() { throw new UnsupportedOperationException("Not implemented: annotateVideoOperationCallable()"); diff --git a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/VideoIntelligenceServiceStubSettings.java b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/VideoIntelligenceServiceStubSettings.java index b499325f8467..66302b973cd7 100644 --- a/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/VideoIntelligenceServiceStubSettings.java +++ b/google-cloud-clients/google-cloud-video-intelligence/src/main/java/com/google/cloud/videointelligence/v1p1beta1/stub/VideoIntelligenceServiceStubSettings.java @@ -93,6 +93,7 @@ public UnaryCallSettings annotateVideoSettings( } /** Returns the object with the settings used for calls to annotateVideo. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings annotateVideoOperationSettings() { return annotateVideoOperationSettings; @@ -305,6 +306,8 @@ public UnaryCallSettings.Builder annotateVideoS } /** Returns the builder for the settings used for calls to annotateVideo. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< AnnotateVideoRequest, AnnotateVideoResponse, AnnotateVideoProgress> annotateVideoOperationSettings() { diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorClient.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorClient.java index 6dbfa667266a..98ff358e287f 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorClient.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorClient.java @@ -17,9 +17,13 @@ import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.longrunning.OperationFuture; +import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.vision.v1.stub.ImageAnnotatorStub; import com.google.cloud.vision.v1.stub.ImageAnnotatorStubSettings; +import com.google.longrunning.Operation; +import com.google.longrunning.OperationsClient; import java.io.IOException; import java.util.List; import java.util.concurrent.TimeUnit; @@ -97,6 +101,7 @@ public class ImageAnnotatorClient implements BackgroundResource { private final ImageAnnotatorSettings settings; private final ImageAnnotatorStub stub; + private final OperationsClient operationsClient; /** Constructs an instance of ImageAnnotatorClient with default settings. */ public static final ImageAnnotatorClient create() throws IOException { @@ -129,12 +134,14 @@ public static final ImageAnnotatorClient create(ImageAnnotatorStub stub) { protected ImageAnnotatorClient(ImageAnnotatorSettings settings) throws IOException { this.settings = settings; this.stub = ((ImageAnnotatorStubSettings) settings.getStubSettings()).createStub(); + this.operationsClient = OperationsClient.create(this.stub.getOperationsStub()); } @BetaApi("A restructuring of stub classes is planned, so this may break in the future") protected ImageAnnotatorClient(ImageAnnotatorStub stub) { this.settings = null; this.stub = stub; + this.operationsClient = OperationsClient.create(this.stub.getOperationsStub()); } public final ImageAnnotatorSettings getSettings() { @@ -146,6 +153,16 @@ public ImageAnnotatorStub getStub() { return stub; } + /** + * Returns the OperationsClient that can be used to query the status of a long-running operation + * returned by another API method call. + */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") + public final OperationsClient getOperationsClient() { + return operationsClient; + } + // AUTO-GENERATED DOCUMENTATION AND METHOD /** * Run image detection and annotation for a batch of images. @@ -217,6 +234,122 @@ private final BatchAnnotateImagesResponse batchAnnotateImages( return stub.batchAnnotateImagesCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Run asynchronous image detection and annotation for a list of generic files, such as PDF files, + * which may contain multiple pages and multiple images per page. Progress and results can be + * retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains + * `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` + * (results). + * + *

Sample code: + * + *


+   * try (ImageAnnotatorClient imageAnnotatorClient = ImageAnnotatorClient.create()) {
+   *   List<AsyncAnnotateFileRequest> requests = new ArrayList<>();
+   *   AsyncBatchAnnotateFilesResponse response = imageAnnotatorClient.asyncBatchAnnotateFilesAsync(requests).get();
+   * }
+   * 
+ * + * @param requests Individual async file annotation requests for this batch. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") + public final OperationFuture + asyncBatchAnnotateFilesAsync(List requests) { + + AsyncBatchAnnotateFilesRequest request = + AsyncBatchAnnotateFilesRequest.newBuilder().addAllRequests(requests).build(); + return asyncBatchAnnotateFilesAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Run asynchronous image detection and annotation for a list of generic files, such as PDF files, + * which may contain multiple pages and multiple images per page. Progress and results can be + * retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains + * `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` + * (results). + * + *

Sample code: + * + *


+   * try (ImageAnnotatorClient imageAnnotatorClient = ImageAnnotatorClient.create()) {
+   *   List<AsyncAnnotateFileRequest> requests = new ArrayList<>();
+   *   AsyncBatchAnnotateFilesRequest request = AsyncBatchAnnotateFilesRequest.newBuilder()
+   *     .addAllRequests(requests)
+   *     .build();
+   *   AsyncBatchAnnotateFilesResponse response = imageAnnotatorClient.asyncBatchAnnotateFilesAsync(request).get();
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") + private final OperationFuture + asyncBatchAnnotateFilesAsync(AsyncBatchAnnotateFilesRequest request) { + return asyncBatchAnnotateFilesOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Run asynchronous image detection and annotation for a list of generic files, such as PDF files, + * which may contain multiple pages and multiple images per page. Progress and results can be + * retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains + * `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` + * (results). + * + *

Sample code: + * + *


+   * try (ImageAnnotatorClient imageAnnotatorClient = ImageAnnotatorClient.create()) {
+   *   List<AsyncAnnotateFileRequest> requests = new ArrayList<>();
+   *   AsyncBatchAnnotateFilesRequest request = AsyncBatchAnnotateFilesRequest.newBuilder()
+   *     .addAllRequests(requests)
+   *     .build();
+   *   OperationFuture<Operation> future = imageAnnotatorClient.asyncBatchAnnotateFilesOperationCallable().futureCall(request);
+   *   // Do something
+   *   AsyncBatchAnnotateFilesResponse response = future.get();
+   * }
+   * 
+ */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") + public final OperationCallable< + AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> + asyncBatchAnnotateFilesOperationCallable() { + return stub.asyncBatchAnnotateFilesOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Run asynchronous image detection and annotation for a list of generic files, such as PDF files, + * which may contain multiple pages and multiple images per page. Progress and results can be + * retrieved through the `google.longrunning.Operations` interface. `Operation.metadata` contains + * `OperationMetadata` (metadata). `Operation.response` contains `AsyncBatchAnnotateFilesResponse` + * (results). + * + *

Sample code: + * + *


+   * try (ImageAnnotatorClient imageAnnotatorClient = ImageAnnotatorClient.create()) {
+   *   List<AsyncAnnotateFileRequest> requests = new ArrayList<>();
+   *   AsyncBatchAnnotateFilesRequest request = AsyncBatchAnnotateFilesRequest.newBuilder()
+   *     .addAllRequests(requests)
+   *     .build();
+   *   ApiFuture<Operation> future = imageAnnotatorClient.asyncBatchAnnotateFilesCallable().futureCall(request);
+   *   // Do something
+   *   Operation response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable + asyncBatchAnnotateFilesCallable() { + return stub.asyncBatchAnnotateFilesCallable(); + } + @Override public final void close() { stub.close(); diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorSettings.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorSettings.java index 18d0b63bb9db..b287d0b6200d 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorSettings.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/ImageAnnotatorSettings.java @@ -23,9 +23,11 @@ import com.google.api.gax.rpc.ApiClientHeaderProvider; import com.google.api.gax.rpc.ClientContext; import com.google.api.gax.rpc.ClientSettings; +import com.google.api.gax.rpc.OperationCallSettings; import com.google.api.gax.rpc.TransportChannelProvider; import com.google.api.gax.rpc.UnaryCallSettings; import com.google.cloud.vision.v1.stub.ImageAnnotatorStubSettings; +import com.google.longrunning.Operation; import java.io.IOException; import java.util.List; import javax.annotation.Generated; @@ -64,6 +66,22 @@ public class ImageAnnotatorSettings extends ClientSettings + asyncBatchAnnotateFilesSettings() { + return ((ImageAnnotatorStubSettings) getStubSettings()).asyncBatchAnnotateFilesSettings(); + } + + /** Returns the object with the settings used for calls to asyncBatchAnnotateFiles. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") + public OperationCallSettings< + AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> + asyncBatchAnnotateFilesOperationSettings() { + return ((ImageAnnotatorStubSettings) getStubSettings()) + .asyncBatchAnnotateFilesOperationSettings(); + } + public static final ImageAnnotatorSettings create(ImageAnnotatorStubSettings stub) throws IOException { return new ImageAnnotatorSettings.Builder(stub.toBuilder()).build(); @@ -167,6 +185,21 @@ public Builder applyToAllUnaryMethods( return getStubSettingsBuilder().batchAnnotateImagesSettings(); } + /** Returns the builder for the settings used for calls to asyncBatchAnnotateFiles. */ + public UnaryCallSettings.Builder + asyncBatchAnnotateFilesSettings() { + return getStubSettingsBuilder().asyncBatchAnnotateFilesSettings(); + } + + /** Returns the builder for the settings used for calls to asyncBatchAnnotateFiles. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") + public OperationCallSettings.Builder< + AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> + asyncBatchAnnotateFilesOperationSettings() { + return getStubSettingsBuilder().asyncBatchAnnotateFilesOperationSettings(); + } + @Override public ImageAnnotatorSettings build() throws IOException { return new ImageAnnotatorSettings(this); diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/package-info.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/package-info.java index 7aed0839971d..d51bd17ad6a5 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/package-info.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/package-info.java @@ -15,7 +15,7 @@ */ /** - * A client to Google Cloud Vision API. + * A client to Cloud Vision API. * *

The interfaces provided are listed below, along with usage samples. * diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/GrpcImageAnnotatorCallableFactory.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/GrpcImageAnnotatorCallableFactory.java index 95be3a6d1ff7..f478951a78a5 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/GrpcImageAnnotatorCallableFactory.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/GrpcImageAnnotatorCallableFactory.java @@ -37,7 +37,7 @@ // AUTO-GENERATED DOCUMENTATION AND CLASS /** - * gRPC callable factory implementation for Google Cloud Vision API. + * gRPC callable factory implementation for Cloud Vision API. * *

This class is for advanced usage. */ @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/GrpcImageAnnotatorStub.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/GrpcImageAnnotatorStub.java index 1d60a4972683..919f77ec4899 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/GrpcImageAnnotatorStub.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/GrpcImageAnnotatorStub.java @@ -21,9 +21,15 @@ import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcStubCallableFactory; import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest; +import com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse; import com.google.cloud.vision.v1.BatchAnnotateImagesRequest; import com.google.cloud.vision.v1.BatchAnnotateImagesResponse; +import com.google.cloud.vision.v1.OperationMetadata; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.GrpcOperationsStub; import io.grpc.MethodDescriptor; import io.grpc.protobuf.ProtoUtils; import java.io.IOException; @@ -32,7 +38,7 @@ // AUTO-GENERATED DOCUMENTATION AND CLASS /** - * gRPC stub implementation for Google Cloud Vision API. + * gRPC stub implementation for Cloud Vision API. * *

This class is for advanced usage and reflects the underlying API directly. */ @@ -50,11 +56,26 @@ public class GrpcImageAnnotatorStub extends ImageAnnotatorStub { .setResponseMarshaller( ProtoUtils.marshaller(BatchAnnotateImagesResponse.getDefaultInstance())) .build(); + private static final MethodDescriptor + asyncBatchAnnotateFilesMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.vision.v1.ImageAnnotator/AsyncBatchAnnotateFiles") + .setRequestMarshaller( + ProtoUtils.marshaller(AsyncBatchAnnotateFilesRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .build(); private final BackgroundResource backgroundResources; + private final GrpcOperationsStub operationsStub; private final UnaryCallable batchAnnotateImagesCallable; + private final UnaryCallable + asyncBatchAnnotateFilesCallable; + private final OperationCallable< + AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> + asyncBatchAnnotateFilesOperationCallable; private final GrpcStubCallableFactory callableFactory; @@ -96,27 +117,61 @@ protected GrpcImageAnnotatorStub( GrpcStubCallableFactory callableFactory) throws IOException { this.callableFactory = callableFactory; + this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); GrpcCallSettings batchAnnotateImagesTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(batchAnnotateImagesMethodDescriptor) .build(); + GrpcCallSettings + asyncBatchAnnotateFilesTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(asyncBatchAnnotateFilesMethodDescriptor) + .build(); this.batchAnnotateImagesCallable = callableFactory.createUnaryCallable( batchAnnotateImagesTransportSettings, settings.batchAnnotateImagesSettings(), clientContext); + this.asyncBatchAnnotateFilesCallable = + callableFactory.createUnaryCallable( + asyncBatchAnnotateFilesTransportSettings, + settings.asyncBatchAnnotateFilesSettings(), + clientContext); + this.asyncBatchAnnotateFilesOperationCallable = + callableFactory.createOperationCallable( + asyncBatchAnnotateFilesTransportSettings, + settings.asyncBatchAnnotateFilesOperationSettings(), + clientContext, + this.operationsStub); backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") + public GrpcOperationsStub getOperationsStub() { + return operationsStub; + } + public UnaryCallable batchAnnotateImagesCallable() { return batchAnnotateImagesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallable< + AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> + asyncBatchAnnotateFilesOperationCallable() { + return asyncBatchAnnotateFilesOperationCallable; + } + + public UnaryCallable + asyncBatchAnnotateFilesCallable() { + return asyncBatchAnnotateFilesCallable; + } + @Override public final void close() { shutdown(); diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/ImageAnnotatorStub.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/ImageAnnotatorStub.java index a5e2a4672e26..4f35c899338a 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/ImageAnnotatorStub.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/ImageAnnotatorStub.java @@ -17,14 +17,20 @@ import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest; +import com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse; import com.google.cloud.vision.v1.BatchAnnotateImagesRequest; import com.google.cloud.vision.v1.BatchAnnotateImagesResponse; +import com.google.cloud.vision.v1.OperationMetadata; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.OperationsStub; import javax.annotation.Generated; // AUTO-GENERATED DOCUMENTATION AND CLASS /** - * Base stub class for Google Cloud Vision API. + * Base stub class for Cloud Vision API. * *

This class is for advanced usage and reflects the underlying API directly. */ @@ -32,11 +38,29 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class ImageAnnotatorStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") + public OperationsStub getOperationsStub() { + throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); + } + public UnaryCallable batchAnnotateImagesCallable() { throw new UnsupportedOperationException("Not implemented: batchAnnotateImagesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallable< + AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> + asyncBatchAnnotateFilesOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: asyncBatchAnnotateFilesOperationCallable()"); + } + + public UnaryCallable + asyncBatchAnnotateFilesCallable() { + throw new UnsupportedOperationException("Not implemented: asyncBatchAnnotateFilesCallable()"); + } + @Override public abstract void close(); } diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/ImageAnnotatorStubSettings.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/ImageAnnotatorStubSettings.java index bf77097ebb28..f1d303347cf8 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/ImageAnnotatorStubSettings.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1/stub/ImageAnnotatorStubSettings.java @@ -23,19 +23,27 @@ import com.google.api.gax.grpc.GaxGrpcProperties; import com.google.api.gax.grpc.GrpcTransportChannel; import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.grpc.ProtoOperationTransformers; +import com.google.api.gax.longrunning.OperationSnapshot; +import com.google.api.gax.longrunning.OperationTimedPollAlgorithm; import com.google.api.gax.retrying.RetrySettings; import com.google.api.gax.rpc.ApiClientHeaderProvider; import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallSettings; import com.google.api.gax.rpc.StatusCode; import com.google.api.gax.rpc.StubSettings; import com.google.api.gax.rpc.TransportChannelProvider; import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.cloud.vision.v1.AsyncBatchAnnotateFilesRequest; +import com.google.cloud.vision.v1.AsyncBatchAnnotateFilesResponse; import com.google.cloud.vision.v1.BatchAnnotateImagesRequest; import com.google.cloud.vision.v1.BatchAnnotateImagesResponse; +import com.google.cloud.vision.v1.OperationMetadata; import com.google.common.collect.ImmutableList; import com.google.common.collect.ImmutableMap; import com.google.common.collect.ImmutableSet; import com.google.common.collect.Lists; +import com.google.longrunning.Operation; import java.io.IOException; import java.util.List; import javax.annotation.Generated; @@ -78,6 +86,11 @@ public class ImageAnnotatorStubSettings extends StubSettings batchAnnotateImagesSettings; + private final UnaryCallSettings + asyncBatchAnnotateFilesSettings; + private final OperationCallSettings< + AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> + asyncBatchAnnotateFilesOperationSettings; /** Returns the object with the settings used for calls to batchAnnotateImages. */ public UnaryCallSettings @@ -85,6 +98,20 @@ public class ImageAnnotatorStubSettings extends StubSettings + asyncBatchAnnotateFilesSettings() { + return asyncBatchAnnotateFilesSettings; + } + + /** Returns the object with the settings used for calls to asyncBatchAnnotateFiles. */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallSettings< + AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> + asyncBatchAnnotateFilesOperationSettings() { + return asyncBatchAnnotateFilesOperationSettings; + } + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public ImageAnnotatorStub createStub() throws IOException { if (getTransportChannelProvider() @@ -154,6 +181,9 @@ protected ImageAnnotatorStubSettings(Builder settingsBuilder) throws IOException super(settingsBuilder); batchAnnotateImagesSettings = settingsBuilder.batchAnnotateImagesSettings().build(); + asyncBatchAnnotateFilesSettings = settingsBuilder.asyncBatchAnnotateFilesSettings().build(); + asyncBatchAnnotateFilesOperationSettings = + settingsBuilder.asyncBatchAnnotateFilesOperationSettings().build(); } /** Builder for ImageAnnotatorStubSettings. */ @@ -162,6 +192,11 @@ public static class Builder extends StubSettings.Builder batchAnnotateImagesSettings; + private final UnaryCallSettings.Builder + asyncBatchAnnotateFilesSettings; + private final OperationCallSettings.Builder< + AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> + asyncBatchAnnotateFilesOperationSettings; private static final ImmutableMap> RETRYABLE_CODE_DEFINITIONS; @@ -206,8 +241,13 @@ protected Builder(ClientContext clientContext) { batchAnnotateImagesSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + asyncBatchAnnotateFilesSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + asyncBatchAnnotateFilesOperationSettings = OperationCallSettings.newBuilder(); + unaryMethodSettingsBuilders = - ImmutableList.>of(batchAnnotateImagesSettings); + ImmutableList.>of( + batchAnnotateImagesSettings, asyncBatchAnnotateFilesSettings); initDefaults(this); } @@ -228,6 +268,35 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + builder + .asyncBatchAnnotateFilesSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + builder + .asyncBatchAnnotateFilesOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create( + AsyncBatchAnnotateFilesResponse.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(20000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelay(Duration.ofMillis(45000L)) + .setInitialRpcTimeout(Duration.ZERO) // ignored + .setRpcTimeoutMultiplier(1.0) // ignored + .setMaxRpcTimeout(Duration.ZERO) // ignored + .setTotalTimeout(Duration.ofMillis(86400000L)) + .build())); + return builder; } @@ -235,9 +304,13 @@ protected Builder(ImageAnnotatorStubSettings settings) { super(settings); batchAnnotateImagesSettings = settings.batchAnnotateImagesSettings.toBuilder(); + asyncBatchAnnotateFilesSettings = settings.asyncBatchAnnotateFilesSettings.toBuilder(); + asyncBatchAnnotateFilesOperationSettings = + settings.asyncBatchAnnotateFilesOperationSettings.toBuilder(); unaryMethodSettingsBuilders = - ImmutableList.>of(batchAnnotateImagesSettings); + ImmutableList.>of( + batchAnnotateImagesSettings, asyncBatchAnnotateFilesSettings); } // NEXT_MAJOR_VER: remove 'throws Exception' @@ -262,6 +335,21 @@ public Builder applyToAllUnaryMethods( return batchAnnotateImagesSettings; } + /** Returns the builder for the settings used for calls to asyncBatchAnnotateFiles. */ + public UnaryCallSettings.Builder + asyncBatchAnnotateFilesSettings() { + return asyncBatchAnnotateFilesSettings; + } + + /** Returns the builder for the settings used for calls to asyncBatchAnnotateFiles. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallSettings.Builder< + AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> + asyncBatchAnnotateFilesOperationSettings() { + return asyncBatchAnnotateFilesOperationSettings; + } + @Override public ImageAnnotatorStubSettings build() throws IOException { return new ImageAnnotatorStubSettings(this); diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p1beta1/stub/GrpcImageAnnotatorCallableFactory.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p1beta1/stub/GrpcImageAnnotatorCallableFactory.java index b50dae133de3..d3988d313dbe 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p1beta1/stub/GrpcImageAnnotatorCallableFactory.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p1beta1/stub/GrpcImageAnnotatorCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/ImageAnnotatorClient.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/ImageAnnotatorClient.java index 3a5fc9b0f3e7..eab5ea4eda09 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/ImageAnnotatorClient.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/ImageAnnotatorClient.java @@ -157,6 +157,8 @@ public ImageAnnotatorStub getStub() { * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationsClient getOperationsClient() { return operationsClient; } @@ -252,6 +254,8 @@ private final BatchAnnotateImagesResponse batchAnnotateImages( * @param requests Individual async file annotation requests for this batch. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public final OperationFuture asyncBatchAnnotateFilesAsync(List requests) { @@ -283,6 +287,8 @@ private final BatchAnnotateImagesResponse batchAnnotateImages( * @param request The request object containing all of the parameters for the API call. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") private final OperationFuture asyncBatchAnnotateFilesAsync(AsyncBatchAnnotateFilesRequest request) { return asyncBatchAnnotateFilesOperationCallable().futureCall(request); @@ -310,6 +316,7 @@ private final BatchAnnotateImagesResponse batchAnnotateImages( * } * */ + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public final OperationCallable< AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> asyncBatchAnnotateFilesOperationCallable() { diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/ImageAnnotatorSettings.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/ImageAnnotatorSettings.java index 8b80c387cf39..166c63373f8e 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/ImageAnnotatorSettings.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/ImageAnnotatorSettings.java @@ -73,6 +73,8 @@ public class ImageAnnotatorSettings extends ClientSettings asyncBatchAnnotateFilesOperationSettings() { @@ -190,6 +192,8 @@ public Builder applyToAllUnaryMethods( } /** Returns the builder for the settings used for calls to asyncBatchAnnotateFiles. */ + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") public OperationCallSettings.Builder< AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> asyncBatchAnnotateFilesOperationSettings() { diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/GrpcImageAnnotatorCallableFactory.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/GrpcImageAnnotatorCallableFactory.java index 61a7315bf8b4..9771d9234814 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/GrpcImageAnnotatorCallableFactory.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/GrpcImageAnnotatorCallableFactory.java @@ -71,6 +71,8 @@ public UnaryCallable createBatchingCa grpcCallSettings, batchingCallSettings, clientContext); } + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") @Override public OperationCallable createOperationCallable( diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/GrpcImageAnnotatorStub.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/GrpcImageAnnotatorStub.java index db17611c3aa1..54f9c4e91e0c 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/GrpcImageAnnotatorStub.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/GrpcImageAnnotatorStub.java @@ -151,6 +151,7 @@ protected GrpcImageAnnotatorStub( backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public GrpcOperationsStub getOperationsStub() { return operationsStub; } @@ -160,6 +161,7 @@ public GrpcOperationsStub getOperationsStub() { return batchAnnotateImagesCallable; } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable< AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> asyncBatchAnnotateFilesOperationCallable() { diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/ImageAnnotatorStub.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/ImageAnnotatorStub.java index bba0fe909b4c..f9645aacfc07 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/ImageAnnotatorStub.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/ImageAnnotatorStub.java @@ -38,6 +38,7 @@ @BetaApi("A restructuring of stub classes is planned, so this may break in the future") public abstract class ImageAnnotatorStub implements BackgroundResource { + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: getOperationsStub()"); } @@ -47,6 +48,7 @@ public OperationsStub getOperationsStub() { throw new UnsupportedOperationException("Not implemented: batchAnnotateImagesCallable()"); } + @BetaApi("The surface for use by generated code is not stable yet and may change in the future.") public OperationCallable< AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> asyncBatchAnnotateFilesOperationCallable() { diff --git a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/ImageAnnotatorStubSettings.java b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/ImageAnnotatorStubSettings.java index 53e3f3f2c1b8..7bac636cb0a4 100644 --- a/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/ImageAnnotatorStubSettings.java +++ b/google-cloud-clients/google-cloud-vision/src/main/java/com/google/cloud/vision/v1p2beta1/stub/ImageAnnotatorStubSettings.java @@ -105,6 +105,7 @@ public class ImageAnnotatorStubSettings extends StubSettings asyncBatchAnnotateFilesOperationSettings() { @@ -341,6 +342,8 @@ public Builder applyToAllUnaryMethods( } /** Returns the builder for the settings used for calls to asyncBatchAnnotateFiles. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") public OperationCallSettings.Builder< AsyncBatchAnnotateFilesRequest, AsyncBatchAnnotateFilesResponse, OperationMetadata> asyncBatchAnnotateFilesOperationSettings() { diff --git a/google-cloud-clients/google-cloud-vision/src/test/java/com/google/cloud/vision/v1/ImageAnnotatorClientTest.java b/google-cloud-clients/google-cloud-vision/src/test/java/com/google/cloud/vision/v1/ImageAnnotatorClientTest.java index 12173de0c694..1927c5473113 100644 --- a/google-cloud-clients/google-cloud-vision/src/test/java/com/google/cloud/vision/v1/ImageAnnotatorClientTest.java +++ b/google-cloud-clients/google-cloud-vision/src/test/java/com/google/cloud/vision/v1/ImageAnnotatorClientTest.java @@ -22,6 +22,9 @@ import com.google.api.gax.grpc.testing.MockServiceHelper; import com.google.api.gax.rpc.ApiClientHeaderProvider; import com.google.api.gax.rpc.InvalidArgumentException; +import com.google.api.gax.rpc.StatusCode; +import com.google.longrunning.Operation; +import com.google.protobuf.Any; import com.google.protobuf.GeneratedMessageV3; import io.grpc.Status; import io.grpc.StatusRuntimeException; @@ -29,6 +32,7 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.List; +import java.util.concurrent.ExecutionException; import org.junit.After; import org.junit.AfterClass; import org.junit.Assert; @@ -110,4 +114,53 @@ public void batchAnnotateImagesExceptionTest() throws Exception { // Expected exception } } + + @Test + @SuppressWarnings("all") + public void asyncBatchAnnotateFilesTest() throws Exception { + AsyncBatchAnnotateFilesResponse expectedResponse = + AsyncBatchAnnotateFilesResponse.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("asyncBatchAnnotateFilesTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockImageAnnotator.addResponse(resultOperation); + + List requests = new ArrayList<>(); + + AsyncBatchAnnotateFilesResponse actualResponse = + client.asyncBatchAnnotateFilesAsync(requests).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockImageAnnotator.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + AsyncBatchAnnotateFilesRequest actualRequest = + (AsyncBatchAnnotateFilesRequest) actualRequests.get(0); + + Assert.assertEquals(requests, actualRequest.getRequestsList()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void asyncBatchAnnotateFilesExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockImageAnnotator.addException(exception); + + try { + List requests = new ArrayList<>(); + + client.asyncBatchAnnotateFilesAsync(requests).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = (InvalidArgumentException) e.getCause(); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } } diff --git a/google-cloud-clients/google-cloud-vision/src/test/java/com/google/cloud/vision/v1/MockImageAnnotatorImpl.java b/google-cloud-clients/google-cloud-vision/src/test/java/com/google/cloud/vision/v1/MockImageAnnotatorImpl.java index 833b5d06b231..dd4012f1d5f9 100644 --- a/google-cloud-clients/google-cloud-vision/src/test/java/com/google/cloud/vision/v1/MockImageAnnotatorImpl.java +++ b/google-cloud-clients/google-cloud-vision/src/test/java/com/google/cloud/vision/v1/MockImageAnnotatorImpl.java @@ -17,6 +17,7 @@ import com.google.api.core.BetaApi; import com.google.cloud.vision.v1.ImageAnnotatorGrpc.ImageAnnotatorImplBase; +import com.google.longrunning.Operation; import com.google.protobuf.GeneratedMessageV3; import io.grpc.stub.StreamObserver; import java.util.ArrayList; @@ -71,4 +72,19 @@ public void batchAnnotateImages( responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); } } + + @Override + public void asyncBatchAnnotateFiles( + AsyncBatchAnnotateFilesRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext((Operation) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } } diff --git a/google-cloud-clients/google-cloud-websecurityscanner/README.md b/google-cloud-clients/google-cloud-websecurityscanner/README.md new file mode 100644 index 000000000000..9402442b7a3f --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/README.md @@ -0,0 +1,102 @@ +Google Cloud Java Client for Web Security Scanner +====================================== + +Java idiomatic client for [Web Security Scanner][cloud-websecurityscanner]. + +[![CircleCI](https://circleci.com/gh/GoogleCloudPlatform/google-cloud-java/tree/master.svg?style=shield)](https://circleci.com/gh/GoogleCloudPlatform/google-cloud-java/tree/master) +[![Coverage Status](https://coveralls.io/repos/GoogleCloudPlatform/google-cloud-java/badge.svg?branch=master)](https://coveralls.io/r/GoogleCloudPlatform/google-cloud-java?branch=master) +[![Maven](https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-websecurityscanner.svg)](https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-websecurityscanner.svg) +[![Codacy Badge](https://api.codacy.com/project/badge/grade/9da006ad7c3a4fe1abd142e77c003917)](https://www.codacy.com/app/mziccard/google-cloud-java) +[![Dependency Status](https://www.versioneye.com/user/projects/58fe4c8d6ac171426c414772/badge.svg?style=flat)](https://www.versioneye.com/user/projects/58fe4c8d6ac171426c414772) + +- [Product Documentation][websecurityscanner-product-docs] +- [Client Library Documentation][websecurityscanner-client-lib-docs] + +> Note: This client is a work-in-progress, and may occasionally +> make backwards-incompatible changes. + +Quickstart +---------- + +[//]: # ({x-version-update-start:google-cloud-websecurityscanner:released}) +If you are using Maven, add this to your pom.xml file +```xml + + com.google.cloud + google-cloud-websecurityscanner + 0.47.0-alpha + +``` +If you are using Gradle, add this to your dependencies +```Groovy +compile 'com.google.cloud:google-cloud-websecurityscanner:0.47.0-alpha' +``` +If you are using SBT, add this to your dependencies +```Scala +libraryDependencies += "com.google.cloud" % "google-cloud-websecurityscanner" % "0.47.0-alpha" +``` +[//]: # ({x-version-update-end}) + +Authentication +-------------- + +See the [Authentication](https://github.com/GoogleCloudPlatform/google-cloud-java#authentication) section in the base directory's README. + +About Google Cloud Web Security Scanner +---------------------------- + +Google [Cloud Web Security Scanner][cloud-websecurityscanner] is a web security scanner for common vulnerabilities in Google App Engine applications. + +See the [Web Security Scanner client library docs][websecurityscanner-client-lib-docs] to learn how to use this Web Security Scanner Client Library. + +Getting Started +--------------- +#### Prerequisites +You will need a [Google Developers Console](https://console.developers.google.com/) project with the Text-to-Speech API enabled. [Follow these instructions](https://cloud.google.com/docs/authentication#preparation) to get your project set up. You will also need to set up the local development environment by [installing the Google Cloud SDK](https://cloud.google.com/sdk/) and running the following commands in command line: `gcloud auth login` and `gcloud config set project [YOUR PROJECT ID]`. + +#### Installation and setup +You'll need to obtain the `google-cloud-websecurityscanner` library. See the [Quickstart](#quickstart) section to add `google-cloud-websecurityscanner` as a dependency in your code. + +Troubleshooting +--------------- + +To get help, follow the instructions in the [shared Troubleshooting document](https://github.com/GoogleCloudPlatform/gcloud-common/blob/master/troubleshooting/readme.md#troubleshooting). + +Transport +--------- +Text-to-Speech uses gRPC for the transport layer. + +Java Versions +------------- + +Java 7 or above is required for using this client. + +Versioning +---------- + +This library follows [Semantic Versioning](http://semver.org/). + +It is currently in major version zero (``0.y.z``), which means that anything may change at any time and the public API should not be considered stable. + +Contributing +------------ + +Contributions to this library are always welcome and highly encouraged. + +See `google-cloud`'s [CONTRIBUTING] documentation and the [shared documentation](https://github.com/GoogleCloudPlatform/gcloud-common/blob/master/contributing/readme.md#how-to-contribute-to-gcloud) for more information on how to get started. + +Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms. See [Code of Conduct][code-of-conduct] for more information. + +License +------- + +Apache 2.0 - See [LICENSE] for more information. + + +[CONTRIBUTING]:https://github.com/GoogleCloudPlatform/google-cloud-java/blob/master/CONTRIBUTING.md +[code-of-conduct]:https://github.com/GoogleCloudPlatform/google-cloud-java/blob/master/CODE_OF_CONDUCT.md#contributor-code-of-conduct +[LICENSE]: https://github.com/GoogleCloudPlatform/google-cloud-java/blob/master/LICENSE +[cloud-platform]: https://cloud.google.com/ +[cloud-websecurityscanner]: https://cloud.google.com/security-scanner +[websecurityscanner-product-docs]: https://cloud.google.com/security-scanner/docs +[websecurityscanner-client-lib-docs]: https://googlecloudplatform.github.io/google-cloud-java/latest/apidocs/index.html?com/google/cloud/websecurityscanner/v1alpha/package-summary.html diff --git a/google-cloud-clients/google-cloud-websecurityscanner/pom.xml b/google-cloud-clients/google-cloud-websecurityscanner/pom.xml new file mode 100644 index 000000000000..73666f34dc5b --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/pom.xml @@ -0,0 +1,68 @@ + + + 4.0.0 + google-cloud-websecurityscanner + 0.47.1-alpha-SNAPSHOT + jar + Google Cloud Web Security Scanner + https://github.com/GoogleCloudPlatform/google-cloud-java/tree/master/google-cloud-websecurityscanner + + Java idiomatic client for Google Cloud Web Security Scanner + + + com.google.cloud + google-cloud-clients + 0.47.1-alpha-SNAPSHOT + + + google-cloud-websecurityscanner + + + + ${project.groupId} + google-cloud-core + + + ${project.groupId} + google-cloud-core-grpc + + + com.google.api.grpc + proto-google-cloud-websecurityscanner-v1alpha + + + io.grpc + grpc-netty-shaded + + + io.grpc + grpc-stub + + + io.grpc + grpc-auth + + + ${project.groupId} + google-cloud-core + test-jar + test + + + junit + junit + test + + + com.google.api.grpc + grpc-google-cloud-websecurityscanner-v1alpha + test + + + com.google.api + gax-grpc + testlib + test + + + diff --git a/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerClient.java b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerClient.java new file mode 100644 index 000000000000..9af9c3547b2b --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerClient.java @@ -0,0 +1,1669 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.websecurityscanner.v1alpha; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.ApiFutures; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.paging.AbstractFixedSizeCollection; +import com.google.api.gax.paging.AbstractPage; +import com.google.api.gax.paging.AbstractPagedListResponse; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.api.pathtemplate.PathTemplate; +import com.google.cloud.websecurityscanner.v1alpha.stub.WebSecurityScannerStub; +import com.google.cloud.websecurityscanner.v1alpha.stub.WebSecurityScannerStubSettings; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import java.io.IOException; +import java.util.List; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND SERVICE +/** + * Service Description: Cloud Web Security Scanner Service identifies security vulnerabilities in + * web applications hosted on Google Cloud Platform. It crawls your application, and attempts to + * exercise as many user inputs and event handlers as possible. + * + *

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

+ * 
+ * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+ *   String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]");
+ *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
+ *   ScanConfig response = webSecurityScannerClient.createScanConfig(formattedParent, scanConfig);
+ * }
+ * 
+ * 
+ * + *

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

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

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

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

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

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

To customize credentials: + * + *

+ * 
+ * WebSecurityScannerSettings webSecurityScannerSettings =
+ *     WebSecurityScannerSettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * WebSecurityScannerClient webSecurityScannerClient =
+ *     WebSecurityScannerClient.create(webSecurityScannerSettings);
+ * 
+ * 
+ * + * To customize the endpoint: + * + *
+ * 
+ * WebSecurityScannerSettings webSecurityScannerSettings =
+ *     WebSecurityScannerSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * WebSecurityScannerClient webSecurityScannerClient =
+ *     WebSecurityScannerClient.create(webSecurityScannerSettings);
+ * 
+ * 
+ */ +@Generated("by gapic-generator") +@BetaApi +public class WebSecurityScannerClient implements BackgroundResource { + private final WebSecurityScannerSettings settings; + private final WebSecurityScannerStub stub; + + private static final PathTemplate PROJECT_PATH_TEMPLATE = + PathTemplate.createWithoutUrlEncoding("projects/{project}"); + + private static final PathTemplate SCAN_CONFIG_PATH_TEMPLATE = + PathTemplate.createWithoutUrlEncoding("projects/{project}/scanConfigs/{scan_config}"); + + private static final PathTemplate SCAN_RUN_PATH_TEMPLATE = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/scanConfigs/{scan_config}/scanRuns/{scan_run}"); + + private static final PathTemplate FINDING_PATH_TEMPLATE = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/scanConfigs/{scan_config}/scanRuns/{scan_run}/findings/{finding}"); + + /** Formats a string containing the fully-qualified path to represent a project resource. */ + public static final String formatProjectName(String project) { + return PROJECT_PATH_TEMPLATE.instantiate("project", project); + } + + /** Formats a string containing the fully-qualified path to represent a scan_config resource. */ + public static final String formatScanConfigName(String project, String scanConfig) { + return SCAN_CONFIG_PATH_TEMPLATE.instantiate( + "project", project, + "scan_config", scanConfig); + } + + /** Formats a string containing the fully-qualified path to represent a scan_run resource. */ + public static final String formatScanRunName(String project, String scanConfig, String scanRun) { + return SCAN_RUN_PATH_TEMPLATE.instantiate( + "project", project, + "scan_config", scanConfig, + "scan_run", scanRun); + } + + /** Formats a string containing the fully-qualified path to represent a finding resource. */ + public static final String formatFindingName( + String project, String scanConfig, String scanRun, String finding) { + return FINDING_PATH_TEMPLATE.instantiate( + "project", project, + "scan_config", scanConfig, + "scan_run", scanRun, + "finding", finding); + } + + /** Parses the project from the given fully-qualified path which represents a project resource. */ + public static final String parseProjectFromProjectName(String projectName) { + return PROJECT_PATH_TEMPLATE.parse(projectName).get("project"); + } + + /** + * Parses the project from the given fully-qualified path which represents a scan_config resource. + */ + public static final String parseProjectFromScanConfigName(String scanConfigName) { + return SCAN_CONFIG_PATH_TEMPLATE.parse(scanConfigName).get("project"); + } + + /** + * Parses the scan_config from the given fully-qualified path which represents a scan_config + * resource. + */ + public static final String parseScanConfigFromScanConfigName(String scanConfigName) { + return SCAN_CONFIG_PATH_TEMPLATE.parse(scanConfigName).get("scan_config"); + } + + /** + * Parses the project from the given fully-qualified path which represents a scan_run resource. + */ + public static final String parseProjectFromScanRunName(String scanRunName) { + return SCAN_RUN_PATH_TEMPLATE.parse(scanRunName).get("project"); + } + + /** + * Parses the scan_config from the given fully-qualified path which represents a scan_run + * resource. + */ + public static final String parseScanConfigFromScanRunName(String scanRunName) { + return SCAN_RUN_PATH_TEMPLATE.parse(scanRunName).get("scan_config"); + } + + /** + * Parses the scan_run from the given fully-qualified path which represents a scan_run resource. + */ + public static final String parseScanRunFromScanRunName(String scanRunName) { + return SCAN_RUN_PATH_TEMPLATE.parse(scanRunName).get("scan_run"); + } + + /** Parses the project from the given fully-qualified path which represents a finding resource. */ + public static final String parseProjectFromFindingName(String findingName) { + return FINDING_PATH_TEMPLATE.parse(findingName).get("project"); + } + + /** + * Parses the scan_config from the given fully-qualified path which represents a finding resource. + */ + public static final String parseScanConfigFromFindingName(String findingName) { + return FINDING_PATH_TEMPLATE.parse(findingName).get("scan_config"); + } + + /** + * Parses the scan_run from the given fully-qualified path which represents a finding resource. + */ + public static final String parseScanRunFromFindingName(String findingName) { + return FINDING_PATH_TEMPLATE.parse(findingName).get("scan_run"); + } + + /** Parses the finding from the given fully-qualified path which represents a finding resource. */ + public static final String parseFindingFromFindingName(String findingName) { + return FINDING_PATH_TEMPLATE.parse(findingName).get("finding"); + } + + /** Constructs an instance of WebSecurityScannerClient with default settings. */ + public static final WebSecurityScannerClient create() throws IOException { + return create(WebSecurityScannerSettings.newBuilder().build()); + } + + /** + * Constructs an instance of WebSecurityScannerClient, using the given settings. The channels are + * created based on the settings passed in, or defaults for any settings that are not set. + */ + public static final WebSecurityScannerClient create(WebSecurityScannerSettings settings) + throws IOException { + return new WebSecurityScannerClient(settings); + } + + /** + * Constructs an instance of WebSecurityScannerClient, using the given stub for making calls. This + * is for advanced usage - prefer to use WebSecurityScannerSettings}. + */ + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public static final WebSecurityScannerClient create(WebSecurityScannerStub stub) { + return new WebSecurityScannerClient(stub); + } + + /** + * Constructs an instance of WebSecurityScannerClient, using the given settings. This is protected + * so that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected WebSecurityScannerClient(WebSecurityScannerSettings settings) throws IOException { + this.settings = settings; + this.stub = ((WebSecurityScannerStubSettings) settings.getStubSettings()).createStub(); + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + protected WebSecurityScannerClient(WebSecurityScannerStub stub) { + this.settings = null; + this.stub = stub; + } + + public final WebSecurityScannerSettings getSettings() { + return settings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public WebSecurityScannerStub getStub() { + return stub; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a new ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]");
+   *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
+   *   ScanConfig response = webSecurityScannerClient.createScanConfig(formattedParent, scanConfig);
+   * }
+   * 
+ * + * @param parent Required. The parent resource name where the scan is created, which should be a + * project resource name in the format 'projects/{projectId}'. + * @param scanConfig Required. The ScanConfig to be created. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ScanConfig createScanConfig(String parent, ScanConfig scanConfig) { + PROJECT_PATH_TEMPLATE.validate(parent, "createScanConfig"); + CreateScanConfigRequest request = + CreateScanConfigRequest.newBuilder().setParent(parent).setScanConfig(scanConfig).build(); + return createScanConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a new ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]");
+   *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
+   *   CreateScanConfigRequest request = CreateScanConfigRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .setScanConfig(scanConfig)
+   *     .build();
+   *   ScanConfig response = webSecurityScannerClient.createScanConfig(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ScanConfig createScanConfig(CreateScanConfigRequest request) { + return createScanConfigCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Creates a new ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]");
+   *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
+   *   CreateScanConfigRequest request = CreateScanConfigRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .setScanConfig(scanConfig)
+   *     .build();
+   *   ApiFuture<ScanConfig> future = webSecurityScannerClient.createScanConfigCallable().futureCall(request);
+   *   // Do something
+   *   ScanConfig response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable createScanConfigCallable() { + return stub.createScanConfigCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes an existing ScanConfig and its child resources. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   webSecurityScannerClient.deleteScanConfig(formattedName);
+   * }
+   * 
+ * + * @param name Required. The resource name of the ScanConfig to be deleted. The name follows the + * format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteScanConfig(String name) { + SCAN_CONFIG_PATH_TEMPLATE.validate(name, "deleteScanConfig"); + DeleteScanConfigRequest request = DeleteScanConfigRequest.newBuilder().setName(name).build(); + deleteScanConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes an existing ScanConfig and its child resources. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   DeleteScanConfigRequest request = DeleteScanConfigRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   webSecurityScannerClient.deleteScanConfig(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final void deleteScanConfig(DeleteScanConfigRequest request) { + deleteScanConfigCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Deletes an existing ScanConfig and its child resources. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   DeleteScanConfigRequest request = DeleteScanConfigRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   ApiFuture<Void> future = webSecurityScannerClient.deleteScanConfigCallable().futureCall(request);
+   *   // Do something
+   *   future.get();
+   * }
+   * 
+ */ + public final UnaryCallable deleteScanConfigCallable() { + return stub.deleteScanConfigCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   ScanConfig response = webSecurityScannerClient.getScanConfig(formattedName);
+   * }
+   * 
+ * + * @param name Required. The resource name of the ScanConfig to be returned. The name follows the + * format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ScanConfig getScanConfig(String name) { + SCAN_CONFIG_PATH_TEMPLATE.validate(name, "getScanConfig"); + GetScanConfigRequest request = GetScanConfigRequest.newBuilder().setName(name).build(); + return getScanConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   GetScanConfigRequest request = GetScanConfigRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   ScanConfig response = webSecurityScannerClient.getScanConfig(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final ScanConfig getScanConfig(GetScanConfigRequest request) { + return getScanConfigCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   GetScanConfigRequest request = GetScanConfigRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   ApiFuture<ScanConfig> future = webSecurityScannerClient.getScanConfigCallable().futureCall(request);
+   *   // Do something
+   *   ScanConfig response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable getScanConfigCallable() { + return stub.getScanConfigCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists ScanConfigs under a given project. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]");
+   *   for (ScanConfig element : webSecurityScannerClient.listScanConfigs(formattedParent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param parent Required. The parent resource name, which should be a project resource name in + * the format 'projects/{projectId}'. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListScanConfigsPagedResponse listScanConfigs(String parent) { + PROJECT_PATH_TEMPLATE.validate(parent, "listScanConfigs"); + ListScanConfigsRequest request = ListScanConfigsRequest.newBuilder().setParent(parent).build(); + return listScanConfigs(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists ScanConfigs under a given project. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]");
+   *   ListScanConfigsRequest request = ListScanConfigsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   for (ScanConfig element : webSecurityScannerClient.listScanConfigs(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListScanConfigsPagedResponse listScanConfigs(ListScanConfigsRequest request) { + return listScanConfigsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists ScanConfigs under a given project. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]");
+   *   ListScanConfigsRequest request = ListScanConfigsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   ApiFuture<ListScanConfigsPagedResponse> future = webSecurityScannerClient.listScanConfigsPagedCallable().futureCall(request);
+   *   // Do something
+   *   for (ScanConfig element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + listScanConfigsPagedCallable() { + return stub.listScanConfigsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists ScanConfigs under a given project. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]");
+   *   ListScanConfigsRequest request = ListScanConfigsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   while (true) {
+   *     ListScanConfigsResponse response = webSecurityScannerClient.listScanConfigsCallable().call(request);
+   *     for (ScanConfig element : response.getScanConfigsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + listScanConfigsCallable() { + return stub.listScanConfigsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Updates a ScanConfig. This method support partial update of a ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   ScanConfig response = webSecurityScannerClient.updateScanConfig(scanConfig, updateMask);
+   * }
+   * 
+ * + * @param scanConfig Required. The ScanConfig to be updated. The name field must be set to + * identify the resource to be updated. The values of fields not covered by the mask will be + * ignored. + * @param updateMask Required. The update mask applies to the resource. For the `FieldMask` + * definition, see + * https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ScanConfig updateScanConfig(ScanConfig scanConfig, FieldMask updateMask) { + + UpdateScanConfigRequest request = + UpdateScanConfigRequest.newBuilder() + .setScanConfig(scanConfig) + .setUpdateMask(updateMask) + .build(); + return updateScanConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Updates a ScanConfig. This method support partial update of a ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   UpdateScanConfigRequest request = UpdateScanConfigRequest.newBuilder()
+   *     .setScanConfig(scanConfig)
+   *     .setUpdateMask(updateMask)
+   *     .build();
+   *   ScanConfig response = webSecurityScannerClient.updateScanConfig(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ScanConfig updateScanConfig(UpdateScanConfigRequest request) { + return updateScanConfigCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Updates a ScanConfig. This method support partial update of a ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   UpdateScanConfigRequest request = UpdateScanConfigRequest.newBuilder()
+   *     .setScanConfig(scanConfig)
+   *     .setUpdateMask(updateMask)
+   *     .build();
+   *   ApiFuture<ScanConfig> future = webSecurityScannerClient.updateScanConfigCallable().futureCall(request);
+   *   // Do something
+   *   ScanConfig response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable updateScanConfigCallable() { + return stub.updateScanConfigCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Start a ScanRun according to the given ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   ScanRun response = webSecurityScannerClient.startScanRun(formattedName);
+   * }
+   * 
+ * + * @param name Required. The resource name of the ScanConfig to be used. The name follows the + * format of 'projects/{projectId}/scanConfigs/{scanConfigId}'. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ScanRun startScanRun(String name) { + SCAN_CONFIG_PATH_TEMPLATE.validate(name, "startScanRun"); + StartScanRunRequest request = StartScanRunRequest.newBuilder().setName(name).build(); + return startScanRun(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Start a ScanRun according to the given ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   StartScanRunRequest request = StartScanRunRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   ScanRun response = webSecurityScannerClient.startScanRun(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final ScanRun startScanRun(StartScanRunRequest request) { + return startScanRunCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Start a ScanRun according to the given ScanConfig. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   StartScanRunRequest request = StartScanRunRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   ApiFuture<ScanRun> future = webSecurityScannerClient.startScanRunCallable().futureCall(request);
+   *   // Do something
+   *   ScanRun response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable startScanRunCallable() { + return stub.startScanRunCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   ScanRun response = webSecurityScannerClient.getScanRun(formattedName);
+   * }
+   * 
+ * + * @param name Required. The resource name of the ScanRun to be returned. The name follows the + * format of 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ScanRun getScanRun(String name) { + SCAN_RUN_PATH_TEMPLATE.validate(name, "getScanRun"); + GetScanRunRequest request = GetScanRunRequest.newBuilder().setName(name).build(); + return getScanRun(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   GetScanRunRequest request = GetScanRunRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   ScanRun response = webSecurityScannerClient.getScanRun(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final ScanRun getScanRun(GetScanRunRequest request) { + return getScanRunCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   GetScanRunRequest request = GetScanRunRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   ApiFuture<ScanRun> future = webSecurityScannerClient.getScanRunCallable().futureCall(request);
+   *   // Do something
+   *   ScanRun response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable getScanRunCallable() { + return stub.getScanRunCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists ScanRuns under a given ScanConfig, in descending order of ScanRun stop time. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   for (ScanRun element : webSecurityScannerClient.listScanRuns(formattedParent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param parent Required. The parent resource name, which should be a scan resource name in the + * format 'projects/{projectId}/scanConfigs/{scanConfigId}'. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListScanRunsPagedResponse listScanRuns(String parent) { + SCAN_CONFIG_PATH_TEMPLATE.validate(parent, "listScanRuns"); + ListScanRunsRequest request = ListScanRunsRequest.newBuilder().setParent(parent).build(); + return listScanRuns(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists ScanRuns under a given ScanConfig, in descending order of ScanRun stop time. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   ListScanRunsRequest request = ListScanRunsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   for (ScanRun element : webSecurityScannerClient.listScanRuns(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListScanRunsPagedResponse listScanRuns(ListScanRunsRequest request) { + return listScanRunsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists ScanRuns under a given ScanConfig, in descending order of ScanRun stop time. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   ListScanRunsRequest request = ListScanRunsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   ApiFuture<ListScanRunsPagedResponse> future = webSecurityScannerClient.listScanRunsPagedCallable().futureCall(request);
+   *   // Do something
+   *   for (ScanRun element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + listScanRunsPagedCallable() { + return stub.listScanRunsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Lists ScanRuns under a given ScanConfig, in descending order of ScanRun stop time. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]");
+   *   ListScanRunsRequest request = ListScanRunsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   while (true) {
+   *     ListScanRunsResponse response = webSecurityScannerClient.listScanRunsCallable().call(request);
+   *     for (ScanRun element : response.getScanRunsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable listScanRunsCallable() { + return stub.listScanRunsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Stops a ScanRun. The stopped ScanRun is returned. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   ScanRun response = webSecurityScannerClient.stopScanRun(formattedName);
+   * }
+   * 
+ * + * @param name Required. The resource name of the ScanRun to be stopped. The name follows the + * format of 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ScanRun stopScanRun(String name) { + SCAN_RUN_PATH_TEMPLATE.validate(name, "stopScanRun"); + StopScanRunRequest request = StopScanRunRequest.newBuilder().setName(name).build(); + return stopScanRun(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Stops a ScanRun. The stopped ScanRun is returned. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   StopScanRunRequest request = StopScanRunRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   ScanRun response = webSecurityScannerClient.stopScanRun(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final ScanRun stopScanRun(StopScanRunRequest request) { + return stopScanRunCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Stops a ScanRun. The stopped ScanRun is returned. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   StopScanRunRequest request = StopScanRunRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   ApiFuture<ScanRun> future = webSecurityScannerClient.stopScanRunCallable().futureCall(request);
+   *   // Do something
+   *   ScanRun response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable stopScanRunCallable() { + return stub.stopScanRunCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List CrawledUrls under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   for (CrawledUrl element : webSecurityScannerClient.listCrawledUrls(formattedParent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param parent Required. The parent resource name, which should be a scan run resource name in + * the format 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListCrawledUrlsPagedResponse listCrawledUrls(String parent) { + SCAN_RUN_PATH_TEMPLATE.validate(parent, "listCrawledUrls"); + ListCrawledUrlsRequest request = ListCrawledUrlsRequest.newBuilder().setParent(parent).build(); + return listCrawledUrls(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List CrawledUrls under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   ListCrawledUrlsRequest request = ListCrawledUrlsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   for (CrawledUrl element : webSecurityScannerClient.listCrawledUrls(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListCrawledUrlsPagedResponse listCrawledUrls(ListCrawledUrlsRequest request) { + return listCrawledUrlsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List CrawledUrls under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   ListCrawledUrlsRequest request = ListCrawledUrlsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   ApiFuture<ListCrawledUrlsPagedResponse> future = webSecurityScannerClient.listCrawledUrlsPagedCallable().futureCall(request);
+   *   // Do something
+   *   for (CrawledUrl element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + listCrawledUrlsPagedCallable() { + return stub.listCrawledUrlsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List CrawledUrls under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   ListCrawledUrlsRequest request = ListCrawledUrlsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   while (true) {
+   *     ListCrawledUrlsResponse response = webSecurityScannerClient.listCrawledUrlsCallable().call(request);
+   *     for (CrawledUrl element : response.getCrawledUrlsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + listCrawledUrlsCallable() { + return stub.listCrawledUrlsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a Finding. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatFindingName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]", "[FINDING]");
+   *   Finding response = webSecurityScannerClient.getFinding(formattedName);
+   * }
+   * 
+ * + * @param name Required. The resource name of the Finding to be returned. The name follows the + * format of + * 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}/findings/{findingId}'. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Finding getFinding(String name) { + FINDING_PATH_TEMPLATE.validate(name, "getFinding"); + GetFindingRequest request = GetFindingRequest.newBuilder().setName(name).build(); + return getFinding(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a Finding. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatFindingName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]", "[FINDING]");
+   *   GetFindingRequest request = GetFindingRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   Finding response = webSecurityScannerClient.getFinding(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final Finding getFinding(GetFindingRequest request) { + return getFindingCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * Gets a Finding. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedName = WebSecurityScannerClient.formatFindingName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]", "[FINDING]");
+   *   GetFindingRequest request = GetFindingRequest.newBuilder()
+   *     .setName(formattedName)
+   *     .build();
+   *   ApiFuture<Finding> future = webSecurityScannerClient.getFindingCallable().futureCall(request);
+   *   // Do something
+   *   Finding response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable getFindingCallable() { + return stub.getFindingCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List Findings under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   String filter = "";
+   *   for (Finding element : webSecurityScannerClient.listFindings(formattedParent, filter).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param parent Required. The parent resource name, which should be a scan run resource name in + * the format 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + * @param filter The filter expression. The expression must be in the format: <field> + * <operator> <value>. Supported field: 'finding_type'. Supported operator: '='. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListFindingsPagedResponse listFindings(String parent, String filter) { + SCAN_RUN_PATH_TEMPLATE.validate(parent, "listFindings"); + ListFindingsRequest request = + ListFindingsRequest.newBuilder().setParent(parent).setFilter(filter).build(); + return listFindings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List Findings under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   String filter = "";
+   *   ListFindingsRequest request = ListFindingsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .setFilter(filter)
+   *     .build();
+   *   for (Finding element : webSecurityScannerClient.listFindings(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListFindingsPagedResponse listFindings(ListFindingsRequest request) { + return listFindingsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List Findings under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   String filter = "";
+   *   ListFindingsRequest request = ListFindingsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .setFilter(filter)
+   *     .build();
+   *   ApiFuture<ListFindingsPagedResponse> future = webSecurityScannerClient.listFindingsPagedCallable().futureCall(request);
+   *   // Do something
+   *   for (Finding element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable + listFindingsPagedCallable() { + return stub.listFindingsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List Findings under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   String filter = "";
+   *   ListFindingsRequest request = ListFindingsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .setFilter(filter)
+   *     .build();
+   *   while (true) {
+   *     ListFindingsResponse response = webSecurityScannerClient.listFindingsCallable().call(request);
+   *     for (Finding element : response.getFindingsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * 
+ */ + public final UnaryCallable listFindingsCallable() { + return stub.listFindingsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List all FindingTypeStats under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   ListFindingTypeStatsResponse response = webSecurityScannerClient.listFindingTypeStats(formattedParent);
+   * }
+   * 
+ * + * @param parent Required. The parent resource name, which should be a scan run resource name in + * the format 'projects/{projectId}/scanConfigs/{scanConfigId}/scanRuns/{scanRunId}'. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListFindingTypeStatsResponse listFindingTypeStats(String parent) { + SCAN_RUN_PATH_TEMPLATE.validate(parent, "listFindingTypeStats"); + ListFindingTypeStatsRequest request = + ListFindingTypeStatsRequest.newBuilder().setParent(parent).build(); + return listFindingTypeStats(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List all FindingTypeStats under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   ListFindingTypeStatsRequest request = ListFindingTypeStatsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   ListFindingTypeStatsResponse response = webSecurityScannerClient.listFindingTypeStats(request);
+   * }
+   * 
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + private final ListFindingTypeStatsResponse listFindingTypeStats( + ListFindingTypeStatsRequest request) { + return listFindingTypeStatsCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD + /** + * List all FindingTypeStats under a given ScanRun. + * + *

Sample code: + * + *


+   * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+   *   String formattedParent = WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]");
+   *   ListFindingTypeStatsRequest request = ListFindingTypeStatsRequest.newBuilder()
+   *     .setParent(formattedParent)
+   *     .build();
+   *   ApiFuture<ListFindingTypeStatsResponse> future = webSecurityScannerClient.listFindingTypeStatsCallable().futureCall(request);
+   *   // Do something
+   *   ListFindingTypeStatsResponse response = future.get();
+   * }
+   * 
+ */ + public final UnaryCallable + listFindingTypeStatsCallable() { + return stub.listFindingTypeStatsCallable(); + } + + @Override + public final void close() { + stub.close(); + } + + @Override + public void shutdown() { + stub.shutdown(); + } + + @Override + public boolean isShutdown() { + return stub.isShutdown(); + } + + @Override + public boolean isTerminated() { + return stub.isTerminated(); + } + + @Override + public void shutdownNow() { + stub.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return stub.awaitTermination(duration, unit); + } + + public static class ListScanConfigsPagedResponse + extends AbstractPagedListResponse< + ListScanConfigsRequest, ListScanConfigsResponse, ScanConfig, ListScanConfigsPage, + ListScanConfigsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListScanConfigsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + new ApiFunction() { + @Override + public ListScanConfigsPagedResponse apply(ListScanConfigsPage input) { + return new ListScanConfigsPagedResponse(input); + } + }); + } + + private ListScanConfigsPagedResponse(ListScanConfigsPage page) { + super(page, ListScanConfigsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListScanConfigsPage + extends AbstractPage< + ListScanConfigsRequest, ListScanConfigsResponse, ScanConfig, ListScanConfigsPage> { + + private ListScanConfigsPage( + PageContext context, + ListScanConfigsResponse response) { + super(context, response); + } + + private static ListScanConfigsPage createEmptyPage() { + return new ListScanConfigsPage(null, null); + } + + @Override + protected ListScanConfigsPage createPage( + PageContext context, + ListScanConfigsResponse response) { + return new ListScanConfigsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListScanConfigsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListScanConfigsRequest, ListScanConfigsResponse, ScanConfig, ListScanConfigsPage, + ListScanConfigsFixedSizeCollection> { + + private ListScanConfigsFixedSizeCollection( + List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListScanConfigsFixedSizeCollection createEmptyCollection() { + return new ListScanConfigsFixedSizeCollection(null, 0); + } + + @Override + protected ListScanConfigsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListScanConfigsFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListScanRunsPagedResponse + extends AbstractPagedListResponse< + ListScanRunsRequest, ListScanRunsResponse, ScanRun, ListScanRunsPage, + ListScanRunsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListScanRunsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + new ApiFunction() { + @Override + public ListScanRunsPagedResponse apply(ListScanRunsPage input) { + return new ListScanRunsPagedResponse(input); + } + }); + } + + private ListScanRunsPagedResponse(ListScanRunsPage page) { + super(page, ListScanRunsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListScanRunsPage + extends AbstractPage { + + private ListScanRunsPage( + PageContext context, + ListScanRunsResponse response) { + super(context, response); + } + + private static ListScanRunsPage createEmptyPage() { + return new ListScanRunsPage(null, null); + } + + @Override + protected ListScanRunsPage createPage( + PageContext context, + ListScanRunsResponse response) { + return new ListScanRunsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListScanRunsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListScanRunsRequest, ListScanRunsResponse, ScanRun, ListScanRunsPage, + ListScanRunsFixedSizeCollection> { + + private ListScanRunsFixedSizeCollection(List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListScanRunsFixedSizeCollection createEmptyCollection() { + return new ListScanRunsFixedSizeCollection(null, 0); + } + + @Override + protected ListScanRunsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListScanRunsFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListCrawledUrlsPagedResponse + extends AbstractPagedListResponse< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, CrawledUrl, ListCrawledUrlsPage, + ListCrawledUrlsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListCrawledUrlsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + new ApiFunction() { + @Override + public ListCrawledUrlsPagedResponse apply(ListCrawledUrlsPage input) { + return new ListCrawledUrlsPagedResponse(input); + } + }); + } + + private ListCrawledUrlsPagedResponse(ListCrawledUrlsPage page) { + super(page, ListCrawledUrlsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListCrawledUrlsPage + extends AbstractPage< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, CrawledUrl, ListCrawledUrlsPage> { + + private ListCrawledUrlsPage( + PageContext context, + ListCrawledUrlsResponse response) { + super(context, response); + } + + private static ListCrawledUrlsPage createEmptyPage() { + return new ListCrawledUrlsPage(null, null); + } + + @Override + protected ListCrawledUrlsPage createPage( + PageContext context, + ListCrawledUrlsResponse response) { + return new ListCrawledUrlsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListCrawledUrlsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, CrawledUrl, ListCrawledUrlsPage, + ListCrawledUrlsFixedSizeCollection> { + + private ListCrawledUrlsFixedSizeCollection( + List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListCrawledUrlsFixedSizeCollection createEmptyCollection() { + return new ListCrawledUrlsFixedSizeCollection(null, 0); + } + + @Override + protected ListCrawledUrlsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListCrawledUrlsFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListFindingsPagedResponse + extends AbstractPagedListResponse< + ListFindingsRequest, ListFindingsResponse, Finding, ListFindingsPage, + ListFindingsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListFindingsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + new ApiFunction() { + @Override + public ListFindingsPagedResponse apply(ListFindingsPage input) { + return new ListFindingsPagedResponse(input); + } + }); + } + + private ListFindingsPagedResponse(ListFindingsPage page) { + super(page, ListFindingsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListFindingsPage + extends AbstractPage { + + private ListFindingsPage( + PageContext context, + ListFindingsResponse response) { + super(context, response); + } + + private static ListFindingsPage createEmptyPage() { + return new ListFindingsPage(null, null); + } + + @Override + protected ListFindingsPage createPage( + PageContext context, + ListFindingsResponse response) { + return new ListFindingsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListFindingsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListFindingsRequest, ListFindingsResponse, Finding, ListFindingsPage, + ListFindingsFixedSizeCollection> { + + private ListFindingsFixedSizeCollection(List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListFindingsFixedSizeCollection createEmptyCollection() { + return new ListFindingsFixedSizeCollection(null, 0); + } + + @Override + protected ListFindingsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListFindingsFixedSizeCollection(pages, collectionSize); + } + } +} diff --git a/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerSettings.java b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerSettings.java new file mode 100644 index 000000000000..dbfbf3cdd3b4 --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerSettings.java @@ -0,0 +1,320 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.websecurityscanner.v1alpha; + +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListCrawledUrlsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListFindingsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListScanConfigsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListScanRunsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientSettings; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.cloud.websecurityscanner.v1alpha.stub.WebSecurityScannerStubSettings; +import com.google.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS +/** + * Settings class to configure an instance of {@link WebSecurityScannerClient}. + * + *

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

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

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. For + * example, to set the total timeout of createScanConfig to 30 seconds: + * + *

+ * 
+ * WebSecurityScannerSettings.Builder webSecurityScannerSettingsBuilder =
+ *     WebSecurityScannerSettings.newBuilder();
+ * webSecurityScannerSettingsBuilder.createScanConfigSettings().getRetrySettings().toBuilder()
+ *     .setTotalTimeout(Duration.ofSeconds(30));
+ * WebSecurityScannerSettings webSecurityScannerSettings = webSecurityScannerSettingsBuilder.build();
+ * 
+ * 
+ */ +@Generated("by gapic-generator") +@BetaApi +public class WebSecurityScannerSettings extends ClientSettings { + /** Returns the object with the settings used for calls to createScanConfig. */ + public UnaryCallSettings createScanConfigSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).createScanConfigSettings(); + } + + /** Returns the object with the settings used for calls to deleteScanConfig. */ + public UnaryCallSettings deleteScanConfigSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).deleteScanConfigSettings(); + } + + /** Returns the object with the settings used for calls to getScanConfig. */ + public UnaryCallSettings getScanConfigSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).getScanConfigSettings(); + } + + /** Returns the object with the settings used for calls to listScanConfigs. */ + public PagedCallSettings< + ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> + listScanConfigsSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).listScanConfigsSettings(); + } + + /** Returns the object with the settings used for calls to updateScanConfig. */ + public UnaryCallSettings updateScanConfigSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).updateScanConfigSettings(); + } + + /** Returns the object with the settings used for calls to startScanRun. */ + public UnaryCallSettings startScanRunSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).startScanRunSettings(); + } + + /** Returns the object with the settings used for calls to getScanRun. */ + public UnaryCallSettings getScanRunSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).getScanRunSettings(); + } + + /** Returns the object with the settings used for calls to listScanRuns. */ + public PagedCallSettings + listScanRunsSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).listScanRunsSettings(); + } + + /** Returns the object with the settings used for calls to stopScanRun. */ + public UnaryCallSettings stopScanRunSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).stopScanRunSettings(); + } + + /** Returns the object with the settings used for calls to listCrawledUrls. */ + public PagedCallSettings< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, ListCrawledUrlsPagedResponse> + listCrawledUrlsSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).listCrawledUrlsSettings(); + } + + /** Returns the object with the settings used for calls to getFinding. */ + public UnaryCallSettings getFindingSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).getFindingSettings(); + } + + /** Returns the object with the settings used for calls to listFindings. */ + public PagedCallSettings + listFindingsSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).listFindingsSettings(); + } + + /** Returns the object with the settings used for calls to listFindingTypeStats. */ + public UnaryCallSettings + listFindingTypeStatsSettings() { + return ((WebSecurityScannerStubSettings) getStubSettings()).listFindingTypeStatsSettings(); + } + + public static final WebSecurityScannerSettings create(WebSecurityScannerStubSettings stub) + throws IOException { + return new WebSecurityScannerSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return WebSecurityScannerStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return WebSecurityScannerStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return WebSecurityScannerStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return WebSecurityScannerStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return WebSecurityScannerStubSettings.defaultGrpcTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return WebSecurityScannerStubSettings.defaultTransportChannelProvider(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return WebSecurityScannerStubSettings.defaultApiClientHeaderProviderBuilder(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected WebSecurityScannerSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for WebSecurityScannerSettings. */ + public static class Builder extends ClientSettings.Builder { + protected Builder() throws IOException { + this((ClientContext) null); + } + + protected Builder(ClientContext clientContext) { + super(WebSecurityScannerStubSettings.newBuilder(clientContext)); + } + + private static Builder createDefault() { + return new Builder(WebSecurityScannerStubSettings.newBuilder()); + } + + protected Builder(WebSecurityScannerSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(WebSecurityScannerStubSettings.Builder stubSettings) { + super(stubSettings); + } + + public WebSecurityScannerStubSettings.Builder getStubSettingsBuilder() { + return ((WebSecurityScannerStubSettings.Builder) getStubSettings()); + } + + // NEXT_MAJOR_VER: remove 'throws Exception' + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) throws Exception { + super.applyToAllUnaryMethods( + getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); + return this; + } + + /** Returns the builder for the settings used for calls to createScanConfig. */ + public UnaryCallSettings.Builder + createScanConfigSettings() { + return getStubSettingsBuilder().createScanConfigSettings(); + } + + /** Returns the builder for the settings used for calls to deleteScanConfig. */ + public UnaryCallSettings.Builder deleteScanConfigSettings() { + return getStubSettingsBuilder().deleteScanConfigSettings(); + } + + /** Returns the builder for the settings used for calls to getScanConfig. */ + public UnaryCallSettings.Builder getScanConfigSettings() { + return getStubSettingsBuilder().getScanConfigSettings(); + } + + /** Returns the builder for the settings used for calls to listScanConfigs. */ + public PagedCallSettings.Builder< + ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> + listScanConfigsSettings() { + return getStubSettingsBuilder().listScanConfigsSettings(); + } + + /** Returns the builder for the settings used for calls to updateScanConfig. */ + public UnaryCallSettings.Builder + updateScanConfigSettings() { + return getStubSettingsBuilder().updateScanConfigSettings(); + } + + /** Returns the builder for the settings used for calls to startScanRun. */ + public UnaryCallSettings.Builder startScanRunSettings() { + return getStubSettingsBuilder().startScanRunSettings(); + } + + /** Returns the builder for the settings used for calls to getScanRun. */ + public UnaryCallSettings.Builder getScanRunSettings() { + return getStubSettingsBuilder().getScanRunSettings(); + } + + /** Returns the builder for the settings used for calls to listScanRuns. */ + public PagedCallSettings.Builder< + ListScanRunsRequest, ListScanRunsResponse, ListScanRunsPagedResponse> + listScanRunsSettings() { + return getStubSettingsBuilder().listScanRunsSettings(); + } + + /** Returns the builder for the settings used for calls to stopScanRun. */ + public UnaryCallSettings.Builder stopScanRunSettings() { + return getStubSettingsBuilder().stopScanRunSettings(); + } + + /** Returns the builder for the settings used for calls to listCrawledUrls. */ + public PagedCallSettings.Builder< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, ListCrawledUrlsPagedResponse> + listCrawledUrlsSettings() { + return getStubSettingsBuilder().listCrawledUrlsSettings(); + } + + /** Returns the builder for the settings used for calls to getFinding. */ + public UnaryCallSettings.Builder getFindingSettings() { + return getStubSettingsBuilder().getFindingSettings(); + } + + /** Returns the builder for the settings used for calls to listFindings. */ + public PagedCallSettings.Builder< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse> + listFindingsSettings() { + return getStubSettingsBuilder().listFindingsSettings(); + } + + /** Returns the builder for the settings used for calls to listFindingTypeStats. */ + public UnaryCallSettings.Builder + listFindingTypeStatsSettings() { + return getStubSettingsBuilder().listFindingTypeStatsSettings(); + } + + @Override + public WebSecurityScannerSettings build() throws IOException { + return new WebSecurityScannerSettings(this); + } + } +} diff --git a/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/package-info.java b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/package-info.java new file mode 100644 index 000000000000..2597fbba4bd3 --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/package-info.java @@ -0,0 +1,40 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * 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. + */ + +/** + * A client to Web Security Scanner API. + * + *

The interfaces provided are listed below, along with usage samples. + * + *

======================== WebSecurityScannerClient ======================== + * + *

Service Description: Cloud Web Security Scanner Service identifies security vulnerabilities in + * web applications hosted on Google Cloud Platform. It crawls your application, and attempts to + * exercise as many user inputs and event handlers as possible. + * + *

Sample for WebSecurityScannerClient: + * + *

+ * 
+ * try (WebSecurityScannerClient webSecurityScannerClient = WebSecurityScannerClient.create()) {
+ *   String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]");
+ *   ScanConfig scanConfig = ScanConfig.newBuilder().build();
+ *   ScanConfig response = webSecurityScannerClient.createScanConfig(formattedParent, scanConfig);
+ * }
+ * 
+ * 
+ */ +package com.google.cloud.websecurityscanner.v1alpha; diff --git a/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/GrpcWebSecurityScannerCallableFactory.java b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/GrpcWebSecurityScannerCallableFactory.java new file mode 100644 index 000000000000..2c1b0795a70a --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/GrpcWebSecurityScannerCallableFactory.java @@ -0,0 +1,116 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.websecurityscanner.v1alpha.stub; + +import com.google.api.core.BetaApi; +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcCallableFactory; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.BatchingCallSettings; +import com.google.api.gax.rpc.BidiStreamingCallable; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientStreamingCallable; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallable; +import com.google.api.gax.rpc.StreamingCallSettings; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.OperationsStub; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS +/** + * gRPC callable factory implementation for Web Security Scanner API. + * + *

This class is for advanced usage. + */ +@Generated("by gapic-generator") +@BetaApi("The surface for use by generated code is not stable yet and may change in the future.") +public class GrpcWebSecurityScannerCallableFactory implements GrpcStubCallableFactory { + @Override + public UnaryCallable createUnaryCallable( + GrpcCallSettings grpcCallSettings, + UnaryCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createUnaryCallable(grpcCallSettings, callSettings, clientContext); + } + + @Override + public + UnaryCallable createPagedCallable( + GrpcCallSettings grpcCallSettings, + PagedCallSettings pagedCallSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createPagedCallable( + grpcCallSettings, pagedCallSettings, clientContext); + } + + @Override + public UnaryCallable createBatchingCallable( + GrpcCallSettings grpcCallSettings, + BatchingCallSettings batchingCallSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createBatchingCallable( + grpcCallSettings, batchingCallSettings, clientContext); + } + + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") + @Override + public + OperationCallable createOperationCallable( + GrpcCallSettings grpcCallSettings, + OperationCallSettings operationCallSettings, + ClientContext clientContext, + OperationsStub operationsStub) { + return GrpcCallableFactory.createOperationCallable( + grpcCallSettings, operationCallSettings, clientContext, operationsStub); + } + + @Override + public + BidiStreamingCallable createBidiStreamingCallable( + GrpcCallSettings grpcCallSettings, + StreamingCallSettings streamingCallSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createBidiStreamingCallable( + grpcCallSettings, streamingCallSettings, clientContext); + } + + @Override + public + ServerStreamingCallable createServerStreamingCallable( + GrpcCallSettings grpcCallSettings, + ServerStreamingCallSettings streamingCallSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createServerStreamingCallable( + grpcCallSettings, streamingCallSettings, clientContext); + } + + @Override + public + ClientStreamingCallable createClientStreamingCallable( + GrpcCallSettings grpcCallSettings, + StreamingCallSettings streamingCallSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createClientStreamingCallable( + grpcCallSettings, streamingCallSettings, clientContext); + } +} diff --git a/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/GrpcWebSecurityScannerStub.java b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/GrpcWebSecurityScannerStub.java new file mode 100644 index 000000000000..56886f38d113 --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/GrpcWebSecurityScannerStub.java @@ -0,0 +1,475 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.websecurityscanner.v1alpha.stub; + +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListCrawledUrlsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListFindingsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListScanConfigsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListScanRunsPagedResponse; + +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.core.BackgroundResourceAggregation; +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.websecurityscanner.v1alpha.CreateScanConfigRequest; +import com.google.cloud.websecurityscanner.v1alpha.DeleteScanConfigRequest; +import com.google.cloud.websecurityscanner.v1alpha.Finding; +import com.google.cloud.websecurityscanner.v1alpha.GetFindingRequest; +import com.google.cloud.websecurityscanner.v1alpha.GetScanConfigRequest; +import com.google.cloud.websecurityscanner.v1alpha.GetScanRunRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListCrawledUrlsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListCrawledUrlsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingTypeStatsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingTypeStatsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListScanConfigsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListScanConfigsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListScanRunsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListScanRunsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ScanConfig; +import com.google.cloud.websecurityscanner.v1alpha.ScanRun; +import com.google.cloud.websecurityscanner.v1alpha.StartScanRunRequest; +import com.google.cloud.websecurityscanner.v1alpha.StopScanRunRequest; +import com.google.cloud.websecurityscanner.v1alpha.UpdateScanConfigRequest; +import com.google.protobuf.Empty; +import io.grpc.MethodDescriptor; +import io.grpc.protobuf.ProtoUtils; +import java.io.IOException; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS +/** + * gRPC stub implementation for Web Security Scanner API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator") +@BetaApi("A restructuring of stub classes is planned, so this may break in the future") +public class GrpcWebSecurityScannerStub extends WebSecurityScannerStub { + + private static final MethodDescriptor + createScanConfigMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/CreateScanConfig") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateScanConfigRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ScanConfig.getDefaultInstance())) + .build(); + private static final MethodDescriptor + deleteScanConfigMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/DeleteScanConfig") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteScanConfigRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) + .build(); + private static final MethodDescriptor + getScanConfigMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/GetScanConfig") + .setRequestMarshaller( + ProtoUtils.marshaller(GetScanConfigRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ScanConfig.getDefaultInstance())) + .build(); + private static final MethodDescriptor + listScanConfigsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/ListScanConfigs") + .setRequestMarshaller( + ProtoUtils.marshaller(ListScanConfigsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListScanConfigsResponse.getDefaultInstance())) + .build(); + private static final MethodDescriptor + updateScanConfigMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/UpdateScanConfig") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateScanConfigRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ScanConfig.getDefaultInstance())) + .build(); + private static final MethodDescriptor startScanRunMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/StartScanRun") + .setRequestMarshaller(ProtoUtils.marshaller(StartScanRunRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ScanRun.getDefaultInstance())) + .build(); + private static final MethodDescriptor getScanRunMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/GetScanRun") + .setRequestMarshaller(ProtoUtils.marshaller(GetScanRunRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ScanRun.getDefaultInstance())) + .build(); + private static final MethodDescriptor + listScanRunsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/ListScanRuns") + .setRequestMarshaller(ProtoUtils.marshaller(ListScanRunsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListScanRunsResponse.getDefaultInstance())) + .build(); + private static final MethodDescriptor stopScanRunMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/StopScanRun") + .setRequestMarshaller(ProtoUtils.marshaller(StopScanRunRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ScanRun.getDefaultInstance())) + .build(); + private static final MethodDescriptor + listCrawledUrlsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/ListCrawledUrls") + .setRequestMarshaller( + ProtoUtils.marshaller(ListCrawledUrlsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListCrawledUrlsResponse.getDefaultInstance())) + .build(); + private static final MethodDescriptor getFindingMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/GetFinding") + .setRequestMarshaller(ProtoUtils.marshaller(GetFindingRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Finding.getDefaultInstance())) + .build(); + private static final MethodDescriptor + listFindingsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/ListFindings") + .setRequestMarshaller(ProtoUtils.marshaller(ListFindingsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListFindingsResponse.getDefaultInstance())) + .build(); + private static final MethodDescriptor + listFindingTypeStatsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.websecurityscanner.v1alpha.WebSecurityScanner/ListFindingTypeStats") + .setRequestMarshaller( + ProtoUtils.marshaller(ListFindingTypeStatsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListFindingTypeStatsResponse.getDefaultInstance())) + .build(); + + private final BackgroundResource backgroundResources; + + private final UnaryCallable createScanConfigCallable; + private final UnaryCallable deleteScanConfigCallable; + private final UnaryCallable getScanConfigCallable; + private final UnaryCallable + listScanConfigsCallable; + private final UnaryCallable + listScanConfigsPagedCallable; + private final UnaryCallable updateScanConfigCallable; + private final UnaryCallable startScanRunCallable; + private final UnaryCallable getScanRunCallable; + private final UnaryCallable listScanRunsCallable; + private final UnaryCallable + listScanRunsPagedCallable; + private final UnaryCallable stopScanRunCallable; + private final UnaryCallable + listCrawledUrlsCallable; + private final UnaryCallable + listCrawledUrlsPagedCallable; + private final UnaryCallable getFindingCallable; + private final UnaryCallable listFindingsCallable; + private final UnaryCallable + listFindingsPagedCallable; + private final UnaryCallable + listFindingTypeStatsCallable; + + private final GrpcStubCallableFactory callableFactory; + + public static final GrpcWebSecurityScannerStub create(WebSecurityScannerStubSettings settings) + throws IOException { + return new GrpcWebSecurityScannerStub(settings, ClientContext.create(settings)); + } + + public static final GrpcWebSecurityScannerStub create(ClientContext clientContext) + throws IOException { + return new GrpcWebSecurityScannerStub( + WebSecurityScannerStubSettings.newBuilder().build(), clientContext); + } + + public static final GrpcWebSecurityScannerStub create( + ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { + return new GrpcWebSecurityScannerStub( + WebSecurityScannerStubSettings.newBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of GrpcWebSecurityScannerStub, using the given settings. This is + * protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected GrpcWebSecurityScannerStub( + WebSecurityScannerStubSettings settings, ClientContext clientContext) throws IOException { + this(settings, clientContext, new GrpcWebSecurityScannerCallableFactory()); + } + + /** + * Constructs an instance of GrpcWebSecurityScannerStub, using the given settings. This is + * protected so that it is easy to make a subclass, but otherwise, the static factory methods + * should be preferred. + */ + protected GrpcWebSecurityScannerStub( + WebSecurityScannerStubSettings settings, + ClientContext clientContext, + GrpcStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + + GrpcCallSettings createScanConfigTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createScanConfigMethodDescriptor) + .build(); + GrpcCallSettings deleteScanConfigTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteScanConfigMethodDescriptor) + .build(); + GrpcCallSettings getScanConfigTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getScanConfigMethodDescriptor) + .build(); + GrpcCallSettings + listScanConfigsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listScanConfigsMethodDescriptor) + .build(); + GrpcCallSettings updateScanConfigTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateScanConfigMethodDescriptor) + .build(); + GrpcCallSettings startScanRunTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(startScanRunMethodDescriptor) + .build(); + GrpcCallSettings getScanRunTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getScanRunMethodDescriptor) + .build(); + GrpcCallSettings listScanRunsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listScanRunsMethodDescriptor) + .build(); + GrpcCallSettings stopScanRunTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(stopScanRunMethodDescriptor) + .build(); + GrpcCallSettings + listCrawledUrlsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listCrawledUrlsMethodDescriptor) + .build(); + GrpcCallSettings getFindingTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getFindingMethodDescriptor) + .build(); + GrpcCallSettings listFindingsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listFindingsMethodDescriptor) + .build(); + GrpcCallSettings + listFindingTypeStatsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listFindingTypeStatsMethodDescriptor) + .build(); + + this.createScanConfigCallable = + callableFactory.createUnaryCallable( + createScanConfigTransportSettings, settings.createScanConfigSettings(), clientContext); + this.deleteScanConfigCallable = + callableFactory.createUnaryCallable( + deleteScanConfigTransportSettings, settings.deleteScanConfigSettings(), clientContext); + this.getScanConfigCallable = + callableFactory.createUnaryCallable( + getScanConfigTransportSettings, settings.getScanConfigSettings(), clientContext); + this.listScanConfigsCallable = + callableFactory.createUnaryCallable( + listScanConfigsTransportSettings, settings.listScanConfigsSettings(), clientContext); + this.listScanConfigsPagedCallable = + callableFactory.createPagedCallable( + listScanConfigsTransportSettings, settings.listScanConfigsSettings(), clientContext); + this.updateScanConfigCallable = + callableFactory.createUnaryCallable( + updateScanConfigTransportSettings, settings.updateScanConfigSettings(), clientContext); + this.startScanRunCallable = + callableFactory.createUnaryCallable( + startScanRunTransportSettings, settings.startScanRunSettings(), clientContext); + this.getScanRunCallable = + callableFactory.createUnaryCallable( + getScanRunTransportSettings, settings.getScanRunSettings(), clientContext); + this.listScanRunsCallable = + callableFactory.createUnaryCallable( + listScanRunsTransportSettings, settings.listScanRunsSettings(), clientContext); + this.listScanRunsPagedCallable = + callableFactory.createPagedCallable( + listScanRunsTransportSettings, settings.listScanRunsSettings(), clientContext); + this.stopScanRunCallable = + callableFactory.createUnaryCallable( + stopScanRunTransportSettings, settings.stopScanRunSettings(), clientContext); + this.listCrawledUrlsCallable = + callableFactory.createUnaryCallable( + listCrawledUrlsTransportSettings, settings.listCrawledUrlsSettings(), clientContext); + this.listCrawledUrlsPagedCallable = + callableFactory.createPagedCallable( + listCrawledUrlsTransportSettings, settings.listCrawledUrlsSettings(), clientContext); + this.getFindingCallable = + callableFactory.createUnaryCallable( + getFindingTransportSettings, settings.getFindingSettings(), clientContext); + this.listFindingsCallable = + callableFactory.createUnaryCallable( + listFindingsTransportSettings, settings.listFindingsSettings(), clientContext); + this.listFindingsPagedCallable = + callableFactory.createPagedCallable( + listFindingsTransportSettings, settings.listFindingsSettings(), clientContext); + this.listFindingTypeStatsCallable = + callableFactory.createUnaryCallable( + listFindingTypeStatsTransportSettings, + settings.listFindingTypeStatsSettings(), + clientContext); + + backgroundResources = new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + public UnaryCallable createScanConfigCallable() { + return createScanConfigCallable; + } + + public UnaryCallable deleteScanConfigCallable() { + return deleteScanConfigCallable; + } + + public UnaryCallable getScanConfigCallable() { + return getScanConfigCallable; + } + + public UnaryCallable + listScanConfigsPagedCallable() { + return listScanConfigsPagedCallable; + } + + public UnaryCallable listScanConfigsCallable() { + return listScanConfigsCallable; + } + + public UnaryCallable updateScanConfigCallable() { + return updateScanConfigCallable; + } + + public UnaryCallable startScanRunCallable() { + return startScanRunCallable; + } + + public UnaryCallable getScanRunCallable() { + return getScanRunCallable; + } + + public UnaryCallable listScanRunsPagedCallable() { + return listScanRunsPagedCallable; + } + + public UnaryCallable listScanRunsCallable() { + return listScanRunsCallable; + } + + public UnaryCallable stopScanRunCallable() { + return stopScanRunCallable; + } + + public UnaryCallable + listCrawledUrlsPagedCallable() { + return listCrawledUrlsPagedCallable; + } + + public UnaryCallable listCrawledUrlsCallable() { + return listCrawledUrlsCallable; + } + + public UnaryCallable getFindingCallable() { + return getFindingCallable; + } + + public UnaryCallable listFindingsPagedCallable() { + return listFindingsPagedCallable; + } + + public UnaryCallable listFindingsCallable() { + return listFindingsCallable; + } + + public UnaryCallable + listFindingTypeStatsCallable() { + return listFindingTypeStatsCallable; + } + + @Override + public final void close() { + shutdown(); + } + + @Override + public void shutdown() { + backgroundResources.shutdown(); + } + + @Override + public boolean isShutdown() { + return backgroundResources.isShutdown(); + } + + @Override + public boolean isTerminated() { + return backgroundResources.isTerminated(); + } + + @Override + public void shutdownNow() { + backgroundResources.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return backgroundResources.awaitTermination(duration, unit); + } +} diff --git a/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/WebSecurityScannerStub.java b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/WebSecurityScannerStub.java new file mode 100644 index 000000000000..08a16023a596 --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/WebSecurityScannerStub.java @@ -0,0 +1,133 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.websecurityscanner.v1alpha.stub; + +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListCrawledUrlsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListFindingsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListScanConfigsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListScanRunsPagedResponse; + +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.websecurityscanner.v1alpha.CreateScanConfigRequest; +import com.google.cloud.websecurityscanner.v1alpha.DeleteScanConfigRequest; +import com.google.cloud.websecurityscanner.v1alpha.Finding; +import com.google.cloud.websecurityscanner.v1alpha.GetFindingRequest; +import com.google.cloud.websecurityscanner.v1alpha.GetScanConfigRequest; +import com.google.cloud.websecurityscanner.v1alpha.GetScanRunRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListCrawledUrlsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListCrawledUrlsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingTypeStatsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingTypeStatsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListScanConfigsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListScanConfigsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListScanRunsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListScanRunsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ScanConfig; +import com.google.cloud.websecurityscanner.v1alpha.ScanRun; +import com.google.cloud.websecurityscanner.v1alpha.StartScanRunRequest; +import com.google.cloud.websecurityscanner.v1alpha.StopScanRunRequest; +import com.google.cloud.websecurityscanner.v1alpha.UpdateScanConfigRequest; +import com.google.protobuf.Empty; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS +/** + * Base stub class for Web Security Scanner API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator") +@BetaApi("A restructuring of stub classes is planned, so this may break in the future") +public abstract class WebSecurityScannerStub implements BackgroundResource { + + public UnaryCallable createScanConfigCallable() { + throw new UnsupportedOperationException("Not implemented: createScanConfigCallable()"); + } + + public UnaryCallable deleteScanConfigCallable() { + throw new UnsupportedOperationException("Not implemented: deleteScanConfigCallable()"); + } + + public UnaryCallable getScanConfigCallable() { + throw new UnsupportedOperationException("Not implemented: getScanConfigCallable()"); + } + + public UnaryCallable + listScanConfigsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listScanConfigsPagedCallable()"); + } + + public UnaryCallable listScanConfigsCallable() { + throw new UnsupportedOperationException("Not implemented: listScanConfigsCallable()"); + } + + public UnaryCallable updateScanConfigCallable() { + throw new UnsupportedOperationException("Not implemented: updateScanConfigCallable()"); + } + + public UnaryCallable startScanRunCallable() { + throw new UnsupportedOperationException("Not implemented: startScanRunCallable()"); + } + + public UnaryCallable getScanRunCallable() { + throw new UnsupportedOperationException("Not implemented: getScanRunCallable()"); + } + + public UnaryCallable listScanRunsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listScanRunsPagedCallable()"); + } + + public UnaryCallable listScanRunsCallable() { + throw new UnsupportedOperationException("Not implemented: listScanRunsCallable()"); + } + + public UnaryCallable stopScanRunCallable() { + throw new UnsupportedOperationException("Not implemented: stopScanRunCallable()"); + } + + public UnaryCallable + listCrawledUrlsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listCrawledUrlsPagedCallable()"); + } + + public UnaryCallable listCrawledUrlsCallable() { + throw new UnsupportedOperationException("Not implemented: listCrawledUrlsCallable()"); + } + + public UnaryCallable getFindingCallable() { + throw new UnsupportedOperationException("Not implemented: getFindingCallable()"); + } + + public UnaryCallable listFindingsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listFindingsPagedCallable()"); + } + + public UnaryCallable listFindingsCallable() { + throw new UnsupportedOperationException("Not implemented: listFindingsCallable()"); + } + + public UnaryCallable + listFindingTypeStatsCallable() { + throw new UnsupportedOperationException("Not implemented: listFindingTypeStatsCallable()"); + } + + @Override + public abstract void close(); +} diff --git a/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/WebSecurityScannerStubSettings.java b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/WebSecurityScannerStubSettings.java new file mode 100644 index 000000000000..0b25d16dd829 --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/src/main/java/com/google/cloud/websecurityscanner/v1alpha/stub/WebSecurityScannerStubSettings.java @@ -0,0 +1,827 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.websecurityscanner.v1alpha.stub; + +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListCrawledUrlsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListFindingsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListScanConfigsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListScanRunsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.GaxProperties; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.GrpcTransportChannel; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.rpc.ApiCallContext; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.PagedListDescriptor; +import com.google.api.gax.rpc.PagedListResponseFactory; +import com.google.api.gax.rpc.StatusCode; +import com.google.api.gax.rpc.StubSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.websecurityscanner.v1alpha.CrawledUrl; +import com.google.cloud.websecurityscanner.v1alpha.CreateScanConfigRequest; +import com.google.cloud.websecurityscanner.v1alpha.DeleteScanConfigRequest; +import com.google.cloud.websecurityscanner.v1alpha.Finding; +import com.google.cloud.websecurityscanner.v1alpha.GetFindingRequest; +import com.google.cloud.websecurityscanner.v1alpha.GetScanConfigRequest; +import com.google.cloud.websecurityscanner.v1alpha.GetScanRunRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListCrawledUrlsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListCrawledUrlsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingTypeStatsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingTypeStatsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListFindingsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListScanConfigsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListScanConfigsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ListScanRunsRequest; +import com.google.cloud.websecurityscanner.v1alpha.ListScanRunsResponse; +import com.google.cloud.websecurityscanner.v1alpha.ScanConfig; +import com.google.cloud.websecurityscanner.v1alpha.ScanRun; +import com.google.cloud.websecurityscanner.v1alpha.StartScanRunRequest; +import com.google.cloud.websecurityscanner.v1alpha.StopScanRunRequest; +import com.google.cloud.websecurityscanner.v1alpha.UpdateScanConfigRequest; +import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableSet; +import com.google.common.collect.Lists; +import com.google.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; +import org.threeten.bp.Duration; + +// AUTO-GENERATED DOCUMENTATION AND CLASS +/** + * Settings class to configure an instance of {@link WebSecurityScannerStub}. + * + *

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

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

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. For + * example, to set the total timeout of createScanConfig to 30 seconds: + * + *

+ * 
+ * WebSecurityScannerStubSettings.Builder webSecurityScannerSettingsBuilder =
+ *     WebSecurityScannerStubSettings.newBuilder();
+ * webSecurityScannerSettingsBuilder.createScanConfigSettings().getRetrySettings().toBuilder()
+ *     .setTotalTimeout(Duration.ofSeconds(30));
+ * WebSecurityScannerStubSettings webSecurityScannerSettings = webSecurityScannerSettingsBuilder.build();
+ * 
+ * 
+ */ +@Generated("by gapic-generator") +@BetaApi +public class WebSecurityScannerStubSettings extends StubSettings { + /** The default scopes of the service. */ + private static final ImmutableList DEFAULT_SERVICE_SCOPES = + ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + + private final UnaryCallSettings createScanConfigSettings; + private final UnaryCallSettings deleteScanConfigSettings; + private final UnaryCallSettings getScanConfigSettings; + private final PagedCallSettings< + ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> + listScanConfigsSettings; + private final UnaryCallSettings updateScanConfigSettings; + private final UnaryCallSettings startScanRunSettings; + private final UnaryCallSettings getScanRunSettings; + private final PagedCallSettings< + ListScanRunsRequest, ListScanRunsResponse, ListScanRunsPagedResponse> + listScanRunsSettings; + private final UnaryCallSettings stopScanRunSettings; + private final PagedCallSettings< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, ListCrawledUrlsPagedResponse> + listCrawledUrlsSettings; + private final UnaryCallSettings getFindingSettings; + private final PagedCallSettings< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse> + listFindingsSettings; + private final UnaryCallSettings + listFindingTypeStatsSettings; + + /** Returns the object with the settings used for calls to createScanConfig. */ + public UnaryCallSettings createScanConfigSettings() { + return createScanConfigSettings; + } + + /** Returns the object with the settings used for calls to deleteScanConfig. */ + public UnaryCallSettings deleteScanConfigSettings() { + return deleteScanConfigSettings; + } + + /** Returns the object with the settings used for calls to getScanConfig. */ + public UnaryCallSettings getScanConfigSettings() { + return getScanConfigSettings; + } + + /** Returns the object with the settings used for calls to listScanConfigs. */ + public PagedCallSettings< + ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> + listScanConfigsSettings() { + return listScanConfigsSettings; + } + + /** Returns the object with the settings used for calls to updateScanConfig. */ + public UnaryCallSettings updateScanConfigSettings() { + return updateScanConfigSettings; + } + + /** Returns the object with the settings used for calls to startScanRun. */ + public UnaryCallSettings startScanRunSettings() { + return startScanRunSettings; + } + + /** Returns the object with the settings used for calls to getScanRun. */ + public UnaryCallSettings getScanRunSettings() { + return getScanRunSettings; + } + + /** Returns the object with the settings used for calls to listScanRuns. */ + public PagedCallSettings + listScanRunsSettings() { + return listScanRunsSettings; + } + + /** Returns the object with the settings used for calls to stopScanRun. */ + public UnaryCallSettings stopScanRunSettings() { + return stopScanRunSettings; + } + + /** Returns the object with the settings used for calls to listCrawledUrls. */ + public PagedCallSettings< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, ListCrawledUrlsPagedResponse> + listCrawledUrlsSettings() { + return listCrawledUrlsSettings; + } + + /** Returns the object with the settings used for calls to getFinding. */ + public UnaryCallSettings getFindingSettings() { + return getFindingSettings; + } + + /** Returns the object with the settings used for calls to listFindings. */ + public PagedCallSettings + listFindingsSettings() { + return listFindingsSettings; + } + + /** Returns the object with the settings used for calls to listFindingTypeStats. */ + public UnaryCallSettings + listFindingTypeStatsSettings() { + return listFindingTypeStatsSettings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public WebSecurityScannerStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(GrpcTransportChannel.getGrpcTransportName())) { + return GrpcWebSecurityScannerStub.create(this); + } else { + throw new UnsupportedOperationException( + "Transport not supported: " + getTransportChannelProvider().getTransportName()); + } + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return InstantiatingExecutorProvider.newBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return "websecurityscanner.googleapis.com:443"; + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return DEFAULT_SERVICE_SCOPES; + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return GoogleCredentialsProvider.newBuilder().setScopesToApply(DEFAULT_SERVICE_SCOPES); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return InstantiatingGrpcChannelProvider.newBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return defaultGrpcTransportProviderBuilder().build(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", GaxProperties.getLibraryVersion(WebSecurityScannerStubSettings.class)) + .setTransportToken( + GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected WebSecurityScannerStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + createScanConfigSettings = settingsBuilder.createScanConfigSettings().build(); + deleteScanConfigSettings = settingsBuilder.deleteScanConfigSettings().build(); + getScanConfigSettings = settingsBuilder.getScanConfigSettings().build(); + listScanConfigsSettings = settingsBuilder.listScanConfigsSettings().build(); + updateScanConfigSettings = settingsBuilder.updateScanConfigSettings().build(); + startScanRunSettings = settingsBuilder.startScanRunSettings().build(); + getScanRunSettings = settingsBuilder.getScanRunSettings().build(); + listScanRunsSettings = settingsBuilder.listScanRunsSettings().build(); + stopScanRunSettings = settingsBuilder.stopScanRunSettings().build(); + listCrawledUrlsSettings = settingsBuilder.listCrawledUrlsSettings().build(); + getFindingSettings = settingsBuilder.getFindingSettings().build(); + listFindingsSettings = settingsBuilder.listFindingsSettings().build(); + listFindingTypeStatsSettings = settingsBuilder.listFindingTypeStatsSettings().build(); + } + + private static final PagedListDescriptor< + ListScanConfigsRequest, ListScanConfigsResponse, ScanConfig> + LIST_SCAN_CONFIGS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListScanConfigsRequest injectToken( + ListScanConfigsRequest payload, String token) { + return ListScanConfigsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListScanConfigsRequest injectPageSize( + ListScanConfigsRequest payload, int pageSize) { + return ListScanConfigsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListScanConfigsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListScanConfigsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListScanConfigsResponse payload) { + return payload.getScanConfigsList(); + } + }; + + private static final PagedListDescriptor + LIST_SCAN_RUNS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListScanRunsRequest injectToken(ListScanRunsRequest payload, String token) { + return ListScanRunsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListScanRunsRequest injectPageSize(ListScanRunsRequest payload, int pageSize) { + return ListScanRunsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListScanRunsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListScanRunsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListScanRunsResponse payload) { + return payload.getScanRunsList(); + } + }; + + private static final PagedListDescriptor< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, CrawledUrl> + LIST_CRAWLED_URLS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListCrawledUrlsRequest injectToken( + ListCrawledUrlsRequest payload, String token) { + return ListCrawledUrlsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListCrawledUrlsRequest injectPageSize( + ListCrawledUrlsRequest payload, int pageSize) { + return ListCrawledUrlsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListCrawledUrlsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListCrawledUrlsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListCrawledUrlsResponse payload) { + return payload.getCrawledUrlsList(); + } + }; + + private static final PagedListDescriptor + LIST_FINDINGS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListFindingsRequest injectToken(ListFindingsRequest payload, String token) { + return ListFindingsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListFindingsRequest injectPageSize(ListFindingsRequest payload, int pageSize) { + return ListFindingsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListFindingsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListFindingsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListFindingsResponse payload) { + return payload.getFindingsList(); + } + }; + + private static final PagedListResponseFactory< + ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> + LIST_SCAN_CONFIGS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListScanConfigsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_SCAN_CONFIGS_PAGE_STR_DESC, request, context); + return ListScanConfigsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListScanRunsRequest, ListScanRunsResponse, ListScanRunsPagedResponse> + LIST_SCAN_RUNS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListScanRunsRequest, ListScanRunsResponse, ListScanRunsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListScanRunsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_SCAN_RUNS_PAGE_STR_DESC, request, context); + return ListScanRunsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, ListCrawledUrlsPagedResponse> + LIST_CRAWLED_URLS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, ListCrawledUrlsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListCrawledUrlsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_CRAWLED_URLS_PAGE_STR_DESC, request, context); + return ListCrawledUrlsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse> + LIST_FINDINGS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListFindingsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_FINDINGS_PAGE_STR_DESC, request, context); + return ListFindingsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + /** Builder for WebSecurityScannerStubSettings. */ + public static class Builder + extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + + private final UnaryCallSettings.Builder + createScanConfigSettings; + private final UnaryCallSettings.Builder + deleteScanConfigSettings; + private final UnaryCallSettings.Builder getScanConfigSettings; + private final PagedCallSettings.Builder< + ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> + listScanConfigsSettings; + private final UnaryCallSettings.Builder + updateScanConfigSettings; + private final UnaryCallSettings.Builder startScanRunSettings; + private final UnaryCallSettings.Builder getScanRunSettings; + private final PagedCallSettings.Builder< + ListScanRunsRequest, ListScanRunsResponse, ListScanRunsPagedResponse> + listScanRunsSettings; + private final UnaryCallSettings.Builder stopScanRunSettings; + private final PagedCallSettings.Builder< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, ListCrawledUrlsPagedResponse> + listCrawledUrlsSettings; + private final UnaryCallSettings.Builder getFindingSettings; + private final PagedCallSettings.Builder< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse> + listFindingsSettings; + private final UnaryCallSettings.Builder< + ListFindingTypeStatsRequest, ListFindingTypeStatsResponse> + listFindingTypeStatsSettings; + + private static final ImmutableMap> + RETRYABLE_CODE_DEFINITIONS; + + static { + ImmutableMap.Builder> definitions = + ImmutableMap.builder(); + definitions.put( + "idempotent", + ImmutableSet.copyOf( + Lists.newArrayList( + StatusCode.Code.DEADLINE_EXCEEDED, StatusCode.Code.UNAVAILABLE))); + definitions.put("non_idempotent", ImmutableSet.copyOf(Lists.newArrayList())); + RETRYABLE_CODE_DEFINITIONS = definitions.build(); + } + + private static final ImmutableMap RETRY_PARAM_DEFINITIONS; + + static { + ImmutableMap.Builder definitions = ImmutableMap.builder(); + RetrySettings settings = null; + settings = + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(100L)) + .setRetryDelayMultiplier(1.3) + .setMaxRetryDelay(Duration.ofMillis(60000L)) + .setInitialRpcTimeout(Duration.ofMillis(20000L)) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ofMillis(20000L)) + .setTotalTimeout(Duration.ofMillis(600000L)) + .build(); + definitions.put("default", settings); + RETRY_PARAM_DEFINITIONS = definitions.build(); + } + + protected Builder() { + this((ClientContext) null); + } + + protected Builder(ClientContext clientContext) { + super(clientContext); + + createScanConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + deleteScanConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + getScanConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + listScanConfigsSettings = PagedCallSettings.newBuilder(LIST_SCAN_CONFIGS_PAGE_STR_FACT); + + updateScanConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + startScanRunSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + getScanRunSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + listScanRunsSettings = PagedCallSettings.newBuilder(LIST_SCAN_RUNS_PAGE_STR_FACT); + + stopScanRunSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + listCrawledUrlsSettings = PagedCallSettings.newBuilder(LIST_CRAWLED_URLS_PAGE_STR_FACT); + + getFindingSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + listFindingsSettings = PagedCallSettings.newBuilder(LIST_FINDINGS_PAGE_STR_FACT); + + listFindingTypeStatsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + createScanConfigSettings, + deleteScanConfigSettings, + getScanConfigSettings, + listScanConfigsSettings, + updateScanConfigSettings, + startScanRunSettings, + getScanRunSettings, + listScanRunsSettings, + stopScanRunSettings, + listCrawledUrlsSettings, + getFindingSettings, + listFindingsSettings, + listFindingTypeStatsSettings); + + initDefaults(this); + } + + private static Builder createDefault() { + Builder builder = new Builder((ClientContext) null); + builder.setTransportChannelProvider(defaultTransportChannelProvider()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); + builder.setEndpoint(getDefaultEndpoint()); + return initDefaults(builder); + } + + private static Builder initDefaults(Builder builder) { + + builder + .createScanConfigSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .deleteScanConfigSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .getScanConfigSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .listScanConfigsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .updateScanConfigSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .startScanRunSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .getScanRunSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .listScanRunsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .stopScanRunSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("non_idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .listCrawledUrlsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .getFindingSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .listFindingsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + builder + .listFindingTypeStatsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("idempotent")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("default")); + + return builder; + } + + protected Builder(WebSecurityScannerStubSettings settings) { + super(settings); + + createScanConfigSettings = settings.createScanConfigSettings.toBuilder(); + deleteScanConfigSettings = settings.deleteScanConfigSettings.toBuilder(); + getScanConfigSettings = settings.getScanConfigSettings.toBuilder(); + listScanConfigsSettings = settings.listScanConfigsSettings.toBuilder(); + updateScanConfigSettings = settings.updateScanConfigSettings.toBuilder(); + startScanRunSettings = settings.startScanRunSettings.toBuilder(); + getScanRunSettings = settings.getScanRunSettings.toBuilder(); + listScanRunsSettings = settings.listScanRunsSettings.toBuilder(); + stopScanRunSettings = settings.stopScanRunSettings.toBuilder(); + listCrawledUrlsSettings = settings.listCrawledUrlsSettings.toBuilder(); + getFindingSettings = settings.getFindingSettings.toBuilder(); + listFindingsSettings = settings.listFindingsSettings.toBuilder(); + listFindingTypeStatsSettings = settings.listFindingTypeStatsSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + createScanConfigSettings, + deleteScanConfigSettings, + getScanConfigSettings, + listScanConfigsSettings, + updateScanConfigSettings, + startScanRunSettings, + getScanRunSettings, + listScanRunsSettings, + stopScanRunSettings, + listCrawledUrlsSettings, + getFindingSettings, + listFindingsSettings, + listFindingTypeStatsSettings); + } + + // NEXT_MAJOR_VER: remove 'throws Exception' + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) throws Exception { + super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); + return this; + } + + public ImmutableList> unaryMethodSettingsBuilders() { + return unaryMethodSettingsBuilders; + } + + /** Returns the builder for the settings used for calls to createScanConfig. */ + public UnaryCallSettings.Builder + createScanConfigSettings() { + return createScanConfigSettings; + } + + /** Returns the builder for the settings used for calls to deleteScanConfig. */ + public UnaryCallSettings.Builder deleteScanConfigSettings() { + return deleteScanConfigSettings; + } + + /** Returns the builder for the settings used for calls to getScanConfig. */ + public UnaryCallSettings.Builder getScanConfigSettings() { + return getScanConfigSettings; + } + + /** Returns the builder for the settings used for calls to listScanConfigs. */ + public PagedCallSettings.Builder< + ListScanConfigsRequest, ListScanConfigsResponse, ListScanConfigsPagedResponse> + listScanConfigsSettings() { + return listScanConfigsSettings; + } + + /** Returns the builder for the settings used for calls to updateScanConfig. */ + public UnaryCallSettings.Builder + updateScanConfigSettings() { + return updateScanConfigSettings; + } + + /** Returns the builder for the settings used for calls to startScanRun. */ + public UnaryCallSettings.Builder startScanRunSettings() { + return startScanRunSettings; + } + + /** Returns the builder for the settings used for calls to getScanRun. */ + public UnaryCallSettings.Builder getScanRunSettings() { + return getScanRunSettings; + } + + /** Returns the builder for the settings used for calls to listScanRuns. */ + public PagedCallSettings.Builder< + ListScanRunsRequest, ListScanRunsResponse, ListScanRunsPagedResponse> + listScanRunsSettings() { + return listScanRunsSettings; + } + + /** Returns the builder for the settings used for calls to stopScanRun. */ + public UnaryCallSettings.Builder stopScanRunSettings() { + return stopScanRunSettings; + } + + /** Returns the builder for the settings used for calls to listCrawledUrls. */ + public PagedCallSettings.Builder< + ListCrawledUrlsRequest, ListCrawledUrlsResponse, ListCrawledUrlsPagedResponse> + listCrawledUrlsSettings() { + return listCrawledUrlsSettings; + } + + /** Returns the builder for the settings used for calls to getFinding. */ + public UnaryCallSettings.Builder getFindingSettings() { + return getFindingSettings; + } + + /** Returns the builder for the settings used for calls to listFindings. */ + public PagedCallSettings.Builder< + ListFindingsRequest, ListFindingsResponse, ListFindingsPagedResponse> + listFindingsSettings() { + return listFindingsSettings; + } + + /** Returns the builder for the settings used for calls to listFindingTypeStats. */ + public UnaryCallSettings.Builder + listFindingTypeStatsSettings() { + return listFindingTypeStatsSettings; + } + + @Override + public WebSecurityScannerStubSettings build() throws IOException { + return new WebSecurityScannerStubSettings(this); + } + } +} diff --git a/google-cloud-clients/google-cloud-websecurityscanner/src/test/java/com/google/cloud/websecurityscanner/v1alpha/MockWebSecurityScanner.java b/google-cloud-clients/google-cloud-websecurityscanner/src/test/java/com/google/cloud/websecurityscanner/v1alpha/MockWebSecurityScanner.java new file mode 100644 index 000000000000..88323eb229b1 --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/src/test/java/com/google/cloud/websecurityscanner/v1alpha/MockWebSecurityScanner.java @@ -0,0 +1,57 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.websecurityscanner.v1alpha; + +import com.google.api.core.BetaApi; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.protobuf.GeneratedMessageV3; +import io.grpc.ServerServiceDefinition; +import java.util.List; + +@javax.annotation.Generated("by GAPIC") +@BetaApi +public class MockWebSecurityScanner implements MockGrpcService { + private final MockWebSecurityScannerImpl serviceImpl; + + public MockWebSecurityScanner() { + serviceImpl = new MockWebSecurityScannerImpl(); + } + + @Override + public List getRequests() { + return serviceImpl.getRequests(); + } + + @Override + public void addResponse(GeneratedMessageV3 response) { + serviceImpl.addResponse(response); + } + + @Override + public void addException(Exception exception) { + serviceImpl.addException(exception); + } + + @Override + public ServerServiceDefinition getServiceDefinition() { + return serviceImpl.bindService(); + } + + @Override + public void reset() { + serviceImpl.reset(); + } +} diff --git a/google-cloud-clients/google-cloud-websecurityscanner/src/test/java/com/google/cloud/websecurityscanner/v1alpha/MockWebSecurityScannerImpl.java b/google-cloud-clients/google-cloud-websecurityscanner/src/test/java/com/google/cloud/websecurityscanner/v1alpha/MockWebSecurityScannerImpl.java new file mode 100644 index 000000000000..e58371ef43dc --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/src/test/java/com/google/cloud/websecurityscanner/v1alpha/MockWebSecurityScannerImpl.java @@ -0,0 +1,251 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.websecurityscanner.v1alpha; + +import com.google.api.core.BetaApi; +import com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerGrpc.WebSecurityScannerImplBase; +import com.google.protobuf.Empty; +import com.google.protobuf.GeneratedMessageV3; +import io.grpc.stub.StreamObserver; +import java.util.ArrayList; +import java.util.LinkedList; +import java.util.List; +import java.util.Queue; + +@javax.annotation.Generated("by GAPIC") +@BetaApi +public class MockWebSecurityScannerImpl extends WebSecurityScannerImplBase { + private ArrayList requests; + private Queue responses; + + public MockWebSecurityScannerImpl() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + public List getRequests() { + return requests; + } + + public void addResponse(GeneratedMessageV3 response) { + responses.add(response); + } + + public void setResponses(List responses) { + this.responses = new LinkedList(responses); + } + + public void addException(Exception exception) { + responses.add(exception); + } + + public void reset() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + @Override + public void createScanConfig( + CreateScanConfigRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ScanConfig) { + requests.add(request); + responseObserver.onNext((ScanConfig) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void deleteScanConfig( + DeleteScanConfigRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Empty) { + requests.add(request); + responseObserver.onNext((Empty) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void getScanConfig( + GetScanConfigRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ScanConfig) { + requests.add(request); + responseObserver.onNext((ScanConfig) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void listScanConfigs( + ListScanConfigsRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListScanConfigsResponse) { + requests.add(request); + responseObserver.onNext((ListScanConfigsResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void updateScanConfig( + UpdateScanConfigRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ScanConfig) { + requests.add(request); + responseObserver.onNext((ScanConfig) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void startScanRun(StartScanRunRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ScanRun) { + requests.add(request); + responseObserver.onNext((ScanRun) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void getScanRun(GetScanRunRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ScanRun) { + requests.add(request); + responseObserver.onNext((ScanRun) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void listScanRuns( + ListScanRunsRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListScanRunsResponse) { + requests.add(request); + responseObserver.onNext((ListScanRunsResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void stopScanRun(StopScanRunRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ScanRun) { + requests.add(request); + responseObserver.onNext((ScanRun) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void listCrawledUrls( + ListCrawledUrlsRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListCrawledUrlsResponse) { + requests.add(request); + responseObserver.onNext((ListCrawledUrlsResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void getFinding(GetFindingRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Finding) { + requests.add(request); + responseObserver.onNext((Finding) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void listFindings( + ListFindingsRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListFindingsResponse) { + requests.add(request); + responseObserver.onNext((ListFindingsResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void listFindingTypeStats( + ListFindingTypeStatsRequest request, + StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListFindingTypeStatsResponse) { + requests.add(request); + responseObserver.onNext((ListFindingTypeStatsResponse) response); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError((Exception) response); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } +} diff --git a/google-cloud-clients/google-cloud-websecurityscanner/src/test/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerClientTest.java b/google-cloud-clients/google-cloud-websecurityscanner/src/test/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerClientTest.java new file mode 100644 index 000000000000..1cf61bfa3e6b --- /dev/null +++ b/google-cloud-clients/google-cloud-websecurityscanner/src/test/java/com/google/cloud/websecurityscanner/v1alpha/WebSecurityScannerClientTest.java @@ -0,0 +1,720 @@ +/* + * Copyright 2018 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.websecurityscanner.v1alpha; + +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListCrawledUrlsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListFindingsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListScanConfigsPagedResponse; +import static com.google.cloud.websecurityscanner.v1alpha.WebSecurityScannerClient.ListScanRunsPagedResponse; + +import com.google.api.gax.core.NoCredentialsProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.testing.LocalChannelProvider; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.api.gax.grpc.testing.MockServiceHelper; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.InvalidArgumentException; +import com.google.common.collect.Lists; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import com.google.protobuf.GeneratedMessageV3; +import io.grpc.Status; +import io.grpc.StatusRuntimeException; +import java.io.IOException; +import java.util.Arrays; +import java.util.List; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; + +@javax.annotation.Generated("by GAPIC") +public class WebSecurityScannerClientTest { + private static MockWebSecurityScanner mockWebSecurityScanner; + private static MockServiceHelper serviceHelper; + private WebSecurityScannerClient client; + private LocalChannelProvider channelProvider; + + @BeforeClass + public static void startStaticServer() { + mockWebSecurityScanner = new MockWebSecurityScanner(); + serviceHelper = + new MockServiceHelper( + "in-process-1", Arrays.asList(mockWebSecurityScanner)); + serviceHelper.start(); + } + + @AfterClass + public static void stopServer() { + serviceHelper.stop(); + } + + @Before + public void setUp() throws IOException { + serviceHelper.reset(); + channelProvider = serviceHelper.createChannelProvider(); + WebSecurityScannerSettings settings = + WebSecurityScannerSettings.newBuilder() + .setTransportChannelProvider(channelProvider) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = WebSecurityScannerClient.create(settings); + } + + @After + public void tearDown() throws Exception { + client.close(); + } + + @Test + @SuppressWarnings("all") + public void createScanConfigTest() { + String name = "name3373707"; + String displayName = "displayName1615086568"; + int maxQps = 844445913; + ScanConfig expectedResponse = + ScanConfig.newBuilder().setName(name).setDisplayName(displayName).setMaxQps(maxQps).build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]"); + ScanConfig scanConfig = ScanConfig.newBuilder().build(); + + ScanConfig actualResponse = client.createScanConfig(formattedParent, scanConfig); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateScanConfigRequest actualRequest = (CreateScanConfigRequest) actualRequests.get(0); + + Assert.assertEquals(formattedParent, actualRequest.getParent()); + Assert.assertEquals(scanConfig, actualRequest.getScanConfig()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void createScanConfigExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]"); + ScanConfig scanConfig = ScanConfig.newBuilder().build(); + + client.createScanConfig(formattedParent, scanConfig); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void deleteScanConfigTest() { + Empty expectedResponse = Empty.newBuilder().build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedName = + WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]"); + + client.deleteScanConfig(formattedName); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteScanConfigRequest actualRequest = (DeleteScanConfigRequest) actualRequests.get(0); + + Assert.assertEquals(formattedName, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void deleteScanConfigExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedName = + WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]"); + + client.deleteScanConfig(formattedName); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void getScanConfigTest() { + String name2 = "name2-1052831874"; + String displayName = "displayName1615086568"; + int maxQps = 844445913; + ScanConfig expectedResponse = + ScanConfig.newBuilder() + .setName(name2) + .setDisplayName(displayName) + .setMaxQps(maxQps) + .build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedName = + WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]"); + + ScanConfig actualResponse = client.getScanConfig(formattedName); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetScanConfigRequest actualRequest = (GetScanConfigRequest) actualRequests.get(0); + + Assert.assertEquals(formattedName, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void getScanConfigExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedName = + WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]"); + + client.getScanConfig(formattedName); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void listScanConfigsTest() { + String nextPageToken = ""; + ScanConfig scanConfigsElement = ScanConfig.newBuilder().build(); + List scanConfigs = Arrays.asList(scanConfigsElement); + ListScanConfigsResponse expectedResponse = + ListScanConfigsResponse.newBuilder() + .setNextPageToken(nextPageToken) + .addAllScanConfigs(scanConfigs) + .build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]"); + + ListScanConfigsPagedResponse pagedListResponse = client.listScanConfigs(formattedParent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getScanConfigsList().get(0), resources.get(0)); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListScanConfigsRequest actualRequest = (ListScanConfigsRequest) actualRequests.get(0); + + Assert.assertEquals(formattedParent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void listScanConfigsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedParent = WebSecurityScannerClient.formatProjectName("[PROJECT]"); + + client.listScanConfigs(formattedParent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void updateScanConfigTest() { + String name = "name3373707"; + String displayName = "displayName1615086568"; + int maxQps = 844445913; + ScanConfig expectedResponse = + ScanConfig.newBuilder().setName(name).setDisplayName(displayName).setMaxQps(maxQps).build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + ScanConfig scanConfig = ScanConfig.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + ScanConfig actualResponse = client.updateScanConfig(scanConfig, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateScanConfigRequest actualRequest = (UpdateScanConfigRequest) actualRequests.get(0); + + Assert.assertEquals(scanConfig, actualRequest.getScanConfig()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void updateScanConfigExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + ScanConfig scanConfig = ScanConfig.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + client.updateScanConfig(scanConfig, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void startScanRunTest() { + String name2 = "name2-1052831874"; + long urlsCrawledCount = 1749797253L; + long urlsTestedCount = 1498664068L; + boolean hasVulnerabilities = false; + int progressPercent = 2137894861; + ScanRun expectedResponse = + ScanRun.newBuilder() + .setName(name2) + .setUrlsCrawledCount(urlsCrawledCount) + .setUrlsTestedCount(urlsTestedCount) + .setHasVulnerabilities(hasVulnerabilities) + .setProgressPercent(progressPercent) + .build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedName = + WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]"); + + ScanRun actualResponse = client.startScanRun(formattedName); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + StartScanRunRequest actualRequest = (StartScanRunRequest) actualRequests.get(0); + + Assert.assertEquals(formattedName, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void startScanRunExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedName = + WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]"); + + client.startScanRun(formattedName); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void getScanRunTest() { + String name2 = "name2-1052831874"; + long urlsCrawledCount = 1749797253L; + long urlsTestedCount = 1498664068L; + boolean hasVulnerabilities = false; + int progressPercent = 2137894861; + ScanRun expectedResponse = + ScanRun.newBuilder() + .setName(name2) + .setUrlsCrawledCount(urlsCrawledCount) + .setUrlsTestedCount(urlsTestedCount) + .setHasVulnerabilities(hasVulnerabilities) + .setProgressPercent(progressPercent) + .build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedName = + WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]"); + + ScanRun actualResponse = client.getScanRun(formattedName); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetScanRunRequest actualRequest = (GetScanRunRequest) actualRequests.get(0); + + Assert.assertEquals(formattedName, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void getScanRunExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedName = + WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]"); + + client.getScanRun(formattedName); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void listScanRunsTest() { + String nextPageToken = ""; + ScanRun scanRunsElement = ScanRun.newBuilder().build(); + List scanRuns = Arrays.asList(scanRunsElement); + ListScanRunsResponse expectedResponse = + ListScanRunsResponse.newBuilder() + .setNextPageToken(nextPageToken) + .addAllScanRuns(scanRuns) + .build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedParent = + WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]"); + + ListScanRunsPagedResponse pagedListResponse = client.listScanRuns(formattedParent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getScanRunsList().get(0), resources.get(0)); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListScanRunsRequest actualRequest = (ListScanRunsRequest) actualRequests.get(0); + + Assert.assertEquals(formattedParent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void listScanRunsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedParent = + WebSecurityScannerClient.formatScanConfigName("[PROJECT]", "[SCAN_CONFIG]"); + + client.listScanRuns(formattedParent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void stopScanRunTest() { + String name2 = "name2-1052831874"; + long urlsCrawledCount = 1749797253L; + long urlsTestedCount = 1498664068L; + boolean hasVulnerabilities = false; + int progressPercent = 2137894861; + ScanRun expectedResponse = + ScanRun.newBuilder() + .setName(name2) + .setUrlsCrawledCount(urlsCrawledCount) + .setUrlsTestedCount(urlsTestedCount) + .setHasVulnerabilities(hasVulnerabilities) + .setProgressPercent(progressPercent) + .build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedName = + WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]"); + + ScanRun actualResponse = client.stopScanRun(formattedName); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + StopScanRunRequest actualRequest = (StopScanRunRequest) actualRequests.get(0); + + Assert.assertEquals(formattedName, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void stopScanRunExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedName = + WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]"); + + client.stopScanRun(formattedName); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void listCrawledUrlsTest() { + String nextPageToken = ""; + CrawledUrl crawledUrlsElement = CrawledUrl.newBuilder().build(); + List crawledUrls = Arrays.asList(crawledUrlsElement); + ListCrawledUrlsResponse expectedResponse = + ListCrawledUrlsResponse.newBuilder() + .setNextPageToken(nextPageToken) + .addAllCrawledUrls(crawledUrls) + .build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedParent = + WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]"); + + ListCrawledUrlsPagedResponse pagedListResponse = client.listCrawledUrls(formattedParent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getCrawledUrlsList().get(0), resources.get(0)); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListCrawledUrlsRequest actualRequest = (ListCrawledUrlsRequest) actualRequests.get(0); + + Assert.assertEquals(formattedParent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void listCrawledUrlsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedParent = + WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]"); + + client.listCrawledUrls(formattedParent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void getFindingTest() { + String name2 = "name2-1052831874"; + String httpMethod = "httpMethod820747384"; + String fuzzedUrl = "fuzzedUrl-2120677666"; + String body = "body3029410"; + String description = "description-1724546052"; + String reproductionUrl = "reproductionUrl-244934180"; + String frameUrl = "frameUrl545464221"; + String finalUrl = "finalUrl355601190"; + String trackingId = "trackingId1878901667"; + Finding expectedResponse = + Finding.newBuilder() + .setName(name2) + .setHttpMethod(httpMethod) + .setFuzzedUrl(fuzzedUrl) + .setBody(body) + .setDescription(description) + .setReproductionUrl(reproductionUrl) + .setFrameUrl(frameUrl) + .setFinalUrl(finalUrl) + .setTrackingId(trackingId) + .build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedName = + WebSecurityScannerClient.formatFindingName( + "[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]", "[FINDING]"); + + Finding actualResponse = client.getFinding(formattedName); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetFindingRequest actualRequest = (GetFindingRequest) actualRequests.get(0); + + Assert.assertEquals(formattedName, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void getFindingExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedName = + WebSecurityScannerClient.formatFindingName( + "[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]", "[FINDING]"); + + client.getFinding(formattedName); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void listFindingsTest() { + String nextPageToken = ""; + Finding findingsElement = Finding.newBuilder().build(); + List findings = Arrays.asList(findingsElement); + ListFindingsResponse expectedResponse = + ListFindingsResponse.newBuilder() + .setNextPageToken(nextPageToken) + .addAllFindings(findings) + .build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedParent = + WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]"); + String filter = "filter-1274492040"; + + ListFindingsPagedResponse pagedListResponse = client.listFindings(formattedParent, filter); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getFindingsList().get(0), resources.get(0)); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListFindingsRequest actualRequest = (ListFindingsRequest) actualRequests.get(0); + + Assert.assertEquals(formattedParent, actualRequest.getParent()); + Assert.assertEquals(filter, actualRequest.getFilter()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void listFindingsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedParent = + WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]"); + String filter = "filter-1274492040"; + + client.listFindings(formattedParent, filter); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } + + @Test + @SuppressWarnings("all") + public void listFindingTypeStatsTest() { + ListFindingTypeStatsResponse expectedResponse = + ListFindingTypeStatsResponse.newBuilder().build(); + mockWebSecurityScanner.addResponse(expectedResponse); + + String formattedParent = + WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]"); + + ListFindingTypeStatsResponse actualResponse = client.listFindingTypeStats(formattedParent); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockWebSecurityScanner.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListFindingTypeStatsRequest actualRequest = (ListFindingTypeStatsRequest) actualRequests.get(0); + + Assert.assertEquals(formattedParent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + @SuppressWarnings("all") + public void listFindingTypeStatsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(Status.INVALID_ARGUMENT); + mockWebSecurityScanner.addException(exception); + + try { + String formattedParent = + WebSecurityScannerClient.formatScanRunName("[PROJECT]", "[SCAN_CONFIG]", "[SCAN_RUN]"); + + client.listFindingTypeStats(formattedParent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception + } + } +} diff --git a/google-cloud-clients/pom.xml b/google-cloud-clients/pom.xml index 4c4d2edd4eaa..65fef5322496 100644 --- a/google-cloud-clients/pom.xml +++ b/google-cloud-clients/pom.xml @@ -428,6 +428,7 @@ google-cloud-dns google-cloud-errorreporting google-cloud-firestore + google-cloud-iot google-cloud-language google-cloud-logging google-cloud-monitoring @@ -444,6 +445,7 @@ google-cloud-translate google-cloud-vision google-cloud-video-intelligence + google-cloud-websecurityscanner diff --git a/versions.txt b/versions.txt index 18d5f232c70c..6108422da5ee 100644 --- a/versions.txt +++ b/versions.txt @@ -16,7 +16,6 @@ grpc-google-cloud-dataproc-v1:0.12.0:0.12.1-SNAPSHOT grpc-google-cloud-dialogflow-v2:0.12.0:0.12.1-SNAPSHOT grpc-google-cloud-dialogflow-v2beta1:0.12.0:0.12.1-SNAPSHOT grpc-google-cloud-dlp-v2:0.12.0:0.12.1-SNAPSHOT -grpc-google-cloud-dlp-v2beta1:0.12.0:0.12.1-SNAPSHOT grpc-google-cloud-error-reporting-v1beta1:0.12.0:0.12.1-SNAPSHOT grpc-google-cloud-firestore-v1beta1:0.12.0:0.12.1-SNAPSHOT grpc-google-cloud-language-v1:1.11.0:1.11.1-SNAPSHOT @@ -41,7 +40,7 @@ grpc-google-cloud-video-intelligence-v1p1beta1:0.12.0:0.12.1-SNAPSHOT grpc-google-cloud-vision-v1:1.11.0:1.11.1-SNAPSHOT grpc-google-cloud-vision-v1p1beta1:0.12.0:0.12.1-SNAPSHOT grpc-google-cloud-vision-v1p2beta1:1.11.0:1.11.1-SNAPSHOT -grpc-google-cloud-cloudiot-v1:0.12.0:0.12.1-SNAPSHOT +grpc-google-cloud-iot-v1:0.12.0:0.12.1-SNAPSHOT grpc-google-cloud-redis-v1beta1:0.12.0:0.12.1-SNAPSHOT grpc-google-cloud-websecurityscanner-v1alpha:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-bigquerydatatransfer-v1:0.12.0:0.12.1-SNAPSHOT @@ -53,7 +52,6 @@ proto-google-cloud-datastore-v1:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-dialogflow-v2:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-dialogflow-v2beta1:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-dlp-v2:0.12.0:0.12.1-SNAPSHOT -proto-google-cloud-dlp-v2beta1:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-error-reporting-v1beta1:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-firestore-v1beta1:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-language-v1:1.11.0:1.11.1-SNAPSHOT @@ -78,7 +76,7 @@ proto-google-cloud-video-intelligence-v1p1beta1:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-vision-v1:1.11.0:1.11.1-SNAPSHOT proto-google-cloud-vision-v1p1beta1:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-vision-v1p2beta1:1.11.0:1.11.1-SNAPSHOT -proto-google-cloud-cloudiot-v1:0.12.0:0.12.1-SNAPSHOT +proto-google-cloud-iot-v1:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-redis-v1beta1:0.12.0:0.12.1-SNAPSHOT proto-google-cloud-websecurityscanner-v1alpha:0.12.0:0.12.1-SNAPSHOT @@ -134,3 +132,5 @@ google-cloud-translate:1.29.0:1.29.1-SNAPSHOT google-cloud-util:0.47.0-alpha:0.47.1-alpha-SNAPSHOT google-cloud-video-intelligence:0.47.0-beta:0.47.1-beta-SNAPSHOT google-cloud-vision:1.29.0:1.29.1-SNAPSHOT +google-cloud-iot:0.47.0-beta:0.47.1-beta-SNAPSHOT +google-cloud-websecurityscanner:0.47.0-alpha:0.47.1-alpha-SNAPSHOT