Class MessageResponse (1.4.12)

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
TypeDescription
int

Static Methods

getDefaultInstance()

public static MessageResponse getDefaultInstance()
Returns
TypeDescription
MessageResponse

getDescriptor()

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

newBuilder()

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

newBuilder(MessageResponse prototype)

public static MessageResponse.Builder newBuilder(MessageResponse prototype)
Parameter
NameDescription
prototypeMessageResponse
Returns
TypeDescription
MessageResponse.Builder

parseDelimitedFrom(InputStream input)

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

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

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

parseFrom(byte[] data)

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

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

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

parseFrom(ByteString data)

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

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

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

parseFrom(CodedInputStream input)

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

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

parseFrom(InputStream input)

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

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

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

parseFrom(ByteBuffer data)

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

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

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

parser()

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

Methods

equals(Object obj)

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

getDefaultInstanceForType()

public MessageResponse getDefaultInstanceForType()
Returns
TypeDescription
MessageResponse

getMessages(int index)

public SequencedMessage getMessages(int index)

Messages from the topic partition.

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

Parameter
NameDescription
indexint
Returns
TypeDescription
SequencedMessage

getMessagesCount()

public int getMessagesCount()

Messages from the topic partition.

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

Returns
TypeDescription
int

getMessagesList()

public List<SequencedMessage> getMessagesList()

Messages from the topic partition.

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

Returns
TypeDescription
List<SequencedMessage>

getMessagesOrBuilder(int index)

public SequencedMessageOrBuilder getMessagesOrBuilder(int index)

Messages from the topic partition.

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

Parameter
NameDescription
indexint
Returns
TypeDescription
SequencedMessageOrBuilder

getMessagesOrBuilderList()

public List<? extends SequencedMessageOrBuilder> getMessagesOrBuilderList()

Messages from the topic partition.

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

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

getParserForType()

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

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

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 MessageResponse.Builder newBuilderForType()
Returns
TypeDescription
MessageResponse.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

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

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

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

toBuilder()

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

writeTo(CodedOutputStream output)

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