Update private group invitation client to include self-destruct timers.

This commit is contained in:
akwizgran
2020-11-23 15:42:39 +00:00
committed by Torsten Grote
parent fa745410cc
commit 3e1c2df4b1
23 changed files with 460 additions and 199 deletions

View File

@@ -32,7 +32,7 @@ public interface GroupInvitationManager extends ConversationClient {
/**
* The current minor version of the private group invitation client.
*/
int MINOR_VERSION = 0;
int MINOR_VERSION = 1;
/**
* Sends an invitation to share the given private group with the given

View File

@@ -11,8 +11,6 @@ import org.briarproject.briar.api.sharing.InvitationRequest;
import javax.annotation.Nullable;
import javax.annotation.concurrent.Immutable;
import static org.briarproject.bramble.api.autodelete.AutoDeleteConstants.NO_AUTO_DELETE_TIMER;
@Immutable
@NotNullByDefault
public class GroupInvitationRequest extends InvitationRequest<PrivateGroup> {
@@ -20,9 +18,10 @@ public class GroupInvitationRequest extends InvitationRequest<PrivateGroup> {
public GroupInvitationRequest(MessageId id, GroupId groupId, long time,
boolean local, boolean read, boolean sent, boolean seen,
SessionId sessionId, PrivateGroup shareable,
@Nullable String text, boolean available, boolean canBeOpened) {
@Nullable String text, boolean available, boolean canBeOpened,
long autoDeleteTimer) {
super(id, groupId, time, local, read, sent, seen, sessionId, shareable,
text, available, canBeOpened, NO_AUTO_DELETE_TIMER);
text, available, canBeOpened, autoDeleteTimer);
}
@Override

View File

@@ -9,17 +9,16 @@ import org.briarproject.briar.api.sharing.InvitationResponse;
import javax.annotation.concurrent.Immutable;
import static org.briarproject.bramble.api.autodelete.AutoDeleteConstants.NO_AUTO_DELETE_TIMER;
@Immutable
@NotNullByDefault
public class GroupInvitationResponse extends InvitationResponse {
public GroupInvitationResponse(MessageId id, GroupId groupId, long time,
boolean local, boolean read, boolean sent, boolean seen,
SessionId sessionId, boolean accept, GroupId shareableId) {
SessionId sessionId, boolean accept, GroupId shareableId,
long autoDeleteTimer) {
super(id, groupId, time, local, read, sent, seen, sessionId,
accept, shareableId, NO_AUTO_DELETE_TIMER);
accept, shareableId, autoDeleteTimer);
}
@Override