# Google Cloud Redis Cluster V1 Client - Class PscServiceAttachment (0.8.0)

0.8.0 (latest) 0.7.0 0.6.4 0.5.1 0.4.1 0.3.2 0.2.5 0.1.0 Reference documentation and code samples for the Google Cloud Redis Cluster V1 Client class PscServiceAttachment.

Configuration of a service attachment of the cluster, for creating PSC
connections.

Generated from protobuf message `google.cloud.redis.cluster.v1.PscServiceAttachment`

## Namespace

Google \\ Cloud \\ Redis \\ Cluster \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ service_attachment` | `string` Output only. Service attachment URI which your self-created PscConnection should use as target |
| `↳ connection_type` | `int` Output only. Type of a PSC connection targeting this service attachment. |

### getServiceAttachment

Output only. Service attachment URI which your self-created PscConnection
should use as target

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

### setServiceAttachment

Output only. Service attachment URI which your self-created PscConnection
should use as target

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

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

### getConnectionType

Output only. Type of a PSC connection targeting this service attachment.

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

### setConnectionType

Output only. Type of a PSC connection targeting this service attachment.

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

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