Package com.google.apps.card.v1
Class Icon
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite
-
- com.google.protobuf.AbstractMessage
-
- com.google.protobuf.GeneratedMessage
-
- com.google.protobuf.GeneratedMessage.ExtendableMessage<com.google.protobuf.GeneratedMessageV3>
-
- com.google.protobuf.GeneratedMessageV3
-
- com.google.apps.card.v1.Icon
-
- All Implemented Interfaces:
IconOrBuilder,com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<com.google.protobuf.GeneratedMessageV3>,com.google.protobuf.Message,com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,java.io.Serializable
public final class Icon extends com.google.protobuf.GeneratedMessageV3 implements IconOrBuilder
An icon displayed in a widget on a card. For an example in Google Chat apps, see [Add an icon](https://developers.google.com/workspace/chat/add-text-image-card-dialog#add_an_icon). 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 Workspace Add-ons and Chat apps](https://developers.google.com/workspace/extend):
Protobuf typegoogle.apps.card.v1.Icon- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classIcon.BuilderAn icon displayed in a widget on a card.static classIcon.IconsCase-
Nested 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.GeneratedMessage.ExtendableMessage
com.google.protobuf.GeneratedMessage.ExtendableMessage.ExtensionSerializer, com.google.protobuf.GeneratedMessage.ExtendableMessage.ExtensionWriter
-
-
Field Summary
Fields Modifier and Type Field Description static intALT_TEXT_FIELD_NUMBERstatic intICON_URL_FIELD_NUMBERstatic intIMAGE_TYPE_FIELD_NUMBERstatic intKNOWN_ICON_FIELD_NUMBERstatic intMATERIAL_ICON_FIELD_NUMBER
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)java.lang.StringgetAltText()Optional.com.google.protobuf.ByteStringgetAltTextBytes()Optional.static IcongetDefaultInstance()IcongetDefaultInstanceForType()static com.google.protobuf.Descriptors.DescriptorgetDescriptor()Icon.IconsCasegetIconsCase()java.lang.StringgetIconUrl()Display a custom icon hosted at an HTTPS URL.com.google.protobuf.ByteStringgetIconUrlBytes()Display a custom icon hosted at an HTTPS URL.Widget.ImageTypegetImageType()The crop style applied to the image.intgetImageTypeValue()The crop style applied to the image.java.lang.StringgetKnownIcon()Display one of the built-in icons provided by Google Workspace.com.google.protobuf.ByteStringgetKnownIconBytes()Display one of the built-in icons provided by Google Workspace.MaterialIcongetMaterialIcon()Display one of the [Google Material Icons](https://fonts.google.com/icons).MaterialIconOrBuildergetMaterialIconOrBuilder()Display one of the [Google Material Icons](https://fonts.google.com/icons).com.google.protobuf.Parser<Icon>getParserForType()intgetSerializedSize()inthashCode()booleanhasIconUrl()Display a custom icon hosted at an HTTPS URL.booleanhasKnownIcon()Display one of the built-in icons provided by Google Workspace.booleanhasMaterialIcon()Display one of the [Google Material Icons](https://fonts.google.com/icons).protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()booleanisInitialized()static Icon.BuildernewBuilder()static Icon.BuildernewBuilder(Icon prototype)Icon.BuildernewBuilderForType()protected Icon.BuildernewBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)protected java.lang.ObjectnewInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)static IconparseDelimitedFrom(java.io.InputStream input)static IconparseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static IconparseFrom(byte[] data)static IconparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static IconparseFrom(com.google.protobuf.ByteString data)static IconparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static IconparseFrom(com.google.protobuf.CodedInputStream input)static IconparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static IconparseFrom(java.io.InputStream input)static IconparseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static IconparseFrom(java.nio.ByteBuffer data)static IconparseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)static com.google.protobuf.Parser<Icon>parser()Icon.BuildertoBuilder()voidwriteTo(com.google.protobuf.CodedOutputStream output)-
Methods inherited from class com.google.protobuf.GeneratedMessageV3
mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBuilderForType
-
Methods inherited from class com.google.protobuf.GeneratedMessage.ExtendableMessage
extensionsAreInitialized, extensionsSerializedSize, extensionsSerializedSizeAsMessageSet, getAllFields, getAllFieldsRaw, getExtension, getExtension, getExtensionCount, getExtensionFields, getField, getRepeatedField, getRepeatedFieldCount, hasExtension, hasField, newExtensionSerializer, newExtensionWriter, newMessageSetExtensionSerializer, newMessageSetExtensionWriter
-
Methods inherited from class com.google.protobuf.GeneratedMessage
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getDescriptorForType, getOneofFieldDescriptor, getUnknownFields, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, newFileScopedGeneratedExtension, newInstance, newMessageScopedGeneratedExtension, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
-
Methods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashFields, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite
addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
-
-
-
Field Detail
-
KNOWN_ICON_FIELD_NUMBER
public static final int KNOWN_ICON_FIELD_NUMBER
- See Also:
- Constant Field Values
-
ICON_URL_FIELD_NUMBER
public static final int ICON_URL_FIELD_NUMBER
- See Also:
- Constant Field Values
-
MATERIAL_ICON_FIELD_NUMBER
public static final int MATERIAL_ICON_FIELD_NUMBER
- See Also:
- Constant Field Values
-
ALT_TEXT_FIELD_NUMBER
public static final int ALT_TEXT_FIELD_NUMBER
- See Also:
- Constant Field Values
-
IMAGE_TYPE_FIELD_NUMBER
public static final int IMAGE_TYPE_FIELD_NUMBER
- See Also:
- Constant Field Values
-
-
Method Detail
-
newInstance
protected java.lang.Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
- Overrides:
newInstancein classcom.google.protobuf.GeneratedMessageV3
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Overrides:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3
-
getIconsCase
public Icon.IconsCase getIconsCase()
- Specified by:
getIconsCasein interfaceIconOrBuilder
-
hasKnownIcon
public boolean hasKnownIcon()
Display one of the built-in icons provided by Google Workspace. For example, to display an airplane icon, specify `AIRPLANE`. For a bus, specify `BUS`. For a full list of supported icons, see [built-in icons](https://developers.google.com/workspace/chat/format-messages#builtinicons).
string known_icon = 1;- Specified by:
hasKnownIconin interfaceIconOrBuilder- Returns:
- Whether the knownIcon field is set.
-
getKnownIcon
public java.lang.String getKnownIcon()
Display one of the built-in icons provided by Google Workspace. For example, to display an airplane icon, specify `AIRPLANE`. For a bus, specify `BUS`. For a full list of supported icons, see [built-in icons](https://developers.google.com/workspace/chat/format-messages#builtinicons).
string known_icon = 1;- Specified by:
getKnownIconin interfaceIconOrBuilder- Returns:
- The knownIcon.
-
getKnownIconBytes
public com.google.protobuf.ByteString getKnownIconBytes()
Display one of the built-in icons provided by Google Workspace. For example, to display an airplane icon, specify `AIRPLANE`. For a bus, specify `BUS`. For a full list of supported icons, see [built-in icons](https://developers.google.com/workspace/chat/format-messages#builtinicons).
string known_icon = 1;- Specified by:
getKnownIconBytesin interfaceIconOrBuilder- Returns:
- The bytes for knownIcon.
-
hasIconUrl
public boolean hasIconUrl()
Display a custom icon hosted at an HTTPS URL. For example: ``` "iconUrl": "https://developers.google.com/workspace/chat/images/quickstart-app-avatar.png" ``` Supported file types include `.png` and `.jpg`.
string icon_url = 2;- Specified by:
hasIconUrlin interfaceIconOrBuilder- Returns:
- Whether the iconUrl field is set.
-
getIconUrl
public java.lang.String getIconUrl()
Display a custom icon hosted at an HTTPS URL. For example: ``` "iconUrl": "https://developers.google.com/workspace/chat/images/quickstart-app-avatar.png" ``` Supported file types include `.png` and `.jpg`.
string icon_url = 2;- Specified by:
getIconUrlin interfaceIconOrBuilder- Returns:
- The iconUrl.
-
getIconUrlBytes
public com.google.protobuf.ByteString getIconUrlBytes()
Display a custom icon hosted at an HTTPS URL. For example: ``` "iconUrl": "https://developers.google.com/workspace/chat/images/quickstart-app-avatar.png" ``` Supported file types include `.png` and `.jpg`.
string icon_url = 2;- Specified by:
getIconUrlBytesin interfaceIconOrBuilder- Returns:
- The bytes for iconUrl.
-
hasMaterialIcon
public boolean hasMaterialIcon()
Display one of the [Google Material Icons](https://fonts.google.com/icons). For example, to display a [checkbox icon](https://fonts.google.com/icons?selected=Material%20Symbols%20Outlined%3Acheck_box%3AFILL%400%3Bwght%40400%3BGRAD%400%3Bopsz%4048), use ``` "material_icon": { "name": "check_box" } ``` [Google Chat apps](https://developers.google.com/workspace/chat):.google.apps.card.v1.MaterialIcon material_icon = 5;- Specified by:
hasMaterialIconin interfaceIconOrBuilder- Returns:
- Whether the materialIcon field is set.
-
getMaterialIcon
public MaterialIcon getMaterialIcon()
Display one of the [Google Material Icons](https://fonts.google.com/icons). For example, to display a [checkbox icon](https://fonts.google.com/icons?selected=Material%20Symbols%20Outlined%3Acheck_box%3AFILL%400%3Bwght%40400%3BGRAD%400%3Bopsz%4048), use ``` "material_icon": { "name": "check_box" } ``` [Google Chat apps](https://developers.google.com/workspace/chat):.google.apps.card.v1.MaterialIcon material_icon = 5;- Specified by:
getMaterialIconin interfaceIconOrBuilder- Returns:
- The materialIcon.
-
getMaterialIconOrBuilder
public MaterialIconOrBuilder getMaterialIconOrBuilder()
Display one of the [Google Material Icons](https://fonts.google.com/icons). For example, to display a [checkbox icon](https://fonts.google.com/icons?selected=Material%20Symbols%20Outlined%3Acheck_box%3AFILL%400%3Bwght%40400%3BGRAD%400%3Bopsz%4048), use ``` "material_icon": { "name": "check_box" } ``` [Google Chat apps](https://developers.google.com/workspace/chat):.google.apps.card.v1.MaterialIcon material_icon = 5;- Specified by:
getMaterialIconOrBuilderin interfaceIconOrBuilder
-
getAltText
public java.lang.String getAltText()
Optional. A description of the icon used for accessibility. If unspecified, the default value `Button` is provided. As a best practice, you should set a helpful description for what the icon displays, and if applicable, what it does. For example, `A user's account portrait`, or `Opens a new browser tab and navigates to the Google Chat developer documentation at https://developers.google.com/workspace/chat`. If the icon is set in a [`Button`][google.apps.card.v1.Button], the `altText` appears as helper text when the user hovers over the button. However, if the button also sets `text`, the icon's `altText` is ignored.
string alt_text = 3;- Specified by:
getAltTextin interfaceIconOrBuilder- Returns:
- The altText.
-
getAltTextBytes
public com.google.protobuf.ByteString getAltTextBytes()
Optional. A description of the icon used for accessibility. If unspecified, the default value `Button` is provided. As a best practice, you should set a helpful description for what the icon displays, and if applicable, what it does. For example, `A user's account portrait`, or `Opens a new browser tab and navigates to the Google Chat developer documentation at https://developers.google.com/workspace/chat`. If the icon is set in a [`Button`][google.apps.card.v1.Button], the `altText` appears as helper text when the user hovers over the button. However, if the button also sets `text`, the icon's `altText` is ignored.
string alt_text = 3;- Specified by:
getAltTextBytesin interfaceIconOrBuilder- Returns:
- The bytes for altText.
-
getImageTypeValue
public int getImageTypeValue()
The crop style applied to the image. In some cases, applying a `CIRCLE` crop causes the image to be drawn larger than a built-in icon.
.google.apps.card.v1.Widget.ImageType image_type = 4;- Specified by:
getImageTypeValuein interfaceIconOrBuilder- Returns:
- The enum numeric value on the wire for imageType.
-
getImageType
public Widget.ImageType getImageType()
The crop style applied to the image. In some cases, applying a `CIRCLE` crop causes the image to be drawn larger than a built-in icon.
.google.apps.card.v1.Widget.ImageType image_type = 4;- Specified by:
getImageTypein interfaceIconOrBuilder- Returns:
- The imageType.
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.ExtendableMessage<com.google.protobuf.GeneratedMessageV3>
-
writeTo
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException- Specified by:
writeToin interfacecom.google.protobuf.MessageLite- Overrides:
writeToin classcom.google.protobuf.GeneratedMessage- Throws:
java.io.IOException
-
getSerializedSize
public int getSerializedSize()
- Specified by:
getSerializedSizein interfacecom.google.protobuf.MessageLite- Overrides:
getSerializedSizein classcom.google.protobuf.GeneratedMessage
-
equals
public boolean equals(java.lang.Object obj)
- 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 Icon parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Icon parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Icon parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Icon parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Icon parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Icon parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Icon parseFrom(java.io.InputStream input) throws java.io.IOException
- Throws:
java.io.IOException
-
parseFrom
public static Icon parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
- Throws:
java.io.IOException
-
parseDelimitedFrom
public static Icon parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException
- Throws:
java.io.IOException
-
parseDelimitedFrom
public static Icon parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
- Throws:
java.io.IOException
-
parseFrom
public static Icon parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException
- Throws:
java.io.IOException
-
parseFrom
public static Icon parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
- Throws:
java.io.IOException
-
newBuilderForType
public Icon.Builder newBuilderForType()
- Specified by:
newBuilderForTypein interfacecom.google.protobuf.Message- Specified by:
newBuilderForTypein interfacecom.google.protobuf.MessageLite
-
newBuilder
public static Icon.Builder newBuilder()
-
newBuilder
public static Icon.Builder newBuilder(Icon prototype)
-
toBuilder
public Icon.Builder toBuilder()
- Specified by:
toBuilderin interfacecom.google.protobuf.Message- Specified by:
toBuilderin interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected Icon.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
- Specified by:
newBuilderForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
public static Icon getDefaultInstance()
-
parser
public static com.google.protobuf.Parser<Icon> parser()
-
getParserForType
public com.google.protobuf.Parser<Icon> getParserForType()
- Specified by:
getParserForTypein interfacecom.google.protobuf.Message- Specified by:
getParserForTypein interfacecom.google.protobuf.MessageLite- Overrides:
getParserForTypein classcom.google.protobuf.GeneratedMessage
-
getDefaultInstanceForType
public Icon getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<com.google.protobuf.GeneratedMessageV3>- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
-