mirror of
https://codeberg.org/Mercury-IM/Mercury-IM
synced 2024-06-18 09:34:52 +02:00
Add handy methods to AccountRepository
This commit is contained in:
parent
ed31f5c8c8
commit
fc48b35f05
|
@ -15,8 +15,16 @@ public interface AccountRepository {
|
|||
|
||||
Single<Account> insertAccount(Account account);
|
||||
|
||||
default Observable<Optional<Account>> observeAccount(Account account) {
|
||||
return observeAccount(account.getId());
|
||||
}
|
||||
|
||||
Observable<Optional<Account>> observeAccount(UUID accountId);
|
||||
|
||||
default Maybe<Account> getAccount(Account account) {
|
||||
return getAccount(account.getId());
|
||||
}
|
||||
|
||||
Maybe<Account> getAccount(UUID accountId);
|
||||
|
||||
Observable<Optional<Account>> observeAccountByAddress(String address);
|
||||
|
|
Loading…
Reference in a new issue