Class OnClick.Builder (2.37.1)

public static final class OnClick.Builder extends GeneratedMessageV3.Builder<OnClick.Builder> implements OnClickOrBuilder

Represents how to respond when users click an interactive element on a card, such as a button.

Google Workspace Add-ons and Chat apps:

Protobuf type google.apps.card.v1.OnClick

Implements

OnClickOrBuilder

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public OnClick.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
OnClick.Builder
Overrides

build()

public OnClick build()
Returns
TypeDescription
OnClick

buildPartial()

public OnClick buildPartial()
Returns
TypeDescription
OnClick

clear()

public OnClick.Builder clear()
Returns
TypeDescription
OnClick.Builder
Overrides

clearAction()

public OnClick.Builder clearAction()

If specified, an action is triggered by this onClick.

.google.apps.card.v1.Action action = 1;

Returns
TypeDescription
OnClick.Builder

clearCard()

public OnClick.Builder clearCard()

A new card is pushed to the card stack after clicking if specified.

Google Workspace Add-ons:

.google.apps.card.v1.Card card = 4;

Returns
TypeDescription
OnClick.Builder

clearData()

public OnClick.Builder clearData()
Returns
TypeDescription
OnClick.Builder

clearField(Descriptors.FieldDescriptor field)

public OnClick.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
OnClick.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public OnClick.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
OnClick.Builder
Overrides

clearOpenDynamicLinkAction()

public OnClick.Builder clearOpenDynamicLinkAction()

An add-on triggers this action when the action needs to open a link. This differs from the open_link above in that this needs to talk to server to get the link. Thus some preparation work is required for web client to do before the open link action response comes back.

Google Workspace Add-ons:

.google.apps.card.v1.Action open_dynamic_link_action = 3;

Returns
TypeDescription
OnClick.Builder
public OnClick.Builder clearOpenLink()

If specified, this onClick triggers an open link action.

.google.apps.card.v1.OpenLink open_link = 2;

Returns
TypeDescription
OnClick.Builder

clone()

public OnClick.Builder clone()
Returns
TypeDescription
OnClick.Builder
Overrides

getAction()

public Action getAction()

If specified, an action is triggered by this onClick.

.google.apps.card.v1.Action action = 1;

Returns
TypeDescription
Action

The action.

getActionBuilder()

public Action.Builder getActionBuilder()

If specified, an action is triggered by this onClick.

.google.apps.card.v1.Action action = 1;

Returns
TypeDescription
Action.Builder

getActionOrBuilder()

public ActionOrBuilder getActionOrBuilder()

If specified, an action is triggered by this onClick.

.google.apps.card.v1.Action action = 1;

Returns
TypeDescription
ActionOrBuilder

getCard()

public Card getCard()

A new card is pushed to the card stack after clicking if specified.

Google Workspace Add-ons:

.google.apps.card.v1.Card card = 4;

Returns
TypeDescription
Card

The card.

getCardBuilder()

public Card.Builder getCardBuilder()

A new card is pushed to the card stack after clicking if specified.

Google Workspace Add-ons:

.google.apps.card.v1.Card card = 4;

Returns
TypeDescription
Card.Builder

getCardOrBuilder()

public CardOrBuilder getCardOrBuilder()

A new card is pushed to the card stack after clicking if specified.

Google Workspace Add-ons:

.google.apps.card.v1.Card card = 4;

Returns
TypeDescription
CardOrBuilder

getDataCase()

public OnClick.DataCase getDataCase()
Returns
TypeDescription
OnClick.DataCase

getDefaultInstanceForType()

public OnClick getDefaultInstanceForType()
Returns
TypeDescription
OnClick

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getOpenDynamicLinkAction()

public Action getOpenDynamicLinkAction()

An add-on triggers this action when the action needs to open a link. This differs from the open_link above in that this needs to talk to server to get the link. Thus some preparation work is required for web client to do before the open link action response comes back.

Google Workspace Add-ons:

.google.apps.card.v1.Action open_dynamic_link_action = 3;

Returns
TypeDescription
Action

The openDynamicLinkAction.

getOpenDynamicLinkActionBuilder()

public Action.Builder getOpenDynamicLinkActionBuilder()

An add-on triggers this action when the action needs to open a link. This differs from the open_link above in that this needs to talk to server to get the link. Thus some preparation work is required for web client to do before the open link action response comes back.

Google Workspace Add-ons:

.google.apps.card.v1.Action open_dynamic_link_action = 3;

Returns
TypeDescription
Action.Builder

getOpenDynamicLinkActionOrBuilder()

public ActionOrBuilder getOpenDynamicLinkActionOrBuilder()

An add-on triggers this action when the action needs to open a link. This differs from the open_link above in that this needs to talk to server to get the link. Thus some preparation work is required for web client to do before the open link action response comes back.

Google Workspace Add-ons:

.google.apps.card.v1.Action open_dynamic_link_action = 3;

Returns
TypeDescription
ActionOrBuilder
public OpenLink getOpenLink()

If specified, this onClick triggers an open link action.

.google.apps.card.v1.OpenLink open_link = 2;

Returns
TypeDescription
OpenLink

The openLink.

getOpenLinkBuilder()

public OpenLink.Builder getOpenLinkBuilder()

If specified, this onClick triggers an open link action.

.google.apps.card.v1.OpenLink open_link = 2;

Returns
TypeDescription
OpenLink.Builder

getOpenLinkOrBuilder()

public OpenLinkOrBuilder getOpenLinkOrBuilder()

If specified, this onClick triggers an open link action.

.google.apps.card.v1.OpenLink open_link = 2;

Returns
TypeDescription
OpenLinkOrBuilder

hasAction()

public boolean hasAction()

If specified, an action is triggered by this onClick.

.google.apps.card.v1.Action action = 1;

Returns
TypeDescription
boolean

Whether the action field is set.

hasCard()

public boolean hasCard()

A new card is pushed to the card stack after clicking if specified.

Google Workspace Add-ons:

.google.apps.card.v1.Card card = 4;

Returns
TypeDescription
boolean

Whether the card field is set.

hasOpenDynamicLinkAction()

public boolean hasOpenDynamicLinkAction()

An add-on triggers this action when the action needs to open a link. This differs from the open_link above in that this needs to talk to server to get the link. Thus some preparation work is required for web client to do before the open link action response comes back.

Google Workspace Add-ons:

.google.apps.card.v1.Action open_dynamic_link_action = 3;

Returns
TypeDescription
boolean

Whether the openDynamicLinkAction field is set.

public boolean hasOpenLink()

If specified, this onClick triggers an open link action.

.google.apps.card.v1.OpenLink open_link = 2;

Returns
TypeDescription
boolean

Whether the openLink field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeAction(Action value)

public OnClick.Builder mergeAction(Action value)

If specified, an action is triggered by this onClick.

.google.apps.card.v1.Action action = 1;

Parameter
NameDescription
valueAction
Returns
TypeDescription
OnClick.Builder

mergeCard(Card value)

public OnClick.Builder mergeCard(Card value)

A new card is pushed to the card stack after clicking if specified.

Google Workspace Add-ons:

.google.apps.card.v1.Card card = 4;

Parameter
NameDescription
valueCard
Returns
TypeDescription
OnClick.Builder

mergeFrom(OnClick other)

public OnClick.Builder mergeFrom(OnClick other)
Parameter
NameDescription
otherOnClick
Returns
TypeDescription
OnClick.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public OnClick.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OnClick.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public OnClick.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
OnClick.Builder
Overrides

mergeOpenDynamicLinkAction(Action value)

public OnClick.Builder mergeOpenDynamicLinkAction(Action value)

An add-on triggers this action when the action needs to open a link. This differs from the open_link above in that this needs to talk to server to get the link. Thus some preparation work is required for web client to do before the open link action response comes back.

Google Workspace Add-ons:

.google.apps.card.v1.Action open_dynamic_link_action = 3;

Parameter
NameDescription
valueAction
Returns
TypeDescription
OnClick.Builder
public OnClick.Builder mergeOpenLink(OpenLink value)

If specified, this onClick triggers an open link action.

.google.apps.card.v1.OpenLink open_link = 2;

Parameter
NameDescription
valueOpenLink
Returns
TypeDescription
OnClick.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final OnClick.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
OnClick.Builder
Overrides

setAction(Action value)

public OnClick.Builder setAction(Action value)

If specified, an action is triggered by this onClick.

.google.apps.card.v1.Action action = 1;

Parameter
NameDescription
valueAction
Returns
TypeDescription
OnClick.Builder

setAction(Action.Builder builderForValue)

public OnClick.Builder setAction(Action.Builder builderForValue)

If specified, an action is triggered by this onClick.

.google.apps.card.v1.Action action = 1;

Parameter
NameDescription
builderForValueAction.Builder
Returns
TypeDescription
OnClick.Builder

setCard(Card value)

public OnClick.Builder setCard(Card value)

A new card is pushed to the card stack after clicking if specified.

Google Workspace Add-ons:

.google.apps.card.v1.Card card = 4;

Parameter
NameDescription
valueCard
Returns
TypeDescription
OnClick.Builder

setCard(Card.Builder builderForValue)

public OnClick.Builder setCard(Card.Builder builderForValue)

A new card is pushed to the card stack after clicking if specified.

Google Workspace Add-ons:

.google.apps.card.v1.Card card = 4;

Parameter
NameDescription
builderForValueCard.Builder
Returns
TypeDescription
OnClick.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public OnClick.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
OnClick.Builder
Overrides

setOpenDynamicLinkAction(Action value)

public OnClick.Builder setOpenDynamicLinkAction(Action value)

An add-on triggers this action when the action needs to open a link. This differs from the open_link above in that this needs to talk to server to get the link. Thus some preparation work is required for web client to do before the open link action response comes back.

Google Workspace Add-ons:

.google.apps.card.v1.Action open_dynamic_link_action = 3;

Parameter
NameDescription
valueAction
Returns
TypeDescription
OnClick.Builder

setOpenDynamicLinkAction(Action.Builder builderForValue)

public OnClick.Builder setOpenDynamicLinkAction(Action.Builder builderForValue)

An add-on triggers this action when the action needs to open a link. This differs from the open_link above in that this needs to talk to server to get the link. Thus some preparation work is required for web client to do before the open link action response comes back.

Google Workspace Add-ons:

.google.apps.card.v1.Action open_dynamic_link_action = 3;

Parameter
NameDescription
builderForValueAction.Builder
Returns
TypeDescription
OnClick.Builder
public OnClick.Builder setOpenLink(OpenLink value)

If specified, this onClick triggers an open link action.

.google.apps.card.v1.OpenLink open_link = 2;

Parameter
NameDescription
valueOpenLink
Returns
TypeDescription
OnClick.Builder
public OnClick.Builder setOpenLink(OpenLink.Builder builderForValue)

If specified, this onClick triggers an open link action.

.google.apps.card.v1.OpenLink open_link = 2;

Parameter
NameDescription
builderForValueOpenLink.Builder
Returns
TypeDescription
OnClick.Builder

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public OnClick.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
OnClick.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final OnClick.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
OnClick.Builder
Overrides