Interface DocumentOrBuilder (2.36.0)

public interface DocumentOrBuilder extends MessageOrBuilder

Implements

MessageOrBuilder

Methods

getContent()

public abstract ByteString getContent()

Optional. Inline document content, represented as a stream of bytes. Note: As with all bytes fields, protobuffers use a pure binary representation, whereas JSON representations use base64.

bytes content = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ByteString

The content.

getEntities(int index)

public abstract Document.Entity getEntities(int index)

A list of entities detected on Document.text. For document shards, entities in this list may cross shard boundaries.

repeated .google.cloud.documentai.v1beta2.Document.Entity entities = 7;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.Entity

getEntitiesCount()

public abstract int getEntitiesCount()

A list of entities detected on Document.text. For document shards, entities in this list may cross shard boundaries.

repeated .google.cloud.documentai.v1beta2.Document.Entity entities = 7;

Returns
TypeDescription
int

getEntitiesList()

public abstract List<Document.Entity> getEntitiesList()

A list of entities detected on Document.text. For document shards, entities in this list may cross shard boundaries.

repeated .google.cloud.documentai.v1beta2.Document.Entity entities = 7;

Returns
TypeDescription
List<Entity>

getEntitiesOrBuilder(int index)

public abstract Document.EntityOrBuilder getEntitiesOrBuilder(int index)

A list of entities detected on Document.text. For document shards, entities in this list may cross shard boundaries.

repeated .google.cloud.documentai.v1beta2.Document.Entity entities = 7;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.EntityOrBuilder

getEntitiesOrBuilderList()

public abstract List<? extends Document.EntityOrBuilder> getEntitiesOrBuilderList()

A list of entities detected on Document.text. For document shards, entities in this list may cross shard boundaries.

repeated .google.cloud.documentai.v1beta2.Document.Entity entities = 7;

Returns
TypeDescription
List<? extends com.google.cloud.documentai.v1beta2.Document.EntityOrBuilder>

getEntityRelations(int index)

public abstract Document.EntityRelation getEntityRelations(int index)

Placeholder. Relationship among Document.entities.

repeated .google.cloud.documentai.v1beta2.Document.EntityRelation entity_relations = 8;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.EntityRelation

getEntityRelationsCount()

public abstract int getEntityRelationsCount()

Placeholder. Relationship among Document.entities.

repeated .google.cloud.documentai.v1beta2.Document.EntityRelation entity_relations = 8;

Returns
TypeDescription
int

getEntityRelationsList()

public abstract List<Document.EntityRelation> getEntityRelationsList()

Placeholder. Relationship among Document.entities.

repeated .google.cloud.documentai.v1beta2.Document.EntityRelation entity_relations = 8;

Returns
TypeDescription
List<EntityRelation>

getEntityRelationsOrBuilder(int index)

public abstract Document.EntityRelationOrBuilder getEntityRelationsOrBuilder(int index)

Placeholder. Relationship among Document.entities.

repeated .google.cloud.documentai.v1beta2.Document.EntityRelation entity_relations = 8;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.EntityRelationOrBuilder

getEntityRelationsOrBuilderList()

public abstract List<? extends Document.EntityRelationOrBuilder> getEntityRelationsOrBuilderList()

Placeholder. Relationship among Document.entities.

repeated .google.cloud.documentai.v1beta2.Document.EntityRelation entity_relations = 8;

Returns
TypeDescription
List<? extends com.google.cloud.documentai.v1beta2.Document.EntityRelationOrBuilder>

getError()

public abstract Status getError()

Any error that occurred while processing this document.

.google.rpc.Status error = 10;

Returns
TypeDescription
com.google.rpc.Status

The error.

getErrorOrBuilder()

public abstract StatusOrBuilder getErrorOrBuilder()

Any error that occurred while processing this document.

.google.rpc.Status error = 10;

Returns
TypeDescription
com.google.rpc.StatusOrBuilder

getLabels(int index)

public abstract Document.Label getLabels(int index)

Labels for this document.

repeated .google.cloud.documentai.v1beta2.Document.Label labels = 11;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.Label

getLabelsCount()

public abstract int getLabelsCount()

Labels for this document.

repeated .google.cloud.documentai.v1beta2.Document.Label labels = 11;

Returns
TypeDescription
int

getLabelsList()

public abstract List<Document.Label> getLabelsList()

Labels for this document.

repeated .google.cloud.documentai.v1beta2.Document.Label labels = 11;

Returns
TypeDescription
List<Label>

getLabelsOrBuilder(int index)

public abstract Document.LabelOrBuilder getLabelsOrBuilder(int index)

Labels for this document.

repeated .google.cloud.documentai.v1beta2.Document.Label labels = 11;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.LabelOrBuilder

getLabelsOrBuilderList()

public abstract List<? extends Document.LabelOrBuilder> getLabelsOrBuilderList()

Labels for this document.

repeated .google.cloud.documentai.v1beta2.Document.Label labels = 11;

Returns
TypeDescription
List<? extends com.google.cloud.documentai.v1beta2.Document.LabelOrBuilder>

getMimeType()

public abstract String getMimeType()

An IANA published media type (MIME type).

string mime_type = 3;

Returns
TypeDescription
String

The mimeType.

getMimeTypeBytes()

public abstract ByteString getMimeTypeBytes()

An IANA published media type (MIME type).

string mime_type = 3;

Returns
TypeDescription
ByteString

The bytes for mimeType.

getPages(int index)

public abstract Document.Page getPages(int index)

Visual page layout for the Document.

repeated .google.cloud.documentai.v1beta2.Document.Page pages = 6;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.Page

getPagesCount()

public abstract int getPagesCount()

Visual page layout for the Document.

repeated .google.cloud.documentai.v1beta2.Document.Page pages = 6;

Returns
TypeDescription
int

getPagesList()

public abstract List<Document.Page> getPagesList()

Visual page layout for the Document.

repeated .google.cloud.documentai.v1beta2.Document.Page pages = 6;

Returns
TypeDescription
List<Page>

getPagesOrBuilder(int index)

public abstract Document.PageOrBuilder getPagesOrBuilder(int index)

Visual page layout for the Document.

repeated .google.cloud.documentai.v1beta2.Document.Page pages = 6;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.PageOrBuilder

getPagesOrBuilderList()

public abstract List<? extends Document.PageOrBuilder> getPagesOrBuilderList()

Visual page layout for the Document.

repeated .google.cloud.documentai.v1beta2.Document.Page pages = 6;

Returns
TypeDescription
List<? extends com.google.cloud.documentai.v1beta2.Document.PageOrBuilder>

getRevisions(int index)

public abstract Document.Revision getRevisions(int index)

Placeholder. Revision history of this document.

repeated .google.cloud.documentai.v1beta2.Document.Revision revisions = 13;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.Revision

getRevisionsCount()

public abstract int getRevisionsCount()

Placeholder. Revision history of this document.

repeated .google.cloud.documentai.v1beta2.Document.Revision revisions = 13;

Returns
TypeDescription
int

getRevisionsList()

public abstract List<Document.Revision> getRevisionsList()

Placeholder. Revision history of this document.

repeated .google.cloud.documentai.v1beta2.Document.Revision revisions = 13;

Returns
TypeDescription
List<Revision>

getRevisionsOrBuilder(int index)

public abstract Document.RevisionOrBuilder getRevisionsOrBuilder(int index)

Placeholder. Revision history of this document.

repeated .google.cloud.documentai.v1beta2.Document.Revision revisions = 13;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.RevisionOrBuilder

getRevisionsOrBuilderList()

public abstract List<? extends Document.RevisionOrBuilder> getRevisionsOrBuilderList()

Placeholder. Revision history of this document.

repeated .google.cloud.documentai.v1beta2.Document.Revision revisions = 13;

Returns
TypeDescription
List<? extends com.google.cloud.documentai.v1beta2.Document.RevisionOrBuilder>

getShardInfo()

public abstract Document.ShardInfo getShardInfo()

Information about the sharding if this document is sharded part of a larger document. If the document is not sharded, this message is not specified.

.google.cloud.documentai.v1beta2.Document.ShardInfo shard_info = 9;

Returns
TypeDescription
Document.ShardInfo

The shardInfo.

getShardInfoOrBuilder()

public abstract Document.ShardInfoOrBuilder getShardInfoOrBuilder()

Information about the sharding if this document is sharded part of a larger document. If the document is not sharded, this message is not specified.

.google.cloud.documentai.v1beta2.Document.ShardInfo shard_info = 9;

Returns
TypeDescription
Document.ShardInfoOrBuilder

getSourceCase()

public abstract Document.SourceCase getSourceCase()
Returns
TypeDescription
Document.SourceCase

getText()

public abstract String getText()

Optional. UTF-8 encoded text in reading order from the document.

string text = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
String

The text.

getTextBytes()

public abstract ByteString getTextBytes()

Optional. UTF-8 encoded text in reading order from the document.

string text = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ByteString

The bytes for text.

getTextChanges(int index)

public abstract Document.TextChange getTextChanges(int index)

Placeholder. A list of text corrections made to Document.text. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap with each other.

repeated .google.cloud.documentai.v1beta2.Document.TextChange text_changes = 14;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.TextChange

getTextChangesCount()

public abstract int getTextChangesCount()

Placeholder. A list of text corrections made to Document.text. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap with each other.

repeated .google.cloud.documentai.v1beta2.Document.TextChange text_changes = 14;

Returns
TypeDescription
int

getTextChangesList()

public abstract List<Document.TextChange> getTextChangesList()

Placeholder. A list of text corrections made to Document.text. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap with each other.

repeated .google.cloud.documentai.v1beta2.Document.TextChange text_changes = 14;

Returns
TypeDescription
List<TextChange>

getTextChangesOrBuilder(int index)

public abstract Document.TextChangeOrBuilder getTextChangesOrBuilder(int index)

Placeholder. A list of text corrections made to Document.text. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap with each other.

repeated .google.cloud.documentai.v1beta2.Document.TextChange text_changes = 14;

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.TextChangeOrBuilder

getTextChangesOrBuilderList()

public abstract List<? extends Document.TextChangeOrBuilder> getTextChangesOrBuilderList()

Placeholder. A list of text corrections made to Document.text. This is usually used for annotating corrections to OCR mistakes. Text changes for a given revision may not overlap with each other.

repeated .google.cloud.documentai.v1beta2.Document.TextChange text_changes = 14;

Returns
TypeDescription
List<? extends com.google.cloud.documentai.v1beta2.Document.TextChangeOrBuilder>

getTextStyles(int index) (deprecated)

public abstract Document.Style getTextStyles(int index)

Styles for the Document.text.

repeated .google.cloud.documentai.v1beta2.Document.Style text_styles = 5 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.Style

getTextStylesCount() (deprecated)

public abstract int getTextStylesCount()

Styles for the Document.text.

repeated .google.cloud.documentai.v1beta2.Document.Style text_styles = 5 [deprecated = true];

Returns
TypeDescription
int

getTextStylesList() (deprecated)

public abstract List<Document.Style> getTextStylesList()

Styles for the Document.text.

repeated .google.cloud.documentai.v1beta2.Document.Style text_styles = 5 [deprecated = true];

Returns
TypeDescription
List<Style>

getTextStylesOrBuilder(int index) (deprecated)

public abstract Document.StyleOrBuilder getTextStylesOrBuilder(int index)

Styles for the Document.text.

repeated .google.cloud.documentai.v1beta2.Document.Style text_styles = 5 [deprecated = true];

Parameter
NameDescription
indexint
Returns
TypeDescription
Document.StyleOrBuilder

getTextStylesOrBuilderList() (deprecated)

public abstract List<? extends Document.StyleOrBuilder> getTextStylesOrBuilderList()

Styles for the Document.text.

repeated .google.cloud.documentai.v1beta2.Document.Style text_styles = 5 [deprecated = true];

Returns
TypeDescription
List<? extends com.google.cloud.documentai.v1beta2.Document.StyleOrBuilder>

getUri()

public abstract String getUri()

Optional. Currently supports Google Cloud Storage URI of the form gs://bucket_name/object_name. Object versioning is not supported. For more information, refer to Google Cloud Storage Request URIs.

string uri = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
String

The uri.

getUriBytes()

public abstract ByteString getUriBytes()

Optional. Currently supports Google Cloud Storage URI of the form gs://bucket_name/object_name. Object versioning is not supported. For more information, refer to Google Cloud Storage Request URIs.

string uri = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ByteString

The bytes for uri.

hasContent()

public abstract boolean hasContent()

Optional. Inline document content, represented as a stream of bytes. Note: As with all bytes fields, protobuffers use a pure binary representation, whereas JSON representations use base64.

bytes content = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
boolean

Whether the content field is set.

hasError()

public abstract boolean hasError()

Any error that occurred while processing this document.

.google.rpc.Status error = 10;

Returns
TypeDescription
boolean

Whether the error field is set.

hasShardInfo()

public abstract boolean hasShardInfo()

Information about the sharding if this document is sharded part of a larger document. If the document is not sharded, this message is not specified.

.google.cloud.documentai.v1beta2.Document.ShardInfo shard_info = 9;

Returns
TypeDescription
boolean

Whether the shardInfo field is set.

hasUri()

public abstract boolean hasUri()

Optional. Currently supports Google Cloud Storage URI of the form gs://bucket_name/object_name. Object versioning is not supported. For more information, refer to Google Cloud Storage Request URIs.

string uri = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
boolean

Whether the uri field is set.