mUpdate method

Future<Map<String, dynamic>> mUpdate(
  1. String index,
  2. String collection,
  3. List<Map<String, dynamic>> documents, {
  4. bool waitForRefresh = false,
  5. int? retryOnConflict,
})

Updates multiple documents.

Implementation

Future<Map<String, dynamic>> mUpdate(
    String index, String collection, List<Map<String, dynamic>> documents,
    {bool waitForRefresh = false, int? retryOnConflict}) async {
  final response = await kuzzle.query(KuzzleRequest(
    controller: name,
    action: 'mUpdate',
    index: index,
    collection: collection,
    body: <String, dynamic>{'documents': documents},
    waitForRefresh: waitForRefresh,
    retryOnConflict: retryOnConflict,
  ));

  return response.result as Map<String, dynamic>;
}