Add a new sync dbus message which shows messages you sent. Necessary for having synchronized chats where you want your message to appear. Format is similar to receive message dbus except instead of sender, it has sender (source) and receiver (destination). (#289)

This commit is contained in:
narodnik 2020-04-03 13:16:57 +02:00 committed by GitHub
parent e684a902bb
commit d49d536c32
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 114 additions and 22 deletions

View file

@ -96,4 +96,47 @@ public interface Signal extends DBusInterface {
return sender;
}
}
class SyncMessageReceived extends DBusSignal {
private long timestamp;
private String source;
private String destination;
private byte[] groupId;
private String message;
private List<String> attachments;
public SyncMessageReceived(String objectpath, long timestamp, String source, String destination, byte[] groupId, String message, List<String> attachments) throws DBusException {
super(objectpath, timestamp, source, destination, groupId, message, attachments);
this.timestamp = timestamp;
this.source = source;
this.destination = destination;
this.groupId = groupId;
this.message = message;
this.attachments = attachments;
}
public long getTimestamp() {
return timestamp;
}
public String getSource() {
return source;
}
public String getDestination() {
return destination;
}
public byte[] getGroupId() {
return groupId;
}
public String getMessage() {
return message;
}
public List<String> getAttachments() {
return attachments;
}
}
}