init method

  1. @override
Future<void> init()
override

Public APIs to be implemented by any Persistor extension like FilePersistor.

Initialization function called when the persistor is instantiated to execute and setup work.

Implementation

@override
Future<void> init() async {
  await spawnWorker(
    SqlitePersistorWorker.new,
    config: SqlitePersistorWorkerConfig(
      useFfi: useFfi,
      persistenceThrottle: persistenceThrottle,
      settings: settings,
      encrypter: encrypter,
    ),
  );
}