mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-14 11:49:04 +01:00
Show blog invitation requests and responses in private conversation
This commit is contained in:
@@ -8,20 +8,20 @@ import org.briarproject.api.sync.MessageId;
|
||||
|
||||
public class BlogInvitationRequest extends InvitationRequest {
|
||||
|
||||
private final String blogTitle;
|
||||
private final String blogAuthorName;
|
||||
|
||||
public BlogInvitationRequest(MessageId id, SessionId sessionId,
|
||||
ContactId contactId, String blogTitle, String message,
|
||||
ContactId contactId, String blogAuthorName, String message,
|
||||
boolean available, long time, boolean local, boolean sent,
|
||||
boolean seen, boolean read) {
|
||||
|
||||
super(id, sessionId, contactId, message, available, time, local, sent,
|
||||
seen, read);
|
||||
this.blogTitle = blogTitle;
|
||||
this.blogAuthorName = blogAuthorName;
|
||||
}
|
||||
|
||||
public String getBlogTitle() {
|
||||
return blogTitle;
|
||||
public String getBlogAuthorName() {
|
||||
return blogAuthorName;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
package org.briarproject.api.blogs;
|
||||
|
||||
import org.briarproject.api.clients.SessionId;
|
||||
import org.briarproject.api.contact.ContactId;
|
||||
import org.briarproject.api.sharing.InvitationResponse;
|
||||
import org.briarproject.api.sync.MessageId;
|
||||
|
||||
public class BlogInvitationResponse extends InvitationResponse {
|
||||
|
||||
public BlogInvitationResponse(MessageId id, SessionId sessionId,
|
||||
ContactId contactId, boolean accept, long time, boolean local,
|
||||
boolean sent, boolean seen, boolean read) {
|
||||
|
||||
super(id, sessionId, contactId, accept, time, local, sent, seen, read);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -3,14 +3,14 @@ package org.briarproject.api.blogs;
|
||||
import org.briarproject.api.contact.Contact;
|
||||
import org.briarproject.api.contact.ContactId;
|
||||
import org.briarproject.api.db.DbException;
|
||||
import org.briarproject.api.sharing.InvitationMessage;
|
||||
import org.briarproject.api.sharing.SharingManager;
|
||||
import org.briarproject.api.sync.ClientId;
|
||||
import org.briarproject.api.sync.GroupId;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
public interface BlogSharingManager
|
||||
extends SharingManager<Blog, BlogInvitationRequest> {
|
||||
public interface BlogSharingManager extends SharingManager<Blog> {
|
||||
|
||||
/**
|
||||
* Returns the unique ID of the blog sharing client.
|
||||
@@ -34,7 +34,7 @@ public interface BlogSharingManager
|
||||
* Returns all blogs sharing messages sent by the Contact
|
||||
* identified by contactId.
|
||||
*/
|
||||
Collection<BlogInvitationRequest> getInvitationMessages(
|
||||
Collection<InvitationMessage> getInvitationMessages(
|
||||
ContactId contactId) throws DbException;
|
||||
|
||||
/**
|
||||
|
||||
@@ -10,7 +10,7 @@ import org.briarproject.api.sync.GroupId;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
public interface ForumSharingManager extends SharingManager<Forum, InvitationMessage> {
|
||||
public interface ForumSharingManager extends SharingManager<Forum> {
|
||||
|
||||
/** Returns the unique ID of the forum sharing client. */
|
||||
ClientId getClientId();
|
||||
|
||||
@@ -8,7 +8,7 @@ import org.briarproject.api.sync.GroupId;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
public interface SharingManager<S extends Shareable, IM extends InvitationMessage> {
|
||||
public interface SharingManager<S extends Shareable> {
|
||||
|
||||
/** Returns the unique ID of the group sharing client. */
|
||||
ClientId getClientId();
|
||||
@@ -30,7 +30,7 @@ public interface SharingManager<S extends Shareable, IM extends InvitationMessag
|
||||
* Returns all group sharing messages sent by the Contact
|
||||
* identified by contactId.
|
||||
*/
|
||||
Collection<IM> getInvitationMessages(
|
||||
Collection<InvitationMessage> getInvitationMessages(
|
||||
ContactId contactId) throws DbException;
|
||||
|
||||
/** Returns all shareables to which the user has been invited. */
|
||||
|
||||
Reference in New Issue
Block a user