TF-1202: Configure FCM
This commit is contained in:
@@ -1,19 +1,19 @@
|
||||
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:tmail_ui_user/features/caching/account_cache_client.dart';
|
||||
import 'package:tmail_ui_user/features/caching/email_cache_client.dart';
|
||||
import 'package:tmail_ui_user/features/caching/firebase_config_cache_client.dart';
|
||||
import 'package:tmail_ui_user/features/caching/mailbox_cache_client.dart';
|
||||
import 'package:tmail_ui_user/features/caching/recent_search_cache_client.dart';
|
||||
import 'package:tmail_ui_user/features/caching/state_cache_client.dart';
|
||||
import 'package:tmail_ui_user/features/mailbox/data/model/state_type.dart';
|
||||
|
||||
class CachingManager {
|
||||
|
||||
final MailboxCacheClient _mailboxCacheClient;
|
||||
final StateCacheClient _stateCacheClient;
|
||||
final EmailCacheClient _emailCacheClient;
|
||||
final RecentSearchCacheClient _recentSearchCacheClient;
|
||||
final AccountCacheClient _accountCacheClient;
|
||||
final FirebaseCacheClient _firebaseCacheClient;
|
||||
|
||||
CachingManager(
|
||||
this._mailboxCacheClient,
|
||||
@@ -21,6 +21,7 @@ class CachingManager {
|
||||
this._emailCacheClient,
|
||||
this._recentSearchCacheClient,
|
||||
this._accountCacheClient,
|
||||
this._firebaseCacheClient,
|
||||
);
|
||||
|
||||
Future<void> clearAll() async {
|
||||
@@ -39,6 +40,7 @@ class CachingManager {
|
||||
_emailCacheClient.deleteBox(),
|
||||
_recentSearchCacheClient.deleteBox(),
|
||||
_accountCacheClient.deleteBox(),
|
||||
_firebaseCacheClient.deleteBox(),
|
||||
]);
|
||||
}
|
||||
}
|
||||
@@ -49,4 +51,4 @@ class CachingManager {
|
||||
_emailCacheClient.clearAllData(),
|
||||
]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
import 'package:tmail_ui_user/features/caching/config/hive_cache_client.dart';
|
||||
import 'package:tmail_ui_user/features/push_notification/data/model/firebase_cache.dart';
|
||||
|
||||
class FirebaseCacheClient extends HiveCacheClient<FirebaseCache> {
|
||||
|
||||
@override
|
||||
String get tableName => 'FirebaseCache';
|
||||
}
|
||||
@@ -13,4 +13,5 @@ class CachingConstants {
|
||||
static const int AUTHENTICATION_INFO_HIVE_CACHE_IDENTIFY = 11;
|
||||
static const int RECENT_LOGIN_URL_HIVE_CACHE_IDENTITY = 12;
|
||||
static const int RECENT_LOGIN_USERNAME_HIVE_CACHE_IDENTITY = 13;
|
||||
static const int FIREBASE_CONFIG_CACHE_IDENTITY = 14;
|
||||
}
|
||||
Reference in New Issue
Block a user