lib/algolia/models/search/get_objects_request.rb in algolia-3.11.0 vs lib/algolia/models/search/get_objects_request.rb in algolia-3.12.0
- old
+ new
@@ -1,5 +1,7 @@
+# frozen_string_literal: true
+
# Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
require "date"
require "time"
@@ -9,29 +11,29 @@
class GetObjectsRequest
# Attributes to retrieve. If not specified, all retrievable attributes are returned.
attr_accessor :attributes_to_retrieve
# Object ID for the record to retrieve.
- attr_accessor :object_id
+ attr_accessor :algolia_object_id
# Index from which to retrieve the records.
attr_accessor :index_name
# Attribute mapping from ruby-style variable name to JSON key.
def self.attribute_map
{
:attributes_to_retrieve => :attributesToRetrieve,
- :object_id => :objectID,
+ :algolia_object_id => :objectID,
:index_name => :indexName
}
end
# Attribute type mapping.
def self.types_mapping
{
:attributes_to_retrieve => :"Array<String>",
- :object_id => :"String",
+ :algolia_object_id => :"String",
:index_name => :"String"
}
end
# List of attributes with nullable: true
@@ -68,14 +70,14 @@
if (value = attributes[:attributes_to_retrieve]).is_a?(Array)
self.attributes_to_retrieve = value
end
end
- if attributes.key?(:object_id)
- self.object_id = attributes[:object_id]
+ if attributes.key?(:algolia_object_id)
+ self.algolia_object_id = attributes[:algolia_object_id]
else
- self.object_id = nil
+ self.algolia_object_id = nil
end
if attributes.key?(:index_name)
self.index_name = attributes[:index_name]
else
@@ -87,11 +89,11 @@
# @param [Object] Object to be compared
def ==(other)
return true if self.equal?(other)
self.class == other.class &&
attributes_to_retrieve == other.attributes_to_retrieve &&
- object_id == other.object_id &&
+ algolia_object_id == other.algolia_object_id &&
index_name == other.index_name
end
# @see the `==` method
# @param [Object] Object to be compared
@@ -100,10 +102,10 @@
end
# Calculates hash code according to all attributes.
# @return [Integer] Hash code
def hash
- [attributes_to_retrieve, object_id, index_name].hash
+ [attributes_to_retrieve, algolia_object_id, index_name].hash
end
# Builds the object from hash
# @param [Hash] attributes Model attributes in the form of hash
# @return [Object] Returns the model itself