Class: Google::Apis::CloudsearchV1::SearchRequest
- Inherits:
-
Object
- Object
- Google::Apis::CloudsearchV1::SearchRequest
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/cloudsearch_v1/classes.rb,
lib/google/apis/cloudsearch_v1/representations.rb,
lib/google/apis/cloudsearch_v1/representations.rb
Overview
The search API request.
Instance Attribute Summary collapse
-
#context_attributes ⇒ Array<Google::Apis::CloudsearchV1::ContextAttribute>
Context attributes for the request which will be used to adjust ranking of search results.
-
#data_source_restrictions ⇒ Array<Google::Apis::CloudsearchV1::DataSourceRestriction>
The sources to use for querying.
-
#facet_options ⇒ Array<Google::Apis::CloudsearchV1::FacetOptions>
Corresponds to the JSON property
facetOptions. -
#page_size ⇒ Fixnum
Maximum number of search results to return in one page.
-
#query ⇒ String
The raw query string.
-
#query_interpretation_options ⇒ Google::Apis::CloudsearchV1::QueryInterpretationOptions
Options to interpret user query.
-
#request_options ⇒ Google::Apis::CloudsearchV1::RequestOptions
Shared request options for all RPC methods.
-
#sort_options ⇒ Google::Apis::CloudsearchV1::SortOptions
The options for sorting the search results Corresponds to the JSON property
sortOptions. -
#start ⇒ Fixnum
Starting index of the results.
Instance Method Summary collapse
-
#initialize(**args) ⇒ SearchRequest
constructor
A new instance of SearchRequest.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ SearchRequest
Returns a new instance of SearchRequest.
17620 17621 17622 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17620 def initialize(**args) update!(**args) end |
Instance Attribute Details
#context_attributes ⇒ Array<Google::Apis::CloudsearchV1::ContextAttribute>
Context attributes for the request which will be used to adjust ranking of
search results. The maximum number of elements is 10.
Corresponds to the JSON property contextAttributes
17574 17575 17576 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17574 def context_attributes @context_attributes end |
#data_source_restrictions ⇒ Array<Google::Apis::CloudsearchV1::DataSourceRestriction>
The sources to use for querying. If not specified, all data sources from the
current search application are used.
Corresponds to the JSON property dataSourceRestrictions
17580 17581 17582 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17580 def data_source_restrictions @data_source_restrictions end |
#facet_options ⇒ Array<Google::Apis::CloudsearchV1::FacetOptions>
Corresponds to the JSON property facetOptions
17585 17586 17587 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17585 def @facet_options end |
#page_size ⇒ Fixnum
Maximum number of search results to return in one page. Valid values are
between 1 and 100, inclusive. Default value is 10. Minimum value is 50 when
results beyond 2000 are requested.
Corresponds to the JSON property pageSize
17592 17593 17594 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17592 def page_size @page_size end |
#query ⇒ String
The raw query string. See supported search operators in the Narrow your
search with operators
Corresponds to the JSON property query
17598 17599 17600 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17598 def query @query end |
#query_interpretation_options ⇒ Google::Apis::CloudsearchV1::QueryInterpretationOptions
Options to interpret user query.
Corresponds to the JSON property queryInterpretationOptions
17603 17604 17605 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17603 def @query_interpretation_options end |
#request_options ⇒ Google::Apis::CloudsearchV1::RequestOptions
Shared request options for all RPC methods.
Corresponds to the JSON property requestOptions
17608 17609 17610 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17608 def @request_options end |
#sort_options ⇒ Google::Apis::CloudsearchV1::SortOptions
The options for sorting the search results
Corresponds to the JSON property sortOptions
17613 17614 17615 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17613 def @sort_options end |
#start ⇒ Fixnum
Starting index of the results.
Corresponds to the JSON property start
17618 17619 17620 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17618 def start @start end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
17625 17626 17627 17628 17629 17630 17631 17632 17633 17634 17635 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 17625 def update!(**args) @context_attributes = args[:context_attributes] if args.key?(:context_attributes) @data_source_restrictions = args[:data_source_restrictions] if args.key?(:data_source_restrictions) @facet_options = args[:facet_options] if args.key?(:facet_options) @page_size = args[:page_size] if args.key?(:page_size) @query = args[:query] if args.key?(:query) @query_interpretation_options = args[:query_interpretation_options] if args.key?(:query_interpretation_options) @request_options = args[:request_options] if args.key?(:request_options) @sort_options = args[:sort_options] if args.key?(:sort_options) @start = args[:start] if args.key?(:start) end |