# Google Cloud Network Services V1 Client - Class HeaderModifier (0.8.2)

0.8.2 (latest) 0.8.1 0.7.1 0.6.1 0.5.0 0.4.0 0.3.0 0.2.3 0.1.1 Reference documentation and code samples for the Google Cloud Network Services V1 Client class HeaderModifier.

The specification for modifying HTTP header in HTTP request and HTTP
response.

Generated from protobuf message `google.cloud.networkservices.v1.HttpRoute.HeaderModifier`

## Namespace

Google \\ Cloud \\ NetworkServices \\ V1 \\ HttpRoute

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ set` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` Completely overwrite/replace the headers with given map where key is the name of the header, value is the value of the header. |
| `↳ add` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` Add the headers with given map where key is the name of the header, value is the value of the header. |
| `↳ remove` | `string[]` Remove headers (matching by header names) specified in the list. |

### getSet

Completely overwrite/replace the headers with given map where key is the
name of the header, value is the value of the header.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` |   |

### setSet

Completely overwrite/replace the headers with given map where key is the
name of the header, value is the value of the header.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` |

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

### getAdd

Add the headers with given map where key is the name of the header, value
is the value of the header.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` |   |

### setAdd

Add the headers with given map where key is the name of the header, value
is the value of the header.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` |

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

### getRemove

Remove headers (matching by header names) specified in the list.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<string>` |   |

### setRemove

Remove headers (matching by header names) specified in the list.

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

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