import 'package:flutter/foundation.dart' show immutable; import 'package:hive_ce/hive.dart'; import 'package:vaani/features/per_book_settings/models/book_settings.dart'; import 'package:vaani/features/settings/models/models.dart'; @immutable class AvailableHiveBoxes { const AvailableHiveBoxes._(); static Future init() async { await Hive.openBox('basicTypes'); /// Box for storing user preferences as [AppSettings] await Hive.openBox('userPrefs'); /// Box for storing [ApiSettings] await Hive.openBox('apiSettings'); /// stores the a list of [AudiobookShelfServer] await Hive.openBox('audiobookShelfServer'); /// stores the a list of [AuthenticatedUser] await Hive.openBox('authenticatedUser'); /// stores the a list of [BookSettings] await Hive.openBox('bookSettings'); } static final basicBox = Hive.box('basicTypes'); /// Box for storing user preferences as [AppSettings] static final userPrefsBox = Hive.box('userPrefs'); /// Box for storing [ApiSettings] static final apiSettingsBox = Hive.box('apiSettings'); /// stores the a list of [AudiobookShelfServer] static final serverBox = Hive.box('audiobookShelfServer'); /// stores the a list of [AuthenticatedUser] static final authenticatedUserBox = Hive.box('authenticatedUser'); /// stores the a list of [BookSettings] static final individualBookSettingsBox = Hive.box('bookSettings'); }