Send feedback
Class Document (2.3.3)
Stay organized with collections
Save and categorize content based on your preferences.
Version 2.3.3 keyboard_arrow_down
public final class Document extends GeneratedMessageV3 implements DocumentOrBuilder
A structured text document e.g. a PDF.
Protobuf type google.cloud.automl.v1.Document
Static Fields
DOCUMENT_DIMENSIONS_FIELD_NUMBER
public static final int DOCUMENT_DIMENSIONS_FIELD_NUMBER
Field Value
DOCUMENT_TEXT_FIELD_NUMBER
public static final int DOCUMENT_TEXT_FIELD_NUMBER
Field Value
public static final int INPUT_CONFIG_FIELD_NUMBER
Field Value
LAYOUT_FIELD_NUMBER
public static final int LAYOUT_FIELD_NUMBER
Field Value
PAGE_COUNT_FIELD_NUMBER
public static final int PAGE_COUNT_FIELD_NUMBER
Field Value
Static Methods
getDefaultInstance()
public static Document getDefaultInstance ()
Returns
getDescriptor()
public static final Descriptors . Descriptor getDescriptor ()
Returns
newBuilder()
public static Document . Builder newBuilder ()
Returns
newBuilder(Document prototype)
public static Document . Builder newBuilder ( Document prototype )
Parameter
Returns
public static Document parseDelimitedFrom ( InputStream input )
Parameter
Returns
Exceptions
public static Document parseDelimitedFrom ( InputStream input , ExtensionRegistryLite extensionRegistry )
Parameters
Returns
Exceptions
parseFrom(byte[] data)
public static Document parseFrom ( byte [] data )
Parameter
Name Description data byte []
Returns
Exceptions
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static Document parseFrom ( byte [] data , ExtensionRegistryLite extensionRegistry )
Parameters
Returns
Exceptions
parseFrom(ByteString data)
public static Document parseFrom ( ByteString data )
Parameter
Returns
Exceptions
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Document parseFrom ( ByteString data , ExtensionRegistryLite extensionRegistry )
Parameters
Returns
Exceptions
public static Document parseFrom ( CodedInputStream input )
Parameter
Returns
Exceptions
public static Document parseFrom ( CodedInputStream input , ExtensionRegistryLite extensionRegistry )
Parameters
Returns
Exceptions
public static Document parseFrom ( InputStream input )
Parameter
Returns
Exceptions
public static Document parseFrom ( InputStream input , ExtensionRegistryLite extensionRegistry )
Parameters
Returns
Exceptions
parseFrom(ByteBuffer data)
public static Document parseFrom ( ByteBuffer data )
Parameter
Returns
Exceptions
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static Document parseFrom ( ByteBuffer data , ExtensionRegistryLite extensionRegistry )
Parameters
Returns
Exceptions
parser()
public static Parser<Document> parser ()
Returns
Methods
equals(Object obj)
public boolean equals ( Object obj )
Parameter
Returns
Overrides
getDefaultInstanceForType()
public Document getDefaultInstanceForType ()
Returns
getDocumentDimensions()
public DocumentDimensions getDocumentDimensions ()
The dimensions of the page in the document.
.google.cloud.automl.v1.DocumentDimensions document_dimensions = 4;
Returns
getDocumentDimensionsOrBuilder()
public DocumentDimensionsOrBuilder getDocumentDimensionsOrBuilder ()
The dimensions of the page in the document.
.google.cloud.automl.v1.DocumentDimensions document_dimensions = 4;
Returns
getDocumentText()
public TextSnippet getDocumentText ()
The plain text version of this document.
.google.cloud.automl.v1.TextSnippet document_text = 2;
Returns
getDocumentTextOrBuilder()
public TextSnippetOrBuilder getDocumentTextOrBuilder ()
The plain text version of this document.
.google.cloud.automl.v1.TextSnippet document_text = 2;
Returns
public DocumentInputConfig getInputConfig ()
An input config specifying the content of the document.
.google.cloud.automl.v1.DocumentInputConfig input_config = 1;
Returns
public DocumentInputConfigOrBuilder getInputConfigOrBuilder ()
An input config specifying the content of the document.
.google.cloud.automl.v1.DocumentInputConfig input_config = 1;
Returns
getLayout(int index)
public Document . Layout getLayout ( int index )
Describes the layout of the document.
Sorted by [page_number][].
repeated .google.cloud.automl.v1.Document.Layout layout = 3;
Parameter
Returns
getLayoutCount()
public int getLayoutCount ()
Describes the layout of the document.
Sorted by [page_number][].
repeated .google.cloud.automl.v1.Document.Layout layout = 3;
Returns
getLayoutList()
public List<Document . Layout > getLayoutList ()
Describes the layout of the document.
Sorted by [page_number][].
repeated .google.cloud.automl.v1.Document.Layout layout = 3;
Returns
getLayoutOrBuilder(int index)
public Document . LayoutOrBuilder getLayoutOrBuilder ( int index )
Describes the layout of the document.
Sorted by [page_number][].
repeated .google.cloud.automl.v1.Document.Layout layout = 3;
Parameter
Returns
getLayoutOrBuilderList()
public List <? extends Document . LayoutOrBuilder > getLayoutOrBuilderList ()
Describes the layout of the document.
Sorted by [page_number][].
repeated .google.cloud.automl.v1.Document.Layout layout = 3;
Returns
Type Description List <? extends com.google.cloud.automl.v1.Document.LayoutOrBuilder >
getPageCount()
public int getPageCount ()
Number of pages in the document.
int32 page_count = 5;
Returns
Type Description int The pageCount.
getParserForType()
public Parser<Document> getParserForType ()
Returns
Overrides
getSerializedSize()
public int getSerializedSize ()
Returns
Overrides
getUnknownFields()
public final UnknownFieldSet getUnknownFields ()
Returns
Overrides
hasDocumentDimensions()
public boolean hasDocumentDimensions ()
The dimensions of the page in the document.
.google.cloud.automl.v1.DocumentDimensions document_dimensions = 4;
Returns
Type Description boolean Whether the documentDimensions field is set.
hasDocumentText()
public boolean hasDocumentText ()
The plain text version of this document.
.google.cloud.automl.v1.TextSnippet document_text = 2;
Returns
Type Description boolean Whether the documentText field is set.
public boolean hasInputConfig ()
An input config specifying the content of the document.
.google.cloud.automl.v1.DocumentInputConfig input_config = 1;
Returns
Type Description boolean Whether the inputConfig field is set.
hashCode()
Returns
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3 . FieldAccessorTable internalGetFieldAccessorTable ()
Returns
Overrides
isInitialized()
public final boolean isInitialized ()
Returns
Overrides
newBuilderForType()
public Document . Builder newBuilderForType ()
Returns
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected Document . Builder newBuilderForType ( GeneratedMessageV3 . BuilderParent parent )
Parameter
Returns
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance ( GeneratedMessageV3 . UnusedPrivateParameter unused )
Parameter
Returns
Overrides
toBuilder()
public Document . Builder toBuilder ()
Returns
writeTo(CodedOutputStream output)
public void writeTo ( CodedOutputStream output )
Parameter
Overrides
Exceptions
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-01-27 UTC.
Need to tell us more?
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-01-27 UTC."],[],[]]