# Google Shopping Merchant DataSources V1 Client - Class Destination (2.0.0)

2.0.0 (latest) 1.3.1 1.2.1 1.1.1 1.0.0 0.6.0 0.5.1 0.4.0 0.3.1 0.2.3 0.1.0 Reference documentation and code samples for the Google Shopping Merchant DataSources V1 Client class Destination.

Destinations also known as [Marketing
methods](https://support.google.com/merchants/answer/15130232) selections.

Generated from protobuf message `google.shopping.merchant.datasources.v1.PrimaryProductDataSource.Destination`

## Namespace

Google \\ Shopping \\ Merchant \\ DataSources \\ V1 \\ PrimaryProductDataSource

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ destination` | `int` [Marketing methods](https://support.google.com/merchants/answer/15130232) (also known as destination) selections. |
| `↳ state` | `int` The state of the destination. |

### getDestination

[Marketing methods](https://support.google.com/merchants/answer/15130232)
(also known as destination) selections.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [DestinationEnum](https://docs.cloud.google.com/php/docs/reference/shopping-common-protos/latest/Type.Destination.DestinationEnum.html). |

### setDestination

[Marketing methods](https://support.google.com/merchants/answer/15130232)
(also known as destination) selections.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [DestinationEnum](https://docs.cloud.google.com/php/docs/reference/shopping-common-protos/latest/Type.Destination.DestinationEnum.html). |

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

### getState

The state of the destination.

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

### setState

The state of the destination.

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

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