Package com.google.apps.card.v1
Class DecoratedText
java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessageV3
com.google.apps.card.v1.DecoratedText
- All Implemented Interfaces:
DecoratedTextOrBuilder,com.google.protobuf.Message,com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Serializable
public final class DecoratedText
extends com.google.protobuf.GeneratedMessageV3
implements DecoratedTextOrBuilder
A widget that displays text with optional decorations such as a label above or below the text, an icon in front of the text, a selection widget, or a button after the text. For an example in Google Chat apps, see [Display text with decorative text](https://developers.google.com/workspace/chat/add-text-image-card-dialog#display_text_with_decorative_elements). [Google Workspace Add-ons and Chat apps](https://developers.google.com/workspace/extend):Protobuf type
google.apps.card.v1.DecoratedText- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA widget that displays text with optional decorations such as a label above or below the text, an icon in front of the text, a selection widget, or a button after the text.static enumstatic final classEither a toggle-style switch or a checkbox inside a `decoratedText` widget.static interfaceNested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT, BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intFields inherited from class com.google.protobuf.GeneratedMessageV3
alwaysUseFieldBuilders, unknownFieldsFields inherited from class com.google.protobuf.AbstractMessage
memoizedSizeFields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode -
Method Summary
Modifier and TypeMethodDescriptionbooleanThe text that appears below `text`.com.google.protobuf.ByteStringThe text that appears below `text`.A button that a user can click to trigger an action.A button that a user can click to trigger an action.static DecoratedTextstatic final com.google.protobuf.Descriptors.DescriptorAn icon displayed after the text.An icon displayed after the text.getIcon()Deprecated.google.apps.card.v1.DecoratedText.icon is deprecated.Deprecated.This action is triggered when users click `topLabel` or `bottomLabel`.This action is triggered when users click `topLabel` or `bottomLabel`.com.google.protobuf.Parser<DecoratedText>intThe icon displayed in front of the text.The icon displayed in front of the text.A switch widget that a user can click to change its state and trigger an action.A switch widget that a user can click to change its state and trigger an action.getText()Required.com.google.protobuf.ByteStringRequired.The text that appears above `text`.com.google.protobuf.ByteStringThe text that appears above `text`.booleanThe wrap text setting.booleanA button that a user can click to trigger an action.booleanAn icon displayed after the text.inthashCode()booleanhasIcon()Deprecated.google.apps.card.v1.DecoratedText.icon is deprecated.booleanThis action is triggered when users click `topLabel` or `bottomLabel`.booleanThe icon displayed in front of the text.booleanA switch widget that a user can click to change its state and trigger an action.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTablefinal booleanstatic DecoratedText.Builderstatic DecoratedText.BuildernewBuilder(DecoratedText prototype) protected DecoratedText.BuildernewBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) protected ObjectnewInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) static DecoratedTextparseDelimitedFrom(InputStream input) static DecoratedTextparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static DecoratedTextparseFrom(byte[] data) static DecoratedTextparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static DecoratedTextparseFrom(com.google.protobuf.ByteString data) static DecoratedTextparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static DecoratedTextparseFrom(com.google.protobuf.CodedInputStream input) static DecoratedTextparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static DecoratedTextparseFrom(InputStream input) static DecoratedTextparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static DecoratedTextparseFrom(ByteBuffer data) static DecoratedTextparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<DecoratedText>parser()voidwriteTo(com.google.protobuf.CodedOutputStream output) Methods inherited from class com.google.protobuf.GeneratedMessageV3
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagMethods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite
addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLite
toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Field Details
-
ICON_FIELD_NUMBER
public static final int ICON_FIELD_NUMBER- See Also:
-
START_ICON_FIELD_NUMBER
public static final int START_ICON_FIELD_NUMBER- See Also:
-
TOP_LABEL_FIELD_NUMBER
public static final int TOP_LABEL_FIELD_NUMBER- See Also:
-
TEXT_FIELD_NUMBER
public static final int TEXT_FIELD_NUMBER- See Also:
-
WRAP_TEXT_FIELD_NUMBER
public static final int WRAP_TEXT_FIELD_NUMBER- See Also:
-
BOTTOM_LABEL_FIELD_NUMBER
public static final int BOTTOM_LABEL_FIELD_NUMBER- See Also:
-
ON_CLICK_FIELD_NUMBER
public static final int ON_CLICK_FIELD_NUMBER- See Also:
-
BUTTON_FIELD_NUMBER
public static final int BUTTON_FIELD_NUMBER- See Also:
-
SWITCH_CONTROL_FIELD_NUMBER
public static final int SWITCH_CONTROL_FIELD_NUMBER- See Also:
-
END_ICON_FIELD_NUMBER
public static final int END_ICON_FIELD_NUMBER- See Also:
-
-
Method Details
-
newInstance
- Overrides:
newInstancein classcom.google.protobuf.GeneratedMessageV3
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3
-
getControlCase
- Specified by:
getControlCasein interfaceDecoratedTextOrBuilder
-
hasIcon
Deprecated.google.apps.card.v1.DecoratedText.icon is deprecated. See google/apps/card/v1/card.proto;l=796Deprecated in favor of `startIcon`.
.google.apps.card.v1.Icon icon = 1 [deprecated = true];- Specified by:
hasIconin interfaceDecoratedTextOrBuilder- Returns:
- Whether the icon field is set.
-
getIcon
Deprecated.google.apps.card.v1.DecoratedText.icon is deprecated. See google/apps/card/v1/card.proto;l=796Deprecated in favor of `startIcon`.
.google.apps.card.v1.Icon icon = 1 [deprecated = true];- Specified by:
getIconin interfaceDecoratedTextOrBuilder- Returns:
- The icon.
-
getIconOrBuilder
Deprecated.Deprecated in favor of `startIcon`.
.google.apps.card.v1.Icon icon = 1 [deprecated = true];- Specified by:
getIconOrBuilderin interfaceDecoratedTextOrBuilder
-
hasStartIcon
public boolean hasStartIcon()The icon displayed in front of the text.
.google.apps.card.v1.Icon start_icon = 12;- Specified by:
hasStartIconin interfaceDecoratedTextOrBuilder- Returns:
- Whether the startIcon field is set.
-
getStartIcon
The icon displayed in front of the text.
.google.apps.card.v1.Icon start_icon = 12;- Specified by:
getStartIconin interfaceDecoratedTextOrBuilder- Returns:
- The startIcon.
-
getStartIconOrBuilder
The icon displayed in front of the text.
.google.apps.card.v1.Icon start_icon = 12;- Specified by:
getStartIconOrBuilderin interfaceDecoratedTextOrBuilder
-
getTopLabel
The text that appears above `text`. Always truncates.
string top_label = 3;- Specified by:
getTopLabelin interfaceDecoratedTextOrBuilder- Returns:
- The topLabel.
-
getTopLabelBytes
public com.google.protobuf.ByteString getTopLabelBytes()The text that appears above `text`. Always truncates.
string top_label = 3;- Specified by:
getTopLabelBytesin interfaceDecoratedTextOrBuilder- Returns:
- The bytes for topLabel.
-
getText
Required. The primary text. Supports simple formatting. For more information about formatting text, see [Formatting text in Google Chat apps](https://developers.google.com/workspace/chat/format-messages#card-formatting) and [Formatting text in Google Workspace Add-ons](https://developers.google.com/apps-script/add-ons/concepts/widgets#text_formatting).
string text = 4;- Specified by:
getTextin interfaceDecoratedTextOrBuilder- Returns:
- The text.
-
getTextBytes
public com.google.protobuf.ByteString getTextBytes()Required. The primary text. Supports simple formatting. For more information about formatting text, see [Formatting text in Google Chat apps](https://developers.google.com/workspace/chat/format-messages#card-formatting) and [Formatting text in Google Workspace Add-ons](https://developers.google.com/apps-script/add-ons/concepts/widgets#text_formatting).
string text = 4;- Specified by:
getTextBytesin interfaceDecoratedTextOrBuilder- Returns:
- The bytes for text.
-
getWrapText
public boolean getWrapText()The wrap text setting. If `true`, the text wraps and displays on multiple lines. Otherwise, the text is truncated. Only applies to `text`, not `topLabel` and `bottomLabel`.
bool wrap_text = 5;- Specified by:
getWrapTextin interfaceDecoratedTextOrBuilder- Returns:
- The wrapText.
-
getBottomLabel
The text that appears below `text`. Always wraps.
string bottom_label = 6;- Specified by:
getBottomLabelin interfaceDecoratedTextOrBuilder- Returns:
- The bottomLabel.
-
getBottomLabelBytes
public com.google.protobuf.ByteString getBottomLabelBytes()The text that appears below `text`. Always wraps.
string bottom_label = 6;- Specified by:
getBottomLabelBytesin interfaceDecoratedTextOrBuilder- Returns:
- The bytes for bottomLabel.
-
hasOnClick
public boolean hasOnClick()This action is triggered when users click `topLabel` or `bottomLabel`.
.google.apps.card.v1.OnClick on_click = 7;- Specified by:
hasOnClickin interfaceDecoratedTextOrBuilder- Returns:
- Whether the onClick field is set.
-
getOnClick
This action is triggered when users click `topLabel` or `bottomLabel`.
.google.apps.card.v1.OnClick on_click = 7;- Specified by:
getOnClickin interfaceDecoratedTextOrBuilder- Returns:
- The onClick.
-
getOnClickOrBuilder
This action is triggered when users click `topLabel` or `bottomLabel`.
.google.apps.card.v1.OnClick on_click = 7;- Specified by:
getOnClickOrBuilderin interfaceDecoratedTextOrBuilder
-
hasButton
public boolean hasButton()A button that a user can click to trigger an action.
.google.apps.card.v1.Button button = 8;- Specified by:
hasButtonin interfaceDecoratedTextOrBuilder- Returns:
- Whether the button field is set.
-
getButton
A button that a user can click to trigger an action.
.google.apps.card.v1.Button button = 8;- Specified by:
getButtonin interfaceDecoratedTextOrBuilder- Returns:
- The button.
-
getButtonOrBuilder
A button that a user can click to trigger an action.
.google.apps.card.v1.Button button = 8;- Specified by:
getButtonOrBuilderin interfaceDecoratedTextOrBuilder
-
hasSwitchControl
public boolean hasSwitchControl()A switch widget that a user can click to change its state and trigger an action.
.google.apps.card.v1.DecoratedText.SwitchControl switch_control = 9;- Specified by:
hasSwitchControlin interfaceDecoratedTextOrBuilder- Returns:
- Whether the switchControl field is set.
-
getSwitchControl
A switch widget that a user can click to change its state and trigger an action.
.google.apps.card.v1.DecoratedText.SwitchControl switch_control = 9;- Specified by:
getSwitchControlin interfaceDecoratedTextOrBuilder- Returns:
- The switchControl.
-
getSwitchControlOrBuilder
A switch widget that a user can click to change its state and trigger an action.
.google.apps.card.v1.DecoratedText.SwitchControl switch_control = 9;- Specified by:
getSwitchControlOrBuilderin interfaceDecoratedTextOrBuilder
-
hasEndIcon
public boolean hasEndIcon()An icon displayed after the text. Supports [built-in](https://developers.google.com/workspace/chat/format-messages#builtinicons) and [custom](https://developers.google.com/workspace/chat/format-messages#customicons) icons.
.google.apps.card.v1.Icon end_icon = 11;- Specified by:
hasEndIconin interfaceDecoratedTextOrBuilder- Returns:
- Whether the endIcon field is set.
-
getEndIcon
An icon displayed after the text. Supports [built-in](https://developers.google.com/workspace/chat/format-messages#builtinicons) and [custom](https://developers.google.com/workspace/chat/format-messages#customicons) icons.
.google.apps.card.v1.Icon end_icon = 11;- Specified by:
getEndIconin interfaceDecoratedTextOrBuilder- Returns:
- The endIcon.
-
getEndIconOrBuilder
An icon displayed after the text. Supports [built-in](https://developers.google.com/workspace/chat/format-messages#builtinicons) and [custom](https://developers.google.com/workspace/chat/format-messages#customicons) icons.
.google.apps.card.v1.Icon end_icon = 11;- Specified by:
getEndIconOrBuilderin interfaceDecoratedTextOrBuilder
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3
-
writeTo
- Specified by:
writeToin interfacecom.google.protobuf.MessageLite- Overrides:
writeToin classcom.google.protobuf.GeneratedMessageV3- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()- Specified by:
getSerializedSizein interfacecom.google.protobuf.MessageLite- Overrides:
getSerializedSizein classcom.google.protobuf.GeneratedMessageV3
-
equals
- Specified by:
equalsin interfacecom.google.protobuf.Message- Overrides:
equalsin classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()- Specified by:
hashCodein interfacecom.google.protobuf.Message- Overrides:
hashCodein classcom.google.protobuf.AbstractMessage
-
parseFrom
public static DecoratedText parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static DecoratedText parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static DecoratedText parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static DecoratedText parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static DecoratedText parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static DecoratedText parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static DecoratedText parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static DecoratedText parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
public static DecoratedText parseFrom(com.google.protobuf.CodedInputStream input) throws IOException - Throws:
IOException
-
parseFrom
public static DecoratedText parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilderForType
- Specified by:
newBuilderForTypein interfacecom.google.protobuf.Message- Specified by:
newBuilderForTypein interfacecom.google.protobuf.MessageLite
-
newBuilder
-
newBuilder
-
toBuilder
- Specified by:
toBuilderin interfacecom.google.protobuf.Message- Specified by:
toBuilderin interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected DecoratedText.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) - Specified by:
newBuilderForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
-
parser
-
getParserForType
- Specified by:
getParserForTypein interfacecom.google.protobuf.Message- Specified by:
getParserForTypein interfacecom.google.protobuf.MessageLite- Overrides:
getParserForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-