Class DocumentMetadata.Builder (2.45.0)

public static final class DocumentMetadata.Builder extends GeneratedMessageV3.Builder<DocumentMetadata.Builder> implements DocumentMetadataOrBuilder

Metadata about a document.

Protobuf type google.cloud.documentai.v1beta3.DocumentMetadata

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public DocumentMetadata.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
DocumentMetadata.Builder
Overrides

build()

public DocumentMetadata build()
Returns
TypeDescription
DocumentMetadata

buildPartial()

public DocumentMetadata buildPartial()
Returns
TypeDescription
DocumentMetadata

clear()

public DocumentMetadata.Builder clear()
Returns
TypeDescription
DocumentMetadata.Builder
Overrides

clearDatasetType()

public DocumentMetadata.Builder clearDatasetType()

Type of the dataset split to which the document belongs.

.google.cloud.documentai.v1beta3.DatasetSplitType dataset_type = 3;

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

clearDisplayName()

public DocumentMetadata.Builder clearDisplayName()

The display name of the document.

string display_name = 6;

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

clearDocumentId()

public DocumentMetadata.Builder clearDocumentId()

Document identifier.

.google.cloud.documentai.v1beta3.DocumentId document_id = 1;

Returns
TypeDescription
DocumentMetadata.Builder

clearField(Descriptors.FieldDescriptor field)

public DocumentMetadata.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
DocumentMetadata.Builder
Overrides

clearLabelingState()

public DocumentMetadata.Builder clearLabelingState()

Labeling state of the document.

.google.cloud.documentai.v1beta3.DocumentLabelingState labeling_state = 5;

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public DocumentMetadata.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
DocumentMetadata.Builder
Overrides

clearPageCount()

public DocumentMetadata.Builder clearPageCount()

Number of pages in the document.

int32 page_count = 2;

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

clone()

public DocumentMetadata.Builder clone()
Returns
TypeDescription
DocumentMetadata.Builder
Overrides

getDatasetType()

public DatasetSplitType getDatasetType()

Type of the dataset split to which the document belongs.

.google.cloud.documentai.v1beta3.DatasetSplitType dataset_type = 3;

Returns
TypeDescription
DatasetSplitType

The datasetType.

getDatasetTypeValue()

public int getDatasetTypeValue()

Type of the dataset split to which the document belongs.

.google.cloud.documentai.v1beta3.DatasetSplitType dataset_type = 3;

Returns
TypeDescription
int

The enum numeric value on the wire for datasetType.

getDefaultInstanceForType()

public DocumentMetadata getDefaultInstanceForType()
Returns
TypeDescription
DocumentMetadata

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getDisplayName()

public String getDisplayName()

The display name of the document.

string display_name = 6;

Returns
TypeDescription
String

The displayName.

getDisplayNameBytes()

public ByteString getDisplayNameBytes()

The display name of the document.

string display_name = 6;

Returns
TypeDescription
ByteString

The bytes for displayName.

getDocumentId()

public DocumentId getDocumentId()

Document identifier.

.google.cloud.documentai.v1beta3.DocumentId document_id = 1;

Returns
TypeDescription
DocumentId

The documentId.

getDocumentIdBuilder()

public DocumentId.Builder getDocumentIdBuilder()

Document identifier.

.google.cloud.documentai.v1beta3.DocumentId document_id = 1;

Returns
TypeDescription
DocumentId.Builder

getDocumentIdOrBuilder()

public DocumentIdOrBuilder getDocumentIdOrBuilder()

Document identifier.

.google.cloud.documentai.v1beta3.DocumentId document_id = 1;

Returns
TypeDescription
DocumentIdOrBuilder

getLabelingState()

public DocumentLabelingState getLabelingState()

Labeling state of the document.

.google.cloud.documentai.v1beta3.DocumentLabelingState labeling_state = 5;

Returns
TypeDescription
DocumentLabelingState

The labelingState.

getLabelingStateValue()

public int getLabelingStateValue()

Labeling state of the document.

.google.cloud.documentai.v1beta3.DocumentLabelingState labeling_state = 5;

Returns
TypeDescription
int

The enum numeric value on the wire for labelingState.

getPageCount()

public int getPageCount()

Number of pages in the document.

int32 page_count = 2;

Returns
TypeDescription
int

The pageCount.

hasDocumentId()

public boolean hasDocumentId()

Document identifier.

.google.cloud.documentai.v1beta3.DocumentId document_id = 1;

Returns
TypeDescription
boolean

Whether the documentId field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeDocumentId(DocumentId value)

public DocumentMetadata.Builder mergeDocumentId(DocumentId value)

Document identifier.

.google.cloud.documentai.v1beta3.DocumentId document_id = 1;

Parameter
NameDescription
valueDocumentId
Returns
TypeDescription
DocumentMetadata.Builder

mergeFrom(DocumentMetadata other)

public DocumentMetadata.Builder mergeFrom(DocumentMetadata other)
Parameter
NameDescription
otherDocumentMetadata
Returns
TypeDescription
DocumentMetadata.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public DocumentMetadata.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
DocumentMetadata.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public DocumentMetadata.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
DocumentMetadata.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final DocumentMetadata.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
DocumentMetadata.Builder
Overrides

setDatasetType(DatasetSplitType value)

public DocumentMetadata.Builder setDatasetType(DatasetSplitType value)

Type of the dataset split to which the document belongs.

.google.cloud.documentai.v1beta3.DatasetSplitType dataset_type = 3;

Parameter
NameDescription
valueDatasetSplitType

The datasetType to set.

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

setDatasetTypeValue(int value)

public DocumentMetadata.Builder setDatasetTypeValue(int value)

Type of the dataset split to which the document belongs.

.google.cloud.documentai.v1beta3.DatasetSplitType dataset_type = 3;

Parameter
NameDescription
valueint

The enum numeric value on the wire for datasetType to set.

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

setDisplayName(String value)

public DocumentMetadata.Builder setDisplayName(String value)

The display name of the document.

string display_name = 6;

Parameter
NameDescription
valueString

The displayName to set.

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

setDisplayNameBytes(ByteString value)

public DocumentMetadata.Builder setDisplayNameBytes(ByteString value)

The display name of the document.

string display_name = 6;

Parameter
NameDescription
valueByteString

The bytes for displayName to set.

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

setDocumentId(DocumentId value)

public DocumentMetadata.Builder setDocumentId(DocumentId value)

Document identifier.

.google.cloud.documentai.v1beta3.DocumentId document_id = 1;

Parameter
NameDescription
valueDocumentId
Returns
TypeDescription
DocumentMetadata.Builder

setDocumentId(DocumentId.Builder builderForValue)

public DocumentMetadata.Builder setDocumentId(DocumentId.Builder builderForValue)

Document identifier.

.google.cloud.documentai.v1beta3.DocumentId document_id = 1;

Parameter
NameDescription
builderForValueDocumentId.Builder
Returns
TypeDescription
DocumentMetadata.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public DocumentMetadata.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
DocumentMetadata.Builder
Overrides

setLabelingState(DocumentLabelingState value)

public DocumentMetadata.Builder setLabelingState(DocumentLabelingState value)

Labeling state of the document.

.google.cloud.documentai.v1beta3.DocumentLabelingState labeling_state = 5;

Parameter
NameDescription
valueDocumentLabelingState

The labelingState to set.

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

setLabelingStateValue(int value)

public DocumentMetadata.Builder setLabelingStateValue(int value)

Labeling state of the document.

.google.cloud.documentai.v1beta3.DocumentLabelingState labeling_state = 5;

Parameter
NameDescription
valueint

The enum numeric value on the wire for labelingState to set.

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

setPageCount(int value)

public DocumentMetadata.Builder setPageCount(int value)

Number of pages in the document.

int32 page_count = 2;

Parameter
NameDescription
valueint

The pageCount to set.

Returns
TypeDescription
DocumentMetadata.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public DocumentMetadata.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
DocumentMetadata.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final DocumentMetadata.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
DocumentMetadata.Builder
Overrides