Class PublishRequest (1.120.3)

public final class PublishRequest extends GeneratedMessageV3 implements PublishRequestOrBuilder

Request for the Publish method.

Protobuf type google.pubsub.v1.PublishRequest

Static Fields

MESSAGES_FIELD_NUMBER

public static final int MESSAGES_FIELD_NUMBER
Field Value
TypeDescription
int

TOPIC_FIELD_NUMBER

public static final int TOPIC_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static PublishRequest getDefaultInstance()
Returns
TypeDescription
PublishRequest

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static PublishRequest.Builder newBuilder()
Returns
TypeDescription
PublishRequest.Builder

newBuilder(PublishRequest prototype)

public static PublishRequest.Builder newBuilder(PublishRequest prototype)
Parameter
NameDescription
prototypePublishRequest
Returns
TypeDescription
PublishRequest.Builder

parseDelimitedFrom(InputStream input)

public static PublishRequest parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static PublishRequest parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static PublishRequest parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static PublishRequest parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static PublishRequest parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static PublishRequest parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static PublishRequest parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static PublishRequest parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static PublishRequest parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static PublishRequest parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static PublishRequest parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static PublishRequest parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
PublishRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<PublishRequest> parser()
Returns
TypeDescription
Parser<PublishRequest>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getDefaultInstanceForType()

public PublishRequest getDefaultInstanceForType()
Returns
TypeDescription
PublishRequest

getMessages(int index)

public PubsubMessage getMessages(int index)

Required. The messages to publish.

repeated .google.pubsub.v1.PubsubMessage messages = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
indexint
Returns
TypeDescription
PubsubMessage

getMessagesCount()

public int getMessagesCount()

Required. The messages to publish.

repeated .google.pubsub.v1.PubsubMessage messages = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
int

getMessagesList()

public List<PubsubMessage> getMessagesList()

Required. The messages to publish.

repeated .google.pubsub.v1.PubsubMessage messages = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
List<PubsubMessage>

getMessagesOrBuilder(int index)

public PubsubMessageOrBuilder getMessagesOrBuilder(int index)

Required. The messages to publish.

repeated .google.pubsub.v1.PubsubMessage messages = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
indexint
Returns
TypeDescription
PubsubMessageOrBuilder

getMessagesOrBuilderList()

public List<? extends PubsubMessageOrBuilder> getMessagesOrBuilderList()

Required. The messages to publish.

repeated .google.pubsub.v1.PubsubMessage messages = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
List<? extends com.google.pubsub.v1.PubsubMessageOrBuilder>

getParserForType()

public Parser<PublishRequest> getParserForType()
Returns
TypeDescription
Parser<PublishRequest>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getTopic()

public String getTopic()

Required. The messages in the request will be published on this topic. Format is projects/{project}/topics/{topic}.

string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
TypeDescription
String

The topic.

getTopicBytes()

public ByteString getTopicBytes()

Required. The messages in the request will be published on this topic. Format is projects/{project}/topics/{topic}.

string topic = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
TypeDescription
ByteString

The bytes for topic.

getUnknownFields()

public final UnknownFieldSet getUnknownFields()
Returns
TypeDescription
UnknownFieldSet
Overrides

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public PublishRequest.Builder newBuilderForType()
Returns
TypeDescription
PublishRequest.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected PublishRequest.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
PublishRequest.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public PublishRequest.Builder toBuilder()
Returns
TypeDescription
PublishRequest.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides Exceptions
TypeDescription
IOException