Package com.google.cloud.documentai.v1
Class Document.Style.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Document.Style.Builder>
com.google.cloud.documentai.v1.Document.Style.Builder
- All Implemented Interfaces:
Document.StyleOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- Document.Style
public static final class Document.Style.Builder
extends com.google.protobuf.GeneratedMessage.Builder<Document.Style.Builder>
implements Document.StyleOrBuilder
Annotation for common text style attributes. This adheres to CSS conventions as much as possible.Protobuf type
google.cloud.documentai.v1.Document.Style-
Method Summary
Modifier and TypeMethodDescriptionbuild()clear()Text background color.Text color.Font family such as `Arial`, `Times New Roman`.Font size.[Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp).Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].[Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp).[Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp).Text background color.Text background color.Text background color.getColor()Text color.Text color.Text color.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorFont family such as `Arial`, `Times New Roman`.com.google.protobuf.ByteStringFont family such as `Arial`, `Times New Roman`.Font size.Font size.Font size.[Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp).com.google.protobuf.ByteString[Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp).Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].[Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp).com.google.protobuf.ByteString[Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp).[Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp).com.google.protobuf.ByteString[Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp).booleanText background color.booleanhasColor()Text color.booleanFont size.booleanText anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeBackgroundColor(Color value) Text background color.mergeColor(Color value) Text color.Font size.mergeFrom(Document.Style other) mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].setBackgroundColor(Color value) Text background color.setBackgroundColor(Color.Builder builderForValue) Text background color.Text color.setColor(Color.Builder builderForValue) Text color.setFontFamily(String value) Font family such as `Arial`, `Times New Roman`.setFontFamilyBytes(com.google.protobuf.ByteString value) Font family such as `Arial`, `Times New Roman`.Font size.setFontSize(Document.Style.FontSize.Builder builderForValue) Font size.setFontWeight(String value) [Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp).setFontWeightBytes(com.google.protobuf.ByteString value) [Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp).setTextAnchor(Document.TextAnchor value) Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].setTextAnchor(Document.TextAnchor.Builder builderForValue) Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].setTextDecoration(String value) [Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp).setTextDecorationBytes(com.google.protobuf.ByteString value) [Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp).setTextStyle(String value) [Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp).setTextStyleBytes(com.google.protobuf.ByteString value) [Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp).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.Style.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.Style.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.Style.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.Style.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<Document.Style.Builder>
-
mergeFrom
public Document.Style.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.Style.Builder>- Throws:
IOException
-
hasTextAnchor
public boolean hasTextAnchor()Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].
.google.cloud.documentai.v1.Document.TextAnchor text_anchor = 1;- Specified by:
hasTextAnchorin interfaceDocument.StyleOrBuilder- Returns:
- Whether the textAnchor field is set.
-
getTextAnchor
Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].
.google.cloud.documentai.v1.Document.TextAnchor text_anchor = 1;- Specified by:
getTextAnchorin interfaceDocument.StyleOrBuilder- Returns:
- The textAnchor.
-
setTextAnchor
Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].
.google.cloud.documentai.v1.Document.TextAnchor text_anchor = 1; -
setTextAnchor
Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].
.google.cloud.documentai.v1.Document.TextAnchor text_anchor = 1; -
mergeTextAnchor
Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].
.google.cloud.documentai.v1.Document.TextAnchor text_anchor = 1; -
clearTextAnchor
Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].
.google.cloud.documentai.v1.Document.TextAnchor text_anchor = 1; -
getTextAnchorBuilder
Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].
.google.cloud.documentai.v1.Document.TextAnchor text_anchor = 1; -
getTextAnchorOrBuilder
Text anchor indexing into the [Document.text][google.cloud.documentai.v1.Document.text].
.google.cloud.documentai.v1.Document.TextAnchor text_anchor = 1;- Specified by:
getTextAnchorOrBuilderin interfaceDocument.StyleOrBuilder
-
hasColor
public boolean hasColor()Text color.
.google.type.Color color = 2;- Specified by:
hasColorin interfaceDocument.StyleOrBuilder- Returns:
- Whether the color field is set.
-
getColor
Text color.
.google.type.Color color = 2;- Specified by:
getColorin interfaceDocument.StyleOrBuilder- Returns:
- The color.
-
setColor
Text color.
.google.type.Color color = 2; -
setColor
Text color.
.google.type.Color color = 2; -
mergeColor
Text color.
.google.type.Color color = 2; -
clearColor
Text color.
.google.type.Color color = 2; -
getColorBuilder
Text color.
.google.type.Color color = 2; -
getColorOrBuilder
Text color.
.google.type.Color color = 2;- Specified by:
getColorOrBuilderin interfaceDocument.StyleOrBuilder
-
hasBackgroundColor
public boolean hasBackgroundColor()Text background color.
.google.type.Color background_color = 3;- Specified by:
hasBackgroundColorin interfaceDocument.StyleOrBuilder- Returns:
- Whether the backgroundColor field is set.
-
getBackgroundColor
Text background color.
.google.type.Color background_color = 3;- Specified by:
getBackgroundColorin interfaceDocument.StyleOrBuilder- Returns:
- The backgroundColor.
-
setBackgroundColor
Text background color.
.google.type.Color background_color = 3; -
setBackgroundColor
Text background color.
.google.type.Color background_color = 3; -
mergeBackgroundColor
Text background color.
.google.type.Color background_color = 3; -
clearBackgroundColor
Text background color.
.google.type.Color background_color = 3; -
getBackgroundColorBuilder
Text background color.
.google.type.Color background_color = 3; -
getBackgroundColorOrBuilder
Text background color.
.google.type.Color background_color = 3;- Specified by:
getBackgroundColorOrBuilderin interfaceDocument.StyleOrBuilder
-
getFontWeight
[Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp). Possible values are `normal`, `bold`, `bolder`, and `lighter`.
string font_weight = 4;- Specified by:
getFontWeightin interfaceDocument.StyleOrBuilder- Returns:
- The fontWeight.
-
getFontWeightBytes
public com.google.protobuf.ByteString getFontWeightBytes()[Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp). Possible values are `normal`, `bold`, `bolder`, and `lighter`.
string font_weight = 4;- Specified by:
getFontWeightBytesin interfaceDocument.StyleOrBuilder- Returns:
- The bytes for fontWeight.
-
setFontWeight
[Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp). Possible values are `normal`, `bold`, `bolder`, and `lighter`.
string font_weight = 4;- Parameters:
value- The fontWeight to set.- Returns:
- This builder for chaining.
-
clearFontWeight
[Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp). Possible values are `normal`, `bold`, `bolder`, and `lighter`.
string font_weight = 4;- Returns:
- This builder for chaining.
-
setFontWeightBytes
[Font weight](https://www.w3schools.com/cssref/pr_font_weight.asp). Possible values are `normal`, `bold`, `bolder`, and `lighter`.
string font_weight = 4;- Parameters:
value- The bytes for fontWeight to set.- Returns:
- This builder for chaining.
-
getTextStyle
[Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp). Possible values are `normal`, `italic`, and `oblique`.
string text_style = 5;- Specified by:
getTextStylein interfaceDocument.StyleOrBuilder- Returns:
- The textStyle.
-
getTextStyleBytes
public com.google.protobuf.ByteString getTextStyleBytes()[Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp). Possible values are `normal`, `italic`, and `oblique`.
string text_style = 5;- Specified by:
getTextStyleBytesin interfaceDocument.StyleOrBuilder- Returns:
- The bytes for textStyle.
-
setTextStyle
[Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp). Possible values are `normal`, `italic`, and `oblique`.
string text_style = 5;- Parameters:
value- The textStyle to set.- Returns:
- This builder for chaining.
-
clearTextStyle
[Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp). Possible values are `normal`, `italic`, and `oblique`.
string text_style = 5;- Returns:
- This builder for chaining.
-
setTextStyleBytes
[Text style](https://www.w3schools.com/cssref/pr_font_font-style.asp). Possible values are `normal`, `italic`, and `oblique`.
string text_style = 5;- Parameters:
value- The bytes for textStyle to set.- Returns:
- This builder for chaining.
-
getTextDecoration
[Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp). Follows CSS standard. <text-decoration-line> <text-decoration-color> <text-decoration-style>
string text_decoration = 6;- Specified by:
getTextDecorationin interfaceDocument.StyleOrBuilder- Returns:
- The textDecoration.
-
getTextDecorationBytes
public com.google.protobuf.ByteString getTextDecorationBytes()[Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp). Follows CSS standard. <text-decoration-line> <text-decoration-color> <text-decoration-style>
string text_decoration = 6;- Specified by:
getTextDecorationBytesin interfaceDocument.StyleOrBuilder- Returns:
- The bytes for textDecoration.
-
setTextDecoration
[Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp). Follows CSS standard. <text-decoration-line> <text-decoration-color> <text-decoration-style>
string text_decoration = 6;- Parameters:
value- The textDecoration to set.- Returns:
- This builder for chaining.
-
clearTextDecoration
[Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp). Follows CSS standard. <text-decoration-line> <text-decoration-color> <text-decoration-style>
string text_decoration = 6;- Returns:
- This builder for chaining.
-
setTextDecorationBytes
[Text decoration](https://www.w3schools.com/cssref/pr_text_text-decoration.asp). Follows CSS standard. <text-decoration-line> <text-decoration-color> <text-decoration-style>
string text_decoration = 6;- Parameters:
value- The bytes for textDecoration to set.- Returns:
- This builder for chaining.
-
hasFontSize
public boolean hasFontSize()Font size.
.google.cloud.documentai.v1.Document.Style.FontSize font_size = 7;- Specified by:
hasFontSizein interfaceDocument.StyleOrBuilder- Returns:
- Whether the fontSize field is set.
-
getFontSize
Font size.
.google.cloud.documentai.v1.Document.Style.FontSize font_size = 7;- Specified by:
getFontSizein interfaceDocument.StyleOrBuilder- Returns:
- The fontSize.
-
setFontSize
Font size.
.google.cloud.documentai.v1.Document.Style.FontSize font_size = 7; -
setFontSize
Font size.
.google.cloud.documentai.v1.Document.Style.FontSize font_size = 7; -
mergeFontSize
Font size.
.google.cloud.documentai.v1.Document.Style.FontSize font_size = 7; -
clearFontSize
Font size.
.google.cloud.documentai.v1.Document.Style.FontSize font_size = 7; -
getFontSizeBuilder
Font size.
.google.cloud.documentai.v1.Document.Style.FontSize font_size = 7; -
getFontSizeOrBuilder
Font size.
.google.cloud.documentai.v1.Document.Style.FontSize font_size = 7;- Specified by:
getFontSizeOrBuilderin interfaceDocument.StyleOrBuilder
-
getFontFamily
Font family such as `Arial`, `Times New Roman`. https://www.w3schools.com/cssref/pr_font_font-family.asp
string font_family = 8;- Specified by:
getFontFamilyin interfaceDocument.StyleOrBuilder- Returns:
- The fontFamily.
-
getFontFamilyBytes
public com.google.protobuf.ByteString getFontFamilyBytes()Font family such as `Arial`, `Times New Roman`. https://www.w3schools.com/cssref/pr_font_font-family.asp
string font_family = 8;- Specified by:
getFontFamilyBytesin interfaceDocument.StyleOrBuilder- Returns:
- The bytes for fontFamily.
-
setFontFamily
Font family such as `Arial`, `Times New Roman`. https://www.w3schools.com/cssref/pr_font_font-family.asp
string font_family = 8;- Parameters:
value- The fontFamily to set.- Returns:
- This builder for chaining.
-
clearFontFamily
Font family such as `Arial`, `Times New Roman`. https://www.w3schools.com/cssref/pr_font_font-family.asp
string font_family = 8;- Returns:
- This builder for chaining.
-
setFontFamilyBytes
Font family such as `Arial`, `Times New Roman`. https://www.w3schools.com/cssref/pr_font_font-family.asp
string font_family = 8;- Parameters:
value- The bytes for fontFamily to set.- Returns:
- This builder for chaining.
-