rawQuery method

Future<ArangoCursor> rawQuery(
  1. String aql,
  2. {Map<String, dynamic> bindVars,
  3. bool allowDirtyRead,
  4. Duration timeout,
  5. bool returnCount = false,
  6. int batchSize,
  7. int ttl,
  8. bool cache,
  9. int memoryLimit,
  10. Map<String, dynamic> options}
)

Implementation

Future<ArangoCursor> rawQuery(
  String aql, {
  Map<String, dynamic> bindVars,
  bool allowDirtyRead,
  Duration timeout,
  bool returnCount = false,
  int batchSize,
  int ttl,
  bool cache,
  int memoryLimit,
  Map<String, dynamic> options,
}) async {
  final resp = await _connection.request(
    method: 'POST',
    path: '/_api/cursor',
    allowDirtyRead: allowDirtyRead,
    timeout: timeout,
    body: {
      'query': aql,
      if (bindVars != null) 'bindVars': bindVars,
      'count': returnCount,
      'batchSize': batchSize,
      'ttl': ttl,
      'cache': cache,
      'memoryLimit': memoryLimit,
      'options': options,
    },
  );

  return ArangoCursor(
    _connection,
    resp.arangoDartHostId,
    allowDirtyRead,
    resp.body,
  );
}