# Google Cloud Notebooks V1 Client - Class Runtime (1.1.3)

1.1.3 (latest) 1.1.2 1.0.5 0.7.5 0.6.2 0.5.0 0.4.1 0.3.6 Reference documentation and code samples for the Google Cloud Notebooks V1 Client class Runtime.

The definition of a Runtime for a managed notebook instance.

Generated from protobuf message `google.cloud.notebooks.v1.Runtime`

## Namespace

Google \\ Cloud \\ Notebooks \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` Output only. The resource name of the runtime. Format: `projects/{project}/locations/{location}/runtimes/{runtimeId}` |
| `↳ virtual_machine` | `https://docs.cloud.google.com/php/docs/reference/cloud-notebooks/latest/V1.VirtualMachine` Use a Compute Engine VM image to start the managed notebook instance. |
| `↳ state` | `int` Output only. Runtime state. |
| `↳ health_state` | `int` Output only. Runtime health_state. |
| `↳ access_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-notebooks/latest/V1.RuntimeAccessConfig` The config settings for accessing runtime. |
| `↳ software_config` | `https://docs.cloud.google.com/php/docs/reference/cloud-notebooks/latest/V1.RuntimeSoftwareConfig` The config settings for software inside the runtime. |
| `↳ metrics` | `https://docs.cloud.google.com/php/docs/reference/cloud-notebooks/latest/V1.RuntimeMetrics` Output only. Contains Runtime daemon metrics such as Service status and JupyterLab stats. |
| `↳ create_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. Runtime creation time. |
| `↳ update_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. Runtime update time. |

### getName

Output only. The resource name of the runtime.

Format:
`projects/{project}/locations/{location}/runtimes/{runtimeId}`

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

### setName

Output only. The resource name of the runtime.

Format:
`projects/{project}/locations/{location}/runtimes/{runtimeId}`

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

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

### getVirtualMachine

Use a Compute Engine VM image to start the managed notebook instance.

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

### hasVirtualMachine

### setVirtualMachine

Use a Compute Engine VM image to start the managed notebook instance.

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

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

### getState

Output only. Runtime state.

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

### setState

Output only. Runtime state.

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

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

### getHealthState

Output only. Runtime health_state.

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

### setHealthState

Output only. Runtime health_state.

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

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

### getAccessConfig

The config settings for accessing runtime.

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

### hasAccessConfig

### clearAccessConfig

### setAccessConfig

The config settings for accessing runtime.

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

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

### getSoftwareConfig

The config settings for software inside the runtime.

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

### hasSoftwareConfig

### clearSoftwareConfig

### setSoftwareConfig

The config settings for software inside the runtime.

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

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

### getMetrics

Output only. Contains Runtime daemon metrics such as Service status and JupyterLab
stats.

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

### hasMetrics

### clearMetrics

### setMetrics

Output only. Contains Runtime daemon metrics such as Service status and JupyterLab
stats.

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

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

### getCreateTime

Output only. Runtime creation time.

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

### hasCreateTime

### clearCreateTime

### setCreateTime

Output only. Runtime creation time.

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

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

### getUpdateTime

Output only. Runtime update time.

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

### hasUpdateTime

### clearUpdateTime

### setUpdateTime

Output only. Runtime update time.

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

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

### getRuntimeType

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