# Google Cloud Gemini Data Analytics V1 Client - Class DataAgentContext (0.11.0)

0.11.0 (latest) 0.10.0 0.9.0 0.8.0 0.7.1 0.6.0 0.5.0 0.4.0 0.3.1 0.2.0 0.1.1 Reference documentation and code samples for the Google Cloud Gemini Data Analytics V1 Client class DataAgentContext.

Context for the chat request using a data agent.

Generated from protobuf message `google.cloud.geminidataanalytics.v1.DataAgentContext`

## Namespace

Google \\ Cloud \\ GeminiDataAnalytics \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ data_agent` | `string` Required. The name of the data agent resource. |
| `↳ context_version` | `int` Optional. Version of context to be used by DCS (e.g. STAGING, PUBLISHED) |

### getDataAgent

Required. The name of the data agent resource.

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

### setDataAgent

Required. The name of the data agent resource.

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

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

### getContextVersion

Optional. Version of context to be used by DCS (e.g. STAGING, PUBLISHED)

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

### setContextVersion

Optional. Version of context to be used by DCS (e.g. STAGING, PUBLISHED)

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

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