Package com.google.cloud.documentai.v1
Class Document.PageAnchor.PageRef.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Document.PageAnchor.PageRef.Builder>
com.google.cloud.documentai.v1.Document.PageAnchor.PageRef.Builder
- All Implemented Interfaces:
Document.PageAnchor.PageRefOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- Document.PageAnchor.PageRef
public static final class Document.PageAnchor.PageRef.Builder
extends com.google.protobuf.GeneratedMessage.Builder<Document.PageAnchor.PageRef.Builder>
implements Document.PageAnchor.PageRefOrBuilder
Represents a weak reference to a page element within a document.Protobuf type
google.cloud.documentai.v1.Document.PageAnchor.PageRef-
Method Summary
Modifier and TypeMethodDescriptionbuild()clear()Optional.Optional.Deprecated.google.cloud.documentai.v1.Document.PageAnchor.PageRef.layout_id is deprecated.Optional.Required.Optional.Optional.Optional.floatOptional.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorDeprecated.google.cloud.documentai.v1.Document.PageAnchor.PageRef.layout_id is deprecated.com.google.protobuf.ByteStringDeprecated.google.cloud.documentai.v1.Document.PageAnchor.PageRef.layout_id is deprecated.Optional.intOptional.longgetPage()Required.booleanOptional.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeBoundingPoly(BoundingPoly value) Optional.mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) setBoundingPoly(BoundingPoly value) Optional.setBoundingPoly(BoundingPoly.Builder builderForValue) Optional.setConfidence(float value) Optional.setLayoutId(String value) Deprecated.google.cloud.documentai.v1.Document.PageAnchor.PageRef.layout_id is deprecated.setLayoutIdBytes(com.google.protobuf.ByteString value) Deprecated.google.cloud.documentai.v1.Document.PageAnchor.PageRef.layout_id is deprecated.Optional.setLayoutTypeValue(int value) Optional.setPage(long value) Required.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<Document.PageAnchor.PageRef.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessage.Builder<Document.PageAnchor.PageRef.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessage.Builder<Document.PageAnchor.PageRef.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<Document.PageAnchor.PageRef.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<Document.PageAnchor.PageRef.Builder>
-
mergeFrom
public Document.PageAnchor.PageRef.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<Document.PageAnchor.PageRef.Builder>- Throws:
IOException
-
getPage
public long getPage()Required. Index into the [Document.pages][google.cloud.documentai.v1.Document.pages] element, for example using `[Document.pages][page_refs.page]` to locate the related page element. This field is skipped when its value is the default `0`. See https://developers.google.com/protocol-buffers/docs/proto3#json.
int64 page = 1 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getPagein interfaceDocument.PageAnchor.PageRefOrBuilder- Returns:
- The page.
-
setPage
Required. Index into the [Document.pages][google.cloud.documentai.v1.Document.pages] element, for example using `[Document.pages][page_refs.page]` to locate the related page element. This field is skipped when its value is the default `0`. See https://developers.google.com/protocol-buffers/docs/proto3#json.
int64 page = 1 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The page to set.- Returns:
- This builder for chaining.
-
clearPage
Required. Index into the [Document.pages][google.cloud.documentai.v1.Document.pages] element, for example using `[Document.pages][page_refs.page]` to locate the related page element. This field is skipped when its value is the default `0`. See https://developers.google.com/protocol-buffers/docs/proto3#json.
int64 page = 1 [(.google.api.field_behavior) = REQUIRED];- Returns:
- This builder for chaining.
-
getLayoutTypeValue
public int getLayoutTypeValue()Optional. The type of the layout element that is being referenced if any.
.google.cloud.documentai.v1.Document.PageAnchor.PageRef.LayoutType layout_type = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getLayoutTypeValuein interfaceDocument.PageAnchor.PageRefOrBuilder- Returns:
- The enum numeric value on the wire for layoutType.
-
setLayoutTypeValue
Optional. The type of the layout element that is being referenced if any.
.google.cloud.documentai.v1.Document.PageAnchor.PageRef.LayoutType layout_type = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The enum numeric value on the wire for layoutType to set.- Returns:
- This builder for chaining.
-
getLayoutType
Optional. The type of the layout element that is being referenced if any.
.google.cloud.documentai.v1.Document.PageAnchor.PageRef.LayoutType layout_type = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getLayoutTypein interfaceDocument.PageAnchor.PageRefOrBuilder- Returns:
- The layoutType.
-
setLayoutType
public Document.PageAnchor.PageRef.Builder setLayoutType(Document.PageAnchor.PageRef.LayoutType value) Optional. The type of the layout element that is being referenced if any.
.google.cloud.documentai.v1.Document.PageAnchor.PageRef.LayoutType layout_type = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The layoutType to set.- Returns:
- This builder for chaining.
-
clearLayoutType
Optional. The type of the layout element that is being referenced if any.
.google.cloud.documentai.v1.Document.PageAnchor.PageRef.LayoutType layout_type = 2 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
getLayoutId
Deprecated.google.cloud.documentai.v1.Document.PageAnchor.PageRef.layout_id is deprecated. See google/cloud/documentai/v1/document.proto;l=775Optional. Deprecated. Use [PageRef.bounding_poly][google.cloud.documentai.v1.Document.PageAnchor.PageRef.bounding_poly] instead.
string layout_id = 3 [deprecated = true, (.google.api.field_behavior) = OPTIONAL];- Specified by:
getLayoutIdin interfaceDocument.PageAnchor.PageRefOrBuilder- Returns:
- The layoutId.
-
getLayoutIdBytes
Deprecated.google.cloud.documentai.v1.Document.PageAnchor.PageRef.layout_id is deprecated. See google/cloud/documentai/v1/document.proto;l=775Optional. Deprecated. Use [PageRef.bounding_poly][google.cloud.documentai.v1.Document.PageAnchor.PageRef.bounding_poly] instead.
string layout_id = 3 [deprecated = true, (.google.api.field_behavior) = OPTIONAL];- Specified by:
getLayoutIdBytesin interfaceDocument.PageAnchor.PageRefOrBuilder- Returns:
- The bytes for layoutId.
-
setLayoutId
Deprecated.google.cloud.documentai.v1.Document.PageAnchor.PageRef.layout_id is deprecated. See google/cloud/documentai/v1/document.proto;l=775Optional. Deprecated. Use [PageRef.bounding_poly][google.cloud.documentai.v1.Document.PageAnchor.PageRef.bounding_poly] instead.
string layout_id = 3 [deprecated = true, (.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The layoutId to set.- Returns:
- This builder for chaining.
-
clearLayoutId
Deprecated.google.cloud.documentai.v1.Document.PageAnchor.PageRef.layout_id is deprecated. See google/cloud/documentai/v1/document.proto;l=775Optional. Deprecated. Use [PageRef.bounding_poly][google.cloud.documentai.v1.Document.PageAnchor.PageRef.bounding_poly] instead.
string layout_id = 3 [deprecated = true, (.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
setLayoutIdBytes
@Deprecated public Document.PageAnchor.PageRef.Builder setLayoutIdBytes(com.google.protobuf.ByteString value) Deprecated.google.cloud.documentai.v1.Document.PageAnchor.PageRef.layout_id is deprecated. See google/cloud/documentai/v1/document.proto;l=775Optional. Deprecated. Use [PageRef.bounding_poly][google.cloud.documentai.v1.Document.PageAnchor.PageRef.bounding_poly] instead.
string layout_id = 3 [deprecated = true, (.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes for layoutId to set.- Returns:
- This builder for chaining.
-
hasBoundingPoly
public boolean hasBoundingPoly()Optional. Identifies the bounding polygon of a layout element on the page. If `layout_type` is set, the bounding polygon must be exactly the same to the layout element it's referring to.
.google.cloud.documentai.v1.BoundingPoly bounding_poly = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
hasBoundingPolyin interfaceDocument.PageAnchor.PageRefOrBuilder- Returns:
- Whether the boundingPoly field is set.
-
getBoundingPoly
Optional. Identifies the bounding polygon of a layout element on the page. If `layout_type` is set, the bounding polygon must be exactly the same to the layout element it's referring to.
.google.cloud.documentai.v1.BoundingPoly bounding_poly = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getBoundingPolyin interfaceDocument.PageAnchor.PageRefOrBuilder- Returns:
- The boundingPoly.
-
setBoundingPoly
Optional. Identifies the bounding polygon of a layout element on the page. If `layout_type` is set, the bounding polygon must be exactly the same to the layout element it's referring to.
.google.cloud.documentai.v1.BoundingPoly bounding_poly = 4 [(.google.api.field_behavior) = OPTIONAL]; -
setBoundingPoly
Optional. Identifies the bounding polygon of a layout element on the page. If `layout_type` is set, the bounding polygon must be exactly the same to the layout element it's referring to.
.google.cloud.documentai.v1.BoundingPoly bounding_poly = 4 [(.google.api.field_behavior) = OPTIONAL]; -
mergeBoundingPoly
Optional. Identifies the bounding polygon of a layout element on the page. If `layout_type` is set, the bounding polygon must be exactly the same to the layout element it's referring to.
.google.cloud.documentai.v1.BoundingPoly bounding_poly = 4 [(.google.api.field_behavior) = OPTIONAL]; -
clearBoundingPoly
Optional. Identifies the bounding polygon of a layout element on the page. If `layout_type` is set, the bounding polygon must be exactly the same to the layout element it's referring to.
.google.cloud.documentai.v1.BoundingPoly bounding_poly = 4 [(.google.api.field_behavior) = OPTIONAL]; -
getBoundingPolyBuilder
Optional. Identifies the bounding polygon of a layout element on the page. If `layout_type` is set, the bounding polygon must be exactly the same to the layout element it's referring to.
.google.cloud.documentai.v1.BoundingPoly bounding_poly = 4 [(.google.api.field_behavior) = OPTIONAL]; -
getBoundingPolyOrBuilder
Optional. Identifies the bounding polygon of a layout element on the page. If `layout_type` is set, the bounding polygon must be exactly the same to the layout element it's referring to.
.google.cloud.documentai.v1.BoundingPoly bounding_poly = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getBoundingPolyOrBuilderin interfaceDocument.PageAnchor.PageRefOrBuilder
-
getConfidence
public float getConfidence()Optional. Confidence of detected page element, if applicable. Range `[0, 1]`.
float confidence = 5 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getConfidencein interfaceDocument.PageAnchor.PageRefOrBuilder- Returns:
- The confidence.
-
setConfidence
Optional. Confidence of detected page element, if applicable. Range `[0, 1]`.
float confidence = 5 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The confidence to set.- Returns:
- This builder for chaining.
-
clearConfidence
Optional. Confidence of detected page element, if applicable. Range `[0, 1]`.
float confidence = 5 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-