# Google Cloud Dms V1 Client - Class ConnectionProfile (2.1.3)

2.1.3 (latest) 2.1.2 2.0.6 1.5.5 1.4.2 1.3.0 1.2.1 1.1.0 1.0.5 Reference documentation and code samples for the Google Cloud Dms V1 Client class ConnectionProfile.

A connection profile definition.

Generated from protobuf message `google.cloud.clouddms.v1.ConnectionProfile`

## Namespace

Google \\ Cloud \\ CloudDms \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` The name of this connection profile resource in the form of projects/{project}/locations/{location}/connectionProfiles/{connectionProfile}. |
| `↳ create_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. The timestamp when the resource was created. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z". |
| `↳ update_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. The timestamp when the resource was last updated. A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z". |
| `↳ labels` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` The resource labels for connection profile to use to annotate any related underlying resources such as Compute Engine VMs. An object containing a list of "key": "value" pairs. Example: `{ "name": "wrench", "mass": "1.3kg", "count": "3" }`. |
| `↳ state` | `int` The current connection profile state (e.g. DRAFT, READY, or FAILED). |
| `↳ display_name` | `string` The connection profile display name. |
| `↳ mysql` | `https://docs.cloud.google.com/php/docs/reference/cloud-dms/latest/V1.MySqlConnectionProfile` A MySQL database connection profile. |
| `↳ postgresql` | `https://docs.cloud.google.com/php/docs/reference/cloud-dms/latest/V1.PostgreSqlConnectionProfile` A PostgreSQL database connection profile. |
| `↳ oracle` | `https://docs.cloud.google.com/php/docs/reference/cloud-dms/latest/V1.OracleConnectionProfile` An Oracle database connection profile. |
| `↳ cloudsql` | `https://docs.cloud.google.com/php/docs/reference/cloud-dms/latest/V1.CloudSqlConnectionProfile` A CloudSQL database connection profile. |
| `↳ alloydb` | `https://docs.cloud.google.com/php/docs/reference/cloud-dms/latest/V1.AlloyDbConnectionProfile` An AlloyDB cluster connection profile. |
| `↳ error` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Rpc.Status.html` Output only. The error details in case of state FAILED. |
| `↳ provider` | `int` The database provider. |

### getName

The name of this connection profile resource in the form of
projects/{project}/locations/{location}/connectionProfiles/{connectionProfile}.

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

### setName

The name of this connection profile resource in the form of
projects/{project}/locations/{location}/connectionProfiles/{connectionProfile}.

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

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

### getCreateTime

Output only. The timestamp when the resource was created.

A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds.
Example: "2014-10-02T15:01:23.045123456Z".

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

### hasCreateTime

### clearCreateTime

### setCreateTime

Output only. The timestamp when the resource was created.

A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds.
Example: "2014-10-02T15:01:23.045123456Z".

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

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

### getUpdateTime

Output only. The timestamp when the resource was last updated.

A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds.
Example: "2014-10-02T15:01:23.045123456Z".

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

### hasUpdateTime

### clearUpdateTime

### setUpdateTime

Output only. The timestamp when the resource was last updated.

A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds.
Example: "2014-10-02T15:01:23.045123456Z".

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

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

### getLabels

The resource labels for connection profile to use to annotate any related
underlying resources such as Compute Engine VMs. An object containing a
list of "key": "value" pairs.

Example: `{ "name": "wrench", "mass": "1.3kg", "count": "3" }`.

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

### setLabels

The resource labels for connection profile to use to annotate any related
underlying resources such as Compute Engine VMs. An object containing a
list of "key": "value" pairs.

Example: `{ "name": "wrench", "mass": "1.3kg", "count": "3" }`.

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

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

### getState

The current connection profile state (e.g. DRAFT, READY, or FAILED).

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

### setState

The current connection profile state (e.g. DRAFT, READY, or FAILED).

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

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

### getDisplayName

The connection profile display name.

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

### setDisplayName

The connection profile display name.

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

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

### getMysql

A MySQL database connection profile.

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

### hasMysql

### setMysql

A MySQL database connection profile.

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

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

### getPostgresql

A PostgreSQL database connection profile.

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

### hasPostgresql

### setPostgresql

A PostgreSQL database connection profile.

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

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

### getOracle

An Oracle database connection profile.

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

### hasOracle

### setOracle

An Oracle database connection profile.

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

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

### getCloudsql

A CloudSQL database connection profile.

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

### hasCloudsql

### setCloudsql

A CloudSQL database connection profile.

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

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

### getAlloydb

An AlloyDB cluster connection profile.

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

### hasAlloydb

### setAlloydb

An AlloyDB cluster connection profile.

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

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

### getError

Output only. The error details in case of state FAILED.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Rpc.Status.html|null` |   |

### hasError

### clearError

### setError

Output only. The error details in case of state FAILED.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Rpc.Status.html` |

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

### getProvider

The database provider.

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

### setProvider

The database provider.

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

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

### getConnectionProfile

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