public class SignalServiceDataMessage
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
SignalServiceDataMessage.Builder |
| Constructor and Description |
|---|
SignalServiceDataMessage(long timestamp,
java.util.List<SignalServiceAttachment> attachments,
java.lang.String body)
Construct a SignalServiceDataMessage with a body and list of attachments.
|
SignalServiceDataMessage(long timestamp,
java.util.List<SignalServiceAttachment> attachments,
java.lang.String body,
int expiresInSeconds)
Construct an expiring SignalServiceDataMessage with a body and list of attachments.
|
SignalServiceDataMessage(long timestamp,
SignalServiceAttachment attachment,
java.lang.String body) |
SignalServiceDataMessage(long timestamp,
SignalServiceGroup group,
java.util.List<SignalServiceAttachment> attachments,
java.lang.String body)
Construct a SignalServiceDataMessage group message with attachments and body.
|
SignalServiceDataMessage(long timestamp,
SignalServiceGroup group,
java.util.List<SignalServiceAttachment> attachments,
java.lang.String body,
boolean endSession,
int expiresInSeconds,
boolean expirationUpdate)
Construct a SignalServiceDataMessage.
|
SignalServiceDataMessage(long timestamp,
SignalServiceGroup group,
java.util.List<SignalServiceAttachment> attachments,
java.lang.String body,
int expiresInSeconds)
Construct an expiring SignalServiceDataMessage group message with attachments and body.
|
SignalServiceDataMessage(long timestamp,
java.lang.String body)
Construct a SignalServiceDataMessage with a body and no attachments.
|
SignalServiceDataMessage(long timestamp,
java.lang.String body,
int expiresInSeconds)
Construct an expiring SignalServiceDataMessage with a body and no attachments.
|
| Modifier and Type | Method and Description |
|---|---|
org.whispersystems.libsignal.util.guava.Optional<java.util.List<SignalServiceAttachment>> |
getAttachments() |
org.whispersystems.libsignal.util.guava.Optional<java.lang.String> |
getBody() |
int |
getExpiresInSeconds() |
org.whispersystems.libsignal.util.guava.Optional<SignalServiceGroup> |
getGroupInfo() |
long |
getTimestamp() |
boolean |
isEndSession() |
boolean |
isExpirationUpdate() |
boolean |
isGroupUpdate() |
static SignalServiceDataMessage.Builder |
newBuilder() |
public SignalServiceDataMessage(long timestamp,
java.lang.String body)
timestamp - The sent timestamp.body - The message contents.public SignalServiceDataMessage(long timestamp,
java.lang.String body,
int expiresInSeconds)
timestamp - The sent timestamp.body - The message contents.expiresInSeconds - The number of seconds in which the message should expire after having been seen.public SignalServiceDataMessage(long timestamp,
SignalServiceAttachment attachment,
java.lang.String body)
public SignalServiceDataMessage(long timestamp,
java.util.List<SignalServiceAttachment> attachments,
java.lang.String body)
timestamp - The sent timestamp.attachments - The attachments.body - The message contents.public SignalServiceDataMessage(long timestamp,
java.util.List<SignalServiceAttachment> attachments,
java.lang.String body,
int expiresInSeconds)
timestamp - The sent timestamp.attachments - The attachments.body - The message contents.expiresInSeconds - The number of seconds in which the message should expire after having been seen.public SignalServiceDataMessage(long timestamp,
SignalServiceGroup group,
java.util.List<SignalServiceAttachment> attachments,
java.lang.String body)
timestamp - The sent timestamp.group - The group information.attachments - The attachments.body - The message contents.public SignalServiceDataMessage(long timestamp,
SignalServiceGroup group,
java.util.List<SignalServiceAttachment> attachments,
java.lang.String body,
int expiresInSeconds)
timestamp - The sent timestamp.group - The group information.attachments - The attachments.body - The message contents.expiresInSeconds - The number of seconds in which a message should disappear after having been seen.public SignalServiceDataMessage(long timestamp,
SignalServiceGroup group,
java.util.List<SignalServiceAttachment> attachments,
java.lang.String body,
boolean endSession,
int expiresInSeconds,
boolean expirationUpdate)
timestamp - The sent timestamp.group - The group information (or null if none).attachments - The attachments (or null if none).body - The message contents.endSession - Flag indicating whether this message should close a session.expiresInSeconds - Number of seconds in which the message should disappear after being seen.public static SignalServiceDataMessage.Builder newBuilder()
public long getTimestamp()
public org.whispersystems.libsignal.util.guava.Optional<java.util.List<SignalServiceAttachment>> getAttachments()
public org.whispersystems.libsignal.util.guava.Optional<java.lang.String> getBody()
public org.whispersystems.libsignal.util.guava.Optional<SignalServiceGroup> getGroupInfo()
public boolean isEndSession()
public boolean isExpirationUpdate()
public boolean isGroupUpdate()
public int getExpiresInSeconds()