public abstract static class PubsubClient.OutgoingMessage
extends java.lang.Object
implements java.io.Serializable
NOTE: This class is Serializable
only to support the PubsubTestClient
. Java
serialization is never used for non-test clients.
Constructor and Description |
---|
OutgoingMessage() |
Modifier and Type | Method and Description |
---|---|
abstract com.google.pubsub.v1.PubsubMessage |
getMessage()
Underlying Message.
|
abstract long |
getTimestampMsSinceEpoch()
Timestamp for element (ms since epoch).
|
static PubsubClient.OutgoingMessage |
of(com.google.pubsub.v1.PubsubMessage message,
long timestampMsSinceEpoch,
@Nullable java.lang.String recordId,
@Nullable java.lang.String topic) |
static PubsubClient.OutgoingMessage |
of(PubsubMessage message,
long timestampMsSinceEpoch,
@Nullable java.lang.String recordId,
@Nullable java.lang.String topic) |
abstract @Nullable java.lang.String |
recordId()
If using an id attribute, the record id to associate with this record's metadata so the
receiver can reject duplicates.
|
abstract @Nullable java.lang.String |
topic() |
public abstract com.google.pubsub.v1.PubsubMessage getMessage()
public abstract long getTimestampMsSinceEpoch()
public abstract @Nullable java.lang.String recordId()
public abstract @Nullable java.lang.String topic()
public static PubsubClient.OutgoingMessage of(com.google.pubsub.v1.PubsubMessage message, long timestampMsSinceEpoch, @Nullable java.lang.String recordId, @Nullable java.lang.String topic)
public static PubsubClient.OutgoingMessage of(PubsubMessage message, long timestampMsSinceEpoch, @Nullable java.lang.String recordId, @Nullable java.lang.String topic)