jay_api 27.5.0 → 28.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0023753053e15b7b8982ebe074f705a6fd2ff103c4088b5913a961fe113e010d
4
- data.tar.gz: 978121f009ece07730bcb0821d21f3ad5798caaf9589a446a31f02e5e25897e3
3
+ metadata.gz: 641132f73f359c5e49bff17518040894399eb1396e5c17b629ae91f44007c702
4
+ data.tar.gz: 5c309039f6ce9ab628632624ebd6cfe542995ecd772dfad834a21fea799d5005
5
5
  SHA512:
6
- metadata.gz: f7ca59c3d9de98e6e3887afd0cae27959703ebf4c213335142dccd6532ed2342f895f15de1deed4c9b73ca910e161293c56bf41e90c45673213ba72b63be3dab
7
- data.tar.gz: a53fc7870322d03b7fd986c3598a3c7e629253a8ebf142006b7ea713f161eed71d752ee02c77e1714ca89ab552de91196baaa7745a483980536338cdd6ebd059
6
+ metadata.gz: 89eeffecce6f605111ea8fc641b287022b636ea06304d7932d9297777c68ecf3e1e65c76ede81876e9dc1d0f06bd4969e80e29d0f75b8da1a85acab95971f9eb
7
+ data.tar.gz: 9505af9f03871fea1f9ceae6ace4718100ac2921c5ec04b17a65769f91dbcd0c2b951a3f38473b3b5186ccf00d70b3add50cc334a47e703eb2a3641f07ea7bdf
data/CHANGELOG.md CHANGED
@@ -8,6 +8,22 @@ Please mark backwards incompatible changes with an exclamation mark at the start
8
8
 
9
9
  ## [Unreleased]
10
10
 
11
+ ## [28.0.0] - 2025-05-09
12
+
13
+ ### Added
14
+ - ! The `#keys` method to the `Configuration` class. The method returns the
15
+ array of keys that the `Configuration` object has.
16
+
17
+ Note that the addition of this method means that it is no longer possible to
18
+ access the value of an attribute called `keys` via the dot syntax, however,
19
+ it is still possible to access its value using the brackets: `[]`
20
+
21
+ ## [27.5.1] - 2025-04-24
22
+
23
+ ### Fixed
24
+ - The `Aggregations::TopHits` class cloning. The nested aggregations are now
25
+ also being cloned as expected.
26
+
11
27
  ## [27.5.0] - 2025-04-22
12
28
 
13
29
  ### Added
@@ -89,6 +89,12 @@ module JayAPI
89
89
  YAML.dump(deep_to_h.deep_stringify_keys)
90
90
  end
91
91
 
92
+ # @return [Array<Object>] An array with the keys (generally the name of the
93
+ # attributes) that the configuration object has.
94
+ def keys
95
+ @table.keys
96
+ end
97
+
92
98
  private
93
99
 
94
100
  # Takes a value and transforms it in accordance to its type.
@@ -104,7 +110,7 @@ module JayAPI
104
110
  when self.class
105
111
  value.deep_to_h
106
112
  when Hash
107
- value.to_h { |hash_key, hash_value| [hash_key, value_for_h(hash_value)] }
113
+ value.transform_values { |hash_value| value_for_h(hash_value) }
108
114
  when Array
109
115
  value.map { |element| value_for_h(element) }
110
116
  else
@@ -28,7 +28,9 @@ module JayAPI
28
28
 
29
29
  # @return [self] A copy of the receiver.
30
30
  def clone
31
- self.class.new(name, size: size)
31
+ copy = self.class.new(name, size: size)
32
+ copy.aggregations = aggregations.clone
33
+ copy
32
34
  end
33
35
 
34
36
  # @return [Hash] The Hash representation of the +Aggregation+.
@@ -2,5 +2,5 @@
2
2
 
3
3
  module JayAPI
4
4
  # JayAPI gem's semantic version
5
- VERSION = '27.5.0'
5
+ VERSION = '28.0.0'
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jay_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 27.5.0
4
+ version: 28.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Accenture-Industry X
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2025-04-22 00:00:00.000000000 Z
12
+ date: 2025-05-09 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activesupport