# Google Cloud Managed Kafka V1 Client - Class ConnectCluster (0.8.0)

0.8.0 (latest) 0.7.2 0.6.1 0.5.0 0.4.1 0.3.1 0.2.3 0.1.3 Reference documentation and code samples for the Google Cloud Managed Kafka V1 Client class ConnectCluster.

An Apache Kafka Connect cluster deployed in a location.

Generated from protobuf message `google.cloud.managedkafka.v1.ConnectCluster`

## Namespace

Google \\ Cloud \\ ManagedKafka \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ gcp_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-managedkafka/latest/V1.ConnectGcpConfig` Required. Configuration properties for a Kafka Connect cluster deployed to Google Cloud Platform. |
| `↳ name` | `string` Identifier. The name of the Kafka Connect cluster. Structured like: projects/{project_number}/locations/{location}/connectClusters/{connect_cluster_id} |
| `↳ kafka_cluster` | `string` Required. Immutable. The name of the Kafka cluster this Kafka Connect cluster is attached to. Structured like: projects/{project}/locations/{location}/clusters/{cluster} |
| `↳ create_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. The time when the cluster was created. |
| `↳ update_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. The time when the cluster was last updated. |
| `↳ labels` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` Optional. Labels as key value pairs. |
| `↳ capacity_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-managedkafka/latest/V1.CapacityConfig` Required. Capacity configuration for the Kafka Connect cluster. |
| `↳ state` | `int` Output only. The current state of the cluster. |
| `↳ config` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` Optional. Configurations for the worker that are overridden from the defaults. The key of the map is a Kafka Connect worker property name, for example: `exactly.once.source.support`. |

### getGcpConfig

Required. Configuration properties for a Kafka Connect cluster deployed
to Google Cloud Platform.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-managedkafka/latest/V1.ConnectGcpConfig|null` |   |

### hasGcpConfig

### setGcpConfig

Required. Configuration properties for a Kafka Connect cluster deployed
to Google Cloud Platform.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-managedkafka/latest/V1.ConnectGcpConfig` |

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

### getName

Identifier. The name of the Kafka Connect cluster. Structured like:
projects/{project_number}/locations/{location}/connectClusters/{connect_cluster_id}

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

### setName

Identifier. The name of the Kafka Connect cluster. Structured like:
projects/{project_number}/locations/{location}/connectClusters/{connect_cluster_id}

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

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

### getKafkaCluster

Required. Immutable. The name of the Kafka cluster this Kafka Connect
cluster is attached to. Structured like:
projects/{project}/locations/{location}/clusters/{cluster}

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

### setKafkaCluster

Required. Immutable. The name of the Kafka cluster this Kafka Connect
cluster is attached to. Structured like:
projects/{project}/locations/{location}/clusters/{cluster}

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

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

### getCreateTime

Output only. The time when the cluster was created.

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

### hasCreateTime

### clearCreateTime

### setCreateTime

Output only. The time when the cluster was created.

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

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

### getUpdateTime

Output only. The time when the cluster was last updated.

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

### hasUpdateTime

### clearUpdateTime

### setUpdateTime

Output only. The time when the cluster was last updated.

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

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

### getLabels

Optional. Labels as key value pairs.

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

### setLabels

Optional. Labels as key value pairs.

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

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

### getCapacityConfig

Required. Capacity configuration for the Kafka Connect cluster.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-managedkafka/latest/V1.CapacityConfig|null` |   |

### hasCapacityConfig

### clearCapacityConfig

### setCapacityConfig

Required. Capacity configuration for the Kafka Connect cluster.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-managedkafka/latest/V1.CapacityConfig` |

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

### getState

Output only. The current state of the cluster.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [State](https://docs.cloud.google.com/php/docs/reference/cloud-managedkafka/latest/V1.ConnectCluster.State). |

### setState

Output only. The current state of the cluster.

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

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

### getConfig

Optional. Configurations for the worker that are overridden from the
defaults. The key of the map is a Kafka Connect worker property name, for
example: `exactly.once.source.support`.

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

### setConfig

Optional. Configurations for the worker that are overridden from the
defaults. The key of the map is a Kafka Connect worker property name, for
example: `exactly.once.source.support`.

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

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

### getPlatformConfig

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