mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-12 18:59:06 +01:00
Merge branch 'master' into '941-store-correct-parent-id'
# Conflicts: # briar-core/src/test/java/org/briarproject/briar/blog/BlogManagerImplTest.java
This commit is contained in:
@@ -34,7 +34,7 @@ public interface BlogManager {
|
||||
/**
|
||||
* Returns true if a blog can be removed.
|
||||
*/
|
||||
boolean canBeRemoved(GroupId g) throws DbException;
|
||||
boolean canBeRemoved(Blog b) throws DbException;
|
||||
|
||||
/**
|
||||
* Removes and deletes a blog.
|
||||
|
||||
@@ -7,6 +7,8 @@ import org.briarproject.bramble.api.sync.GroupId;
|
||||
import org.briarproject.bramble.api.sync.Message;
|
||||
import org.briarproject.bramble.api.sync.MessageId;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
|
||||
@NotNullByDefault
|
||||
public interface MessageTracker {
|
||||
|
||||
@@ -38,6 +40,19 @@ public interface MessageTracker {
|
||||
void trackMessage(Transaction txn, GroupId g, long timestamp, boolean read)
|
||||
throws DbException;
|
||||
|
||||
/**
|
||||
* Loads the stored message id for the respective group id or returns null
|
||||
* if none is available.
|
||||
*/
|
||||
@Nullable
|
||||
MessageId loadStoredMessageId(GroupId g) throws DbException;
|
||||
|
||||
/**
|
||||
* Stores the message id for the respective group id. Exactly one message id
|
||||
* can be stored for any group id at any time, older values are overwritten.
|
||||
*/
|
||||
void storeMessageId(GroupId g, MessageId m) throws DbException;
|
||||
|
||||
/**
|
||||
* Marks a message as read or unread and updates the group count.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user