@Generated(value="by gapic-generator-java")
See: Description
The interfaces provided are listed below, along with usage samples.
======================= DocumentProcessorServiceClient =======================
Service Description: Service to call Document AI to process documents according to the processor's definition. Processors are built using state-of-the-art Google AI such as natural language, computer vision, and translation to extract structured information from unstructured or semi-structured documents.
Sample for DocumentProcessorServiceClient:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DocumentProcessorServiceClient documentProcessorServiceClient =
DocumentProcessorServiceClient.create()) {
ResourceName name = ProcessorName.of("[PROJECT]", "[LOCATION]", "[PROCESSOR]");
ProcessResponse response = documentProcessorServiceClient.processDocument(name);
}
======================= DocumentServiceClient =======================
Service Description: Service to call Cloud DocumentAI to manage document collection (dataset).
Sample for DocumentServiceClient:
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (DocumentServiceClient documentServiceClient = DocumentServiceClient.create()) {
DatasetName dataset = DatasetName.of("[PROJECT]", "[LOCATION]", "[PROCESSOR]");
GetDocumentResponse response = documentServiceClient.getDocument(dataset);
}
Copyright © 2024 Google LLC. All rights reserved.