lib/algolia/models/search/browse_response.rb in algolia-3.0.0.alpha.10 vs lib/algolia/models/search/browse_response.rb in algolia-3.0.0.alpha.11

- old
+ new

@@ -82,10 +82,13 @@ attr_accessor :server_used # Lets you store custom data in your indices. attr_accessor :user_data + # Unique identifier for the query. This is used for [click analytics](https://www.algolia.com/doc/guides/analytics/click-analytics/). + attr_accessor :query_id + attr_accessor :hits # Text to search for in an index. attr_accessor :query @@ -123,10 +126,11 @@ :redirect => :redirect, :rendering_content => :renderingContent, :server_time_ms => :serverTimeMS, :server_used => :serverUsed, :user_data => :userData, + :query_id => :queryID, :hits => :hits, :query => :query, :params => :params, :cursor => :cursor } @@ -165,10 +169,11 @@ :redirect => :Redirect, :rendering_content => :RenderingContent, :server_time_ms => :Integer, :server_used => :String, :user_data => :Object, + :query_id => :String, :hits => :'Array<Hit>', :query => :String, :params => :String, :cursor => :String } @@ -325,10 +330,14 @@ if attributes.key?(:user_data) self.user_data = attributes[:user_data] end + if attributes.key?(:query_id) + self.query_id = attributes[:query_id] + end + if attributes.key?(:hits) if (value = attributes[:hits]).is_a?(Array) self.hits = value end else @@ -430,10 +439,11 @@ redirect == other.redirect && rendering_content == other.rendering_content && server_time_ms == other.server_time_ms && server_used == other.server_used && user_data == other.user_data && + query_id == other.query_id && hits == other.hits && query == other.query && params == other.params && cursor == other.cursor end @@ -446,10 +456,10 @@ # Calculates hash code according to all attributes. # @return [Integer] Hash code def hash [ab_test_id, ab_test_variant_id, around_lat_lng, automatic_radius, exhaustive, exhaustive_facets_count, exhaustive_nb_hits, exhaustive_typo, facets, facets_stats, - hits_per_page, index, index_used, message, nb_hits, nb_pages, nb_sorted_hits, page, parsed_query, processing_time_ms, processing_timings_ms, query_after_removal, redirect, rendering_content, server_time_ms, server_used, user_data, hits, query, params, cursor].hash + hits_per_page, index, index_used, message, nb_hits, nb_pages, nb_sorted_hits, page, parsed_query, processing_time_ms, processing_timings_ms, query_after_removal, redirect, rendering_content, server_time_ms, server_used, user_data, query_id, hits, query, params, cursor].hash end # Builds the object from hash # @param [Hash] attributes Model attributes in the form of hash # @return [Object] Returns the model itself