Google Apps Chat V1 Client - Class WidgetMarkup (0.3.0)

Reference documentation and code samples for the Google Apps Chat V1 Client class WidgetMarkup.

A widget is a UI element that presents text and images.

Generated from protobuf message google.chat.v1.WidgetMarkup

Namespace

Google \ Apps \ Chat \ V1

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ text_paragraph Google\Apps\Chat\V1\WidgetMarkup\TextParagraph

Display a text paragraph in this widget.

↳ image Google\Apps\Chat\V1\WidgetMarkup\Image

Display an image in this widget.

↳ key_value Google\Apps\Chat\V1\WidgetMarkup\KeyValue

Display a key value item in this widget.

↳ buttons array<Google\Apps\Chat\V1\WidgetMarkup\Button>

A list of buttons. Buttons is also oneof data and only one of these fields should be set.

getTextParagraph

Display a text paragraph in this widget.

Returns
Type Description
Google\Apps\Chat\V1\WidgetMarkup\TextParagraph|null

hasTextParagraph

setTextParagraph

Display a text paragraph in this widget.

Parameter
Name Description
var Google\Apps\Chat\V1\WidgetMarkup\TextParagraph
Returns
Type Description
$this

getImage

Display an image in this widget.

Returns
Type Description
Google\Apps\Chat\V1\WidgetMarkup\Image|null

hasImage

setImage

Display an image in this widget.

Parameter
Name Description
var Google\Apps\Chat\V1\WidgetMarkup\Image
Returns
Type Description
$this

getKeyValue

Display a key value item in this widget.

Returns
Type Description
Google\Apps\Chat\V1\WidgetMarkup\KeyValue|null

hasKeyValue

setKeyValue

Display a key value item in this widget.

Parameter
Name Description
var Google\Apps\Chat\V1\WidgetMarkup\KeyValue
Returns
Type Description
$this

getButtons

A list of buttons. Buttons is also oneof data and only one of these fields should be set.

Returns
Type Description
Google\Protobuf\Internal\RepeatedField

setButtons

A list of buttons. Buttons is also oneof data and only one of these fields should be set.

Parameter
Name Description
var array<Google\Apps\Chat\V1\WidgetMarkup\Button>
Returns
Type Description
$this

getData

Returns
Type Description
string