Skip to content

Commit 113dfb9

Browse files
algolia-botrenovate[bot]shortcuts
committed
chore(deps): dependencies 2025-01-06 [skip-bc] (generated)
algolia/api-clients-automation#4299 Co-authored-by: algolia-bot <[email protected]> Co-authored-by: Algolia Bot <[email protected]> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Clément Vannicatte <[email protected]>
1 parent 6144f9b commit 113dfb9

File tree

3 files changed

+23
-23
lines changed

3 files changed

+23
-23
lines changed

lib/algolia/models/personalization/event_scoring.rb renamed to lib/algolia/models/personalization/events_scoring.rb

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
module Algolia
77
module Personalization
8-
class EventScoring
8+
class EventsScoring
99
# Event score.
1010
attr_accessor :score
1111

@@ -50,7 +50,7 @@ def initialize(attributes = {})
5050
if (!attributes.is_a?(Hash))
5151
raise(
5252
ArgumentError,
53-
"The input argument (attributes) must be a hash in `Algolia::EventScoring` initialize method"
53+
"The input argument (attributes) must be a hash in `Algolia::EventsScoring` initialize method"
5454
)
5555
end
5656

@@ -59,7 +59,7 @@ def initialize(attributes = {})
5959
if (!self.class.attribute_map.key?(k.to_sym))
6060
raise(
6161
ArgumentError,
62-
"`#{k}` is not a valid attribute in `Algolia::EventScoring`. Please check the name to make sure it's valid. List of attributes: " +
62+
"`#{k}` is not a valid attribute in `Algolia::EventsScoring`. Please check the name to make sure it's valid. List of attributes: " +
6363
self.class.attribute_map.keys.inspect
6464
)
6565
end

lib/algolia/models/personalization/facet_scoring.rb renamed to lib/algolia/models/personalization/facets_scoring.rb

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
module Algolia
77
module Personalization
8-
class FacetScoring
8+
class FacetsScoring
99
# Event score.
1010
attr_accessor :score
1111

@@ -46,7 +46,7 @@ def initialize(attributes = {})
4646
if (!attributes.is_a?(Hash))
4747
raise(
4848
ArgumentError,
49-
"The input argument (attributes) must be a hash in `Algolia::FacetScoring` initialize method"
49+
"The input argument (attributes) must be a hash in `Algolia::FacetsScoring` initialize method"
5050
)
5151
end
5252

@@ -55,7 +55,7 @@ def initialize(attributes = {})
5555
if (!self.class.attribute_map.key?(k.to_sym))
5656
raise(
5757
ArgumentError,
58-
"`#{k}` is not a valid attribute in `Algolia::FacetScoring`. Please check the name to make sure it's valid. List of attributes: " +
58+
"`#{k}` is not a valid attribute in `Algolia::FacetsScoring`. Please check the name to make sure it's valid. List of attributes: " +
5959
self.class.attribute_map.keys.inspect
6060
)
6161
end

lib/algolia/models/personalization/personalization_strategy_params.rb

+17-17
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,19 @@ module Algolia
77
module Personalization
88
class PersonalizationStrategyParams
99
# Scores associated with each event. The higher the scores, the higher the impact of those events on the personalization of search results.
10-
attr_accessor :event_scoring
10+
attr_accessor :events_scoring
1111

1212
# Scores associated with each facet. The higher the scores, the higher the impact of those events on the personalization of search results.
13-
attr_accessor :facet_scoring
13+
attr_accessor :facets_scoring
1414

1515
# Impact of personalization on the search results. If set to 0, personalization has no impact on the search results.
1616
attr_accessor :personalization_impact
1717

1818
# Attribute mapping from ruby-style variable name to JSON key.
1919
def self.attribute_map
2020
{
21-
:event_scoring => :eventScoring,
22-
:facet_scoring => :facetScoring,
21+
:events_scoring => :eventsScoring,
22+
:facets_scoring => :facetsScoring,
2323
:personalization_impact => :personalizationImpact
2424
}
2525
end
@@ -32,8 +32,8 @@ def self.acceptable_attributes
3232
# Attribute type mapping.
3333
def self.types_mapping
3434
{
35-
:event_scoring => :"Array<EventScoring>",
36-
:facet_scoring => :"Array<FacetScoring>",
35+
:events_scoring => :"Array<EventsScoring>",
36+
:facets_scoring => :"Array<FacetsScoring>",
3737
:personalization_impact => :"Integer"
3838
}
3939
end
@@ -68,20 +68,20 @@ def initialize(attributes = {})
6868
h[k.to_sym] = v
6969
}
7070

71-
if attributes.key?(:event_scoring)
72-
if (value = attributes[:event_scoring]).is_a?(Array)
73-
self.event_scoring = value
71+
if attributes.key?(:events_scoring)
72+
if (value = attributes[:events_scoring]).is_a?(Array)
73+
self.events_scoring = value
7474
end
7575
else
76-
self.event_scoring = nil
76+
self.events_scoring = nil
7777
end
7878

79-
if attributes.key?(:facet_scoring)
80-
if (value = attributes[:facet_scoring]).is_a?(Array)
81-
self.facet_scoring = value
79+
if attributes.key?(:facets_scoring)
80+
if (value = attributes[:facets_scoring]).is_a?(Array)
81+
self.facets_scoring = value
8282
end
8383
else
84-
self.facet_scoring = nil
84+
self.facets_scoring = nil
8585
end
8686

8787
if attributes.key?(:personalization_impact)
@@ -96,8 +96,8 @@ def initialize(attributes = {})
9696
def ==(other)
9797
return true if self.equal?(other)
9898
self.class == other.class &&
99-
event_scoring == other.event_scoring &&
100-
facet_scoring == other.facet_scoring &&
99+
events_scoring == other.events_scoring &&
100+
facets_scoring == other.facets_scoring &&
101101
personalization_impact == other.personalization_impact
102102
end
103103

@@ -110,7 +110,7 @@ def eql?(other)
110110
# Calculates hash code according to all attributes.
111111
# @return [Integer] Hash code
112112
def hash
113-
[event_scoring, facet_scoring, personalization_impact].hash
113+
[events_scoring, facets_scoring, personalization_impact].hash
114114
end
115115

116116
# Builds the object from hash

0 commit comments

Comments
 (0)