mGet #
Gets multiple documents.
Arguments #
Future<Map<String, dynamic>> mGet(
String index,
String collection,
List<String> ids,
)
Arguments | Type | Description |
---|---|---|
index | String | Index name |
collection | String | Collection name |
ids | List<String> | Document IDs |
Return #
A Map<String, dynamic>
which has a successes
and errors
: Each created document is an object of the successes
array with the following properties:
Property | Type | Description |
---|---|---|
_source | Map<String, dynamic> | Document content |
_id | String | Document ID |
_version | int | Version of the document in the persistent data storage |
The errors
array contains the IDs of not found documents.
Usage #
final result = await kuzzle
.document
.mGet('nyc-open-data', 'yellow-taxi', [
'some-id',
'some-id2'
]);
Edit this page on Github(opens new window)