0.31.0 (latest) 0.30.0 0.29.0 0.28.0 0.27.0 0.23.0 0.20.0 0.19.0 0.18.0 0.17.1 0.16.1 0.15.0 0.14.0 0.13.1 0.12.1 0.11.2 0.10.0 0.9.0 0.8.1 0.7.2 0.6.1 0.5.0 0.4.0 0.3.0 0.2.0 0.1.4 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` | `WidgetMarkup\TextParagraph` Display a text paragraph in this widget. |
| `↳ image` | `WidgetMarkup\Image` Display an image in this widget. |
| `↳ key_value` | `WidgetMarkup\KeyValue` Display a key value item in this widget. |
| `↳ buttons` | `array<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** |
| `WidgetMarkup\TextParagraph|null` |   |

### hasTextParagraph

### setTextParagraph

Display a text paragraph in this widget.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `WidgetMarkup\TextParagraph` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getImage

Display an image in this widget.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `WidgetMarkup\Image|null` |   |

### hasImage

### setImage

Display an image in this widget.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `WidgetMarkup\Image` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getKeyValue

Display a key value item in this widget.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `WidgetMarkup\KeyValue|null` |   |

### hasKeyValue

### setKeyValue

Display a key value item in this widget.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `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\RepeatedField<WidgetMarkup\Button>` |   |

### setButtons

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

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<WidgetMarkup\Button>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getData

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |