# Cloud Vision V1 Client - Class UpdateProductRequest (2.2.1)

2.2.1 (latest) 2.2.0 2.1.3 2.0.3 1.10.3 1.9.4 1.8.0 1.7.6 1.6.8 Reference documentation and code samples for the Cloud Vision V1 Client class UpdateProductRequest.

Request message for the `UpdateProduct` method.

Generated from protobuf message `google.cloud.vision.v1.UpdateProductRequest`

## Namespace

Google \\ Cloud \\ Vision \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ product` | `https://docs.cloud.google.com/php/docs/reference/cloud-vision/latest/V1.Product` Required. The Product resource which replaces the one on the server. product.name is immutable. |
| `↳ update_mask` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/FieldMask` The [FieldMask](https://protobuf.dev/reference/php/api-docs/FieldMask) that specifies which fields to update. If update_mask isn't specified, all mutable fields are to be updated. Valid mask paths include `product_labels`, `display_name`, and `description`. |

### getProduct

Required. The Product resource which replaces the one on the server.

product.name is immutable.

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

### hasProduct

### clearProduct

### setProduct

Required. The Product resource which replaces the one on the server.

product.name is immutable.

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

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

### getUpdateMask

The [FieldMask](https://protobuf.dev/reference/php/api-docs/FieldMask) that specifies which fields
to update.

If update_mask isn't specified, all mutable fields are to be updated.
Valid mask paths include `product_labels`, `display_name`, and
`description`.

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

### hasUpdateMask

### clearUpdateMask

### setUpdateMask

The [FieldMask](https://protobuf.dev/reference/php/api-docs/FieldMask) that specifies which fields
to update.

If update_mask isn't specified, all mutable fields are to be updated.
Valid mask paths include `product_labels`, `display_name`, and
`description`.

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

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

### static::build

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `product` | `https://docs.cloud.google.com/php/docs/reference/cloud-vision/latest/V1.Product` Required. The Product resource which replaces the one on the server. product.name is immutable. |
| `updateMask` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/FieldMask` The [FieldMask](https://protobuf.dev/reference/php/api-docs/FieldMask) that specifies which fields to update. If update_mask isn't specified, all mutable fields are to be updated. Valid mask paths include `product_labels`, `display_name`, and `description`. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-vision/latest/V1.UpdateProductRequest` |   |