# Recommender V1 Client - Class RecommendationReference (2.2.0)

2.2.0 (latest) 2.1.3 2.0.5 1.11.5 1.10.0 1.9.1 1.8.2 1.7.8 Reference documentation and code samples for the Recommender V1 Client class RecommendationReference.

Reference to an associated recommendation.

Generated from protobuf message `google.cloud.recommender.v1.Insight.RecommendationReference`

## Namespace

Google \\ Cloud \\ Recommender \\ V1 \\ Insight

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ recommendation` | `string` Recommendation resource name, e.g. projects/\[PROJECT_NUMBER\]/locations/\[LOCATION\]/recommenders/\[RECOMMENDER_ID\]/recommendations/\[RECOMMENDATION_ID\] |

### getRecommendation

Recommendation resource name, e.g.

projects/\[PROJECT_NUMBER\]/locations/\[LOCATION\]/recommenders/\[RECOMMENDER_ID\]/recommendations/\[RECOMMENDATION_ID\]

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

### setRecommendation

Recommendation resource name, e.g.

projects/\[PROJECT_NUMBER\]/locations/\[LOCATION\]/recommenders/\[RECOMMENDER_ID\]/recommendations/\[RECOMMENDATION_ID\]

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

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