# Google Cloud Asset V1 Client - Class SavedQuery (2.3.3)

2.3.3 (latest) 2.3.2 2.2.3 2.1.3 2.0.1 1.16.4 1.14.1 1.13.2 1.12.2 1.11.3 1.10.2 1.9.2 Reference documentation and code samples for the Google Cloud Asset V1 Client class SavedQuery.

A saved query which can be shared with others or used later.

Generated from protobuf message `google.cloud.asset.v1.SavedQuery`

## Namespace

Google \\ Cloud \\ Asset \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` The resource name of the saved query. The format must be: \* \* projects/project_number/savedQueries/saved_query_id \* \* folders/folder_number/savedQueries/saved_query_id \* \* organizations/organization_number/savedQueries/saved_query_id |
| `↳ description` | `string` The description of this saved query. This value should be fewer than 255 characters. |
| `↳ create_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. The create time of this saved query. |
| `↳ creator` | `string` Output only. The account's email address who has created this saved query. |
| `↳ last_update_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. The last update time of this saved query. |
| `↳ last_updater` | `string` Output only. The account's email address who has updated this saved query most recently. |
| `↳ labels` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` Labels applied on the resource. This value should not contain more than 10 entries. The key and value of each entry must be non-empty and fewer than 64 characters. |
| `↳ content` | `https://docs.cloud.google.com/php/docs/reference/cloud-asset/latest/V1.SavedQuery.QueryContent` The query content. |

### getName

The resource name of the saved query. The format must be:

- projects/project_number/savedQueries/saved_query_id
- folders/folder_number/savedQueries/saved_query_id
- organizations/organization_number/savedQueries/saved_query_id

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

### setName

The resource name of the saved query. The format must be:

- projects/project_number/savedQueries/saved_query_id
- folders/folder_number/savedQueries/saved_query_id
- organizations/organization_number/savedQueries/saved_query_id

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

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

### getDescription

The description of this saved query. This value should be fewer than 255
characters.

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

### setDescription

The description of this saved query. This value should be fewer than 255
characters.

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

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

### getCreateTime

Output only. The create time of this saved query.

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

### hasCreateTime

### clearCreateTime

### setCreateTime

Output only. The create time of this saved query.

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

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

### getCreator

Output only. The account's email address who has created this saved query.

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

### setCreator

Output only. The account's email address who has created this saved query.

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

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

### getLastUpdateTime

Output only. The last update time of this saved query.

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

### hasLastUpdateTime

### clearLastUpdateTime

### setLastUpdateTime

Output only. The last update time of this saved query.

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

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

### getLastUpdater

Output only. The account's email address who has updated this saved query
most recently.

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

### setLastUpdater

Output only. The account's email address who has updated this saved query
most recently.

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

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

### getLabels

Labels applied on the resource.

This value should not contain more than 10 entries. The key and value of
each entry must be non-empty and fewer than 64 characters.

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

### setLabels

Labels applied on the resource.

This value should not contain more than 10 entries. The key and value of
each entry must be non-empty and fewer than 64 characters.

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

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

### getContent

The query content.

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

### hasContent

### clearContent

### setContent

The query content.

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

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