# Google Anthos Multi Cloud V1 Client - Class Toleration (1.4.1)

1.4.1 (latest) 1.4.0 1.3.1 1.2.2 1.1.2 1.0.0 0.6.1 0.5.4 0.4.4 0.3.0 0.2.3 0.1.4 Reference documentation and code samples for the Google Anthos Multi Cloud V1 Client class Toleration.

Toleration defines the fields for tolerations for pods created by
auto-installed components.

Generated from protobuf message `google.cloud.gkemulticloud.v1.Toleration`

## Namespace

Google \\ Cloud \\ GkeMultiCloud \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ key` | `string` Key is the taint key that the toleration applies to. |
| `↳ value` | `string` Value is the taint value that the toleration applies to. |
| `↳ key_operator` | `int` KeyOperator represents a key's relationship to the value e.g. 'Exist'. |
| `↳ effect` | `int` Effect indicates the taint effect to match e.g. 'NoSchedule' |

### getKey

Key is the taint key that the toleration applies to.

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

### setKey

Key is the taint key that the toleration applies to.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

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

### getValue

Value is the taint value that the toleration applies to.

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

### setValue

Value is the taint value that the toleration applies to.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

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

### getKeyOperator

KeyOperator represents a key's relationship to the value e.g. 'Exist'.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [KeyOperator](https://docs.cloud.google.com/php/docs/reference/cloud-gke-multi-cloud/latest/V1.Toleration.KeyOperator). |

### setKeyOperator

KeyOperator represents a key's relationship to the value e.g. 'Exist'.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [KeyOperator](https://docs.cloud.google.com/php/docs/reference/cloud-gke-multi-cloud/latest/V1.Toleration.KeyOperator). |

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

### getEffect

Effect indicates the taint effect to match e.g. 'NoSchedule'

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [Effect](https://docs.cloud.google.com/php/docs/reference/cloud-gke-multi-cloud/latest/V1.Toleration.Effect). |

### setEffect

Effect indicates the taint effect to match e.g. 'NoSchedule'

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [Effect](https://docs.cloud.google.com/php/docs/reference/cloud-gke-multi-cloud/latest/V1.Toleration.Effect). |

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