# Google Cloud Vector Search V1 Client - Class Collection (0.4.0)

0.4.0 (latest) 0.3.0 0.2.0 0.1.0 Reference documentation and code samples for the Google Cloud Vector Search V1 Client class Collection.

Message describing Collection object

Generated from protobuf message `google.cloud.vectorsearch.v1.Collection`

## Namespace

Google \\ Cloud \\ VectorSearch \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` Identifier. name of resource |
| `↳ display_name` | `string` Optional. User-specified display name of the collection |
| `↳ description` | `string` Optional. User-specified description of the collection |
| `↳ create_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. \[Output only\] Create time stamp |
| `↳ update_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. \[Output only\] Update time stamp |
| `↳ labels` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` Optional. Labels as key value pairs. |
| `↳ vector_schema` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` Optional. Schema for vector fields. Only vector fields in this schema will be searchable. Field names must contain only alphanumeric characters, underscores, and hyphens. |
| `↳ data_schema` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Struct` Optional. JSON Schema for data. Field names must contain only alphanumeric characters, underscores, and hyphens. The schema must be compliant with [JSON Schema Draft 7](https://json-schema.org/draft-07/schema). |
| `↳ encryption_spec` | `https://docs.cloud.google.com/php/docs/reference/cloud-vectorsearch/latest/V1.EncryptionSpec` Optional. Immutable. Specifies the customer-managed encryption key spec for a Collection. If set, this Collection and all sub-resources of this Collection will be secured by this key. |

### getName

Identifier. name of resource

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

### setName

Identifier. name of resource

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

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

### getDisplayName

Optional. User-specified display name of the collection

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

### setDisplayName

Optional. User-specified display name of the collection

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

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

### getDescription

Optional. User-specified description of the collection

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

### setDescription

Optional. User-specified description of the collection

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

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

### getCreateTime

Output only. \[Output only\] Create time stamp

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

### hasCreateTime

### clearCreateTime

### setCreateTime

Output only. \[Output only\] Create time stamp

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

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

### getUpdateTime

Output only. \[Output only\] Update time stamp

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

### hasUpdateTime

### clearUpdateTime

### setUpdateTime

Output only. \[Output only\] Update time stamp

| **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` |   |

### getVectorSchema

Optional. Schema for vector fields. Only vector fields in this schema will
be searchable. Field names must contain only alphanumeric characters,
underscores, and hyphens.

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

### setVectorSchema

Optional. Schema for vector fields. Only vector fields in this schema will
be searchable. Field names must contain only alphanumeric characters,
underscores, and hyphens.

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

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

### getDataSchema

Optional. JSON Schema for data.

Field names must contain only alphanumeric characters,
underscores, and hyphens.
The schema must be compliant with
[JSON Schema Draft 7](https://json-schema.org/draft-07/schema).

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

### hasDataSchema

### clearDataSchema

### setDataSchema

Optional. JSON Schema for data.

Field names must contain only alphanumeric characters,
underscores, and hyphens.
The schema must be compliant with
[JSON Schema Draft 7](https://json-schema.org/draft-07/schema).

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

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

### getEncryptionSpec

Optional. Immutable. Specifies the customer-managed encryption key spec for
a Collection. If set, this Collection and all sub-resources of this
Collection will be secured by this key.

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

### hasEncryptionSpec

### clearEncryptionSpec

### setEncryptionSpec

Optional. Immutable. Specifies the customer-managed encryption key spec for
a Collection. If set, this Collection and all sub-resources of this
Collection will be secured by this key.

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

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