mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-12 18:59:06 +01:00
Add a contactExists() method to the contactManager
This requires exposing the `containsContact()` method to the `DatabaseComponent` and is needed for finding out efficiently whether a contact already exists.
This commit is contained in:
@@ -162,6 +162,13 @@ public interface DatabaseComponent {
|
||||
Collection<ContactId> getContacts(Transaction txn, AuthorId a)
|
||||
throws DbException;
|
||||
|
||||
/**
|
||||
* Returns true if the database contains the given contact for the given
|
||||
* local pseudonym.
|
||||
*/
|
||||
boolean containsContact(Transaction txn, AuthorId remote, AuthorId local)
|
||||
throws DbException;
|
||||
|
||||
/**
|
||||
* Returns the unique ID for this device.
|
||||
* <p/>
|
||||
|
||||
Reference in New Issue
Block a user