From 481e545d82d7bd292fbed3b90037df87984fcf5d Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Wed, 9 Jun 2021 13:44:08 -0700 Subject: [PATCH] feat: Move CommonOperationMetadata into a separate proto file for potential reuse (#505) This PR was generated using Autosynth. :rainbow: Synth log will be available here: https://source.cloud.google.com/results/invocations/acbdbcfb-4be0-4bc6-af06-1fb3c1efa1b8/targets - [ ] To automatically regenerate this PR, check this box. (May take up to 24 hours.) PiperOrigin-RevId: 377562108 Source-Link: https://github.com/googleapis/googleapis/commit/3e0f7ebfbbd2344412e7622fab4bc0c9004c5932 --- .../v1/CommonOperationMetadata.java | 12 +- .../v1/CommonOperationMetadataOrBuilder.java | 2 +- .../v1/DocumentAiProcessorService.java | 195 ++++++++---------- .../cloud/documentai/v1/NormalizedVertex.java | 8 +- .../v1/NormalizedVertexOrBuilder.java | 2 +- .../documentai/v1/OperationMetadataProto.java | 82 ++++++++ .../google/cloud/documentai/v1/Vertex.java | 8 +- .../cloud/documentai/v1/VertexOrBuilder.java | 2 +- .../v1/document_processor_service.proto | 37 +--- .../google/cloud/documentai/v1/geometry.proto | 4 +- .../documentai/v1/operation_metadata.proto | 64 ++++++ synth.metadata | 20 +- 12 files changed, 266 insertions(+), 170 deletions(-) create mode 100644 proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/OperationMetadataProto.java create mode 100644 proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/operation_metadata.proto diff --git a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/CommonOperationMetadata.java b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/CommonOperationMetadata.java index 5f512ba6..4fbc0fc2 100644 --- a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/CommonOperationMetadata.java +++ b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/CommonOperationMetadata.java @@ -14,7 +14,7 @@ * limitations under the License. */ // Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/documentai/v1/document_processor_service.proto +// source: google/cloud/documentai/v1/operation_metadata.proto package com.google.cloud.documentai.v1; @@ -135,14 +135,14 @@ private CommonOperationMetadata( } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.documentai.v1.DocumentAiProcessorService + return com.google.cloud.documentai.v1.OperationMetadataProto .internal_static_google_cloud_documentai_v1_CommonOperationMetadata_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.documentai.v1.DocumentAiProcessorService + return com.google.cloud.documentai.v1.OperationMetadataProto .internal_static_google_cloud_documentai_v1_CommonOperationMetadata_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.documentai.v1.CommonOperationMetadata.class, @@ -768,14 +768,14 @@ public static final class Builder extends com.google.protobuf.GeneratedMessageV3 // @@protoc_insertion_point(builder_implements:google.cloud.documentai.v1.CommonOperationMetadata) com.google.cloud.documentai.v1.CommonOperationMetadataOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.documentai.v1.DocumentAiProcessorService + return com.google.cloud.documentai.v1.OperationMetadataProto .internal_static_google_cloud_documentai_v1_CommonOperationMetadata_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.documentai.v1.DocumentAiProcessorService + return com.google.cloud.documentai.v1.OperationMetadataProto .internal_static_google_cloud_documentai_v1_CommonOperationMetadata_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.documentai.v1.CommonOperationMetadata.class, @@ -820,7 +820,7 @@ public Builder clear() { @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.documentai.v1.DocumentAiProcessorService + return com.google.cloud.documentai.v1.OperationMetadataProto .internal_static_google_cloud_documentai_v1_CommonOperationMetadata_descriptor; } diff --git a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/CommonOperationMetadataOrBuilder.java b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/CommonOperationMetadataOrBuilder.java index 6af53725..efb39be1 100644 --- a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/CommonOperationMetadataOrBuilder.java +++ b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/CommonOperationMetadataOrBuilder.java @@ -14,7 +14,7 @@ * limitations under the License. */ // Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/documentai/v1/document_processor_service.proto +// source: google/cloud/documentai/v1/operation_metadata.proto package com.google.cloud.documentai.v1; diff --git a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/DocumentAiProcessorService.java b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/DocumentAiProcessorService.java index 1f1f4304..b99c68ab 100644 --- a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/DocumentAiProcessorService.java +++ b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/DocumentAiProcessorService.java @@ -67,10 +67,6 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_documentai_v1_ReviewDocumentOperationMetadata_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_documentai_v1_ReviewDocumentOperationMetadata_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_documentai_v1_CommonOperationMetadata_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_documentai_v1_CommonOperationMetadata_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -87,100 +83,93 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ld_behavior.proto\032\031google/api/resource.p" + "roto\032)google/cloud/documentai/v1/documen" + "t.proto\032,google/cloud/documentai/v1/docu" - + "ment_io.proto\032#google/longrunning/operat" - + "ions.proto\032 google/protobuf/field_mask.p" - + "roto\032\037google/protobuf/timestamp.proto\032\027g" - + "oogle/rpc/status.proto\"\362\001\n\016ProcessReques" - + "t\022?\n\017inline_document\030\004 \001(\0132$.google.clou" - + "d.documentai.v1.DocumentH\000\022?\n\014raw_docume" - + "nt\030\005 \001(\0132\'.google.cloud.documentai.v1.Ra" - + "wDocumentH\000\0229\n\004name\030\001 \001(\tB+\340A\002\372A%\n#docum" - + "entai.googleapis.com/Processor\022\031\n\021skip_h" - + "uman_review\030\003 \001(\010B\010\n\006source\"\356\001\n\021HumanRev" - + "iewStatus\022B\n\005state\030\001 \001(\01623.google.cloud." - + "documentai.v1.HumanReviewStatus.State\022\025\n" - + "\rstate_message\030\002 \001(\t\022\036\n\026human_review_ope" - + "ration\030\003 \001(\t\"^\n\005State\022\025\n\021STATE_UNSPECIFI" - + "ED\020\000\022\013\n\007SKIPPED\020\001\022\025\n\021VALIDATION_PASSED\020\002" - + "\022\017\n\013IN_PROGRESS\020\003\022\t\n\005ERROR\020\004\"\225\001\n\017Process" - + "Response\0226\n\010document\030\001 \001(\0132$.google.clou" - + "d.documentai.v1.Document\022J\n\023human_review" - + "_status\030\003 \001(\0132-.google.cloud.documentai." - + "v1.HumanReviewStatus\"\215\002\n\023BatchProcessReq" - + "uest\0229\n\004name\030\001 \001(\tB+\340A\002\372A%\n#documentai.g" - + "oogleapis.com/Processor\022N\n\017input_documen" - + "ts\030\005 \001(\01325.google.cloud.documentai.v1.Ba" - + "tchDocumentsInputConfig\022P\n\026document_outp" - + "ut_config\030\006 \001(\01320.google.cloud.documenta" - + "i.v1.DocumentOutputConfig\022\031\n\021skip_human_" - + "review\030\004 \001(\010\"\026\n\024BatchProcessResponse\"\377\004\n" - + "\024BatchProcessMetadata\022E\n\005state\030\001 \001(\01626.g" - + "oogle.cloud.documentai.v1.BatchProcessMe" - + "tadata.State\022\025\n\rstate_message\030\002 \001(\t\022/\n\013c" - + "reate_time\030\003 \001(\0132\032.google.protobuf.Times" - + "tamp\022/\n\013update_time\030\004 \001(\0132\032.google.proto" - + "buf.Timestamp\022m\n\033individual_process_stat" - + "uses\030\005 \003(\0132H.google.cloud.documentai.v1." - + "BatchProcessMetadata.IndividualProcessSt" - + "atus\032\303\001\n\027IndividualProcessStatus\022\030\n\020inpu" - + "t_gcs_source\030\001 \001(\t\022\"\n\006status\030\002 \001(\0132\022.goo" - + "gle.rpc.Status\022\036\n\026output_gcs_destination" - + "\030\003 \001(\t\022J\n\023human_review_status\030\005 \001(\0132-.go" - + "ogle.cloud.documentai.v1.HumanReviewStat" - + "us\"r\n\005State\022\025\n\021STATE_UNSPECIFIED\020\000\022\013\n\007WA" - + "ITING\020\001\022\013\n\007RUNNING\020\002\022\r\n\tSUCCEEDED\020\003\022\016\n\nC" - + "ANCELLING\020\004\022\r\n\tCANCELLED\020\005\022\n\n\006FAILED\020\006\"\264" - + "\001\n\025ReviewDocumentRequest\022?\n\017inline_docum" - + "ent\030\004 \001(\0132$.google.cloud.documentai.v1.D" - + "ocumentH\000\022P\n\023human_review_config\030\001 \001(\tB3" - + "\340A\002\372A-\n+documentai.googleapis.com/HumanR" - + "eviewConfigB\010\n\006source\"1\n\026ReviewDocumentR" - + "esponse\022\027\n\017gcs_destination\030\001 \001(\t\"o\n\037Revi" - + "ewDocumentOperationMetadata\022L\n\017common_me" - + "tadata\030\005 \001(\01323.google.cloud.documentai.v" - + "1.CommonOperationMetadata\"\303\002\n\027CommonOper" - + "ationMetadata\022H\n\005state\030\001 \001(\01629.google.cl" - + "oud.documentai.v1.CommonOperationMetadat" - + "a.State\022\025\n\rstate_message\030\002 \001(\t\022/\n\013create" - + "_time\030\003 \001(\0132\032.google.protobuf.Timestamp\022" - + "/\n\013update_time\030\004 \001(\0132\032.google.protobuf.T" - + "imestamp\"e\n\005State\022\025\n\021STATE_UNSPECIFIED\020\000" - + "\022\013\n\007RUNNING\020\001\022\016\n\nCANCELLING\020\002\022\r\n\tSUCCEED" - + "ED\020\003\022\n\n\006FAILED\020\004\022\r\n\tCANCELLED\020\0052\253\006\n\030Docu" - + "mentProcessorService\022\264\001\n\017ProcessDocument" - + "\022*.google.cloud.documentai.v1.ProcessReq" - + "uest\032+.google.cloud.documentai.v1.Proces" - + "sResponse\"H\202\323\344\223\002;\"6/v1/{name=projects/*/" - + "locations/*/processors/*}:process:\001*\332A\004n" - + "ame\022\345\001\n\025BatchProcessDocuments\022/.google.c" - + "loud.documentai.v1.BatchProcessRequest\032\035" - + ".google.longrunning.Operation\"|\202\323\344\223\002@\";/" - + "v1/{name=projects/*/locations/*/processo" - + "rs/*}:batchProcess:\001*\332A\004name\312A,\n\024BatchPr" - + "ocessResponse\022\024BatchProcessMetadata\022\240\002\n\016" - + "ReviewDocument\0221.google.cloud.documentai" - + ".v1.ReviewDocumentRequest\032\035.google.longr" - + "unning.Operation\"\273\001\202\323\344\223\002c\"^/v1/{human_re" - + "view_config=projects/*/locations/*/proce" - + "ssors/*/humanReviewConfig}:reviewDocumen" - + "t:\001*\332A\023human_review_config\312A9\n\026ReviewDoc" - + "umentResponse\022\037ReviewDocumentOperationMe" - + "tadata\032M\312A\031documentai.googleapis.com\322A.h" - + "ttps://www.googleapis.com/auth/cloud-pla" - + "tformB\230\004\n\036com.google.cloud.documentai.v1" - + "B\032DocumentAiProcessorServiceP\001ZDgoogle.g" - + "olang.org/genproto/googleapis/cloud/docu" - + "mentai/v1;documentai\252\002\032Google.Cloud.Docu" - + "mentAI.V1\312\002\032Google\\Cloud\\DocumentAI\\V1\352\002" - + "\035Google::Cloud::DocumentAI::V1\352AM\n\"docum" - + "entai.googleapis.com/Location\022\'projects/" - + "{project}/locations/{location}\352Ae\n#docum" - + "entai.googleapis.com/Processor\022>projects" - + "/{project}/locations/{location}/processo" - + "rs/{processor}\352A\177\n+documentai.googleapis" - + ".com/HumanReviewConfig\022Pprojects/{projec" - + "t}/locations/{location}/processors/{proc" - + "essor}/humanReviewConfigb\006proto3" + + "ment_io.proto\0323google/cloud/documentai/v" + + "1/operation_metadata.proto\032#google/longr" + + "unning/operations.proto\032 google/protobuf" + + "/field_mask.proto\032\037google/protobuf/times" + + "tamp.proto\032\027google/rpc/status.proto\"\362\001\n\016" + + "ProcessRequest\022?\n\017inline_document\030\004 \001(\0132" + + "$.google.cloud.documentai.v1.DocumentH\000\022" + + "?\n\014raw_document\030\005 \001(\0132\'.google.cloud.doc" + + "umentai.v1.RawDocumentH\000\0229\n\004name\030\001 \001(\tB+" + + "\340A\002\372A%\n#documentai.googleapis.com/Proces" + + "sor\022\031\n\021skip_human_review\030\003 \001(\010B\010\n\006source" + + "\"\356\001\n\021HumanReviewStatus\022B\n\005state\030\001 \001(\01623." + + "google.cloud.documentai.v1.HumanReviewSt" + + "atus.State\022\025\n\rstate_message\030\002 \001(\t\022\036\n\026hum" + + "an_review_operation\030\003 \001(\t\"^\n\005State\022\025\n\021ST" + + "ATE_UNSPECIFIED\020\000\022\013\n\007SKIPPED\020\001\022\025\n\021VALIDA" + + "TION_PASSED\020\002\022\017\n\013IN_PROGRESS\020\003\022\t\n\005ERROR\020" + + "\004\"\225\001\n\017ProcessResponse\0226\n\010document\030\001 \001(\0132" + + "$.google.cloud.documentai.v1.Document\022J\n" + + "\023human_review_status\030\003 \001(\0132-.google.clou" + + "d.documentai.v1.HumanReviewStatus\"\215\002\n\023Ba" + + "tchProcessRequest\0229\n\004name\030\001 \001(\tB+\340A\002\372A%\n" + + "#documentai.googleapis.com/Processor\022N\n\017" + + "input_documents\030\005 \001(\01325.google.cloud.doc" + + "umentai.v1.BatchDocumentsInputConfig\022P\n\026" + + "document_output_config\030\006 \001(\01320.google.cl" + + "oud.documentai.v1.DocumentOutputConfig\022\031" + + "\n\021skip_human_review\030\004 \001(\010\"\026\n\024BatchProces" + + "sResponse\"\377\004\n\024BatchProcessMetadata\022E\n\005st" + + "ate\030\001 \001(\01626.google.cloud.documentai.v1.B" + + "atchProcessMetadata.State\022\025\n\rstate_messa" + + "ge\030\002 \001(\t\022/\n\013create_time\030\003 \001(\0132\032.google.p" + + "rotobuf.Timestamp\022/\n\013update_time\030\004 \001(\0132\032" + + ".google.protobuf.Timestamp\022m\n\033individual" + + "_process_statuses\030\005 \003(\0132H.google.cloud.d" + + "ocumentai.v1.BatchProcessMetadata.Indivi" + + "dualProcessStatus\032\303\001\n\027IndividualProcessS" + + "tatus\022\030\n\020input_gcs_source\030\001 \001(\t\022\"\n\006statu" + + "s\030\002 \001(\0132\022.google.rpc.Status\022\036\n\026output_gc" + + "s_destination\030\003 \001(\t\022J\n\023human_review_stat" + + "us\030\005 \001(\0132-.google.cloud.documentai.v1.Hu" + + "manReviewStatus\"r\n\005State\022\025\n\021STATE_UNSPEC" + + "IFIED\020\000\022\013\n\007WAITING\020\001\022\013\n\007RUNNING\020\002\022\r\n\tSUC" + + "CEEDED\020\003\022\016\n\nCANCELLING\020\004\022\r\n\tCANCELLED\020\005\022" + + "\n\n\006FAILED\020\006\"\264\001\n\025ReviewDocumentRequest\022?\n" + + "\017inline_document\030\004 \001(\0132$.google.cloud.do" + + "cumentai.v1.DocumentH\000\022P\n\023human_review_c" + + "onfig\030\001 \001(\tB3\340A\002\372A-\n+documentai.googleap" + + "is.com/HumanReviewConfigB\010\n\006source\"1\n\026Re" + + "viewDocumentResponse\022\027\n\017gcs_destination\030" + + "\001 \001(\t\"o\n\037ReviewDocumentOperationMetadata" + + "\022L\n\017common_metadata\030\005 \001(\01323.google.cloud" + + ".documentai.v1.CommonOperationMetadata2\253" + + "\006\n\030DocumentProcessorService\022\264\001\n\017ProcessD" + + "ocument\022*.google.cloud.documentai.v1.Pro" + + "cessRequest\032+.google.cloud.documentai.v1" + + ".ProcessResponse\"H\202\323\344\223\002;\"6/v1/{name=proj" + + "ects/*/locations/*/processors/*}:process" + + ":\001*\332A\004name\022\345\001\n\025BatchProcessDocuments\022/.g" + + "oogle.cloud.documentai.v1.BatchProcessRe" + + "quest\032\035.google.longrunning.Operation\"|\202\323" + + "\344\223\002@\";/v1/{name=projects/*/locations/*/p" + + "rocessors/*}:batchProcess:\001*\332A\004name\312A,\n\024" + + "BatchProcessResponse\022\024BatchProcessMetada" + + "ta\022\240\002\n\016ReviewDocument\0221.google.cloud.doc" + + "umentai.v1.ReviewDocumentRequest\032\035.googl" + + "e.longrunning.Operation\"\273\001\202\323\344\223\002c\"^/v1/{h" + + "uman_review_config=projects/*/locations/" + + "*/processors/*/humanReviewConfig}:review" + + "Document:\001*\332A\023human_review_config\312A9\n\026Re" + + "viewDocumentResponse\022\037ReviewDocumentOper" + + "ationMetadata\032M\312A\031documentai.googleapis." + + "com\322A.https://www.googleapis.com/auth/cl" + + "oud-platformB\230\004\n\036com.google.cloud.docume" + + "ntai.v1B\032DocumentAiProcessorServiceP\001ZDg" + + "oogle.golang.org/genproto/googleapis/clo" + + "ud/documentai/v1;documentai\252\002\032Google.Clo" + + "ud.DocumentAI.V1\312\002\032Google\\Cloud\\Document" + + "AI\\V1\352\002\035Google::Cloud::DocumentAI::V1\352AM" + + "\n\"documentai.googleapis.com/Location\022\'pr" + + "ojects/{project}/locations/{location}\352Ae" + + "\n#documentai.googleapis.com/Processor\022>p" + + "rojects/{project}/locations/{location}/p" + + "rocessors/{processor}\352A\177\n+documentai.goo" + + "gleapis.com/HumanReviewConfig\022Pprojects/" + + "{project}/locations/{location}/processor" + + "s/{processor}/humanReviewConfigb\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -192,6 +181,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.ResourceProto.getDescriptor(), com.google.cloud.documentai.v1.DocumentProto.getDescriptor(), com.google.cloud.documentai.v1.DocumentIoProto.getDescriptor(), + com.google.cloud.documentai.v1.OperationMetadataProto.getDescriptor(), com.google.longrunning.OperationsProto.getDescriptor(), com.google.protobuf.FieldMaskProto.getDescriptor(), com.google.protobuf.TimestampProto.getDescriptor(), @@ -277,14 +267,6 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "CommonMetadata", }); - internal_static_google_cloud_documentai_v1_CommonOperationMetadata_descriptor = - getDescriptor().getMessageTypes().get(9); - internal_static_google_cloud_documentai_v1_CommonOperationMetadata_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_documentai_v1_CommonOperationMetadata_descriptor, - new java.lang.String[] { - "State", "StateMessage", "CreateTime", "UpdateTime", - }); com.google.protobuf.ExtensionRegistry registry = com.google.protobuf.ExtensionRegistry.newInstance(); registry.add(com.google.api.ClientProto.defaultHost); @@ -303,6 +285,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.ResourceProto.getDescriptor(); com.google.cloud.documentai.v1.DocumentProto.getDescriptor(); com.google.cloud.documentai.v1.DocumentIoProto.getDescriptor(); + com.google.cloud.documentai.v1.OperationMetadataProto.getDescriptor(); com.google.longrunning.OperationsProto.getDescriptor(); com.google.protobuf.FieldMaskProto.getDescriptor(); com.google.protobuf.TimestampProto.getDescriptor(); diff --git a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/NormalizedVertex.java b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/NormalizedVertex.java index df17f1d0..d861d18d 100644 --- a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/NormalizedVertex.java +++ b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/NormalizedVertex.java @@ -138,7 +138,7 @@ public float getX() { * * *
-   * Y coordinate.
+   * Y coordinate (starts from the top of the image).
    * 
* * float y = 2; @@ -542,7 +542,7 @@ public Builder clearX() { * * *
-     * Y coordinate.
+     * Y coordinate (starts from the top of the image).
      * 
* * float y = 2; @@ -557,7 +557,7 @@ public float getY() { * * *
-     * Y coordinate.
+     * Y coordinate (starts from the top of the image).
      * 
* * float y = 2; @@ -575,7 +575,7 @@ public Builder setY(float value) { * * *
-     * Y coordinate.
+     * Y coordinate (starts from the top of the image).
      * 
* * float y = 2; diff --git a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/NormalizedVertexOrBuilder.java b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/NormalizedVertexOrBuilder.java index 21cad2d9..bba4e87e 100644 --- a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/NormalizedVertexOrBuilder.java +++ b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/NormalizedVertexOrBuilder.java @@ -40,7 +40,7 @@ public interface NormalizedVertexOrBuilder * * *
-   * Y coordinate.
+   * Y coordinate (starts from the top of the image).
    * 
* * float y = 2; diff --git a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/OperationMetadataProto.java b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/OperationMetadataProto.java new file mode 100644 index 00000000..f4dd8f92 --- /dev/null +++ b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/OperationMetadataProto.java @@ -0,0 +1,82 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/documentai/v1/operation_metadata.proto + +package com.google.cloud.documentai.v1; + +public final class OperationMetadataProto { + private OperationMetadataProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_documentai_v1_CommonOperationMetadata_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_documentai_v1_CommonOperationMetadata_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n3google/cloud/documentai/v1/operation_m" + + "etadata.proto\022\032google.cloud.documentai.v" + + "1\032\037google/protobuf/timestamp.proto\032\034goog" + + "le/api/annotations.proto\"\303\002\n\027CommonOpera" + + "tionMetadata\022H\n\005state\030\001 \001(\01629.google.clo" + + "ud.documentai.v1.CommonOperationMetadata" + + ".State\022\025\n\rstate_message\030\002 \001(\t\022/\n\013create_" + + "time\030\003 \001(\0132\032.google.protobuf.Timestamp\022/" + + "\n\013update_time\030\004 \001(\0132\032.google.protobuf.Ti" + + "mestamp\"e\n\005State\022\025\n\021STATE_UNSPECIFIED\020\000\022" + + "\013\n\007RUNNING\020\001\022\016\n\nCANCELLING\020\002\022\r\n\tSUCCEEDE" + + "D\020\003\022\n\n\006FAILED\020\004\022\r\n\tCANCELLED\020\005B\332\001\n\036com.g" + + "oogle.cloud.documentai.v1B\026OperationMeta" + + "dataProtoP\001ZDgoogle.golang.org/genproto/" + + "googleapis/cloud/documentai/v1;documenta" + + "i\252\002\032Google.Cloud.DocumentAI.V1\312\002\032Google\\" + + "Cloud\\DocumentAI\\V1\352\002\035Google::Cloud::Doc" + + "umentAI::V1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.protobuf.TimestampProto.getDescriptor(), + com.google.api.AnnotationsProto.getDescriptor(), + }); + internal_static_google_cloud_documentai_v1_CommonOperationMetadata_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_documentai_v1_CommonOperationMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_documentai_v1_CommonOperationMetadata_descriptor, + new java.lang.String[] { + "State", "StateMessage", "CreateTime", "UpdateTime", + }); + com.google.protobuf.TimestampProto.getDescriptor(); + com.google.api.AnnotationsProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/Vertex.java b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/Vertex.java index 71de4910..ba7c7be5 100644 --- a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/Vertex.java +++ b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/Vertex.java @@ -137,7 +137,7 @@ public int getX() { * * *
-   * Y coordinate.
+   * Y coordinate (starts from the top of the image).
    * 
* * int32 y = 2; @@ -535,7 +535,7 @@ public Builder clearX() { * * *
-     * Y coordinate.
+     * Y coordinate (starts from the top of the image).
      * 
* * int32 y = 2; @@ -550,7 +550,7 @@ public int getY() { * * *
-     * Y coordinate.
+     * Y coordinate (starts from the top of the image).
      * 
* * int32 y = 2; @@ -568,7 +568,7 @@ public Builder setY(int value) { * * *
-     * Y coordinate.
+     * Y coordinate (starts from the top of the image).
      * 
* * int32 y = 2; diff --git a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/VertexOrBuilder.java b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/VertexOrBuilder.java index 99b55ee4..08534b37 100644 --- a/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/VertexOrBuilder.java +++ b/proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/VertexOrBuilder.java @@ -40,7 +40,7 @@ public interface VertexOrBuilder * * *
-   * Y coordinate.
+   * Y coordinate (starts from the top of the image).
    * 
* * int32 y = 2; diff --git a/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/document_processor_service.proto b/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/document_processor_service.proto index 033b3cb7..9f0b11a7 100644 --- a/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/document_processor_service.proto +++ b/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/document_processor_service.proto @@ -22,6 +22,7 @@ import "google/api/field_behavior.proto"; import "google/api/resource.proto"; import "google/cloud/documentai/v1/document.proto"; import "google/cloud/documentai/v1/document_io.proto"; +import "google/cloud/documentai/v1/operation_metadata.proto"; import "google/longrunning/operations.proto"; import "google/protobuf/field_mask.proto"; import "google/protobuf/timestamp.proto"; @@ -280,39 +281,3 @@ message ReviewDocumentOperationMetadata { // The basic metadata of the long running operation. CommonOperationMetadata common_metadata = 5; } - -// The common metadata for long running operations. -message CommonOperationMetadata { - // State of the longrunning operation. - enum State { - // Unspecified state. - STATE_UNSPECIFIED = 0; - - // Operation is still running. - RUNNING = 1; - - // Operation is being cancelled. - CANCELLING = 2; - - // Operation succeeded. - SUCCEEDED = 3; - - // Operation failed. - FAILED = 4; - - // Operation is cancelled. - CANCELLED = 5; - } - - // The state of the operation. - State state = 1; - - // A message providing more details about the current state of processing. - string state_message = 2; - - // The creation time of the operation. - google.protobuf.Timestamp create_time = 3; - - // The last update time of the operation. - google.protobuf.Timestamp update_time = 4; -} diff --git a/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/geometry.proto b/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/geometry.proto index 779e9664..19ced507 100644 --- a/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/geometry.proto +++ b/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/geometry.proto @@ -32,7 +32,7 @@ message Vertex { // X coordinate. int32 x = 1; - // Y coordinate. + // Y coordinate (starts from the top of the image). int32 y = 2; } @@ -43,7 +43,7 @@ message NormalizedVertex { // X coordinate. float x = 1; - // Y coordinate. + // Y coordinate (starts from the top of the image). float y = 2; } diff --git a/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/operation_metadata.proto b/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/operation_metadata.proto new file mode 100644 index 00000000..503451bf --- /dev/null +++ b/proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/operation_metadata.proto @@ -0,0 +1,64 @@ +// Copyright 2021 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +syntax = "proto3"; + +package google.cloud.documentai.v1; + +import "google/protobuf/timestamp.proto"; +import "google/api/annotations.proto"; + +option csharp_namespace = "Google.Cloud.DocumentAI.V1"; +option go_package = "google.golang.org/genproto/googleapis/cloud/documentai/v1;documentai"; +option java_multiple_files = true; +option java_outer_classname = "OperationMetadataProto"; +option java_package = "com.google.cloud.documentai.v1"; +option php_namespace = "Google\\Cloud\\DocumentAI\\V1"; +option ruby_package = "Google::Cloud::DocumentAI::V1"; + +// The common metadata for long running operations. +message CommonOperationMetadata { + // State of the longrunning operation. + enum State { + // Unspecified state. + STATE_UNSPECIFIED = 0; + + // Operation is still running. + RUNNING = 1; + + // Operation is being cancelled. + CANCELLING = 2; + + // Operation succeeded. + SUCCEEDED = 3; + + // Operation failed. + FAILED = 4; + + // Operation is cancelled. + CANCELLED = 5; + } + + // The state of the operation. + State state = 1; + + // A message providing more details about the current state of processing. + string state_message = 2; + + // The creation time of the operation. + google.protobuf.Timestamp create_time = 3; + + // The last update time of the operation. + google.protobuf.Timestamp update_time = 4; +} diff --git a/synth.metadata b/synth.metadata index 24056870..44d11978 100644 --- a/synth.metadata +++ b/synth.metadata @@ -4,39 +4,39 @@ "git": { "name": ".", "remote": "https://github.com/googleapis/java-document-ai.git", - "sha": "dd8a78652d562c51b6a3b4f5e015f7c8622d6380" + "sha": "aad8db8c46e83ec2b488734432d1465711ac0429" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "204809ddb580527550e61a7ca524e837b5a8409d", - "internalRef": "377114643" + "sha": "3e0f7ebfbbd2344412e7622fab4bc0c9004c5932", + "internalRef": "377562108" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "204809ddb580527550e61a7ca524e837b5a8409d", - "internalRef": "377114643" + "sha": "3e0f7ebfbbd2344412e7622fab4bc0c9004c5932", + "internalRef": "377562108" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "204809ddb580527550e61a7ca524e837b5a8409d", - "internalRef": "377114643" + "sha": "3e0f7ebfbbd2344412e7622fab4bc0c9004c5932", + "internalRef": "377562108" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "204809ddb580527550e61a7ca524e837b5a8409d", - "internalRef": "377114643" + "sha": "3e0f7ebfbbd2344412e7622fab4bc0c9004c5932", + "internalRef": "377562108" } }, { @@ -234,6 +234,7 @@ "proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/HumanReviewStatusOrBuilder.java", "proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/NormalizedVertex.java", "proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/NormalizedVertexOrBuilder.java", + "proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/OperationMetadataProto.java", "proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/ProcessRequest.java", "proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/ProcessRequestOrBuilder.java", "proto-google-cloud-document-ai-v1/src/main/java/com/google/cloud/documentai/v1/ProcessResponse.java", @@ -253,6 +254,7 @@ "proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/document_io.proto", "proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/document_processor_service.proto", "proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/geometry.proto", + "proto-google-cloud-document-ai-v1/src/main/proto/google/cloud/documentai/v1/operation_metadata.proto", "proto-google-cloud-document-ai-v1beta1/src/main/java/com/google/cloud/documentai/v1beta1/BatchProcessDocumentsRequest.java", "proto-google-cloud-document-ai-v1beta1/src/main/java/com/google/cloud/documentai/v1beta1/BatchProcessDocumentsRequestOrBuilder.java", "proto-google-cloud-document-ai-v1beta1/src/main/java/com/google/cloud/documentai/v1beta1/BatchProcessDocumentsResponse.java",