You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: clients/algoliasearch-client-kotlin/client/src/commonMain/kotlin/com/algolia/client/extensions/SearchClient.kt
+14-14Lines changed: 14 additions & 14 deletions
Original file line number
Diff line number
Diff line change
@@ -311,7 +311,7 @@ public suspend fun SearchClient.searchForFacets(
311
311
* @param indexName The index in which to perform the request.
312
312
* @param objects The list of objects to index.
313
313
* @param action The action to perform on the objects. Default is `Action.AddObject`.
314
-
* @param waitForTask If true, wait for the task to complete.
314
+
* @param waitForTasks If true, wait for the task to complete.
315
315
* @param batchSize The size of the batch. Default is 1000.
316
316
* @param requestOptions The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
317
317
* @return The list of responses from the batch requests.
@@ -321,7 +321,7 @@ public suspend fun SearchClient.chunkedBatch(
321
321
indexName:String,
322
322
objects:List<JsonObject>,
323
323
action:Action = Action.AddObject,
324
-
waitForTask:Boolean,
324
+
waitForTasks:Boolean,
325
325
batchSize:Int = 1000,
326
326
requestOptions:RequestOptions? = null,
327
327
): List<BatchResponse> {
@@ -340,7 +340,7 @@ public suspend fun SearchClient.chunkedBatch(
@@ -351,7 +351,7 @@ public suspend fun SearchClient.chunkedBatch(
351
351
*
352
352
* @param indexName The index in which to perform the request.
353
353
* @param objects The list of objects to index.
354
-
* @param waitForTask If true, wait for the task to complete.
354
+
* @param waitForTasks If true, wait for the task to complete.
355
355
* @param batchSize The size of the batch. Default is 1000.
356
356
* @param requestOptions The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
357
357
* @return The list of responses from the batch requests.
@@ -360,24 +360,24 @@ public suspend fun SearchClient.chunkedBatch(
360
360
publicsuspendfun SearchClient.saveObjects(
361
361
indexName:String,
362
362
objects:List<JsonObject>,
363
-
waitForTask:Boolean = false,
363
+
waitForTasks:Boolean = false,
364
364
batchSize:Int = 1000,
365
365
requestOptions:RequestOptions? = null,
366
366
): List<BatchResponse> =this.chunkedBatch(
367
367
indexName = indexName,
368
368
objects = objects,
369
369
action =Action.AddObject,
370
-
waitForTask=waitForTask,
370
+
waitForTasks=waitForTasks,
371
371
batchSize = batchSize,
372
372
requestOptions = requestOptions,
373
373
)
374
374
375
375
/**
376
-
* Helper: Deletes every records for the given objectIDs. The `chunkedBatch` helper is used under the hood, which creates a `batch` requests with at most 1000 objectIDs in it.
376
+
* Helper: Deletes every record for the given objectIDs. The `chunkedBatch` helper is used under the hood, which creates a `batch` requests with at most 1000 objectIDs in it.
377
377
*
378
378
* @param indexName The index in which to perform the request.
379
379
* @param objectIDs The list of objectIDs to delete from the index.
380
-
* @param waitForTask If true, wait for the task to complete.
380
+
* @param waitForTasks If true, wait for the task to complete.
381
381
* @param batchSize The size of the batch. Default is 1000.
382
382
* @param requestOptions The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
383
383
* @return The list of responses from the batch requests.
@@ -386,14 +386,14 @@ public suspend fun SearchClient.saveObjects(
386
386
publicsuspendfun SearchClient.deleteObjects(
387
387
indexName:String,
388
388
objectIDs:List<String>,
389
-
waitForTask:Boolean = false,
389
+
waitForTasks:Boolean = false,
390
390
batchSize:Int = 1000,
391
391
requestOptions:RequestOptions? = null,
392
392
): List<BatchResponse> =this.chunkedBatch(
393
393
indexName = indexName,
394
394
objects = objectIDs.map { id ->JsonObject(mapOf("objectID" to Json.encodeToJsonElement(id))) },
395
395
action =Action.DeleteObject,
396
-
waitForTask=waitForTask,
396
+
waitForTasks=waitForTasks,
397
397
batchSize = batchSize,
398
398
requestOptions = requestOptions,
399
399
)
@@ -404,7 +404,7 @@ public suspend fun SearchClient.deleteObjects(
404
404
* @param indexName The index in which to perform the request.
405
405
* @param objects The list of objects to update in the index.
406
406
* @param createIfNotExists To be provided if non-existing objects are passed, otherwise, the call will fail..
407
-
* @param waitForTask If true, wait for the task to complete.
407
+
* @param waitForTasks If true, wait for the task to complete.
408
408
* @param batchSize The size of the batch. Default is 1000.
409
409
* @param requestOptions The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
410
410
* @return The list of responses from the batch requests.
@@ -414,14 +414,14 @@ public suspend fun SearchClient.partialUpdateObjects(
Copy file name to clipboardExpand all lines: templates/php/api.mustache
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -509,7 +509,7 @@ use Algolia\AlgoliaSearch\Exceptions\NotFoundException;
509
509
* @param array $requestOptions Request options
510
510
* @param bool $waitForTasks Whether or not we should wait until every `batch` tasks has been processed, this operation may slow the total execution time of this method but is more reliable
511
511
*/
512
-
public function saveObjects($indexName, $objects, $batchSize = 1000, $requestOptions = [], $waitForTasks = false) {
512
+
public function saveObjects($indexName, $objects, $waitForTasks = false, $batchSize = 1000, $requestOptions = [])
0 commit comments