Class: Google::Apis::CloudsearchV1::SuggestRequest

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/cloudsearch_v1/classes.rb,
generated/google/apis/cloudsearch_v1/representations.rb,
generated/google/apis/cloudsearch_v1/representations.rb

Overview

Request of suggest API.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Google::Apis::Core::JsonObjectSupport

#to_json

Methods included from Google::Apis::Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ SuggestRequest

Returns a new instance of SuggestRequest



4766
4767
4768
# File 'generated/google/apis/cloudsearch_v1/classes.rb', line 4766

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#data_source_restrictionsArray<Google::Apis::CloudsearchV1::DataSourceRestriction>

The sources to use for suggestions. If not specified, all data sources from the current search application are used. Suggestions are based on Gmail titles. Suggestions from third party sources are not available. Corresponds to the JSON property dataSourceRestrictions



4752
4753
4754
# File 'generated/google/apis/cloudsearch_v1/classes.rb', line 4752

def data_source_restrictions
  @data_source_restrictions
end

#queryString

Partial query for which autocomplete suggestions will be shown. For example, if the query is "sea", then the server might return "season", "search", "seagull" and so on. Corresponds to the JSON property query

Returns:

  • (String)


4759
4760
4761
# File 'generated/google/apis/cloudsearch_v1/classes.rb', line 4759

def query
  @query
end

#request_optionsGoogle::Apis::CloudsearchV1::RequestOptions

Shared request options for all RPC methods. Corresponds to the JSON property requestOptions



4764
4765
4766
# File 'generated/google/apis/cloudsearch_v1/classes.rb', line 4764

def request_options
  @request_options
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



4771
4772
4773
4774
4775
# File 'generated/google/apis/cloudsearch_v1/classes.rb', line 4771

def update!(**args)
  @data_source_restrictions = args[:data_source_restrictions] if args.key?(:data_source_restrictions)
  @query = args[:query] if args.key?(:query)
  @request_options = args[:request_options] if args.key?(:request_options)
end