public static final class InitialPublishRequest.Builder extends GeneratedMessage.Builder<InitialPublishRequest.Builder> implements InitialPublishRequestOrBuilderThe first request that must be sent on a newly-opened stream.
Protobuf type google.cloud.pubsublite.v1.InitialPublishRequest
Inheritance
java.lang.Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessage.Builder > InitialPublishRequest.BuilderImplements
InitialPublishRequestOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
build()
public InitialPublishRequest build()| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest |
|
buildPartial()
public InitialPublishRequest buildPartial()| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest |
|
clear()
public InitialPublishRequest.Builder clear()| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
|
clearClientId()
public InitialPublishRequest.Builder clearClientId()Unique identifier for a publisher client. If set, enables publish idempotency within a publisher client session.
The length of this field must be exactly 16 bytes long and should be populated with a 128 bit uuid, generated by standard uuid algorithms like uuid1 or uuid4. The same identifier should be reused following disconnections with retryable stream errors.
bytes client_id = 3;
| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
This builder for chaining. |
clearPartition()
public InitialPublishRequest.Builder clearPartition() The partition within the topic to which messages will be written.
Partitions are zero indexed, so partition must be in the range [0,
topic.num_partitions).
int64 partition = 2;
| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
This builder for chaining. |
clearTopic()
public InitialPublishRequest.Builder clearTopic()The topic to which messages will be written.
string topic = 1;
| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
This builder for chaining. |
getClientId()
public ByteString getClientId()Unique identifier for a publisher client. If set, enables publish idempotency within a publisher client session.
The length of this field must be exactly 16 bytes long and should be populated with a 128 bit uuid, generated by standard uuid algorithms like uuid1 or uuid4. The same identifier should be reused following disconnections with retryable stream errors.
bytes client_id = 3;
| Returns | |
|---|---|
| Type | Description |
ByteString |
The clientId. |
getDefaultInstanceForType()
public InitialPublishRequest getDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest |
|
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getPartition()
public long getPartition() The partition within the topic to which messages will be written.
Partitions are zero indexed, so partition must be in the range [0,
topic.num_partitions).
int64 partition = 2;
| Returns | |
|---|---|
| Type | Description |
long |
The partition. |
getTopic()
public String getTopic()The topic to which messages will be written.
string topic = 1;
| Returns | |
|---|---|
| Type | Description |
String |
The topic. |
getTopicBytes()
public ByteString getTopicBytes()The topic to which messages will be written.
string topic = 1;
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for topic. |
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
public final boolean isInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeFrom(InitialPublishRequest other)
public InitialPublishRequest.Builder mergeFrom(InitialPublishRequest other)| Parameter | |
|---|---|
| Name | Description |
other |
InitialPublishRequest |
| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public InitialPublishRequest.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
public InitialPublishRequest.Builder mergeFrom(Message other)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
|
setClientId(ByteString value)
public InitialPublishRequest.Builder setClientId(ByteString value)Unique identifier for a publisher client. If set, enables publish idempotency within a publisher client session.
The length of this field must be exactly 16 bytes long and should be populated with a 128 bit uuid, generated by standard uuid algorithms like uuid1 or uuid4. The same identifier should be reused following disconnections with retryable stream errors.
bytes client_id = 3;
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe clientId to set. |
| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
This builder for chaining. |
setPartition(long value)
public InitialPublishRequest.Builder setPartition(long value) The partition within the topic to which messages will be written.
Partitions are zero indexed, so partition must be in the range [0,
topic.num_partitions).
int64 partition = 2;
| Parameter | |
|---|---|
| Name | Description |
value |
longThe partition to set. |
| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
This builder for chaining. |
setTopic(String value)
public InitialPublishRequest.Builder setTopic(String value)The topic to which messages will be written.
string topic = 1;
| Parameter | |
|---|---|
| Name | Description |
value |
StringThe topic to set. |
| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
This builder for chaining. |
setTopicBytes(ByteString value)
public InitialPublishRequest.Builder setTopicBytes(ByteString value)The topic to which messages will be written.
string topic = 1;
| Parameter | |
|---|---|
| Name | Description |
value |
ByteStringThe bytes for topic to set. |
| Returns | |
|---|---|
| Type | Description |
InitialPublishRequest.Builder |
This builder for chaining. |