initializeStore method
Implementation
@override
Future<JobDone> initializeStore() async {
try {
if (_store != null) {
return const JobDone();
}
if (storeFactory == null) {
throw const DatabaseBridgeException(
error:
'Store factory is required. Please provide a store factory function that returns a Store instance.',
);
}
final directory = await _getStoreDirectory();
_store = await storeFactory!(directory.path);
return const JobDone();
} catch (e) {
throw DatabaseBridgeException(error: e);
}
}