# Google Cloud Cloud Controls Partner V1beta Client - Class EkmConnection (0.5.3)

0.5.3 (latest) 0.5.2 0.4.1 0.3.0 0.2.2 0.1.4

> [!WARNING]
> **Beta**
>
>
> This library is covered by the [Pre-GA Offerings Terms](https://docs.cloud.google.com/terms/service-terms#1)
> of the Terms of Service. Pre-GA libraries might have limited support,
> and changes to pre-GA libraries might not be compatible with other pre-GA versions.
> For more information, see the
> [launch stage descriptions](https://docs.cloud.google.com/products#product-launch-stages).

Reference documentation and code samples for the Google Cloud Cloud Controls Partner V1beta Client class EkmConnection.

Details about the EKM connection

Generated from protobuf message `google.cloud.cloudcontrolspartner.v1beta.EkmConnection`

## Namespace

Google \\ Cloud \\ CloudControlsPartner \\ V1beta

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ connection_name` | `string` Resource name of the EKM connection in the format: projects/{project}/locations/{location}/ekmConnections/{ekm_connection} |
| `↳ connection_state` | `int` Output only. The connection state |
| `↳ connection_error` | `https://docs.cloud.google.com/php/docs/reference/cloud-cloudcontrolspartner/latest/V1beta.EkmConnection.ConnectionError` The connection error that occurred if any |

### getConnectionName

Resource name of the EKM connection in the format:
projects/{project}/locations/{location}/ekmConnections/{ekm_connection}

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

### setConnectionName

Resource name of the EKM connection in the format:
projects/{project}/locations/{location}/ekmConnections/{ekm_connection}

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

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

### getConnectionState

Output only. The connection state

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [ConnectionState](https://docs.cloud.google.com/php/docs/reference/cloud-cloudcontrolspartner/latest/V1beta.EkmConnection.ConnectionState). |

### setConnectionState

Output only. The connection state

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [ConnectionState](https://docs.cloud.google.com/php/docs/reference/cloud-cloudcontrolspartner/latest/V1beta.EkmConnection.ConnectionState). |

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

### getConnectionError

The connection error that occurred if any

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-cloudcontrolspartner/latest/V1beta.EkmConnection.ConnectionError|null` |   |

### hasConnectionError

### clearConnectionError

### setConnectionError

The connection error that occurred if any

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-cloudcontrolspartner/latest/V1beta.EkmConnection.ConnectionError` |

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