run static method
Runs a recommendation query
The query
is a map with:
['pois']: a list of maps with
['poi']: an string with the poi identifier
['categories']: a list of string ids with the categories of the poi
The query returns a list of ResultEntry sorted decreasingly by the ResultEntry score. The methods throws a LgcreException if an internal error occurs and the query cannot be executed. This method is transactional and can be executed concurrently with other transactional methods
Implementation
static Future<List<ResultEntry>?> run(Map<String,dynamic> query) async
{
try
{
final List<String>? entries = await _channel.invokeListMethod<String>('run', query);
return entries?.map(ResultEntry.fromJson).toList() ?? <ResultEntry>[];
} on PlatformException catch (e)
{
throw new LgcreException('${e.message}');
}
}