Implement delivery receipts.

1) Support a "receipt" push message type.

2) Identify messages by timestamp.

3) Introduce a JobManager to handle the queue for network
   dependent jobs.
This commit is contained in:
Moxie Marlinspike
2014-07-25 15:14:29 -07:00
parent 8d6b9ae43e
commit 36ec1d84a1
48 changed files with 739 additions and 271 deletions

View File

@@ -25,6 +25,7 @@ public class SendReq extends MultimediaMessagePdu {
private static final String TAG = "SendReq";
private long databaseMessageId;
private long messageBox;
private long timestamp;
public SendReq() {
super();
@@ -90,11 +91,12 @@ public class SendReq extends MultimediaMessagePdu {
super(headers, body);
}
public SendReq(PduHeaders headers, PduBody body, long messageId, long messageBox)
public SendReq(PduHeaders headers, PduBody body, long messageId, long messageBox, long timestamp)
{
super(headers, body);
this.databaseMessageId = messageId;
this.messageBox = messageBox;
this.timestamp = timestamp;
}
public long getDatabaseMessageBox() {
@@ -105,6 +107,10 @@ public class SendReq extends MultimediaMessagePdu {
return databaseMessageId;
}
public long getSentTimestamp() {
return timestamp;
}
/**
* Get Bcc value.
*