Class MessageResponse (1.14.4)

public final class MessageResponse extends GeneratedMessageV3 implements MessageResponseOrBuilder

Response containing a list of messages. Upon delivering a MessageResponse to the client, the server:

  • Updates the stream's delivery cursor to one greater than the cursor of the last message in the list.
  • Subtracts the total number of bytes and messages from the tokens available to the server.

Protobuf type google.cloud.pubsublite.v1.MessageResponse

Static Fields

MESSAGES_FIELD_NUMBER

public static final int MESSAGES_FIELD_NUMBER
Field Value
Type Description
int

Static Methods

getDefaultInstance()

public static MessageResponse getDefaultInstance()
Returns
Type Description
MessageResponse

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

newBuilder()

public static MessageResponse.Builder newBuilder()
Returns
Type Description
MessageResponse.Builder

newBuilder(MessageResponse prototype)

public static MessageResponse.Builder newBuilder(MessageResponse prototype)
Parameter
Name Description
prototype MessageResponse
Returns
Type Description
MessageResponse.Builder

parseDelimitedFrom(InputStream input)

public static MessageResponse parseDelimitedFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
MessageResponse
Exceptions
Type Description
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static MessageResponse parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
MessageResponse
Exceptions
Type Description
IOException

parseFrom(byte[] data)

public static MessageResponse parseFrom(byte[] data)
Parameter
Name Description
data byte[]
Returns
Type Description
MessageResponse
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static MessageResponse parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data byte[]
extensionRegistry ExtensionRegistryLite
Returns
Type Description
MessageResponse
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data)

public static MessageResponse parseFrom(ByteString data)
Parameter
Name Description
data ByteString
Returns
Type Description
MessageResponse
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static MessageResponse parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteString
extensionRegistry ExtensionRegistryLite
Returns
Type Description
MessageResponse
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static MessageResponse parseFrom(CodedInputStream input)
Parameter
Name Description
input CodedInputStream
Returns
Type Description
MessageResponse
Exceptions
Type Description
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static MessageResponse parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
MessageResponse
Exceptions
Type Description
IOException

parseFrom(InputStream input)

public static MessageResponse parseFrom(InputStream input)
Parameter
Name Description
input InputStream
Returns
Type Description
MessageResponse
Exceptions
Type Description
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static MessageResponse parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
MessageResponse
Exceptions
Type Description
IOException

parseFrom(ByteBuffer data)

public static MessageResponse parseFrom(ByteBuffer data)
Parameter
Name Description
data ByteBuffer
Returns
Type Description
MessageResponse
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static MessageResponse parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
data ByteBuffer
extensionRegistry ExtensionRegistryLite
Returns
Type Description
MessageResponse
Exceptions
Type Description
InvalidProtocolBufferException

parser()

public static Parser<MessageResponse> parser()
Returns
Type Description
Parser<MessageResponse>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
Name Description
obj Object
Returns
Type Description
boolean
Overrides

getDefaultInstanceForType()

public MessageResponse getDefaultInstanceForType()
Returns
Type Description
MessageResponse

getMessages(int index)

public SequencedMessage getMessages(int index)

Messages from the topic partition.

repeated .google.cloud.pubsublite.v1.SequencedMessage messages = 1;

Parameter
Name Description
index int
Returns
Type Description
SequencedMessage

getMessagesCount()

public int getMessagesCount()

Messages from the topic partition.

repeated .google.cloud.pubsublite.v1.SequencedMessage messages = 1;

Returns
Type Description
int

getMessagesList()

public List<SequencedMessage> getMessagesList()

Messages from the topic partition.

repeated .google.cloud.pubsublite.v1.SequencedMessage messages = 1;

Returns
Type Description
List<SequencedMessage>

getMessagesOrBuilder(int index)

public SequencedMessageOrBuilder getMessagesOrBuilder(int index)

Messages from the topic partition.

repeated .google.cloud.pubsublite.v1.SequencedMessage messages = 1;

Parameter
Name Description
index int
Returns
Type Description
SequencedMessageOrBuilder

getMessagesOrBuilderList()

public List<? extends SequencedMessageOrBuilder> getMessagesOrBuilderList()

Messages from the topic partition.

repeated .google.cloud.pubsublite.v1.SequencedMessage messages = 1;

Returns
Type Description
List<? extends com.google.cloud.pubsublite.proto.SequencedMessageOrBuilder>

getParserForType()

public Parser<MessageResponse> getParserForType()
Returns
Type Description
Parser<MessageResponse>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
Type Description
int
Overrides

hashCode()

public int hashCode()
Returns
Type Description
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

newBuilderForType()

public MessageResponse.Builder newBuilderForType()
Returns
Type Description
MessageResponse.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected MessageResponse.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Name Description
parent BuilderParent
Returns
Type Description
MessageResponse.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Name Description
unused UnusedPrivateParameter
Returns
Type Description
Object
Overrides

toBuilder()

public MessageResponse.Builder toBuilder()
Returns
Type Description
MessageResponse.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
Name Description
output CodedOutputStream
Overrides
Exceptions
Type Description
IOException