Package com.google.apps.card.v1
Class Card.Section.Builder
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite.Builder
-
- com.google.protobuf.AbstractMessage.Builder<BuilderT>
-
- com.google.protobuf.GeneratedMessage.Builder<BuilderT>
-
- com.google.protobuf.GeneratedMessage.ExtendableBuilder<com.google.protobuf.GeneratedMessageV3,BuilderT>
-
- com.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
- com.google.apps.card.v1.Card.Section.Builder
-
- All Implemented Interfaces:
Card.SectionOrBuilder
,com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<com.google.protobuf.GeneratedMessageV3>
,com.google.protobuf.Message.Builder
,com.google.protobuf.MessageLite.Builder
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,java.lang.Cloneable
- Enclosing class:
- Card.Section
public static final class Card.Section.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder> implements Card.SectionOrBuilder
A section contains a collection of widgets that are rendered vertically in the order that they're specified. [Google Workspace Add-ons and Chat apps](https://developers.google.com/workspace/extend):
Protobuf typegoogle.apps.card.v1.Card.Section
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Card.Section.Builder
addAllWidgets(java.lang.Iterable<? extends Widget> values)
All the widgets in the section.Card.Section.Builder
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)
Card.Section.Builder
addWidgets(int index, Widget value)
All the widgets in the section.Card.Section.Builder
addWidgets(int index, Widget.Builder builderForValue)
All the widgets in the section.Card.Section.Builder
addWidgets(Widget value)
All the widgets in the section.Card.Section.Builder
addWidgets(Widget.Builder builderForValue)
All the widgets in the section.Widget.Builder
addWidgetsBuilder()
All the widgets in the section.Widget.Builder
addWidgetsBuilder(int index)
All the widgets in the section.Card.Section
build()
Card.Section
buildPartial()
Card.Section.Builder
clear()
Card.Section.Builder
clearCollapsible()
Indicates whether this section is collapsible.Card.Section.Builder
clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
Card.Section.Builder
clearHeader()
Text that appears at the top of a section.Card.Section.Builder
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
Card.Section.Builder
clearUncollapsibleWidgetsCount()
The number of uncollapsible widgets which remain visible even when a section is collapsed.Card.Section.Builder
clearWidgets()
All the widgets in the section.Card.Section.Builder
clone()
boolean
getCollapsible()
Indicates whether this section is collapsible.Card.Section
getDefaultInstanceForType()
static com.google.protobuf.Descriptors.Descriptor
getDescriptor()
com.google.protobuf.Descriptors.Descriptor
getDescriptorForType()
java.lang.String
getHeader()
Text that appears at the top of a section.com.google.protobuf.ByteString
getHeaderBytes()
Text that appears at the top of a section.int
getUncollapsibleWidgetsCount()
The number of uncollapsible widgets which remain visible even when a section is collapsed.Widget
getWidgets(int index)
All the widgets in the section.Widget.Builder
getWidgetsBuilder(int index)
All the widgets in the section.java.util.List<Widget.Builder>
getWidgetsBuilderList()
All the widgets in the section.int
getWidgetsCount()
All the widgets in the section.java.util.List<Widget>
getWidgetsList()
All the widgets in the section.WidgetOrBuilder
getWidgetsOrBuilder(int index)
All the widgets in the section.java.util.List<? extends WidgetOrBuilder>
getWidgetsOrBuilderList()
All the widgets in the section.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()
boolean
isInitialized()
Card.Section.Builder
mergeFrom(Card.Section other)
Card.Section.Builder
mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
Card.Section.Builder
mergeFrom(com.google.protobuf.Message other)
Card.Section.Builder
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
Card.Section.Builder
removeWidgets(int index)
All the widgets in the section.Card.Section.Builder
setCollapsible(boolean value)
Indicates whether this section is collapsible.Card.Section.Builder
setField(com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)
Card.Section.Builder
setHeader(java.lang.String value)
Text that appears at the top of a section.Card.Section.Builder
setHeaderBytes(com.google.protobuf.ByteString value)
Text that appears at the top of a section.Card.Section.Builder
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)
Card.Section.Builder
setUncollapsibleWidgetsCount(int value)
The number of uncollapsible widgets which remain visible even when a section is collapsed.Card.Section.Builder
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
Card.Section.Builder
setWidgets(int index, Widget value)
All the widgets in the section.Card.Section.Builder
setWidgets(int index, Widget.Builder builderForValue)
All the widgets in the section.-
Methods inherited from class com.google.protobuf.GeneratedMessage.ExtendableBuilder
addExtension, clearExtension, extensionsAreInitialized, getAllFields, getExtension, getExtension, getExtensionCount, getField, getFieldBuilder, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, hasExtension, hasField, mergeExtensionFields, newBuilderForField, parseUnknownField, setExtension, setExtension
-
Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
getOneofFieldDescriptor, getUnknownFields, getUnknownFieldSetBuilder, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, onBuilt, onChanged, setUnknownFieldSetBuilder, setUnknownFieldsProto3
-
Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
-
-
-
Method Detail
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Overrides:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
clear
public Card.Section.Builder clear()
- Specified by:
clear
in interfacecom.google.protobuf.Message.Builder
- Specified by:
clear
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
clear
in classcom.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.Message.Builder
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.MessageOrBuilder
- Overrides:
getDescriptorForType
in classcom.google.protobuf.GeneratedMessage.Builder<Card.Section.Builder>
-
getDefaultInstanceForType
public Card.Section getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<com.google.protobuf.GeneratedMessageV3>
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-
build
public Card.Section build()
- Specified by:
build
in interfacecom.google.protobuf.Message.Builder
- Specified by:
build
in interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
public Card.Section buildPartial()
- Specified by:
buildPartial
in interfacecom.google.protobuf.Message.Builder
- Specified by:
buildPartial
in interfacecom.google.protobuf.MessageLite.Builder
-
clone
public Card.Section.Builder clone()
- Specified by:
clone
in interfacecom.google.protobuf.Message.Builder
- Specified by:
clone
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
clone
in classcom.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
setField
public Card.Section.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)
- Specified by:
setField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setField
in classcom.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
clearField
public Card.Section.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
- Specified by:
clearField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
clearField
in classcom.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
clearOneof
public Card.Section.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
- Specified by:
clearOneof
in interfacecom.google.protobuf.Message.Builder
- Overrides:
clearOneof
in classcom.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
setRepeatedField
public Card.Section.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)
- Specified by:
setRepeatedField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setRepeatedField
in classcom.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
addRepeatedField
public Card.Section.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)
- Specified by:
addRepeatedField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
addRepeatedField
in classcom.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
mergeFrom
public Card.Section.Builder mergeFrom(com.google.protobuf.Message other)
- Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<Card.Section.Builder>
-
mergeFrom
public Card.Section.Builder mergeFrom(Card.Section other)
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessage.ExtendableBuilder<com.google.protobuf.GeneratedMessageV3,Card.Section.Builder>
-
mergeFrom
public Card.Section.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
- Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Specified by:
mergeFrom
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<Card.Section.Builder>
- Throws:
java.io.IOException
-
getHeader
public java.lang.String getHeader()
Text that appears at the top of a section. Supports simple HTML formatted text. 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 header = 1;
- Specified by:
getHeader
in interfaceCard.SectionOrBuilder
- Returns:
- The header.
-
getHeaderBytes
public com.google.protobuf.ByteString getHeaderBytes()
Text that appears at the top of a section. Supports simple HTML formatted text. 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 header = 1;
- Specified by:
getHeaderBytes
in interfaceCard.SectionOrBuilder
- Returns:
- The bytes for header.
-
setHeader
public Card.Section.Builder setHeader(java.lang.String value)
Text that appears at the top of a section. Supports simple HTML formatted text. 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 header = 1;
- Parameters:
value
- The header to set.- Returns:
- This builder for chaining.
-
clearHeader
public Card.Section.Builder clearHeader()
Text that appears at the top of a section. Supports simple HTML formatted text. 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 header = 1;
- Returns:
- This builder for chaining.
-
setHeaderBytes
public Card.Section.Builder setHeaderBytes(com.google.protobuf.ByteString value)
Text that appears at the top of a section. Supports simple HTML formatted text. 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 header = 1;
- Parameters:
value
- The bytes for header to set.- Returns:
- This builder for chaining.
-
getWidgetsList
public java.util.List<Widget> getWidgetsList()
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
- Specified by:
getWidgetsList
in interfaceCard.SectionOrBuilder
-
getWidgetsCount
public int getWidgetsCount()
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
- Specified by:
getWidgetsCount
in interfaceCard.SectionOrBuilder
-
getWidgets
public Widget getWidgets(int index)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
- Specified by:
getWidgets
in interfaceCard.SectionOrBuilder
-
setWidgets
public Card.Section.Builder setWidgets(int index, Widget value)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
setWidgets
public Card.Section.Builder setWidgets(int index, Widget.Builder builderForValue)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
addWidgets
public Card.Section.Builder addWidgets(Widget value)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
addWidgets
public Card.Section.Builder addWidgets(int index, Widget value)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
addWidgets
public Card.Section.Builder addWidgets(Widget.Builder builderForValue)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
addWidgets
public Card.Section.Builder addWidgets(int index, Widget.Builder builderForValue)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
addAllWidgets
public Card.Section.Builder addAllWidgets(java.lang.Iterable<? extends Widget> values)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
clearWidgets
public Card.Section.Builder clearWidgets()
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
removeWidgets
public Card.Section.Builder removeWidgets(int index)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
getWidgetsBuilder
public Widget.Builder getWidgetsBuilder(int index)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
getWidgetsOrBuilder
public WidgetOrBuilder getWidgetsOrBuilder(int index)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
- Specified by:
getWidgetsOrBuilder
in interfaceCard.SectionOrBuilder
-
getWidgetsOrBuilderList
public java.util.List<? extends WidgetOrBuilder> getWidgetsOrBuilderList()
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
- Specified by:
getWidgetsOrBuilderList
in interfaceCard.SectionOrBuilder
-
addWidgetsBuilder
public Widget.Builder addWidgetsBuilder()
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
addWidgetsBuilder
public Widget.Builder addWidgetsBuilder(int index)
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
getWidgetsBuilderList
public java.util.List<Widget.Builder> getWidgetsBuilderList()
All the widgets in the section. Must contain at least one widget.
repeated .google.apps.card.v1.Widget widgets = 2;
-
getCollapsible
public boolean getCollapsible()
Indicates whether this section is collapsible. Collapsible sections hide some or all widgets, but users can expand the section to reveal the hidden widgets by clicking **Show more**. Users can hide the widgets again by clicking **Show less**. To determine which widgets are hidden, specify `uncollapsibleWidgetsCount`.
bool collapsible = 5;
- Specified by:
getCollapsible
in interfaceCard.SectionOrBuilder
- Returns:
- The collapsible.
-
setCollapsible
public Card.Section.Builder setCollapsible(boolean value)
Indicates whether this section is collapsible. Collapsible sections hide some or all widgets, but users can expand the section to reveal the hidden widgets by clicking **Show more**. Users can hide the widgets again by clicking **Show less**. To determine which widgets are hidden, specify `uncollapsibleWidgetsCount`.
bool collapsible = 5;
- Parameters:
value
- The collapsible to set.- Returns:
- This builder for chaining.
-
clearCollapsible
public Card.Section.Builder clearCollapsible()
Indicates whether this section is collapsible. Collapsible sections hide some or all widgets, but users can expand the section to reveal the hidden widgets by clicking **Show more**. Users can hide the widgets again by clicking **Show less**. To determine which widgets are hidden, specify `uncollapsibleWidgetsCount`.
bool collapsible = 5;
- Returns:
- This builder for chaining.
-
getUncollapsibleWidgetsCount
public int getUncollapsibleWidgetsCount()
The number of uncollapsible widgets which remain visible even when a section is collapsed. For example, when a section contains five widgets and the `uncollapsibleWidgetsCount` is set to `2`, the first two widgets are always shown and the last three are collapsed by default. The `uncollapsibleWidgetsCount` is taken into account only when `collapsible` is `true`.
int32 uncollapsible_widgets_count = 6;
- Specified by:
getUncollapsibleWidgetsCount
in interfaceCard.SectionOrBuilder
- Returns:
- The uncollapsibleWidgetsCount.
-
setUncollapsibleWidgetsCount
public Card.Section.Builder setUncollapsibleWidgetsCount(int value)
The number of uncollapsible widgets which remain visible even when a section is collapsed. For example, when a section contains five widgets and the `uncollapsibleWidgetsCount` is set to `2`, the first two widgets are always shown and the last three are collapsed by default. The `uncollapsibleWidgetsCount` is taken into account only when `collapsible` is `true`.
int32 uncollapsible_widgets_count = 6;
- Parameters:
value
- The uncollapsibleWidgetsCount to set.- Returns:
- This builder for chaining.
-
clearUncollapsibleWidgetsCount
public Card.Section.Builder clearUncollapsibleWidgetsCount()
The number of uncollapsible widgets which remain visible even when a section is collapsed. For example, when a section contains five widgets and the `uncollapsibleWidgetsCount` is set to `2`, the first two widgets are always shown and the last three are collapsed by default. The `uncollapsibleWidgetsCount` is taken into account only when `collapsible` is `true`.
int32 uncollapsible_widgets_count = 6;
- Returns:
- This builder for chaining.
-
setUnknownFields
public final Card.Section.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
setUnknownFields
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setUnknownFields
in classcom.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
mergeUnknownFields
public final Card.Section.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
mergeUnknownFields
in interfacecom.google.protobuf.Message.Builder
- Overrides:
mergeUnknownFields
in classcom.google.protobuf.GeneratedMessageV3.Builder<Card.Section.Builder>
-
-