Reference documentation and code samples for the Google Cloud Discovery Engine V1beta Client class SnippetSpec.
A specification for configuring snippets in a search response.
Generated from protobuf message google.cloud.discoveryengine.v1beta.SearchRequest.ContentSearchSpec.SnippetSpec
Namespace
Google \ Cloud \ DiscoveryEngine \ V1beta \ SearchRequest \ ContentSearchSpecMethods
__construct
Constructor.
Parameters | |
---|---|
Name | Description |
data | array Optional. Data for populating the Message object. |
↳ max_snippet_count | int [DEPRECATED] This field is deprecated. To control snippet return, use |
↳ reference_only | bool [DEPRECATED] This field is deprecated and will have no affect on the snippet. |
↳ return_snippet | bool If |
getMaxSnippetCount
[DEPRECATED] This field is deprecated. To control snippet return, use return_snippet
field. For backwards compatibility, we will return snippet if max_snippet_count > 0.
Returns | |
---|---|
Type | Description |
int |
setMaxSnippetCount
[DEPRECATED] This field is deprecated. To control snippet return, use return_snippet
field. For backwards compatibility, we will return snippet if max_snippet_count > 0.
Parameter | |
---|---|
Name | Description |
var | int |
Returns | |
---|---|
Type | Description |
$this |
getReferenceOnly
[DEPRECATED] This field is deprecated and will have no affect on the snippet.
Returns | |
---|---|
Type | Description |
bool |
setReferenceOnly
[DEPRECATED] This field is deprecated and will have no affect on the snippet.
Parameter | |
---|---|
Name | Description |
var | bool |
Returns | |
---|---|
Type | Description |
$this |
getReturnSnippet
If true
, then return snippet. If no snippet can be generated, we return "No snippet is available for this page." A snippet_status
with SUCCESS
or NO_SNIPPET_AVAILABLE
will also be returned.
Returns | |
---|---|
Type | Description |
bool |
setReturnSnippet
If true
, then return snippet. If no snippet can be generated, we return "No snippet is available for this page." A snippet_status
with SUCCESS
or NO_SNIPPET_AVAILABLE
will also be returned.
Parameter | |
---|---|
Name | Description |
var | bool |
Returns | |
---|---|
Type | Description |
$this |