# Google Cloud Vision Ai V1 Client - Class UploadAssetRequest (0.3.0)

0.3.0 (latest) 0.2.0 0.1.0 Reference documentation and code samples for the Google Cloud Vision Ai V1 Client class UploadAssetRequest.

Request message for UploadAsset.

Generated from protobuf message `google.cloud.visionai.v1.UploadAssetRequest`

## Namespace

Google \\ Cloud \\ VisionAI \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` Required. The resource name of the asset to upload. Format: `projects/{project_number}/locations/{location_id}/corpora/{corpus_id}/assets/{asset_id}` |
| `↳ asset_source` | `https://docs.cloud.google.com/php/docs/reference/cloud-visionai/latest/V1.AssetSource` The source of the asset. |

### getName

Required. The resource name of the asset to upload.

Format:
`projects/{project_number}/locations/{location_id}/corpora/{corpus_id}/assets/{asset_id}`

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

### setName

Required. The resource name of the asset to upload.

Format:
`projects/{project_number}/locations/{location_id}/corpora/{corpus_id}/assets/{asset_id}`

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

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

### getAssetSource

The source of the asset.

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

### hasAssetSource

### clearAssetSource

### setAssetSource

The source of the asset.

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

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