deleteLocalByKeys method

void deleteLocalByKeys(
  1. Iterable<String> keys, {
  2. bool notify = true,
})
inherited

Deletes models with keys from local storage.

Implementation

void deleteLocalByKeys(Iterable<String> keys, {bool notify = true}) {
  final intKeys = keys.map((k) => k.detypifyKey()!).toList();
  db.execute(
      'DELETE FROM $internalType WHERE key IN (${keys.map((_) => '?').join(', ')})',
      intKeys);
  core.deleteKeys(keys);
  if (notify) {
    core._notify([...keys], type: DataGraphEventType.removeNode);
  }
}