Reference documentation and code samples for the Google Cloud Discovery Engine V1beta Client class RecommendationResult.
RecommendationResult represents a generic recommendation result with associated metadata.
Generated from protobuf message google.cloud.discoveryengine.v1beta.RecommendResponse.RecommendationResult
Methods
__construct
Constructor.
Parameters | |
---|---|
Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ id |
string
Resource ID of the recommended Document. |
↳ document |
Google\Cloud\DiscoveryEngine\V1beta\Document
Set if |
↳ metadata |
array|Google\Protobuf\Internal\MapField
Additional Document metadata / annotations. Possible values: * |
getId
Resource ID of the recommended Document.
Returns | |
---|---|
Type | Description |
string |
setId
Resource ID of the recommended Document.
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getDocument
Set if returnDocument
is set to true in
RecommendRequest.params.
Returns | |
---|---|
Type | Description |
Google\Cloud\DiscoveryEngine\V1beta\Document|null |
hasDocument
clearDocument
setDocument
Set if returnDocument
is set to true in
RecommendRequest.params.
Parameter | |
---|---|
Name | Description |
var |
Google\Cloud\DiscoveryEngine\V1beta\Document
|
Returns | |
---|---|
Type | Description |
$this |
getMetadata
Additional Document metadata / annotations.
Possible values:
score
: Recommendation score in double value. Is set ifreturnScore
is set to true in RecommendRequest.params.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\MapField |
setMetadata
Additional Document metadata / annotations.
Possible values:
score
: Recommendation score in double value. Is set ifreturnScore
is set to true in RecommendRequest.params.
Parameter | |
---|---|
Name | Description |
var |
array|Google\Protobuf\Internal\MapField
|
Returns | |
---|---|
Type | Description |
$this |