final class PubsubMessage extends GeneratedMessageV3 with PubsubMessageOrBuilder
A message that is published by publishers and consumed by subscribers. The message must contain either a non-empty data field or at least one attribute. Note that client libraries represent this object differently depending on the language. See the corresponding [client library documentation](https://cloud.google.com/pubsub/docs/reference/libraries) for more information. See [quotas and limits] (https://cloud.google.com/pubsub/quotas) for more information about message limits.
Protobuf type google.pubsub.v1.PubsubMessage
- Source
- PubsubMessage.java
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- PubsubMessage
- PubsubMessageOrBuilder
- GeneratedMessageV3
- Serializable
- AbstractMessage
- Message
- MessageOrBuilder
- AbstractMessageLite
- MessageLite
- MessageLiteOrBuilder
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- Protected
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def containsAttributes(key: String): Boolean
Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.
Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.
map<string, string> attributes = 2;
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(obj: AnyRef): Boolean
- Definition Classes
- PubsubMessage → AbstractMessage → Message → AnyRef → Any
- Annotations
- @Override()
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- def findInitializationErrors(): List[String]
- Definition Classes
- AbstractMessage → MessageOrBuilder
- def getAllFields(): Map[FieldDescriptor, AnyRef]
- Definition Classes
- GeneratedMessageV3 → MessageOrBuilder
- def getAttributesCount(): Int
Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.
Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.
map<string, string> attributes = 2;
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- def getAttributesMap(): Map[String, String]
Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.
Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.
map<string, string> attributes = 2;
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- def getAttributesOrDefault(key: String, defaultValue: String): String
Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.
Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.
map<string, string> attributes = 2;
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- def getAttributesOrThrow(key: String): String
Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.
Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.
map<string, string> attributes = 2;
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def getData(): ByteString
The message data field. If this field is empty, the message must contain at least one attribute.
The message data field. If this field is empty, the message must contain at least one attribute.
bytes data = 1;
- returns
The data.
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- def getDefaultInstanceForType(): PubsubMessage
- Definition Classes
- PubsubMessage → MessageOrBuilder → MessageLiteOrBuilder
- Annotations
- @Override()
- def getDescriptorForType(): Descriptor
- Definition Classes
- GeneratedMessageV3 → MessageOrBuilder
- def getField(arg0: FieldDescriptor): AnyRef
- Definition Classes
- GeneratedMessageV3 → MessageOrBuilder
- def getInitializationErrorString(): String
- Definition Classes
- AbstractMessage → MessageOrBuilder
- def getMessageId(): String
ID of this message, assigned by the server when the message is published. Guaranteed to be unique within the topic. This value may be read by a subscriber that receives a `PubsubMessage` via a `Pull` call or a push delivery. It must not be populated by the publisher in a `Publish` call.
ID of this message, assigned by the server when the message is published. Guaranteed to be unique within the topic. This value may be read by a subscriber that receives a `PubsubMessage` via a `Pull` call or a push delivery. It must not be populated by the publisher in a `Publish` call.
string message_id = 3;
- returns
The messageId.
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- def getMessageIdBytes(): ByteString
ID of this message, assigned by the server when the message is published. Guaranteed to be unique within the topic. This value may be read by a subscriber that receives a `PubsubMessage` via a `Pull` call or a push delivery. It must not be populated by the publisher in a `Publish` call.
ID of this message, assigned by the server when the message is published. Guaranteed to be unique within the topic. This value may be read by a subscriber that receives a `PubsubMessage` via a `Pull` call or a push delivery. It must not be populated by the publisher in a `Publish` call.
string message_id = 3;
- returns
The bytes for messageId.
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- def getOneofFieldDescriptor(arg0: OneofDescriptor): FieldDescriptor
- Definition Classes
- GeneratedMessageV3 → AbstractMessage → MessageOrBuilder
- def getOrderingKey(): String
If non-empty, identifies related messages for which publish order should be respected. If a `Subscription` has `enable_message_ordering` set to `true`, messages published with the same non-empty `ordering_key` value will be delivered to subscribers in the order in which they are received by the Pub/Sub system. All `PubsubMessage`s published in a given `PublishRequest` must specify the same `ordering_key` value.
If non-empty, identifies related messages for which publish order should be respected. If a `Subscription` has `enable_message_ordering` set to `true`, messages published with the same non-empty `ordering_key` value will be delivered to subscribers in the order in which they are received by the Pub/Sub system. All `PubsubMessage`s published in a given `PublishRequest` must specify the same `ordering_key` value.
string ordering_key = 5;
- returns
The orderingKey.
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- def getOrderingKeyBytes(): ByteString
If non-empty, identifies related messages for which publish order should be respected. If a `Subscription` has `enable_message_ordering` set to `true`, messages published with the same non-empty `ordering_key` value will be delivered to subscribers in the order in which they are received by the Pub/Sub system. All `PubsubMessage`s published in a given `PublishRequest` must specify the same `ordering_key` value.
If non-empty, identifies related messages for which publish order should be respected. If a `Subscription` has `enable_message_ordering` set to `true`, messages published with the same non-empty `ordering_key` value will be delivered to subscribers in the order in which they are received by the Pub/Sub system. All `PubsubMessage`s published in a given `PublishRequest` must specify the same `ordering_key` value.
string ordering_key = 5;
- returns
The bytes for orderingKey.
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- def getParserForType(): Parser[PubsubMessage]
- Definition Classes
- PubsubMessage → GeneratedMessageV3 → Message → MessageLite
- Annotations
- @Override()
- def getPublishTime(): Timestamp
The time at which the message was published, populated by the server when it receives the `Publish` call. It must not be populated by the publisher in a `Publish` call.
The time at which the message was published, populated by the server when it receives the `Publish` call. It must not be populated by the publisher in a `Publish` call.
.google.protobuf.Timestamp publish_time = 4;
- returns
The publishTime.
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- def getPublishTimeOrBuilder(): TimestampOrBuilder
The time at which the message was published, populated by the server when it receives the `Publish` call. It must not be populated by the publisher in a `Publish` call.
The time at which the message was published, populated by the server when it receives the `Publish` call. It must not be populated by the publisher in a `Publish` call.
.google.protobuf.Timestamp publish_time = 4;
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- def getRepeatedField(arg0: FieldDescriptor, arg1: Int): AnyRef
- Definition Classes
- GeneratedMessageV3 → MessageOrBuilder
- def getRepeatedFieldCount(arg0: FieldDescriptor): Int
- Definition Classes
- GeneratedMessageV3 → MessageOrBuilder
- def getSerializedSize(): Int
- Definition Classes
- PubsubMessage → GeneratedMessageV3 → AbstractMessage → MessageLite
- Annotations
- @Override()
- final def getUnknownFields(): UnknownFieldSet
- Definition Classes
- PubsubMessage → GeneratedMessageV3 → MessageOrBuilder
- Annotations
- @Override()
- def hasField(arg0: FieldDescriptor): Boolean
- Definition Classes
- GeneratedMessageV3 → MessageOrBuilder
- def hasOneof(arg0: OneofDescriptor): Boolean
- Definition Classes
- GeneratedMessageV3 → AbstractMessage → MessageOrBuilder
- def hasPublishTime(): Boolean
The time at which the message was published, populated by the server when it receives the `Publish` call. It must not be populated by the publisher in a `Publish` call.
The time at which the message was published, populated by the server when it receives the `Publish` call. It must not be populated by the publisher in a `Publish` call.
.google.protobuf.Timestamp publish_time = 4;
- returns
Whether the publishTime field is set.
- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override()
- def hashCode(): Int
- Definition Classes
- PubsubMessage → AbstractMessage → Message → AnyRef → Any
- Annotations
- @Override()
- def internalGetFieldAccessorTable(): FieldAccessorTable
- Attributes
- protected[v1]
- Definition Classes
- PubsubMessage → GeneratedMessageV3
- Annotations
- @Override()
- def internalGetMapField(number: Int): MapField
- Attributes
- protected[v1]
- Definition Classes
- PubsubMessage → GeneratedMessageV3
- Annotations
- @SuppressWarnings() @Override()
- final def isInitialized(): Boolean
- Definition Classes
- PubsubMessage → GeneratedMessageV3 → AbstractMessage → MessageLiteOrBuilder
- Annotations
- @Override()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def makeExtensionsImmutable(): Unit
- Attributes
- protected[protobuf]
- Definition Classes
- GeneratedMessageV3
- def mergeFromAndMakeImmutableInternal(arg0: CodedInputStream, arg1: ExtensionRegistryLite): Unit
- Attributes
- protected[protobuf]
- Definition Classes
- GeneratedMessageV3
- Annotations
- @throws(classOf[com.google.protobuf.InvalidProtocolBufferException])
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def newBuilderForType(parent: BuilderParent): Builder
- Attributes
- protected[v1]
- Definition Classes
- PubsubMessage → GeneratedMessageV3
- Annotations
- @Override()
- def newBuilderForType(): Builder
- Definition Classes
- PubsubMessage → Message → MessageLite
- Annotations
- @Override()
- def newBuilderForType(arg0: BuilderParent): Builder
- Attributes
- protected[protobuf]
- Definition Classes
- GeneratedMessageV3 → AbstractMessage
- def newInstance(unused: UnusedPrivateParameter): AnyRef
- Attributes
- protected[v1]
- Definition Classes
- PubsubMessage → GeneratedMessageV3
- Annotations
- @Override() @SuppressWarnings()
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def parseUnknownField(arg0: CodedInputStream, arg1: Builder, arg2: ExtensionRegistryLite, arg3: Int): Boolean
- Attributes
- protected[protobuf]
- Definition Classes
- GeneratedMessageV3
- Annotations
- @throws(classOf[java.io.IOException])
- def parseUnknownFieldProto3(arg0: CodedInputStream, arg1: Builder, arg2: ExtensionRegistryLite, arg3: Int): Boolean
- Attributes
- protected[protobuf]
- Definition Classes
- GeneratedMessageV3
- Annotations
- @throws(classOf[java.io.IOException])
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toBuilder(): Builder
- Definition Classes
- PubsubMessage → Message → MessageLite
- Annotations
- @Override()
- def toByteArray(): Array[Byte]
- Definition Classes
- AbstractMessageLite → MessageLite
- def toByteString(): ByteString
- Definition Classes
- AbstractMessageLite → MessageLite
- final def toString(): String
- Definition Classes
- AbstractMessage → Message → AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- def writeDelimitedTo(arg0: OutputStream): Unit
- Definition Classes
- AbstractMessageLite → MessageLite
- Annotations
- @throws(classOf[java.io.IOException])
- def writeReplace(): AnyRef
- Attributes
- protected[protobuf]
- Definition Classes
- GeneratedMessageV3
- Annotations
- @throws(classOf[java.io.ObjectStreamException])
- def writeTo(output: CodedOutputStream): Unit
- Definition Classes
- PubsubMessage → GeneratedMessageV3 → AbstractMessage → MessageLite
- Annotations
- @Override()
- def writeTo(arg0: OutputStream): Unit
- Definition Classes
- AbstractMessageLite → MessageLite
- Annotations
- @throws(classOf[java.io.IOException])
Deprecated Value Members
- def getAttributes(): Map[String, String]
Use
#getAttributesMap()
instead.Use
#getAttributesMap()
instead.- Definition Classes
- PubsubMessage → PubsubMessageOrBuilder
- Annotations
- @Override() @Deprecated
- Deprecated