Skip to content
This repository has been archived by the owner on Nov 9, 2023. It is now read-only.

feat: update document.proto, add the processor management methods #515

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view

Large diffs are not rendered by default.

Expand Up @@ -16,6 +16,8 @@

package com.google.cloud.documentai.v1beta3;

import static com.google.cloud.documentai.v1beta3.DocumentProcessorServiceClient.ListProcessorsPagedResponse;

import com.google.api.core.ApiFunction;
import com.google.api.core.BetaApi;
import com.google.api.gax.core.GoogleCredentialsProvider;
Expand All @@ -25,10 +27,12 @@
import com.google.api.gax.rpc.ClientContext;
import com.google.api.gax.rpc.ClientSettings;
import com.google.api.gax.rpc.OperationCallSettings;
import com.google.api.gax.rpc.PagedCallSettings;
import com.google.api.gax.rpc.TransportChannelProvider;
import com.google.api.gax.rpc.UnaryCallSettings;
import com.google.cloud.documentai.v1beta3.stub.DocumentProcessorServiceStubSettings;
import com.google.longrunning.Operation;
import com.google.protobuf.Empty;
import java.io.IOException;
import java.util.List;
import javax.annotation.Generated;
Expand Down Expand Up @@ -89,6 +93,62 @@ public UnaryCallSettings<BatchProcessRequest, Operation> batchProcessDocumentsSe
.batchProcessDocumentsOperationSettings();
}

/** Returns the object with the settings used for calls to fetchProcessorTypes. */
public UnaryCallSettings<FetchProcessorTypesRequest, FetchProcessorTypesResponse>
fetchProcessorTypesSettings() {
return ((DocumentProcessorServiceStubSettings) getStubSettings()).fetchProcessorTypesSettings();
}

/** Returns the object with the settings used for calls to listProcessors. */
public PagedCallSettings<
ListProcessorsRequest, ListProcessorsResponse, ListProcessorsPagedResponse>
listProcessorsSettings() {
return ((DocumentProcessorServiceStubSettings) getStubSettings()).listProcessorsSettings();
}

/** Returns the object with the settings used for calls to createProcessor. */
public UnaryCallSettings<CreateProcessorRequest, Processor> createProcessorSettings() {
return ((DocumentProcessorServiceStubSettings) getStubSettings()).createProcessorSettings();
}

/** Returns the object with the settings used for calls to deleteProcessor. */
public UnaryCallSettings<DeleteProcessorRequest, Operation> deleteProcessorSettings() {
return ((DocumentProcessorServiceStubSettings) getStubSettings()).deleteProcessorSettings();
}

/** Returns the object with the settings used for calls to deleteProcessor. */
public OperationCallSettings<DeleteProcessorRequest, Empty, DeleteProcessorMetadata>
deleteProcessorOperationSettings() {
return ((DocumentProcessorServiceStubSettings) getStubSettings())
.deleteProcessorOperationSettings();
}

/** Returns the object with the settings used for calls to enableProcessor. */
public UnaryCallSettings<EnableProcessorRequest, Operation> enableProcessorSettings() {
return ((DocumentProcessorServiceStubSettings) getStubSettings()).enableProcessorSettings();
}

/** Returns the object with the settings used for calls to enableProcessor. */
public OperationCallSettings<
EnableProcessorRequest, EnableProcessorResponse, EnableProcessorMetadata>
enableProcessorOperationSettings() {
return ((DocumentProcessorServiceStubSettings) getStubSettings())
.enableProcessorOperationSettings();
}

/** Returns the object with the settings used for calls to disableProcessor. */
public UnaryCallSettings<DisableProcessorRequest, Operation> disableProcessorSettings() {
return ((DocumentProcessorServiceStubSettings) getStubSettings()).disableProcessorSettings();
}

/** Returns the object with the settings used for calls to disableProcessor. */
public OperationCallSettings<
DisableProcessorRequest, DisableProcessorResponse, DisableProcessorMetadata>
disableProcessorOperationSettings() {
return ((DocumentProcessorServiceStubSettings) getStubSettings())
.disableProcessorOperationSettings();
}

/** Returns the object with the settings used for calls to reviewDocument. */
public UnaryCallSettings<ReviewDocumentRequest, Operation> reviewDocumentSettings() {
return ((DocumentProcessorServiceStubSettings) getStubSettings()).reviewDocumentSettings();
Expand Down Expand Up @@ -219,6 +279,60 @@ public UnaryCallSettings.Builder<ProcessRequest, ProcessResponse> processDocumen
return getStubSettingsBuilder().batchProcessDocumentsOperationSettings();
}

/** Returns the builder for the settings used for calls to fetchProcessorTypes. */
public UnaryCallSettings.Builder<FetchProcessorTypesRequest, FetchProcessorTypesResponse>
fetchProcessorTypesSettings() {
return getStubSettingsBuilder().fetchProcessorTypesSettings();
}

/** Returns the builder for the settings used for calls to listProcessors. */
public PagedCallSettings.Builder<
ListProcessorsRequest, ListProcessorsResponse, ListProcessorsPagedResponse>
listProcessorsSettings() {
return getStubSettingsBuilder().listProcessorsSettings();
}

/** Returns the builder for the settings used for calls to createProcessor. */
public UnaryCallSettings.Builder<CreateProcessorRequest, Processor> createProcessorSettings() {
return getStubSettingsBuilder().createProcessorSettings();
}

/** Returns the builder for the settings used for calls to deleteProcessor. */
public UnaryCallSettings.Builder<DeleteProcessorRequest, Operation> deleteProcessorSettings() {
return getStubSettingsBuilder().deleteProcessorSettings();
}

/** Returns the builder for the settings used for calls to deleteProcessor. */
public OperationCallSettings.Builder<DeleteProcessorRequest, Empty, DeleteProcessorMetadata>
deleteProcessorOperationSettings() {
return getStubSettingsBuilder().deleteProcessorOperationSettings();
}

/** Returns the builder for the settings used for calls to enableProcessor. */
public UnaryCallSettings.Builder<EnableProcessorRequest, Operation> enableProcessorSettings() {
return getStubSettingsBuilder().enableProcessorSettings();
}

/** Returns the builder for the settings used for calls to enableProcessor. */
public OperationCallSettings.Builder<
EnableProcessorRequest, EnableProcessorResponse, EnableProcessorMetadata>
enableProcessorOperationSettings() {
return getStubSettingsBuilder().enableProcessorOperationSettings();
}

/** Returns the builder for the settings used for calls to disableProcessor. */
public UnaryCallSettings.Builder<DisableProcessorRequest, Operation>
disableProcessorSettings() {
return getStubSettingsBuilder().disableProcessorSettings();
}

/** Returns the builder for the settings used for calls to disableProcessor. */
public OperationCallSettings.Builder<
DisableProcessorRequest, DisableProcessorResponse, DisableProcessorMetadata>
disableProcessorOperationSettings() {
return getStubSettingsBuilder().disableProcessorOperationSettings();
}

/** Returns the builder for the settings used for calls to reviewDocument. */
public UnaryCallSettings.Builder<ReviewDocumentRequest, Operation> reviewDocumentSettings() {
return getStubSettingsBuilder().reviewDocumentSettings();
Expand Down
Expand Up @@ -13,6 +13,24 @@
"BatchProcessDocuments": {
"methods": ["batchProcessDocumentsAsync", "batchProcessDocumentsAsync", "batchProcessDocumentsAsync", "batchProcessDocumentsOperationCallable", "batchProcessDocumentsCallable"]
},
"CreateProcessor": {
"methods": ["createProcessor", "createProcessor", "createProcessor", "createProcessorCallable"]
},
"DeleteProcessor": {
"methods": ["deleteProcessorAsync", "deleteProcessorAsync", "deleteProcessorAsync", "deleteProcessorOperationCallable", "deleteProcessorCallable"]
},
"DisableProcessor": {
"methods": ["disableProcessorAsync", "disableProcessorOperationCallable", "disableProcessorCallable"]
},
"EnableProcessor": {
"methods": ["enableProcessorAsync", "enableProcessorOperationCallable", "enableProcessorCallable"]
},
"FetchProcessorTypes": {
"methods": ["fetchProcessorTypes", "fetchProcessorTypes", "fetchProcessorTypes", "fetchProcessorTypesCallable"]
},
"ListProcessors": {
"methods": ["listProcessors", "listProcessors", "listProcessors", "listProcessorsPagedCallable", "listProcessorsCallable"]
},
"ProcessDocument": {
"methods": ["processDocument", "processDocument", "processDocument", "processDocumentCallable"]
},
Expand Down
Expand Up @@ -16,20 +16,37 @@

package com.google.cloud.documentai.v1beta3.stub;

import static com.google.cloud.documentai.v1beta3.DocumentProcessorServiceClient.ListProcessorsPagedResponse;

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.documentai.v1beta3.BatchProcessMetadata;
import com.google.cloud.documentai.v1beta3.BatchProcessRequest;
import com.google.cloud.documentai.v1beta3.BatchProcessResponse;
import com.google.cloud.documentai.v1beta3.CreateProcessorRequest;
import com.google.cloud.documentai.v1beta3.DeleteProcessorMetadata;
import com.google.cloud.documentai.v1beta3.DeleteProcessorRequest;
import com.google.cloud.documentai.v1beta3.DisableProcessorMetadata;
import com.google.cloud.documentai.v1beta3.DisableProcessorRequest;
import com.google.cloud.documentai.v1beta3.DisableProcessorResponse;
import com.google.cloud.documentai.v1beta3.EnableProcessorMetadata;
import com.google.cloud.documentai.v1beta3.EnableProcessorRequest;
import com.google.cloud.documentai.v1beta3.EnableProcessorResponse;
import com.google.cloud.documentai.v1beta3.FetchProcessorTypesRequest;
import com.google.cloud.documentai.v1beta3.FetchProcessorTypesResponse;
import com.google.cloud.documentai.v1beta3.ListProcessorsRequest;
import com.google.cloud.documentai.v1beta3.ListProcessorsResponse;
import com.google.cloud.documentai.v1beta3.ProcessRequest;
import com.google.cloud.documentai.v1beta3.ProcessResponse;
import com.google.cloud.documentai.v1beta3.Processor;
import com.google.cloud.documentai.v1beta3.ReviewDocumentOperationMetadata;
import com.google.cloud.documentai.v1beta3.ReviewDocumentRequest;
import com.google.cloud.documentai.v1beta3.ReviewDocumentResponse;
import com.google.longrunning.Operation;
import com.google.longrunning.stub.OperationsStub;
import com.google.protobuf.Empty;
import javax.annotation.Generated;

// AUTO-GENERATED DOCUMENTATION AND CLASS.
Expand Down Expand Up @@ -60,6 +77,52 @@ public UnaryCallable<BatchProcessRequest, Operation> batchProcessDocumentsCallab
throw new UnsupportedOperationException("Not implemented: batchProcessDocumentsCallable()");
}

public UnaryCallable<FetchProcessorTypesRequest, FetchProcessorTypesResponse>
fetchProcessorTypesCallable() {
throw new UnsupportedOperationException("Not implemented: fetchProcessorTypesCallable()");
}

public UnaryCallable<ListProcessorsRequest, ListProcessorsPagedResponse>
listProcessorsPagedCallable() {
throw new UnsupportedOperationException("Not implemented: listProcessorsPagedCallable()");
}

public UnaryCallable<ListProcessorsRequest, ListProcessorsResponse> listProcessorsCallable() {
throw new UnsupportedOperationException("Not implemented: listProcessorsCallable()");
}

public UnaryCallable<CreateProcessorRequest, Processor> createProcessorCallable() {
throw new UnsupportedOperationException("Not implemented: createProcessorCallable()");
}

public OperationCallable<DeleteProcessorRequest, Empty, DeleteProcessorMetadata>
deleteProcessorOperationCallable() {
throw new UnsupportedOperationException("Not implemented: deleteProcessorOperationCallable()");
}

public UnaryCallable<DeleteProcessorRequest, Operation> deleteProcessorCallable() {
throw new UnsupportedOperationException("Not implemented: deleteProcessorCallable()");
}

public OperationCallable<EnableProcessorRequest, EnableProcessorResponse, EnableProcessorMetadata>
enableProcessorOperationCallable() {
throw new UnsupportedOperationException("Not implemented: enableProcessorOperationCallable()");
}

public UnaryCallable<EnableProcessorRequest, Operation> enableProcessorCallable() {
throw new UnsupportedOperationException("Not implemented: enableProcessorCallable()");
}

public OperationCallable<
DisableProcessorRequest, DisableProcessorResponse, DisableProcessorMetadata>
disableProcessorOperationCallable() {
throw new UnsupportedOperationException("Not implemented: disableProcessorOperationCallable()");
}

public UnaryCallable<DisableProcessorRequest, Operation> disableProcessorCallable() {
throw new UnsupportedOperationException("Not implemented: disableProcessorCallable()");
}

public OperationCallable<
ReviewDocumentRequest, ReviewDocumentResponse, ReviewDocumentOperationMetadata>
reviewDocumentOperationCallable() {
Expand Down