Skip to content

Commit 54060ee

Browse files
committed
fix(specs): multiple clients fixes (generated)
algolia/api-clients-automation#3971 Co-authored-by: algolia-bot <[email protected]>
1 parent 555a596 commit 54060ee

File tree

8 files changed

+141
-25
lines changed

8 files changed

+141
-25
lines changed

lib/Model/Abtesting/ABTestConfiguration.php

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -155,13 +155,7 @@ public static function getters()
155155
*/
156156
public function listInvalidProperties()
157157
{
158-
$invalidProperties = [];
159-
160-
if (!isset($this->container['outliers']) || null === $this->container['outliers']) {
161-
$invalidProperties[] = "'outliers' can't be null";
162-
}
163-
164-
return $invalidProperties;
158+
return [];
165159
}
166160

167161
/**
@@ -178,7 +172,7 @@ public function valid()
178172
/**
179173
* Gets outliers.
180174
*
181-
* @return Outliers
175+
* @return null|Outliers
182176
*/
183177
public function getOutliers()
184178
{
@@ -188,7 +182,7 @@ public function getOutliers()
188182
/**
189183
* Sets outliers.
190184
*
191-
* @param Outliers $outliers outliers
185+
* @param null|Outliers $outliers outliers
192186
*
193187
* @return self
194188
*/

lib/Model/Abtesting/Variant.php

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -300,9 +300,6 @@ public function listInvalidProperties()
300300
if (!isset($this->container['conversionCount']) || null === $this->container['conversionCount']) {
301301
$invalidProperties[] = "'conversionCount' can't be null";
302302
}
303-
if (!isset($this->container['description']) || null === $this->container['description']) {
304-
$invalidProperties[] = "'description' can't be null";
305-
}
306303
if (!isset($this->container['index']) || null === $this->container['index']) {
307304
$invalidProperties[] = "'index' can't be null";
308305
}
@@ -534,7 +531,7 @@ public function setCurrencies($currencies)
534531
/**
535532
* Gets description.
536533
*
537-
* @return string
534+
* @return null|string
538535
*/
539536
public function getDescription()
540537
{
@@ -544,7 +541,7 @@ public function getDescription()
544541
/**
545542
* Sets description.
546543
*
547-
* @param string $description description for this variant
544+
* @param null|string $description description for this variant
548545
*
549546
* @return self
550547
*/

lib/Model/Recommend/RecommendationsResults.php

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ class RecommendationsResults extends AbstractModel implements ModelInterface, \A
2525
'aroundLatLng' => 'string',
2626
'automaticRadius' => 'string',
2727
'exhaustive' => '\Algolia\AlgoliaSearch\Model\Recommend\Exhaustive',
28+
'appliedRules' => 'object[]',
2829
'exhaustiveFacetsCount' => 'bool',
2930
'exhaustiveNbHits' => 'bool',
3031
'exhaustiveTypo' => 'bool',
@@ -63,6 +64,7 @@ class RecommendationsResults extends AbstractModel implements ModelInterface, \A
6364
'aroundLatLng' => null,
6465
'automaticRadius' => null,
6566
'exhaustive' => null,
67+
'appliedRules' => null,
6668
'exhaustiveFacetsCount' => null,
6769
'exhaustiveNbHits' => null,
6870
'exhaustiveTypo' => null,
@@ -102,6 +104,7 @@ class RecommendationsResults extends AbstractModel implements ModelInterface, \A
102104
'aroundLatLng' => 'aroundLatLng',
103105
'automaticRadius' => 'automaticRadius',
104106
'exhaustive' => 'exhaustive',
107+
'appliedRules' => 'appliedRules',
105108
'exhaustiveFacetsCount' => 'exhaustiveFacetsCount',
106109
'exhaustiveNbHits' => 'exhaustiveNbHits',
107110
'exhaustiveTypo' => 'exhaustiveTypo',
@@ -140,6 +143,7 @@ class RecommendationsResults extends AbstractModel implements ModelInterface, \A
140143
'aroundLatLng' => 'setAroundLatLng',
141144
'automaticRadius' => 'setAutomaticRadius',
142145
'exhaustive' => 'setExhaustive',
146+
'appliedRules' => 'setAppliedRules',
143147
'exhaustiveFacetsCount' => 'setExhaustiveFacetsCount',
144148
'exhaustiveNbHits' => 'setExhaustiveNbHits',
145149
'exhaustiveTypo' => 'setExhaustiveTypo',
@@ -178,6 +182,7 @@ class RecommendationsResults extends AbstractModel implements ModelInterface, \A
178182
'aroundLatLng' => 'getAroundLatLng',
179183
'automaticRadius' => 'getAutomaticRadius',
180184
'exhaustive' => 'getExhaustive',
185+
'appliedRules' => 'getAppliedRules',
181186
'exhaustiveFacetsCount' => 'getExhaustiveFacetsCount',
182187
'exhaustiveNbHits' => 'getExhaustiveNbHits',
183188
'exhaustiveTypo' => 'getExhaustiveTypo',
@@ -234,6 +239,9 @@ public function __construct(?array $data = null)
234239
if (isset($data['exhaustive'])) {
235240
$this->container['exhaustive'] = $data['exhaustive'];
236241
}
242+
if (isset($data['appliedRules'])) {
243+
$this->container['appliedRules'] = $data['appliedRules'];
244+
}
237245
if (isset($data['exhaustiveFacetsCount'])) {
238246
$this->container['exhaustiveFacetsCount'] = $data['exhaustiveFacetsCount'];
239247
}
@@ -512,6 +520,30 @@ public function setExhaustive($exhaustive)
512520
return $this;
513521
}
514522

523+
/**
524+
* Gets appliedRules.
525+
*
526+
* @return null|object[]
527+
*/
528+
public function getAppliedRules()
529+
{
530+
return $this->container['appliedRules'] ?? null;
531+
}
532+
533+
/**
534+
* Sets appliedRules.
535+
*
536+
* @param null|object[] $appliedRules rules applied to the query
537+
*
538+
* @return self
539+
*/
540+
public function setAppliedRules($appliedRules)
541+
{
542+
$this->container['appliedRules'] = $appliedRules;
543+
544+
return $this;
545+
}
546+
515547
/**
516548
* Gets exhaustiveFacetsCount.
517549
*

lib/Model/Search/BrowseResponse.php

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ class BrowseResponse extends AbstractModel implements ModelInterface, \ArrayAcce
2525
'aroundLatLng' => 'string',
2626
'automaticRadius' => 'string',
2727
'exhaustive' => '\Algolia\AlgoliaSearch\Model\Search\Exhaustive',
28+
'appliedRules' => 'object[]',
2829
'exhaustiveFacetsCount' => 'bool',
2930
'exhaustiveNbHits' => 'bool',
3031
'exhaustiveTypo' => 'bool',
@@ -66,6 +67,7 @@ class BrowseResponse extends AbstractModel implements ModelInterface, \ArrayAcce
6667
'aroundLatLng' => null,
6768
'automaticRadius' => null,
6869
'exhaustive' => null,
70+
'appliedRules' => null,
6971
'exhaustiveFacetsCount' => null,
7072
'exhaustiveNbHits' => null,
7173
'exhaustiveTypo' => null,
@@ -108,6 +110,7 @@ class BrowseResponse extends AbstractModel implements ModelInterface, \ArrayAcce
108110
'aroundLatLng' => 'aroundLatLng',
109111
'automaticRadius' => 'automaticRadius',
110112
'exhaustive' => 'exhaustive',
113+
'appliedRules' => 'appliedRules',
111114
'exhaustiveFacetsCount' => 'exhaustiveFacetsCount',
112115
'exhaustiveNbHits' => 'exhaustiveNbHits',
113116
'exhaustiveTypo' => 'exhaustiveTypo',
@@ -149,6 +152,7 @@ class BrowseResponse extends AbstractModel implements ModelInterface, \ArrayAcce
149152
'aroundLatLng' => 'setAroundLatLng',
150153
'automaticRadius' => 'setAutomaticRadius',
151154
'exhaustive' => 'setExhaustive',
155+
'appliedRules' => 'setAppliedRules',
152156
'exhaustiveFacetsCount' => 'setExhaustiveFacetsCount',
153157
'exhaustiveNbHits' => 'setExhaustiveNbHits',
154158
'exhaustiveTypo' => 'setExhaustiveTypo',
@@ -190,6 +194,7 @@ class BrowseResponse extends AbstractModel implements ModelInterface, \ArrayAcce
190194
'aroundLatLng' => 'getAroundLatLng',
191195
'automaticRadius' => 'getAutomaticRadius',
192196
'exhaustive' => 'getExhaustive',
197+
'appliedRules' => 'getAppliedRules',
193198
'exhaustiveFacetsCount' => 'getExhaustiveFacetsCount',
194199
'exhaustiveNbHits' => 'getExhaustiveNbHits',
195200
'exhaustiveTypo' => 'getExhaustiveTypo',
@@ -249,6 +254,9 @@ public function __construct(?array $data = null)
249254
if (isset($data['exhaustive'])) {
250255
$this->container['exhaustive'] = $data['exhaustive'];
251256
}
257+
if (isset($data['appliedRules'])) {
258+
$this->container['appliedRules'] = $data['appliedRules'];
259+
}
252260
if (isset($data['exhaustiveFacetsCount'])) {
253261
$this->container['exhaustiveFacetsCount'] = $data['exhaustiveFacetsCount'];
254262
}
@@ -542,6 +550,30 @@ public function setExhaustive($exhaustive)
542550
return $this;
543551
}
544552

553+
/**
554+
* Gets appliedRules.
555+
*
556+
* @return null|object[]
557+
*/
558+
public function getAppliedRules()
559+
{
560+
return $this->container['appliedRules'] ?? null;
561+
}
562+
563+
/**
564+
* Sets appliedRules.
565+
*
566+
* @param null|object[] $appliedRules rules applied to the query
567+
*
568+
* @return self
569+
*/
570+
public function setAppliedRules($appliedRules)
571+
{
572+
$this->container['appliedRules'] = $appliedRules;
573+
574+
return $this;
575+
}
576+
545577
/**
546578
* Gets exhaustiveFacetsCount.
547579
*

lib/Model/Search/GetApiKeyResponse.php

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,9 @@ public function listInvalidProperties()
211211
{
212212
$invalidProperties = [];
213213

214+
if (!isset($this->container['value']) || null === $this->container['value']) {
215+
$invalidProperties[] = "'value' can't be null";
216+
}
214217
if (!isset($this->container['createdAt']) || null === $this->container['createdAt']) {
215218
$invalidProperties[] = "'createdAt' can't be null";
216219
}
@@ -235,7 +238,7 @@ public function valid()
235238
/**
236239
* Gets value.
237240
*
238-
* @return null|string
241+
* @return string
239242
*/
240243
public function getValue()
241244
{
@@ -245,7 +248,7 @@ public function getValue()
245248
/**
246249
* Sets value.
247250
*
248-
* @param null|string $value API key
251+
* @param string $value API key
249252
*
250253
* @return self
251254
*/

lib/Model/Search/GetObjectsResponse.php

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -137,13 +137,7 @@ public static function getters()
137137
*/
138138
public function listInvalidProperties()
139139
{
140-
$invalidProperties = [];
141-
142-
if (!isset($this->container['results']) || null === $this->container['results']) {
143-
$invalidProperties[] = "'results' can't be null";
144-
}
145-
146-
return $invalidProperties;
140+
return [];
147141
}
148142

149143
/**
@@ -160,7 +154,7 @@ public function valid()
160154
/**
161155
* Gets results.
162156
*
163-
* @return object[]
157+
* @return null|object[]
164158
*/
165159
public function getResults()
166160
{
@@ -170,7 +164,7 @@ public function getResults()
170164
/**
171165
* Sets results.
172166
*
173-
* @param object[] $results retrieved records
167+
* @param null|object[] $results retrieved records
174168
*
175169
* @return self
176170
*/

lib/Model/Search/SearchResponse.php

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ class SearchResponse extends AbstractModel implements ModelInterface, \ArrayAcce
2525
'aroundLatLng' => 'string',
2626
'automaticRadius' => 'string',
2727
'exhaustive' => '\Algolia\AlgoliaSearch\Model\Search\Exhaustive',
28+
'appliedRules' => 'object[]',
2829
'exhaustiveFacetsCount' => 'bool',
2930
'exhaustiveNbHits' => 'bool',
3031
'exhaustiveTypo' => 'bool',
@@ -65,6 +66,7 @@ class SearchResponse extends AbstractModel implements ModelInterface, \ArrayAcce
6566
'aroundLatLng' => null,
6667
'automaticRadius' => null,
6768
'exhaustive' => null,
69+
'appliedRules' => null,
6870
'exhaustiveFacetsCount' => null,
6971
'exhaustiveNbHits' => null,
7072
'exhaustiveTypo' => null,
@@ -106,6 +108,7 @@ class SearchResponse extends AbstractModel implements ModelInterface, \ArrayAcce
106108
'aroundLatLng' => 'aroundLatLng',
107109
'automaticRadius' => 'automaticRadius',
108110
'exhaustive' => 'exhaustive',
111+
'appliedRules' => 'appliedRules',
109112
'exhaustiveFacetsCount' => 'exhaustiveFacetsCount',
110113
'exhaustiveNbHits' => 'exhaustiveNbHits',
111114
'exhaustiveTypo' => 'exhaustiveTypo',
@@ -146,6 +149,7 @@ class SearchResponse extends AbstractModel implements ModelInterface, \ArrayAcce
146149
'aroundLatLng' => 'setAroundLatLng',
147150
'automaticRadius' => 'setAutomaticRadius',
148151
'exhaustive' => 'setExhaustive',
152+
'appliedRules' => 'setAppliedRules',
149153
'exhaustiveFacetsCount' => 'setExhaustiveFacetsCount',
150154
'exhaustiveNbHits' => 'setExhaustiveNbHits',
151155
'exhaustiveTypo' => 'setExhaustiveTypo',
@@ -186,6 +190,7 @@ class SearchResponse extends AbstractModel implements ModelInterface, \ArrayAcce
186190
'aroundLatLng' => 'getAroundLatLng',
187191
'automaticRadius' => 'getAutomaticRadius',
188192
'exhaustive' => 'getExhaustive',
193+
'appliedRules' => 'getAppliedRules',
189194
'exhaustiveFacetsCount' => 'getExhaustiveFacetsCount',
190195
'exhaustiveNbHits' => 'getExhaustiveNbHits',
191196
'exhaustiveTypo' => 'getExhaustiveTypo',
@@ -244,6 +249,9 @@ public function __construct(?array $data = null)
244249
if (isset($data['exhaustive'])) {
245250
$this->container['exhaustive'] = $data['exhaustive'];
246251
}
252+
if (isset($data['appliedRules'])) {
253+
$this->container['appliedRules'] = $data['appliedRules'];
254+
}
247255
if (isset($data['exhaustiveFacetsCount'])) {
248256
$this->container['exhaustiveFacetsCount'] = $data['exhaustiveFacetsCount'];
249257
}
@@ -534,6 +542,30 @@ public function setExhaustive($exhaustive)
534542
return $this;
535543
}
536544

545+
/**
546+
* Gets appliedRules.
547+
*
548+
* @return null|object[]
549+
*/
550+
public function getAppliedRules()
551+
{
552+
return $this->container['appliedRules'] ?? null;
553+
}
554+
555+
/**
556+
* Sets appliedRules.
557+
*
558+
* @param null|object[] $appliedRules rules applied to the query
559+
*
560+
* @return self
561+
*/
562+
public function setAppliedRules($appliedRules)
563+
{
564+
$this->container['appliedRules'] = $appliedRules;
565+
566+
return $this;
567+
}
568+
537569
/**
538570
* Gets exhaustiveFacetsCount.
539571
*

0 commit comments

Comments
 (0)