Future insertAll(List<T> records) async { await _collection.insertAll(records.map((e) => toJson.call(e)).toList()); }