Use TupleKey(ObjectKey-AccountId-UserName) to store data to hive

(cherry picked from commit e0ace535d5f3af71eb13598d92524caf2c6d9bbf)
This commit is contained in:
dab246
2023-04-27 11:03:39 +07:00
committed by Dat Vu
parent 7d0a5729b2
commit 876cc368b0
107 changed files with 562 additions and 340 deletions
@@ -1,9 +1,9 @@
import 'package:model/account/account.dart';
import 'package:model/account/personal_account.dart';
abstract class AccountDatasource {
Future<Account> getCurrentAccount();
Future<PersonalAccount> getCurrentAccount();
Future<void> setCurrentAccount(Account newCurrentAccount);
Future<void> setCurrentAccount(PersonalAccount newCurrentAccount);
Future<void> deleteCurrentAccount(String accountId);
}
@@ -1,4 +1,6 @@
import 'package:model/model.dart';
import 'package:jmap_dart_client/jmap/core/user_name.dart';
import 'package:model/account/password.dart';
import 'package:model/user/user_profile.dart';
abstract class AuthenticationDataSource {
Future<UserProfile> authenticationUser(Uri baseUrl, UserName userName, Password password);